-
-
Notifications
You must be signed in to change notification settings - Fork 954
Add remaining types to remote.py #1232
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
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.
Thanks a lot for powering through this!
What I don't understand just yet is why the indirection via git.compat.typing
isn't required anymore. And I thought it was required to handle the difference between python versions, some requiring typing_extension
, some coming with typing
out of the box.
Of course it's great that this doesn't seem to be necessary anymore, but it makes me wonder what changed.
Thanks a lot.
Differentiating between python versions is still there, but it's needed in multiple files (any time typing_extensions is used eg. Literal or Final).
So it is included in git.types, where we already have logic for different python version imports. It got copied across in the last PR, but the original only deleted here.
Thanks for explaining, and of course for your continued efforts! I hope more and more people will start to benefit from the increased usability provided by the types.
Uh oh!
There was an error while loading. Please reload this page.
Adding remaining types to remote.py and moved compat.py back.
Accidentally squashed a bunch of commits!
Here's which did what:
206f345 HEAD@{6}: commit: flake8 and forward ref fixes
d28ba6d HEAD@{12}: commit: del compat module folder
046899e HEAD@{13}: commit: change config back to file, point imports to git.types
1f90e3b HEAD@{14}: commit: Add types to Remote. ne() hash()
1d7062b HEAD@{15}: commit: Add types to Remote. config_reader() config_writer()
c1ccc59 HEAD@{16}: commit: Add types to Remote. fetch() pull() push())
19dafe3 HEAD@{17}: commit: Add types to Remote. update() _get_fetch_info_from_stderr() _get_push_info()
519ddea HEAD@{18}: commit: Add types to Remote. create() remove() rename() and make agree with base.Repo
2391d8a HEAD@{19}: commit: Add types to Remote. urls() refs() stale_refs()
df8d1c3 HEAD@{20}: commit: fix iter_items() type to match supertype
6b8d6e9 HEAD@{21}: commit: Add types to Remote. iter_items() set_url() add_url() delete_url()
7a9eedb HEAD@{22}: commit: Add types to Remote. _asser_refspec() _clear_cache() _config_section_name() _set_cache()
6a2f5d0 HEAD@{23}: commit: Add types to Remote. init getattr exists
Ready for review :)