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

Cannot build on latest hugo #395

Closed
1ridic opened this issue Nov 28, 2023 · 6 comments
Closed

Cannot build on latest hugo #395

1ridic opened this issue Nov 28, 2023 · 6 comments

Comments

@1ridic
Copy link

1ridic commented Nov 28, 2023

Start building sites … 
hugo v0.120.1+extended linux/amd64 BuildDate=unknown

ERROR render of "term" failed: template: _internal/_default/rss.xml:3:9: executing "_internal/_default/rss.xml" at <site>: can't evaluate field email in type string
ERROR render of "section" failed: template: _internal/_default/rss.xml:3:9: executing "_internal/_default/rss.xml" at <site>: can't evaluate field email in type string
ERROR render of "taxonomy" failed: template: _internal/_default/rss.xml:3:9: executing "_internal/_default/rss.xml" at <site>: can't evaluate field email in type string
Built in 67 ms
Error: error building site: render: failed to render pages: render of "home" failed: template: _internal/_default/rss.xml:3:9: executing "_internal/_default/rss.xml" at <site>: can't evaluate field email in type string

ref: https://discourse.gohugo.io/t/render-of-section-failed-cannot-find-the-template-that-has-the-error/46883

@ryanfox1985
Copy link
Contributor

it works fine in my end:

version: hugo v0.121.2+extended linux/amd64
> hugo server
Watching for changes in /home/guillermo/workspace/hugo-universal-theme/{archetypes,exampleSite,i18n,layouts,package.json,static}
Watching for config changes in /home/guillermo/workspace/hugo-universal-theme/exampleSite/config.toml
Start building sites … 
hugo v0.121.2+extended linux/amd64 BuildDate=unknown


                   | EN   
-------------------+------
  Pages            |  43  
  Paginator pages  |   0  
  Non-page files   |   0  
  Static files     | 105  
  Processed images |   0  
  Aliases          |  17  
  Sitemaps         |   1  
  Cleaned          |   0  

Built in 70 ms
Environment: "development"
Serving pages from memory
Running in Fast Render Mode. For full rebuilds on change: hugo server --disableFastRender
Web Server is available at http://localhost:1313/hugo-universal-theme/ (bind address 127.0.0.1) 
Press Ctrl+C to stop

@al3xandru
Copy link

This is with a clean clone:

WARN  calling IsSet with unsupported type "invalid" (<nil>) will always return false.
ERROR render of "page" failed: "~/themes/universal/layouts/_default/single.html:35:65": execute of template failed: template: _default/single.html:35:65: executing "_default/single.html" at <.Site.Params.date_format>: invalid value; expected string
ERROR render of "section" failed: "~/themes/universal/layouts/_default/list.html:59:75": execute of template failed: template: _default/list.html:59:75: executing "_default/list.html" at <.Site.Params.date_format>: invalid value; expected string
ERROR render: failed to render pages: render of "page" failed: "~/themes/universal/layouts/_default/single.html:35:65": execute of template failed: template: _default/single.html:35:65: executing "_default/single.html" at <.Site.Params.date_format>: invalid value; expected string
Rebuilt in 51 ms

@ryanfox1985
Copy link
Contributor

still not reproduccing the error:

image

@matthewcornell
Copy link

matthewcornell commented Aug 20, 2024

Following @ryanfox1985 steps, I get a different error:

ERROR deprecated: .Site.DisqusShortname was deprecated in Hugo v0.120.0 and will be removed in Hugo 0.133.0. Use .Site.Config.Services.Disqus.Shortname instead.

cd ~/IdeaProjects/
git clone https://github.com/devcows/hugo-universal-theme.git
cd hugo-universal-theme
cd exampleSite
hugo serve
Watching for changes in /Users/cornell/IdeaProjects/hugo-universal-theme/{archetypes,exampleSite,i18n,layouts,package.json,static}
Watching for config changes in /Users/cornell/IdeaProjects/hugo-universal-theme/exampleSite/config.toml
Start building sites … 
hugo v0.132.0+extended darwin/arm64 BuildDate=2024-08-12T15:21:36Z VendorInfo=brew

ERROR deprecated: .Site.DisqusShortname was deprecated in Hugo v0.120.0 and will be removed in Hugo 0.133.0. Use .Site.Config.Services.Disqus.Shortname instead.
Built in 87 ms
Error: error building site: logged 1 error(s)

I worked around it by replacing the two occurrences I found with the suggestion:

image

@Magneticdud
Copy link

PR #406 fixes the latest error due to that disqus deprecation, which happened one version earlier than what the message says

hopefully it can be merged soon

meanwhile, for a quick fix, copy those files from the PR in /layout to override the ones in the theme

@ryanfox1985
Copy link
Contributor

closed by #406 , thanks @Magneticdud

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants