Title: Adding inital types to remote.py by Yobmod · Pull Request #1229 · gitpython-developers/GitPython · GitHub
Open Graph Title: Adding inital types to remote.py by Yobmod · Pull Request #1229 · gitpython-developers/GitPython
X Title: Adding inital types to remote.py by Yobmod · Pull Request #1229 · gitpython-developers/GitPython
Description: Adding types to remote.py: add_progress() to_progress_instance() PushInfo. init() old_commit() remote_ref() FetchInfo. refresh() init() str() name() commit() _from_line() A few places the functions can take multiple Reference types including child and parent classes (e.g. Reference, TagReference, RemoteReference, SymbolicReference). In those cases i've used the base class that covers them all (e.g. SymbolicReference). I could change that to a union of all the classes if it would be better. I copied the compat.typing Literal and Final import logic to types.py, as it would be used in multiple places, not just compat.py. I didn't remove it from compat yet, in case there were bigger plans for it being a module. Q. PushInfo.init() and FetchInfo() both have an 'old_commit' arg. Should they be the same type (bytes or string rather than a Commit object?) Theres a comment saying should be bytes, but that gives 14 mypy errors, whereas str gives no errors. A leftover from py2?
Open Graph Description: Adding types to remote.py: add_progress() to_progress_instance() PushInfo. init() old_commit() remote_ref() FetchInfo. refresh() init() str() name() commit() _from_line() A few places the functio...
X Description: Adding types to remote.py: add_progress() to_progress_instance() PushInfo. init() old_commit() remote_ref() FetchInfo. refresh() init() str() name() commit() _from_line() A few places the functio...
Opengraph URL: https://github.com/gitpython-developers/GitPython/pull/1229
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/checks(.:format) |
| route-controller | pull_requests |
| route-action | checks |
| fetch-nonce | v2:75e08839-6f88-fef3-7c4c-04fbf9d4e7d8 |
| current-catalog-service-hash | 87dc3bc62d9b466312751bfd5f889726f4f1337bdff4e8be7da7c93d6c00a25a |
| request-id | DEE4:D2872:1259B:189D8:6968AFA2 |
| html-safe-nonce | c21bdd8168f3c8b861bf76797ac5b5532fdce7ea0a225ca6f1d5d5983b587019 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJERUU0OkQyODcyOjEyNTlCOjE4OUQ4OjY5NjhBRkEyIiwidmlzaXRvcl9pZCI6IjcyMDgyOTkxNjE0NTczMDc1NTQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 0a3672def5cf7cf2408bbc0a9a16c5b98987054941d1acb3e1df70fed284d472 |
| hovercard-subject-tag | pull_request:629182256 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,checks,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/gitpython-developers/GitPython/pull/1229/checks |
| twitter:image | https://avatars.githubusercontent.com/u/22235459?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/22235459?s=400&v=4 |
| og:image:alt | Adding types to remote.py: add_progress() to_progress_instance() PushInfo. init() old_commit() remote_ref() FetchInfo. refresh() init() str() name() commit() _from_line() A few places the functio... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | fdc7c66bd36a6c12eb8e771e806db863266e573fc299e77f27505a768d4f8a98 |
| turbo-cache-control | no-preview |
| go-import | github.com/gitpython-developers/GitPython git https://github.com/gitpython-developers/GitPython.git |
| octolytics-dimension-user_id | 503709 |
| octolytics-dimension-user_login | gitpython-developers |
| octolytics-dimension-repository_id | 1126087 |
| octolytics-dimension-repository_nwo | gitpython-developers/GitPython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1126087 |
| octolytics-dimension-repository_network_root_nwo | gitpython-developers/GitPython |
| turbo-body-classes | logged-out env-production page-responsive full-width full-width-p-0 |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 3223a6503d318917691422cdadfbe16cd8fb21e5 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width