Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Cannot Build Site when I remove the example Site Content ... #340

Closed
andyjenkins1 opened this issue May 10, 2020 · 4 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@andyjenkins1
Copy link

Describe the bug 描述你遇到的错误

A clear and concise description of what the bug is.

  1. I create a new folder on my laptop called test

  2. I initialise git for the folder test

  3. I add the Loveit Theme using the git submodule command

  4. I copy the contents of the example site (from the loveit theme directory) to the root of my test folder

  5. I add files to git with git add *

  6. I edit the config.toml file and comment out the theme directory setting (# themesDir = "../..")

  7. I check the site it working as expected with hugo serve --disableFastRender -D

  8. Everything looks great!.

  9. I make an initial commit with git.

  10. I add some of my own posts with the hugo new posts/testpost3.md command

  11. I can see these added to the site and all looks great locally and exit the hugo serve command.

  12. I now want to remove the example site posts that I copied over, so I can make the site my own, so i remove them from the /test/content/posts folder.

  13. I now try to start the local webserver again with hugo serve --disableFastRender -D. I now receive the following error

Error: Error building site: failed to render pages: render of "taxonomy" failed: "/Users/xxxxxx/MyDevStuff/test/themes/LoveIt/layouts/taxonomy/list.html:22:26": execute of template failed: template: taxonomy/list.html:22:26: executing "content" at <$.Paginate>: error calling Paginate: cannot convert type page.PagesGroup to Pages

Expected behavior 期待的行为

I would assume the local webserver would just work as normal, cant work out why removing the example posts would cause the issue!.

一段简短的对于你期待的行为的描述.

Screenshots 屏幕截图

N/A error message above

如果可以的话, 提供屏幕截图对解决问题很有帮助.

Build Environment 构建环境

  • OS: MacOS
  • Theme version/commit Latest Master (0.26)
  • Hugo version [e.g. 0.69.0]: 0.69.2/extended

Please use Hugo extended version.
请使用 Hugo extended 版本.

Preview Environment 预览环境

N/A

Additional Information 补充信息

N/A

@andyjenkins1 andyjenkins1 added the bug Something isn't working label May 10, 2020
@andyjenkins1
Copy link
Author

Quick Update -> If I follow the instructions on creating a basic site everything works fine!. I am guessing this is the correct approach for building a new site!. I just thought I could speed up that process by using the example site as a baseline - which has clearly not worked!! 😄 . I will close this issue based on going down the clean site route. However I wont delete as I am sure others will try and use the same approach as me thinking it might save time. It did not 🤦

@dillonzq
Copy link
Owner

@andyjenkins1 It is a bug about pagination.
natarajmb/charaka-hugo-theme#1
I thought it should be fixed by Hugo.

@andyjenkins1
Copy link
Author

Good spot @dillonzq thank you for sharing and good to know.

@dillonzq
Copy link
Owner

@andyjenkins1 Fixed in #350

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants