-
Notifications
You must be signed in to change notification settings - Fork 93
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
Report unsupport tags/filters more nicely #220
Comments
code to reproduce? |
I'll make a test that has a template with a tag that has not been implemented and it should yield the error above. In my case it was happening as the template I was using made use of a Actually it tells you when a filter is missing, but I don't think the same happens with tags. |
So at this location: https://github.com/bkiers/Liqp/blob/master/src/main/java/liqp/parser/v4/NodeVisitor.java#L103 Placing something like this:
Helped me report and find the tags that are missing. Maybe this isn't the ideal way to do this but something like this to help users determine if there are tags missing. I'm testing various Jekyll sites and there are a bunch of tags I'll have to implement so some better reporting would be good. |
@msangel What's the recommend way to create templates with custom filters and tags? |
The examples in readme are good. I can just suggest to use those variants
of apply method that also accept TemplateContext.
пт, 20 серп. 2021 о 21:23 Jason van Zyl ***@***.***> пише:
@msangel <https://github.com/msangel> What's the recommend way to create
templates with custom filters and tags?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#220 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAF4YK2TIMHDKXZ5LMBNAZTT52MTZANCNFSM5CQXPUQA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>
.
--
Надіслано з Gmail Mobile
|
I'll try and see if there is a test for registering a new tag and using it as this seems not to be working for me. I'll make a test quickly. |
Thanks for the commit! |
Right now it's really hard to tell during parsing when a tag/filter is not implemented. You just get a NPE:
Which is very hard to figure out what is not implemented.
The text was updated successfully, but these errors were encountered: