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
new linter: do not use db_column in model fields #736
Labels
€ 50 bounty
See bounty-program milestone
Milestone
Comments
atodorov
added
€ 50 bounty
See bounty-program milestone
and removed
PyConBalkan
help wanted
labels
Apr 30, 2020
brymut
added a commit
to brymut/Kiwi
that referenced
this issue
Sep 1, 2020
…b_column argument in model field definition.
brymut
added a commit
to brymut/Kiwi
that referenced
this issue
Sep 2, 2020
…b_column argument in model field definition.
brymut
added a commit
to brymut/Kiwi
that referenced
this issue
Sep 2, 2020
…b_column argument in model field definition.
atodorov
pushed a commit
that referenced
this issue
Sep 2, 2020
… argument in model field definition.
@atodorov submitted new expense on https://opencollective.com/kiwitcms/expenses/24577 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
db_column
argument in model field definitions is a legacy leftover and in many cases the column name in the DB is a bit different from the model field name. All of this has been fixed but it took lots of effort to do so.Kiwi TCMS needs a custom kiwi_lint/ checker which will discover all of these issues (if we forgot to fix some) and prevent them from happening again.
Definition of Done:
kiwi_lint/
which implements the necessary pylint machinerydb_column
parameter name is rather unique and we probably don't use it for anything not related to declaring Django models. It should be sufficient to raise a warning when a function call contains a parameter with the name db_column.Here's me explaining how to write pylint plugins:
This issue is part of Kiwi TCMS open source bounty program. For more information see the link(s) in bounty-program milestone
The text was updated successfully, but these errors were encountered: