-
-
Notifications
You must be signed in to change notification settings - Fork 62
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
Fix support comprehensions inside functions when use strict_undefined… #399
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, this is sqla-tester setting up my work on behalf of zzzeek to try to get revision a52802b of this pull request into gerrit so we can run tests and reviews and stuff
New Gerrit review created for change a52802b: https://gerrit.sqlalchemy.org/c/sqlalchemy/mako/+/5322 |
thanks! |
I have added an test failing with version 1.3.3. I think the first issue is that an AST node representing a dictionnary comprehension hasn't a attribute But this doesn't fix the initial issue if I was just an user of the mako library and I have spent just a few hours trying to fix this issue. @cocolato can you take look at this? It's my first pull request. I have just seen that some things are failing, I will check that. |
I don't know why 2 of the checks above are failing. Should I add a |
pep8 failures you can address if you install pre commit:
|
also sure changeset file would be very helpful thanks! |
I have added a changeset file and the commit hooks but they don't report any failures. |
oh, this is a new thing in flake8 that we are disabling, sorry please add this diff --git a/setup.cfg b/setup.cfg
index f643d01..ecbbe0f 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -89,7 +89,7 @@ show-source = true
enable-extensions = G
# E203 is due to https://github.com/PyCQA/pycodestyle/issues/373
ignore =
- A003,
+ A003,A005
D,
E203,E305,E711,E712,E721,E722,E741,
N801,N802,N806,
|
… flag Fixes: sqlalchemy#398 The element or key and value used respectively in list/set comprehension and dictionary comprehension cannot be used to declare identifiers so no need to visit them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, this is sqla-tester setting up my work on behalf of zzzeek to try to get revision d708e27 of this pull request into gerrit so we can run tests and reviews and stuff
Patchset d708e27 added to existing Gerrit review https://gerrit.sqlalchemy.org/c/sqlalchemy/mako/+/5322 |
i dont get any ping when code is updated.....running again |
Gerrit review https://gerrit.sqlalchemy.org/c/sqlalchemy/mako/+/5322 has been merged. Congratulations! :) |
… flag
Fixes: #398
The element or key and value used respectively in list/set comprehension and dictionary comprehension cannot be used to declare identifiers so no need to visit them.