ibm-appconfiguration-python-sdk 0.3.2__py3-none-any.whl → 0.3.4__py3-none-any.whl

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.
@@ -38,6 +38,7 @@ class AppConfiguration:
38
38
  REGION_EU_GB = "eu-gb"
39
39
  REGION_AU_SYD = "au-syd"
40
40
  REGION_US_EAST = "us-east"
41
+ REGION_EU_DE = "eu-de"
41
42
  __override_service_url = None
42
43
  __use_private_endpoint = False
43
44
 
@@ -44,7 +44,7 @@ class Socket:
44
44
  )
45
45
  self.ws_client.run_forever(sslopt={"cert_reqs": ssl.CERT_NONE})
46
46
 
47
- def on_message(self, message):
47
+ def on_message(self, _, message):
48
48
  """Socket on-message
49
49
 
50
50
  Args:
@@ -54,7 +54,7 @@ class Socket:
54
54
  return
55
55
  self.__callback(message=message)
56
56
 
57
- def on_error(self, error):
57
+ def on_error(self, _, error):
58
58
  """Socket on-error
59
59
 
60
60
  Args:
@@ -63,11 +63,11 @@ class Socket:
63
63
  self.__callback(error_state=error)
64
64
  self.ws_client.close()
65
65
 
66
- def on_close(self):
66
+ def on_close(self, _, close_status_code, close_msg):
67
67
  """Socket on-close call"""
68
68
  self.__callback(closed_state='Closed the web_socket')
69
69
 
70
- def on_open(self):
70
+ def on_open(self, _):
71
71
  """Socket on-open call"""
72
72
  self.__callback(open_state='Opened the web_socket')
73
73
 
@@ -15,4 +15,4 @@
15
15
  """
16
16
  Version of ibm-appconfiguration-python-sdk
17
17
  """
18
- __version__ = '0.3.2'
18
+ __version__ = '0.3.4'
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ibm-appconfiguration-python-sdk
3
- Version: 0.3.2
3
+ Version: 0.3.4
4
4
  Summary: IBM Cloud App Configuration Python SDK
5
5
  Home-page: https://github.com/IBM/appconfiguration-python-sdk
6
6
  Author: IBM
@@ -15,9 +15,9 @@ Requires-Python: >=3.0
15
15
  Description-Content-Type: text/markdown
16
16
  License-File: LICENSE
17
17
  Requires-Dist: python-dateutil <3.0.0,>=2.8
18
- Requires-Dist: requests <3.0,>=2.31.0
19
- Requires-Dist: websocket-client ==0.57.0
20
- Requires-Dist: ibm-cloud-sdk-core <4.0.0,>=3.18.0
18
+ Requires-Dist: requests <3.0,>=2.32.2
19
+ Requires-Dist: websocket-client <2.0.0,>=1.8.0
20
+ Requires-Dist: ibm-cloud-sdk-core <4.0.0,>=3.20.3
21
21
  Requires-Dist: pyyaml >=5.4.1
22
22
  Requires-Dist: schema >=0.7.5
23
23
  Requires-Dist: mmh3 ==3.0.0
@@ -79,6 +79,7 @@ using **`AppConfiguration.get_instance()`**. [See this example below](#fetching
79
79
  - `AppConfiguration.REGION_EU_GB` for London
80
80
  - `AppConfiguration.REGION_AU_SYD` for Sydney
81
81
  - `AppConfiguration.REGION_US_EAST` for Washington DC
82
+ - `AppConfiguration.REGION_EU_DE` for Frankfurt
82
83
  - guid : GUID of the App Configuration service. Obtain it from the service credentials section of the dashboard
83
84
  - apikey : ApiKey of the App Configuration service. Obtain it from the service credentials section of the dashboard
84
85
  - collection_id : Id of the collection created in App Configuration service instance under the **Collections** section.
@@ -2,8 +2,8 @@ examples/__init__.py,sha256=lUFn6j5Q9SBHlJ-7ScnhU3pLOP8Ae-o6MW2GtQnURyQ,588
2
2
  examples/sample_app.py,sha256=jcrF23xJkMEplNZ90eQqV4JyM_PtHCgLUN80INs9zGs,5284
3
3
  examples/server_sample.py,sha256=WxnCJqEQQj_YhjQ21KxfuPEBiCkIvpxI1bBDx34xLog,4320
4
4
  ibm_appconfiguration/__init__.py,sha256=aQvGtHciXc4pjnvhfza3twhfcOFAj2pbxiKLSJwUe6s,895
5
- ibm_appconfiguration/appconfiguration.py,sha256=upFw70hjezrFKYsfk9_w9FpIvfoJQPDcjuqZgaUoHbs,12445
6
- ibm_appconfiguration/version.py,sha256=fFoZde9mOEZt2Nw0OKfIvln56avEoiNCSeCymA-c414,664
5
+ ibm_appconfiguration/appconfiguration.py,sha256=0GFiMPqxrZziKqU-JGj7NxjCEV4wQmOjVsh8llymwZc,12472
6
+ ibm_appconfiguration/version.py,sha256=fbhzkqZOPRInqrrLkngf7xZQ3drE1iYsTWhxClhxa6U,664
7
7
  ibm_appconfiguration/configurations/__init__.py,sha256=8PyXXczv26V_FmPiTHgz3VjFS1wg0ebSwqnMNZ7UJ6k,589
8
8
  ibm_appconfiguration/configurations/configuration_handler.py,sha256=bvPAR2lW67ZkBxSZrplDaFbuiRdV-xqQPK1WDBl-g0I,26029
9
9
  ibm_appconfiguration/configurations/internal/__init__.py,sha256=8PyXXczv26V_FmPiTHgz3VjFS1wg0ebSwqnMNZ7UJ6k,589
@@ -17,7 +17,7 @@ ibm_appconfiguration/configurations/internal/utils/connectivity.py,sha256=EIlg5r
17
17
  ibm_appconfiguration/configurations/internal/utils/file_manager.py,sha256=mhLeDGg-Y6sucDLpsTdKI4UTNNv11Ajo4RaAqFbrKcQ,1991
18
18
  ibm_appconfiguration/configurations/internal/utils/logger.py,sha256=oLkNSobvke5VUVmqqJ3e8sO4jkUEhn0RUvbVYBGdFsc,3114
19
19
  ibm_appconfiguration/configurations/internal/utils/metering.py,sha256=osBCavRXq66nkq95K5D9E9RySL9Y81-HM_N0oayhVPY,10697
20
- ibm_appconfiguration/configurations/internal/utils/socket.py,sha256=GImnhpLQ4E7lB67lhHC1vgtIlDjIy_2Jri2O_GS5eUc,2240
20
+ ibm_appconfiguration/configurations/internal/utils/socket.py,sha256=CqoYG2-6yWN5xg4z9Ryqrhz8WV4M_1IvtyQGsY-inDw,2282
21
21
  ibm_appconfiguration/configurations/internal/utils/url_builder.py,sha256=9GOaMlI8FHy44nnx_URqIyebZCBYaPwO7W6YuRNxBe4,6164
22
22
  ibm_appconfiguration/configurations/internal/utils/validators.py,sha256=FvMEAaZKri_GEs-R89a15N2sqD0Tm1LNaVgOBk5xdKQ,2101
23
23
  ibm_appconfiguration/configurations/models/__init__.py,sha256=mC2Tig3fv7K28B2ZrAI0_kpRsHarwAaB-o0valv0EB0,878
@@ -43,10 +43,10 @@ unit_tests/configurations/utils/__init__.py,sha256=8PyXXczv26V_FmPiTHgz3VjFS1wg0
43
43
  unit_tests/configurations/utils/test_api_manager.py,sha256=cUjbJUk9IdyeCFO1hMH22lMihQcwFISW5mjtITpJzkM,2527
44
44
  unit_tests/configurations/utils/test_file_manager.py,sha256=ufl9cBw5HCcXUMThy1HmMpuznCppIZ-zWb0uHCfh3Yk,2643
45
45
  unit_tests/configurations/utils/test_metering.py,sha256=KBD9UGhlZmoUJ6iawXqU4evaZ-lIts8mBTMouH2qKJM,3783
46
- unit_tests/configurations/utils/test_socket.py,sha256=xdH18PTOkV4YHGEwRl9LpyklRHvhPk4bZbWCdkOPJHk,1830
46
+ unit_tests/configurations/utils/test_socket.py,sha256=AdKTLHcchW4WUBDypIqWGJiUmRh7s7RUqaTwr9qHaek,1965
47
47
  unit_tests/configurations/utils/test_url_builder.py,sha256=4QhRESvyQYeA9agWk7x5q5uFuZH_n4Ng74JjZlRC-vM,5636
48
- ibm_appconfiguration_python_sdk-0.3.2.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
49
- ibm_appconfiguration_python_sdk-0.3.2.dist-info/METADATA,sha256=1sMVy6s2ZqSlJSKQCFm3UxbiHpe8MvHExIiR1So0hnY,17164
50
- ibm_appconfiguration_python_sdk-0.3.2.dist-info/WHEEL,sha256=oiQVh_5PnQM0E3gPdiz09WCNmwiHDMaGer_elqB3coM,92
51
- ibm_appconfiguration_python_sdk-0.3.2.dist-info/top_level.txt,sha256=9eb0V7JdVIDUKF3J4vc281Pe70ySrEL5qMhvrOuCMJk,59
52
- ibm_appconfiguration_python_sdk-0.3.2.dist-info/RECORD,,
48
+ ibm_appconfiguration_python_sdk-0.3.4.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
49
+ ibm_appconfiguration_python_sdk-0.3.4.dist-info/METADATA,sha256=CPK85rDYbZzvGvTjK6WqogrRTf0KXHuAmssLSQ8AqNM,17220
50
+ ibm_appconfiguration_python_sdk-0.3.4.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
51
+ ibm_appconfiguration_python_sdk-0.3.4.dist-info/top_level.txt,sha256=9eb0V7JdVIDUKF3J4vc281Pe70ySrEL5qMhvrOuCMJk,59
52
+ ibm_appconfiguration_python_sdk-0.3.4.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: bdist_wheel (0.42.0)
2
+ Generator: setuptools (75.1.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -32,23 +32,23 @@ class MyTestCase(unittest.TestCase):
32
32
  def test_socket(self):
33
33
  self.__socket = Socket()
34
34
  self.__socket.setup(
35
- url="",
35
+ url="ws://testurl.com",
36
36
  headers=[],
37
37
  callback=self.callback
38
38
  )
39
39
 
40
40
  self.assertIsNotNone(self.__socket)
41
41
 
42
- self.__socket.on_message("Socket message")
42
+ self.__socket.on_message(self.__socket.ws_client,"Socket message")
43
43
  self.assertEqual(self.expected_message, "Socket message")
44
44
 
45
- self.__socket.on_error("Error message")
45
+ self.__socket.on_error(self.__socket.ws_client, "Error message")
46
46
  self.assertEqual(self.expected_error, "Error message")
47
47
 
48
- self.__socket.on_open()
48
+ self.__socket.on_open(self.__socket.ws_client)
49
49
  self.assertEqual(self.expected_open_state, "Opened the web_socket")
50
50
 
51
- self.__socket.on_close()
51
+ self.__socket.on_close(self.__socket.ws_client, 1000, "normal closure")
52
52
  self.assertEqual(self.expected_closed_state, "Closed the web_socket")
53
53
 
54
54