Skip to content
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

merge and generalize lint rules #70

Open
willkg opened this issue Oct 2, 2015 · 0 comments
Open

merge and generalize lint rules #70

willkg opened this issue Oct 2, 2015 · 0 comments

Comments

@willkg
Copy link
Member

willkg commented Oct 2, 2015

The linter is kind of a mess right now. Issues:

  1. We have "lint rules" and "template lint rules", but we should really have "rules for id strings" and "rules for translated strings". In other words, one file with all the rules in them and they're all of type LintRule. That'll reduce a ton of repeated code.
  2. Lint rules do goofy things to make sure they only look at strings that apply to them. For example, some lint rules only apply to strings with python-format variables. Right now, we do goofy things at the beginning to handle that. We should do something better. Maybe call the lint rule with more context so it's easier for it to figure out whether it should check things?
  3. The documentation for lint rules is split between the docs and the code and it's almost certainly out of sync. We need a better way to deal with that. Maybe document it in the code and extract it with autodoc?
  4. We should have better registration infrastructure for lint rules. Right now it's pretty hard-coded-esque and not plugin-friendly.
@willkg willkg modified the milestone: 0.8 Nov 5, 2016
@willkg willkg modified the milestones: v0.8: fix the parsing pipeline, v0.9 fix the parsing pipeline Jan 4, 2017
@willkg willkg removed this from the v0.10 clean up project milestone May 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant