python-jira-plus 1.0.15__tar.gz → 2.0.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_jira_plus-1.0.15/python_jira_plus.egg-info → python_jira_plus-2.0.2}/PKG-INFO +19 -20
- python_jira_plus-2.0.2/pyproject.toml +43 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus/jira_plus.py +43 -2
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2/python_jira_plus.egg-info}/PKG-INFO +19 -20
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus.egg-info/SOURCES.txt +0 -2
- python_jira_plus-2.0.2/python_jira_plus.egg-info/requires.txt +9 -0
- python_jira_plus-1.0.15/pyproject.toml +0 -11
- python_jira_plus-1.0.15/python_jira_plus.egg-info/requires.txt +0 -9
- python_jira_plus-1.0.15/requirements.txt +0 -9
- python_jira_plus-1.0.15/setup.py +0 -35
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/LICENSE +0 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/MANIFEST.in +0 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/README.md +0 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus/__init__.py +0 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus/describe_allowed_value.py +0 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus.egg-info/dependency_links.txt +0 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus.egg-info/top_level.txt +0 -0
- {python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/setup.cfg +0 -0
|
@@ -1,32 +1,31 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-jira-plus
|
|
3
|
-
Version:
|
|
3
|
+
Version: 2.0.2
|
|
4
4
|
Summary: Enhanced Python client for JIRA with better error handling, pagination, and metadata validation.
|
|
5
|
-
Home-page: https://github.com/aviz92/python-jira-plus
|
|
6
5
|
Author: Avi Zaguri
|
|
7
|
-
|
|
6
|
+
License: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/aviz92/python-jira-plus
|
|
8
8
|
Project-URL: Repository, https://github.com/aviz92/python-jira-plus
|
|
9
|
+
Project-URL: Issues, https://github.com/aviz92/python-jira-plus/issues
|
|
10
|
+
Keywords: development,jira,atlassian,api,client,python
|
|
11
|
+
Classifier: Development Status :: 4 - Beta
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
15
|
+
Classifier: Topic :: System :: Logging
|
|
9
16
|
Requires-Python: >=3.11
|
|
10
17
|
Description-Content-Type: text/markdown
|
|
11
18
|
License-File: LICENSE
|
|
12
|
-
Requires-Dist:
|
|
13
|
-
Requires-Dist:
|
|
14
|
-
Requires-Dist:
|
|
15
|
-
Requires-Dist: pre-commit
|
|
16
|
-
Requires-Dist:
|
|
17
|
-
Requires-Dist:
|
|
18
|
-
Requires-Dist:
|
|
19
|
-
Requires-Dist:
|
|
20
|
-
Requires-Dist:
|
|
21
|
-
Dynamic: author
|
|
22
|
-
Dynamic: description
|
|
23
|
-
Dynamic: description-content-type
|
|
24
|
-
Dynamic: home-page
|
|
19
|
+
Requires-Dist: custom-python-logger>=2.0.10
|
|
20
|
+
Requires-Dist: dotenv>=0.9.9
|
|
21
|
+
Requires-Dist: jira>=3.10.5
|
|
22
|
+
Requires-Dist: pre-commit>=4.5.0
|
|
23
|
+
Requires-Dist: pytest>=9.0.1
|
|
24
|
+
Requires-Dist: requests>=2.32.5
|
|
25
|
+
Requires-Dist: retrying>=1.4.2
|
|
26
|
+
Requires-Dist: setuptools>=80.9.0
|
|
27
|
+
Requires-Dist: wheel>=0.45.1
|
|
25
28
|
Dynamic: license-file
|
|
26
|
-
Dynamic: project-url
|
|
27
|
-
Dynamic: requires-dist
|
|
28
|
-
Dynamic: requires-python
|
|
29
|
-
Dynamic: summary
|
|
30
29
|
|
|
31
30
|
# Python JIRA Plus
|
|
32
31
|
An enhanced Python client for JIRA that extends the functionality of the official `jira` package, providing better error handling, pagination, metadata validation, and more.
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "python-jira-plus"
|
|
7
|
+
version = "2.0.2"
|
|
8
|
+
description = "Enhanced Python client for JIRA with better error handling, pagination, and metadata validation."
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.11"
|
|
11
|
+
license = { text = "MIT" }
|
|
12
|
+
authors = [{ name = "Avi Zaguri" },]
|
|
13
|
+
keywords = ["development", "jira", "atlassian", "api", "client", "python"]
|
|
14
|
+
|
|
15
|
+
classifiers = [
|
|
16
|
+
"Development Status :: 4 - Beta",
|
|
17
|
+
"Intended Audience :: Developers",
|
|
18
|
+
"Programming Language :: Python :: 3.11",
|
|
19
|
+
"Operating System :: OS Independent",
|
|
20
|
+
"Topic :: System :: Logging",
|
|
21
|
+
]
|
|
22
|
+
|
|
23
|
+
dependencies = [
|
|
24
|
+
"custom-python-logger>=2.0.10",
|
|
25
|
+
"dotenv>=0.9.9",
|
|
26
|
+
"jira>=3.10.5",
|
|
27
|
+
"pre-commit>=4.5.0",
|
|
28
|
+
"pytest>=9.0.1",
|
|
29
|
+
"requests>=2.32.5",
|
|
30
|
+
"retrying>=1.4.2",
|
|
31
|
+
"setuptools>=80.9.0",
|
|
32
|
+
"wheel>=0.45.1",
|
|
33
|
+
]
|
|
34
|
+
|
|
35
|
+
[project.urls]
|
|
36
|
+
Homepage = "https://github.com/aviz92/python-jira-plus"
|
|
37
|
+
Repository = "https://github.com/aviz92/python-jira-plus"
|
|
38
|
+
Issues = "https://github.com/aviz92/python-jira-plus/issues"
|
|
39
|
+
|
|
40
|
+
[tool.setuptools.packages.find]
|
|
41
|
+
where = ["."]
|
|
42
|
+
include = ["python_jira_plus*"]
|
|
43
|
+
namespaces = false
|
|
@@ -119,7 +119,11 @@ class JiraPlus:
|
|
|
119
119
|
jira_err_count: int = 3,
|
|
120
120
|
json_result: bool = True,
|
|
121
121
|
) -> ResultList[Issue] | dict | None:
|
|
122
|
-
|
|
122
|
+
if self.server_type == ServerType.ON_PREMISE:
|
|
123
|
+
_paginate_query_func = self._paginate_query
|
|
124
|
+
else:
|
|
125
|
+
_paginate_query_func = self._paginate_query_new
|
|
126
|
+
return _paginate_query_func(
|
|
123
127
|
query=query,
|
|
124
128
|
max_results=max_results,
|
|
125
129
|
specific_fields=specific_fields,
|
|
@@ -127,6 +131,43 @@ class JiraPlus:
|
|
|
127
131
|
json_result=json_result,
|
|
128
132
|
)
|
|
129
133
|
|
|
134
|
+
def _paginate_query_new(
|
|
135
|
+
self,
|
|
136
|
+
query: str,
|
|
137
|
+
max_results: int,
|
|
138
|
+
specific_fields: str | list[str],
|
|
139
|
+
jira_err_limit: int,
|
|
140
|
+
json_result: bool,
|
|
141
|
+
) -> ResultList[Issue] | list:
|
|
142
|
+
all_issues = []
|
|
143
|
+
retries = 0
|
|
144
|
+
page = None
|
|
145
|
+
while True: # pylint: disable=W0149
|
|
146
|
+
try:
|
|
147
|
+
self.logger.debug(f"Fetching issues from startAt={len(all_issues)}")
|
|
148
|
+
page = self.jira_client.enhanced_search_issues(
|
|
149
|
+
jql_str=query,
|
|
150
|
+
nextPageToken=page['nextPageToken'] if page else None,
|
|
151
|
+
maxResults=max_results,
|
|
152
|
+
fields=specific_fields,
|
|
153
|
+
json_result=json_result,
|
|
154
|
+
)
|
|
155
|
+
all_issues += page["issues"] if json_result else page
|
|
156
|
+
if page['isLast']:
|
|
157
|
+
break
|
|
158
|
+
retries = 0 # reset on success
|
|
159
|
+
except JIRAError as err:
|
|
160
|
+
if err.status_code == 400:
|
|
161
|
+
self.logger.error(f"Bad Request: {err.text}")
|
|
162
|
+
raise JIRAError(f"Bad Request: {err.text}") from err
|
|
163
|
+
retries += 1
|
|
164
|
+
self.logger.warning(f"Retry {retries}/{jira_err_limit} after JIRAError: {err}")
|
|
165
|
+
if retries >= jira_err_limit:
|
|
166
|
+
self.logger.exception("Max retries exceeded.")
|
|
167
|
+
return []
|
|
168
|
+
time.sleep(300 if retries == jira_err_limit - 1 else 90)
|
|
169
|
+
return all_issues
|
|
170
|
+
|
|
130
171
|
def _paginate_query(
|
|
131
172
|
self,
|
|
132
173
|
query: str,
|
|
@@ -141,7 +182,7 @@ class JiraPlus:
|
|
|
141
182
|
while True: # pylint: disable=W0149
|
|
142
183
|
try:
|
|
143
184
|
self.logger.debug(f"Fetching issues from startAt={start_at}")
|
|
144
|
-
page = self.jira_client.
|
|
185
|
+
page = self.jira_client.enhanced_search_issues(
|
|
145
186
|
jql_str=query,
|
|
146
187
|
startAt=start_at,
|
|
147
188
|
maxResults=max_results,
|
|
@@ -1,32 +1,31 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-jira-plus
|
|
3
|
-
Version:
|
|
3
|
+
Version: 2.0.2
|
|
4
4
|
Summary: Enhanced Python client for JIRA with better error handling, pagination, and metadata validation.
|
|
5
|
-
Home-page: https://github.com/aviz92/python-jira-plus
|
|
6
5
|
Author: Avi Zaguri
|
|
7
|
-
|
|
6
|
+
License: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/aviz92/python-jira-plus
|
|
8
8
|
Project-URL: Repository, https://github.com/aviz92/python-jira-plus
|
|
9
|
+
Project-URL: Issues, https://github.com/aviz92/python-jira-plus/issues
|
|
10
|
+
Keywords: development,jira,atlassian,api,client,python
|
|
11
|
+
Classifier: Development Status :: 4 - Beta
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
15
|
+
Classifier: Topic :: System :: Logging
|
|
9
16
|
Requires-Python: >=3.11
|
|
10
17
|
Description-Content-Type: text/markdown
|
|
11
18
|
License-File: LICENSE
|
|
12
|
-
Requires-Dist:
|
|
13
|
-
Requires-Dist:
|
|
14
|
-
Requires-Dist:
|
|
15
|
-
Requires-Dist: pre-commit
|
|
16
|
-
Requires-Dist:
|
|
17
|
-
Requires-Dist:
|
|
18
|
-
Requires-Dist:
|
|
19
|
-
Requires-Dist:
|
|
20
|
-
Requires-Dist:
|
|
21
|
-
Dynamic: author
|
|
22
|
-
Dynamic: description
|
|
23
|
-
Dynamic: description-content-type
|
|
24
|
-
Dynamic: home-page
|
|
19
|
+
Requires-Dist: custom-python-logger>=2.0.10
|
|
20
|
+
Requires-Dist: dotenv>=0.9.9
|
|
21
|
+
Requires-Dist: jira>=3.10.5
|
|
22
|
+
Requires-Dist: pre-commit>=4.5.0
|
|
23
|
+
Requires-Dist: pytest>=9.0.1
|
|
24
|
+
Requires-Dist: requests>=2.32.5
|
|
25
|
+
Requires-Dist: retrying>=1.4.2
|
|
26
|
+
Requires-Dist: setuptools>=80.9.0
|
|
27
|
+
Requires-Dist: wheel>=0.45.1
|
|
25
28
|
Dynamic: license-file
|
|
26
|
-
Dynamic: project-url
|
|
27
|
-
Dynamic: requires-dist
|
|
28
|
-
Dynamic: requires-python
|
|
29
|
-
Dynamic: summary
|
|
30
29
|
|
|
31
30
|
# Python JIRA Plus
|
|
32
31
|
An enhanced Python client for JIRA that extends the functionality of the official `jira` package, providing better error handling, pagination, metadata validation, and more.
|
python_jira_plus-1.0.15/setup.py
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
from setuptools import find_packages, setup
|
|
2
|
-
|
|
3
|
-
package_version = "1.0.15"
|
|
4
|
-
|
|
5
|
-
package_name = "python-jira-plus"
|
|
6
|
-
package_description = "Enhanced Python client for JIRA with better error handling, pagination, and metadata validation."
|
|
7
|
-
|
|
8
|
-
package_name_ = package_name.replace("-", "_")
|
|
9
|
-
package_long_description_content_type = "text/markdown"
|
|
10
|
-
package_url = f"https://github.com/aviz92/{package_name}"
|
|
11
|
-
package_python_requires = ">=3.11"
|
|
12
|
-
package_author = "Avi Zaguri"
|
|
13
|
-
|
|
14
|
-
with open("requirements.txt") as file:
|
|
15
|
-
package_install_requires = [line.strip() for line in file.readlines() if line.strip() and not line.startswith("#")]
|
|
16
|
-
|
|
17
|
-
with open("README.md") as file:
|
|
18
|
-
package_long_description = file.read()
|
|
19
|
-
|
|
20
|
-
setup(
|
|
21
|
-
name=package_name,
|
|
22
|
-
version=package_version,
|
|
23
|
-
packages=find_packages(include=[package_name_, f"{package_name_}.*"]),
|
|
24
|
-
install_requires=package_install_requires,
|
|
25
|
-
author=package_author,
|
|
26
|
-
author_email="",
|
|
27
|
-
description=package_description,
|
|
28
|
-
long_description=package_long_description,
|
|
29
|
-
long_description_content_type=package_long_description_content_type,
|
|
30
|
-
url=package_url,
|
|
31
|
-
project_urls={
|
|
32
|
-
"Repository": package_url,
|
|
33
|
-
},
|
|
34
|
-
python_requires=package_python_requires,
|
|
35
|
-
)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus/describe_allowed_value.py
RENAMED
|
File without changes
|
{python_jira_plus-1.0.15 → python_jira_plus-2.0.2}/python_jira_plus.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|