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

min_version is treated as a float, thus can't have two dots like 0.18.1 #3025

Closed
anthonyfok opened this issue Feb 10, 2017 · 2 comments
Closed
Assignees
Milestone

Comments

@anthonyfok
Copy link
Member

anthonyfok commented Feb 10, 2017

Perhaps a bug, and perhaps not a bug:

After building a local copy of themes.gohugo.io using spf13/hugoThemeSiteScript,
running hugo server -s hugoThemeSite/themeSite fails to start the server due to the
following fatal error:

ERROR: page.go:1309: Error parsing page meta data for startbootstrap-clean-blog.md
ERROR: page.go:1310: (15, 15): cannot have two dots in one float
ERROR: page.go:683: (15, 15): cannot have two dots in one float

It turns out that the author of the said theme has set the min_version in his theme.toml to 0.18.1, but min_version is currently treated as a float number in hugo, and thus can't have two or more "decimal points".

I have sent a pull request to change 0.18.1 to 0.18 at humboldtux/startbootstrap-clean-blog#26

Though I wonder if we should change min_version to read a string (so 0.18.1 would work) in some future version, or if we should just document the current behaviour?

@moorereason
Copy link
Contributor

We should start using https://github.com/Masterminds/semver.

@bep bep added this to the v0.20 milestone Feb 28, 2017
@bep bep self-assigned this Mar 1, 2017
@bep bep closed this as completed in 3669015 Mar 1, 2017
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 26, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants