-
Notifications
You must be signed in to change notification settings - Fork 18
Add pylint support to travis. #16
base: master
Are you sure you want to change the base?
Conversation
Initial .pylint rc generated via `pylint --generate-rc`. Default rcfile updated with: - reports turned off (just show the errors/warnings) - ignore some generated files (proto, parsetab) - 2 spaces instead of 4 - PascalCaseMethodNames Fixes: Issue #11
We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for the commit author(s). If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google. |
@@ -89,6 +89,9 @@ def __init__(self, name): | |||
def __eq__(self, other): | |||
return NamedObject.__eq__(self, other) and self.params == other.params | |||
|
|||
def Resolve(self, env, resolved_params): | |||
raise NotImplementedError('Resolved() is not needed: ' + self.name) | |||
|
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.
Why is it necessary while NapeObject.Resolve() exists?
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.
It's an quirk of how pylint works. Pylint sees that NameObject.Resolve just does a raise NotImplementedError
, so pylint considers that method to be abstract. Then it doesn't see an overrdie in the child class, so it throws an unimplemented abstract method warning.
Another option would be to just disable the warning in this file
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.
What about:
if True:
raise NotImplementedError('Resolved() is not needed: ' + self.name)
in base class? Would "if True" do some trick?
Initial .pylint rc generated via
pylint --generate-rc
. Defaultrcfile updated with:
Fixes: Issue #11