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

Missing small but important logging information when using watch #3696

Closed
axi opened this Issue Jul 13, 2017 · 4 comments

Comments

Projects
None yet
5 participants
@axi

axi commented Jul 13, 2017

I had problems locating which file was throwing an error:

Using hugo -w mode and -verboseLog, the following logging appears on log file:

INFO 2017/07/13 14:14:01 Using config file:
INFO 2017/07/13 14:14:01 /var/www/html/hugo/static/ is the only static directory available to sync from
INFO 2017/07/13 14:14:01 syncing static files to /var/www/html/hugo/public/
LOG: 2017/07/13 14:14:01 Started building sites ...
ERROR 2017/07/13 14:14:04 unable to read frontmatter at filepos 364: EOF

HERE HUGO FINALLY CRASH AND IS BEING RESTARTED BY A CRON JOB

INFO 2017/07/13 14:15:14 Using config file:
INFO 2017/07/13 14:15:14 /var/www/html/hugo/static/ is the only static directory available to sync from
INFO 2017/07/13 14:15:14 syncing static files to /var/www/html/hugo/public/
LOG: 2017/07/13 14:15:14 Started building sites ...
ERROR 2017/07/13 14:15:16 unable to read frontmatter at filepos 364: EOF

When I use start manually hugo (without -w mode), I also get the same error but it's finally followed by a very useful information in the console, the file which causes the error ;-)

Started building sites ...
ERROR 2017/07/13 14:31:54 unable to read frontmatter at filepos 364: EOF
Error: Error building site: Errors reading pages: Error: unable to read frontmatter at filepos 364: EOF for actualitedanslereseauboyeratoursle26aout2016-tours-37000-182528.md

HERE HUGO FINALLY CRASH BUT I DONT CARE, I KNOW WHERE TO SEARCH

should be very nice if logging could log the file name even in watch mode.

@bep bep added the Enhancement label Jul 13, 2017

@bep bep added this to the v0.26 milestone Jul 13, 2017

@bep

This comment has been minimized.

Member

bep commented Jul 13, 2017

I haven't noticed, but thanks a lot for the report -- this we should fix.

@bep bep added Bug and removed Enhancement labels Jul 13, 2017

@bep bep modified the milestones: v0.26, v0.27 Aug 6, 2017

@bep bep modified the milestones: v0.27, v0.28 Sep 7, 2017

@bep bep modified the milestones: v0.28, v0.29, v0.30 Sep 21, 2017

@bep bep added the Hacktoberfest label Sep 28, 2017

@GregorioMartinez

This comment has been minimized.

Contributor

GregorioMartinez commented Oct 3, 2017

I'll have a look at this one.

@ItsPugle

This comment has been minimized.

ItsPugle commented Oct 16, 2017

@bep How come this keeps getting pushed back through releases?

@bep bep modified the milestones: v0.31, v0.32 Oct 30, 2017

@bep bep modified the milestones: v0.32, v0.33 Dec 16, 2017

@bep bep modified the milestones: v0.33, v0.34 Jan 11, 2018

@bep bep modified the milestones: v0.34, v0.35, v0.36 Jan 22, 2018

@lobopraveen

This comment has been minimized.

lobopraveen commented Jan 27, 2018

v0.34 does NOT show the file name that caused the error. verbose, verboseLog, w .... none of the options show the log as shown in @axi's original comment above.

I had to binary chop to get to the files. I see someone has submitted a pr #3970 already.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment