Skip to content

chore: add type-hints to gitlab/client.py #1339

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 1 commit into from
Feb 27, 2021
Merged

chore: add type-hints to gitlab/client.py #1339

merged 1 commit into from
Feb 27, 2021

Conversation

JohnVillalovos
Copy link
Member

Adding some initial type-hints to gitlab/client.py

Unsure about my usage of assert to identify the type of the object. Feedback appreciated.

@JohnVillalovos JohnVillalovos marked this pull request as draft February 26, 2021 19:53
Adding some initial type-hints to gitlab/client.py
@JohnVillalovos JohnVillalovos marked this pull request as ready for review February 26, 2021 20:57
@max-wittig
Copy link
Member

@JohnVillalovos I love these type merge requests. Just a quick question. What about the depreciation of the typing module in Python 3.9? We may need some feature imports then right?

@JohnVillalovos
Copy link
Member Author

@JohnVillalovos I love these type merge requests. Just a quick question. What about the depreciation of the typing module in Python 3.9? We may need some feature imports then right?

I was not aware of that. But I just read this: https://docs.python.org/3/library/typing.html

The deprecated types will be removed from the typing module in the first Python version released 5 years after the release of Python 3.9.0.

Which sounds like we will have 5 years to take care of this. Maybe I misunderstand that.

@max-wittig
Copy link
Member

Okay then it should be fine.

@max-wittig max-wittig merged commit b0d75d9 into python-gitlab:master Feb 27, 2021
@max-wittig
Copy link
Member

Thanks for the MR!

@JohnVillalovos
Copy link
Member Author

Thanks for the MR!

Slowly coming along. One file at a time!

@JohnVillalovos JohnVillalovos deleted the jlvillal/mypy_client_py branch March 14, 2021 17:48
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.

2 participants