hugo/docs/content/en/news/0.50-relnotes/index.md

20 KiB
Raw Blame History


date: 2018-10-29 title: "Hugo 0.50: Errors so Good, Youll Want to Fail!" description: "Errors with full filename and line and column number, shown in browser. And improved Fast Render Mode …" categories: ["Releases"]

Hugo 0.50 brings greatly improved error messages, and we now also show them in the browser. Having error messages with filename, line- and column number greatly simplify troubleshooting. Many editors (like VS Code) even let you click and navigate directly to the problematic line. If your editor requires a different log format, you can set it via the HUGO_FILE_LOG_FORMAT OS environment variable:

env HUGO_FILE_LOG_FORMAT="\":file::line::col\"" hugo server

But this release isn't all about error handling. Getting line- and column number into "every" error also meant that we had to consolidate and simplify some code paths, which, as a nice side effect, made Hugo a little bit faster. Benchmarks show it running about 5% faster and consume about 8% less memory.

Also, we have now implemented "render on demand" in Hugo's Fast Render Mode (default when running hugo server). This means that you should now always see updated content when navigating around the site after a change.

This release represents 88 contributions by 14 contributors to the main Hugo code base. @bep leads the Hugo development with a significant amount of contributions, but also a big shoutout to @moorereason, @anthonyfok, and @GregorioMartinez for their ongoing contributions.

And a big thanks to @digitalcraftsman and @onedrawingperday for their relentless work on keeping the themes site in pristine condition and to @kaushalmodi for his great work on the documentation site.

Many have also been busy writing and fixing the documentation in hugoDocs, which has received 14 contributions by 9 contributors. A special thanks to @bep, @NotWoods, @Nick-Rivera, and @tomanistor for their work on the documentation site.

Hugo now has:

Notes

  • You should not get stale content in Fast Render Mode anymore.
  • Errors will now show up in the browser by default, turn it off by running hugo server --disableBrowserError
  • jsonify will now produce pretty/indented output

Enhancements

Templates

Core

Other

Fixes

Templates

Core

Other