Skip to content

Upd base #1

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

Merged
merged 35 commits into from
Jul 25, 2019
Merged

Upd base #1

merged 35 commits into from
Jul 25, 2019

Conversation

arodiss
Copy link
Owner

@arodiss arodiss commented Jul 25, 2019

Issue #, if available:

Description of changes:

Merge Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your pull request.

  • I have read the CONTRIBUTING doc
  • I used the commit message format described in CONTRIBUTING
  • I have added tests that prove my fix is effective or that my feature works (if appropriate)
  • I have updated any necessary documentation (if appropriate)

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

knakad and others added 30 commits July 10, 2019 09:11
By running Pylint before any of the unit tests (and dependency
installs), the import-error check will always fail since the
dependencies are not yet installed.

We could move Pylint to a later stage to resolve this, but there's
value in this quick check occurring before the unit tests.

As a result, this Pylint check is being disabled.
* add functions, tests and doc for CodeCommit
Note that this commit also raises ValueErrors in situations that would
previously have returned None.

Per PEP8: Be consistent in return statements. Either all return
statements in a function should return an expression, or none of them
should. If any return statement returns an expression, any return
statements where no value is returned should explicitly state this as
return None, and an explicit return statement should be present at the
end of the function (if reachable).
Note that this commit will also enable simplifiable-if-statement, as
there are no code changes needed for it.
The logic behind this rule is to improve readability by defining all
the attributes of a class inside the init function, even if it simply
sets them to None.
Per PEP8:
Imports should be grouped in the following order:
1- Standard library imports.
2- Related third party imports.
3- Local application/library specific imports.
* change: enable wrong-import-order Pylint check

Per PEP8:
Imports should be grouped in the following order:
1- Standard library imports.
2- Related third party imports.
3- Local application/library specific imports.
* change: enable consider-using-in Pylint check
* change: enable too-many-public-methods Pylint check

This is a useful check to have, but is a lot of work to retroactively
enforce.
Enabling it while ignoring the single violation allows the validation
to run for future code.
This commit will add an exclusion for all auto-generated files.

I chose to ignore the single violation, because the alternative is
confusingly convoluted:
`(hasattr(obj, '__getitem__') if hasattr(obj, '__iter__')
else isinstance(obj, str))`
The check recommendations are only valid for packages that exclusively
support Python 3. The changes cannot be made in Python 2.
The TODO was updated to clarify this.
This commit will format all existing docstring to follow Google
style: https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html
This commit will also add docstring placeholders to any class or method
previously missing it.

An ideal approach would be to take the time to include meaningful
docstrings in every file. However, since that is not a task that will
be prioritized, I've declared docstring bankruptcy on this package, in
order to enforce docstring on all future code changes to this package.
[pr-827][followups] Improve documentation of some functions.
Also some unit test fixes. See comments from marcio in
#827
@arodiss arodiss merged commit d7d33c4 into arodiss:master Jul 25, 2019
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

Successfully merging this pull request may close these issues.

9 participants