Skip to content

Commit c46ee45

Browse files
authored
Merge pull request #31 from splitio/fix-issue-with-change-request-list-url
Update version to 3.5.7 and fix issue #30
2 parents 26951d3 + b35527c commit c46ee45

File tree

9 files changed

+32
-16
lines changed

9 files changed

+32
-16
lines changed

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,4 +93,7 @@ ENV/
9393

9494
#IDE
9595
.idea
96-
.DS_Store
96+
.DS_Store
97+
98+
#uv.lock
99+
uv.lock

CHANGES.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,14 @@ CHANGELOG
33

44
This file tracks the version history and changes made to the Split/Harness FME Python API Client library.
55

6+
3.5.7 (November 26, 2025)
7+
-------------------------
8+
Bug Fixes:
9+
- Fixed ChangeRequestMicroClient to keep it from mutating the _endpoint
10+
- This will make it so repeated api calls don't make the URL too long for HTTP requests
11+
- updated license in pyproject.toml
12+
- updated url to harness from split in readme
13+
614
3.5.6 (October 31, 2025)
715
-------------------------
816
Bug Fixes:

check_package_contents.sh

Lines changed: 0 additions & 1 deletion
This file was deleted.

examples/README.md

Lines changed: 0 additions & 1 deletion
This file was deleted.

examples/error_handling_example.py

Lines changed: 0 additions & 1 deletion
This file was deleted.

examples/list_traffic_types_and_attributes.py

Lines changed: 0 additions & 1 deletion
This file was deleted.

pyproject.toml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "splitapiclient"
7-
version = "3.5.6"
7+
version = "3.5.7"
8+
license = "Apache-2.0"
89
description = "This Python Library provides full support for Split REST Admin API, allow creating, deleting and editing Environments, Splits, Split Definitions, Segments, Segment Keys, Users, Groups, API Keys, Change Requests, Attributes and Identities"
910
classifiers = [
1011
"Programming Language :: Python :: 3",
@@ -44,8 +45,6 @@ dev = [
4445
"twine >= 3.4.0",
4546
]
4647

47-
[project.license]
48-
text = "Apache License 2.0"
4948

5049
[project.readme]
5150
file = "README.md"
@@ -54,7 +53,7 @@ content-type = "text/markdown"
5453
[project.urls]
5554
Homepage = "https://github.com/splitio/python-api"
5655
"Bug Tracker" = "https://github.com/splitio/python-api/issues"
57-
Documentation = "https://help.split.io/hc/en-us/articles/4412331052685-Python-PyPi-library-for-Split-REST-Admin-API"
56+
Documentation = "https://developer.harness.io/docs/feature-management-experimentation/api/wrappers/python-admin-api/"
5857

5958
[tool.aliases]
6059
test = "pytest"

splitapiclient/microclients/change_request_microclient.py

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -69,22 +69,32 @@ def list(self, environment_id, status):
6969
'''
7070
final_list = []
7171
afterMarker = 0
72+
73+
# Build URL templates locally without mutating self._endpoint
74+
list_initial_url = self._endpoint['list_initial']['url_template']
75+
list_next_url = self._endpoint['list_next']['url_template']
76+
7277
if(environment_id!=None):
73-
self._endpoint['list_next']['url_template'] = self._endpoint['list_next']['url_template'] + "&environmentId={environmentId}"
74-
self._endpoint['list_initial']['url_template'] = self._endpoint['list_initial']['url_template'] + "&environmentId={environmentId}"
78+
list_initial_url = list_initial_url + "&environmentId={environmentId}"
79+
list_next_url = list_next_url + "&environmentId={environmentId}"
7580
if(status!=None):
76-
self._endpoint['list_next']['url_template'] = self._endpoint['list_next']['url_template'] + "&status={status}"
77-
self._endpoint['list_initial']['url_template'] = self._endpoint['list_initial']['url_template'] + "&status={status}"
81+
list_initial_url = list_initial_url + "&status={status}"
82+
list_next_url = list_next_url + "&status={status}"
83+
7884
while True:
7985
if afterMarker==0:
86+
# Create a new endpoint dict with modified URL template (keeping _endpoint immutable)
87+
endpoint = {**self._endpoint['list_initial'], 'url_template': list_initial_url}
8088
response = self._http_client.make_request(
81-
self._endpoint['list_initial'],
89+
endpoint,
8290
status=status,
8391
environmentId=environment_id
8492
)
8593
else:
94+
# Create a new endpoint dict with modified URL template (keeping _endpoint immutable)
95+
endpoint = {**self._endpoint['list_next'], 'url_template': list_next_url}
8696
response = self._http_client.make_request(
87-
self._endpoint['list_next'],
97+
endpoint,
8898
status=status,
8999
environmentId=environment_id,
90100
after = afterMarker

splitapiclient/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = '3.5.6'
1+
__version__ = '3.5.7'

0 commit comments

Comments
 (0)