shopware-api-client 1.0.107__py3-none-any.whl → 1.0.108__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.

Potentially problematic release.


This version of shopware-api-client might be problematic. Click here for more details.

@@ -159,7 +159,7 @@ class ClientBase:
159
159
  raise ValueError("`errors` attribute in json not a list/tuple!")
160
160
 
161
161
  error: SWAPIError | SWAPIErrorList = SWAPIError.from_errors(errors) # type: ignore
162
- except (json.JSONDecodeError, ValueError):
162
+ except ValueError:
163
163
  error: SWAPIError | SWAPIErrorList = SWAPIError.from_response(response) # type: ignore
164
164
 
165
165
  if isinstance(error, SWAPIErrorList) and len(error.errors) == 1:
@@ -95,7 +95,13 @@ class SWAPIError(SWAPIException):
95
95
  @classmethod
96
96
  def from_response(cls, response: Response) -> "SWAPIError":
97
97
  exception_class = cls.get_exception_class(response.status_code)
98
- response.headers["requested-url"] = str(response.request.url)
98
+
99
+ try:
100
+ response.headers["requested-url"] = str(response.request.url)
101
+ except RuntimeError:
102
+ # If the request URL is not available, we can ignore it.
103
+ pass
104
+
99
105
  return exception_class(
100
106
  status=response.status_code,
101
107
  title=response.reason_phrase,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: shopware-api-client
3
- Version: 1.0.107
3
+ Version: 1.0.108
4
4
  Summary: An api client for the Shopware API
5
5
  License: MIT
6
6
  Keywords: shopware,api,client
@@ -1,5 +1,5 @@
1
1
  shopware_api_client/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
- shopware_api_client/base.py,sha256=8KrOSxlFXDzkxvAj9YsjZhuEo07ZcXEvK3UvgZxGzZI,25331
2
+ shopware_api_client/base.py,sha256=nSTayZmkrSdHaRbQ8XbCbYRPnCjL4Nvg71D83FTcoR4,25307
3
3
  shopware_api_client/client.py,sha256=vkTZ8WLIu0Q3_73gXvidkTSpMJlWsJUjFyhDY2f2ISM,7583
4
4
  shopware_api_client/config.py,sha256=HStgfQcClpo_aqaTRDrqdTUjqSGPFkIMjrPwSruVnM8,1565
5
5
  shopware_api_client/endpoints/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -105,10 +105,10 @@ shopware_api_client/endpoints/store/__init__.py,sha256=LE_GL4jYVGrRdp6M1cPURI-UJ
105
105
  shopware_api_client/endpoints/store/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
106
106
  shopware_api_client/endpoints/store/core/address.py,sha256=Tm7ri-i0zhyt4LVEHaQy3xEvjapCCPRsYAp5lOCDOew,2774
107
107
  shopware_api_client/endpoints/store/core/cart.py,sha256=34eNwuv7H9WZUtJGf4TkTGHiGynDT6xeAt0gIl7V4KI,2584
108
- shopware_api_client/exceptions.py,sha256=KnOxav3iBPFfL3DVeURpaP2-lVHNDtiOt8jcmeZgxY8,4529
108
+ shopware_api_client/exceptions.py,sha256=tTnxdhlW0O8U_AsPF4NGoJ8wE3ScFj6QXwjjyIrUMsA,4663
109
109
  shopware_api_client/logging.py,sha256=4QSTK1vcdBew4shvLG-fm-xDOlddhOZeyb5T9Og0fSA,251
110
110
  shopware_api_client/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
111
- shopware_api_client-1.0.107.dist-info/LICENSE,sha256=qTihFhbGE2ZJJ7Byc9hnEYBY33yDK2Jw87SpAm0IKUs,1107
112
- shopware_api_client-1.0.107.dist-info/METADATA,sha256=-kfmkjiQsLqvwM9y4QoeNCnt9qpows2Pg_h8uLbOUd4,22659
113
- shopware_api_client-1.0.107.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
114
- shopware_api_client-1.0.107.dist-info/RECORD,,
111
+ shopware_api_client-1.0.108.dist-info/LICENSE,sha256=qTihFhbGE2ZJJ7Byc9hnEYBY33yDK2Jw87SpAm0IKUs,1107
112
+ shopware_api_client-1.0.108.dist-info/METADATA,sha256=HsMIVO-fyTVZGtuUO76vTw-Op4MDVm3eYf33RY5OvkU,22659
113
+ shopware_api_client-1.0.108.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
114
+ shopware_api_client-1.0.108.dist-info/RECORD,,