-
-
Notifications
You must be signed in to change notification settings - Fork 84
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
[BUG] [Linter] Linter fails with D018 on url parameter with name = "action" #755
Comments
I've a branch adding this issue to the tests: danigm@016b7c9 I've been trying to improve the regex, but I think it's not easy to detect this condition with just a regular expression... |
Thanks for those tests, I'll update the regex to make them pass. The regex is not foolproof, but will pass the tests, which is what we need :) One day all the rules should be converted to python and use the template and attribute parser packages for finding things. Wish someone from ruff would do it 😀 |
# [1.33.0](v1.32.1...v1.33.0) (2023-09-18) ### Bug Fixes * **formatter:** fixed extra breaks added around html tags inside template tags ([6091ffb](6091ffb)), closes [#742](#742) * **formatter:** fixed extra indend in script tags ([9d04d51](9d04d51)), closes [#733](#733) * **formatter:** fixed formatting on functions that used python keywords as the param name ([183a7c0](183a7c0)), closes [#756](#756) * **h033:** fix rull to not match data-action ([f6881e0](f6881e0)) * **linter:** fixed false positive on DJ018 ([78d81dc](78d81dc)), closes [#755](#755) ### Features * **formatter:** added support for nunjucks async loop tags ([5a32bb3](5a32bb3))
🎉 This issue has been resolved in version 1.33.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
System Info
python --version
): python 3.11.5djlint --version
): 1.32.1Issue
The Linter complains with an error D018 1:0 (Django) Internal links should use the {% url ... %} pattern. if a form has a django url with a parameter named "action".
How To Reproduce
Lint the following file:
Contents of .djlintrc/pyproject.toml [tool.djlint]
The text was updated successfully, but these errors were encountered: