Skip to content
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

Adding Typehints for jira.py #1418

Open
wants to merge 23 commits into
base: master
Choose a base branch
from

Conversation

bandophahita
Copy link
Contributor

Since adding typehints to the entire repo would make for a VERY large PR, I'm breaking up the changes mostly by module. This PR focuses on adding hints to jira.py

@bandophahita bandophahita changed the title Adding Typehints Adding Typehints for jira.py Jun 12, 2024
@@ -61,7 +61,7 @@ def each(self, q=None, sort=None):

return

def get(self, uuid):
def get(self, uuid: str): # type: ignore[override]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The signature for get in AtlassianRestAPI doesn't match here. So we need to override.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

requirements.txt Outdated
requests>=2.8.1
six
oauthlib
requests_oauthlib
requests-oauthlib
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure why this wasn't included as it's used in the library.

types-Deprecated
types-requests
types-six
types-beautifulsoup4
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of the above get used in tox so it only made sense to include them in the dev reqs.

absolute=False,
advanced_mode=False,
):
path: str,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not adding the override variations here since patch doesn't get used in jira.py.

pyproject.toml Outdated
@@ -7,7 +7,6 @@
[tool.black]
target-version = ['py36', 'py37', 'py38', 'py39']
line-length = 120
include_trailing_comma = false
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't a valid configuration parameter.

Copy link

codecov bot commented Jun 12, 2024

Codecov Report

Attention: Patch coverage is 72.54902% with 28 lines in your changes missing coverage. Please review.

Project coverage is 34.15%. Comparing base (d02241a) to head (a5b6151).
Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
atlassian/rest_client.py 76.25% 18 Missing and 1 partial ⚠️
atlassian/confluence.py 25.00% 9 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1418      +/-   ##
==========================================
+ Coverage   33.85%   34.15%   +0.30%     
==========================================
  Files          46       47       +1     
  Lines        8897     8974      +77     
  Branches     1215     1217       +2     
==========================================
+ Hits         3012     3065      +53     
- Misses       5762     5786      +24     
  Partials      123      123              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@gonchik
Copy link
Member

gonchik commented Mar 25, 2025

@bandophahita once you're ready feel free to update the status of PR

@bandophahita
Copy link
Contributor Author

I'm about to give up and abandon this PR. There are just too many hurdles in the codebase to deal with that are outside my purview. I'll leave it here for now in case someone wants to pick up where I left off.

@gonchik gonchik marked this pull request as ready for review March 27, 2025 07:40
@gonchik
Copy link
Member

gonchik commented Mar 27, 2025

@bandophahita could you double check everything is expected from typehints perspective ?

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.

3 participants