You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems that parsing local links is a bit too greedy: A link [Grammar: VarDef](src/VarDef.g4) in the Markdown sources to an existing file VarDef.g4 in the local subfolder src/ is mistakenly(?) treated as link to a Markdown file and on rendering it gives an error because there's no suitable template for it.
(theme: 5.23.0, hugo: 0.120.0)
That said, I'm incredibly grateful for the portable linking implementation (c836962) and the improved warnings (8b0214e)! This has already helped me to find quite a lot of hidden bugs :)
The text was updated successfully, but these errors were encountered:
This is the line with the warnf statement. It's explicitly just a warning to avoid build errors. Did you reconfigure Hugo's error handling in your config.toml.
I will relax the condition to ignore links if they are local and contain any suffix
McShelby
changed the title
theme 5.23.0 too greedy when parsing for local markdown links
links: ignore local markdown links linking to files with extension
Oct 30, 2023
You are right, I have configured Hugo to consider warnings as errors.
On the other hand, the warning is coming from the Relearn theme because no matching template could be found for the linked file. I think the file (an ANTLR grammar) was incorrectly considered and treated as a local Markdown file?
It seems that parsing local links is a bit too greedy: A link
[Grammar: VarDef](src/VarDef.g4)
in the Markdown sources to an existing fileVarDef.g4
in the local subfoldersrc/
is mistakenly(?) treated as link to a Markdown file and on rendering it gives an error because there's no suitable template for it.(theme: 5.23.0, hugo: 0.120.0)
That said, I'm incredibly grateful for the portable linking implementation (c836962) and the improved warnings (8b0214e)! This has already helped me to find quite a lot of hidden bugs :)
The text was updated successfully, but these errors were encountered: