-
Notifications
You must be signed in to change notification settings - Fork 669
chore: convert to using relative imports #1728
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
Draft
JohnVillalovos
wants to merge
2
commits into
main
Choose a base branch
from
jlvillal/relative_imports
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Codecov Report
@@ Coverage Diff @@
## main #1728 +/- ##
=======================================
Coverage 92.02% 92.03%
=======================================
Files 76 76
Lines 4790 4793 +3
=======================================
+ Hits 4408 4411 +3
Misses 382 382
Flags with carried forward coverage won't be shown. Click here to find out more.
|
a9cf620
to
45f3959
Compare
45f3959
to
834677e
Compare
Note 834677e is only a rebase with no functional changes. Had conflicts after another PR merged. Will work on fixing things in regards to comments later on today most likely. |
c2dca37
to
9afb42f
Compare
7da5ac0
to
c873c92
Compare
c873c92
to
17ac7c1
Compare
It was confusing having __version__.py as we were importing the __version__ variable from __version__.py into the top-level namespace while also having __version__.py. So depending where we were in the import chain __version__ could refer to the module __version__.py or it could refer to the variable __version__
17ac7c1
to
89981c6
Compare
Switch to using relative imports to ensure that we are importing from within our library. Also use the form: from foo import bar as bar When we want to signify that we want the import to be re-exported. https://mypy.readthedocs.io/en/stable/command_line.html#cmdoption-mypy-no-implicit-reexport
89981c6
to
6b3e7c0
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
First commit renames
gitlab/__version__.py
togitlab.version.py
to minimize confusion.Switch to using relative imports to ensure that we are importing from
within our library.
Also use the form:
from foo import bar as bar
When we want to signify that we want the import to be re-exported.
https://mypy.readthedocs.io/en/stable/command_line.html#cmdoption-mypy-no-implicit-reexport