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

Fix deprecation warning #364

Closed
wants to merge 1 commit into from

Conversation

deining
Copy link
Contributor

@deining deining commented Apr 1, 2024

When previewing the example site with hugo v0.124.1, a warning is shown:

WARN  The author key in site configuration is deprecated. Use params.author.name instead.

This PR fixes this warning.

@Vimux
Copy link
Owner

Vimux commented Apr 3, 2024

This PR fixes this warning.

This is a breaking change as it will require manual action by users of existing sites if they want to update the theme. It will break our demo site as well.

Preview

@deining
Copy link
Contributor Author

deining commented Apr 3, 2024

This PR fixes this warning.
It will break our demo site as well.

Where does the site break?

This is a breaking change as it will require manual action by users of existing sites if they want to update the theme.

Feel free to close this PR if you don't like it or you think it comes in prematurely.

@Vimux
Copy link
Owner

Vimux commented Apr 9, 2024

Where does the site break?

I gave a link to the preview page where the problem is pretty clear.

pr-authorbox-problem

Feel free to close this PR if you don't like it or you think it comes in prematurely.

One thing I can say for sure is that we do not break users' sites without a really good reason, and especially without a commit properly marked as BREAKING.


Regarding the Hugo warning. My concern is how Hugo will deprecate this thing (as well as .Site.IsServer). Will we be able to use .Site.Author as the default after this? Will it throw an error when called from templates for newer versions? Let's just wait and fix it once, instead of guessing how exactly things will break in Hugo this time. I'm definitely not a fan of releasing patch after patch after patch. Who knows, maybe a real miracle will happen and we will be able to avoid breaking changes. Closed for now.

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

Successfully merging this pull request may close these issues.

2 participants