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

"page" faile #616

Open
jianguo888 opened this issue Aug 3, 2021 · 9 comments
Open

"page" faile #616

jianguo888 opened this issue Aug 3, 2021 · 9 comments
Labels
bug Something isn't working

Comments

@jianguo888
Copy link

ERROR 2021/08/03 22:04:26 render of "page" failed: execute of template failed: t
emplate: posts/single.html:92:124: executing "content" at <partial "function/con
tent.html">: error calling partial: "D:\2021workspace\hugo\blog\layouts\partials
\function\content.html:15:15": execute of template failed: template: partials/fu
nction/content.html:15:15: executing "partials/function/content.html" at <partia
l "function/checkbox.html" $content>: error calling partial: partial that return
s a value needs a non-zero argument.

@jianguo888 jianguo888 added the bug Something isn't working label Aug 3, 2021
@simpleKalvin
Copy link

我也遇到这个情况,麻烦作者解决,辛苦了,十分感谢

@songtianlun
Copy link

M1 Macbook 下报同样的错,如果第一篇文章 draft 为 true 则不报错:

以下是我的软件版本,使用 git submodule add https://github.com/dillonzq/LoveIt.git themes/LoveIt 导入主题并配置。

songtianlun@Frytea-MacBook-Air quickstart % go version
go version go1.16.3 darwin/amd64
songtianlun@Frytea-MacBook-Air quickstart % hugo version
hugo v0.82.0+extended darwin/arm64 BuildDate=unknown

复现方法:

$ hugo new site quickstart
$ cd quickstart
$ git init
$ git submodule add https://github.com/dillonzq/LoveIt.git themes/LoveIt
# 将 config.toml 替换为 https://hugoloveit.com/zh-cn/theme-documentation-basics/ 给出的基本配置
$ hugo new posts/first_post.md
# draft 改为 false
$ hugo serve
# 报错

$ hugo serve
Start building sites …
WARN 2021/09/23 09:09:59

Current environment is "development". The "comment system", "CDN" and "fingerprint" will be disabled.
当前运行环境是 "development". "评论系统", "CDN" 和 "fingerprint" 不会启用.

Built in 46 ms
Error: Error building site: failed to render pages: render of "page" failed: execute of template failed: template: posts/single.html:92:124: executing "content" at <partial "function/content.html">: error calling partial: "/Users/songtianlun/Dev/quickstart/themes/LoveIt/layouts/partials/function/content.html:15:15": execute of template failed: template: partials/function/content.html:15:15: executing "partials/function/content.html" at <partial "function/checkbox.html" $content>: error calling partial: partial that returns a value needs a non-zero argument.

@FushuWang
Copy link

是hugo版本的问题,我使用hugo最新版本0.88的会报这个错误。 我将版本回退到了0.69.2,再启动server就可以了。估计是没有适配Hugo最新版本吧

@jianguo888
Copy link
Author

jianguo888 commented Oct 26, 2021 via email

@FushuWang
Copy link

谢谢,如何锁定版本

------------------ 原始邮件 ------------------ 发件人: "dillonzq/LoveIt" @.>; 发送时间: 2021年10月26日(星期二) 晚上7:01 @.>; @.@.>; 主题: Re: [dillonzq/LoveIt] "page" faile (#616) 是hugo版本的问题,我使用hugo最新版本0.88的会报这个错误。 我将版本回退到了0.69.2,再启动server就可以了。估计是没有适配Hugo最新版本吧 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

锁定啥版本?

@jianguo888
Copy link
Author

jianguo888 commented Oct 26, 2021 via email

@FushuWang
Copy link

将hugo版本回退到你说的这个版本

------------------ 原始邮件 ------------------ 发件人: "dillonzq/LoveIt" @.>; 发送时间: 2021年10月26日(星期二) 晚上7:15 @.>; @.@.>; 主题: Re: [dillonzq/LoveIt] "page" faile (#616) 谢谢,如何锁定版本 … ------------------ 原始邮件 ------------------ 发件人: "dillonzq/LoveIt" @.>; 发送时间: 2021年10月26日(星期二) 晚上7:01 @.>; @.@.>; 主题: Re: [dillonzq/LoveIt] "page" faile (#616) 是hugo版本的问题,我使用hugo最新版本0.88的会报这个错误。 我将版本回退到了0.69.2,再启动server就可以了。估计是没有适配Hugo最新版本吧 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. 锁定啥版本? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

去release下载对应版本的包就可以,你还可以继续试试看看最高兼容到哪个版本。

@jianguo888
Copy link
Author

jianguo888 commented Oct 26, 2021 via email

@FushuWang
Copy link

好的,谢谢你的耐心解答

------------------ 原始邮件 ------------------ 发件人: "dillonzq/LoveIt" @.>; 发送时间: 2021年10月26日(星期二) 晚上7:35 @.>; @.@.>; 主题: Re: [dillonzq/LoveIt] "page" faile (#616) 将hugo版本回退到你说的这个版本 … ------------------ 原始邮件 ------------------ 发件人: "dillonzq/LoveIt" @.>; 发送时间: 2021年10月26日(星期二) 晚上7:15 @.>; @.@.>; 主题: Re: [dillonzq/LoveIt] "page" faile (#616) 谢谢,如何锁定版本 … ------------------ 原始邮件 ------------------ 发件人: "dillonzq/LoveIt" @.>; 发送时间: 2021年10月26日(星期二) 晚上7:01 @.>; @.@.>; 主题: Re: [dillonzq/LoveIt] "page" faile (#616) 是hugo版本的问题,我使用hugo最新版本0.88的会报这个错误。 我将版本回退到了0.69.2,再启动server就可以了。估计是没有适配Hugo最新版本吧 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. 锁定啥版本? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. 去release下载对应版本的包就可以,你还可以继续试试看看最高兼容到哪个版本。 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

#518 这个issues里有提及最高到0.74

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

4 participants