wcp-library 1.6.6__py3-none-any.whl → 1.6.7__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.
@@ -25,8 +25,10 @@ def retry(func: callable) -> callable:
25
25
  return func(self, *args, **kwargs)
26
26
  except (oracledb.OperationalError, oracledb.DatabaseError, psycopg.OperationalError) as e:
27
27
  if isinstance(e, (oracledb.OperationalError, oracledb.DatabaseError, psycopg.OperationalError, psycopg.DatabaseError)):
28
- error_obj, = e.args
29
- if error_obj.full_code in self.retry_error_codes and self._retry_count < self.retry_limit:
28
+ (error_obj,) = e.args
29
+ if isinstance(error_obj, str):
30
+ raise e
31
+ elif error_obj.full_code in self.retry_error_codes and self._retry_count < self.retry_limit:
30
32
  self._retry_count += 1
31
33
  logger.debug("Oracle connection error")
32
34
  logger.debug(error_obj.message)
@@ -55,7 +57,9 @@ def async_retry(func: callable) -> callable:
55
57
  except (oracledb.OperationalError, oracledb.DatabaseError, psycopg.OperationalError) as e:
56
58
  if isinstance(e, (oracledb.OperationalError, oracledb.DatabaseError, psycopg.OperationalError, psycopg.DatabaseError)):
57
59
  error_obj, = e.args
58
- if error_obj.full_code in self.retry_error_codes and self._retry_count < self.retry_limit:
60
+ if isinstance(error_obj, str):
61
+ raise e
62
+ elif error_obj.full_code in self.retry_error_codes and self._retry_count < self.retry_limit:
59
63
  self._retry_count += 1
60
64
  logger.debug(f"{self._db_service} connection error")
61
65
  logger.debug(error_obj.message)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: wcp-library
3
- Version: 1.6.6
3
+ Version: 1.6.7
4
4
  Summary: Common utilites for internal development at WCP
5
5
  Author: Mitch-Petersen
6
6
  Author-email: mitch.petersen@wcap.ca
@@ -19,10 +19,10 @@ wcp_library/logging.py,sha256=e6gG7HFgUrMajUZs4Gs0atFfOJJmdmxN0GerfynNWlY,2061
19
19
  wcp_library/selenium/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
20
20
  wcp_library/selenium/_selenium_driver.py,sha256=Es83ISNryOVhYGDo_xrr8nCLsbnVBeXsaz1sRiz7kLI,2961
21
21
  wcp_library/selenium/selenium_helper.py,sha256=OJvC0RlblfMWhmjNxiY582yuzkDgjzFZMuRz_8to3PY,2000
22
- wcp_library/sql/__init__.py,sha256=f0JyVyFyUjueQ1XdVmCgmRjzkFENmFKl3BOzrvv3i1I,2422
22
+ wcp_library/sql/__init__.py,sha256=fgewoQeGWIkVXwPWvt2_PRyDBajaSq2ztanOYezRcqY,2594
23
23
  wcp_library/sql/oracle.py,sha256=hsZbnuCxEZuUdZ8Z4FVRjxAcIjkMNkHMzLEAiT51nQY,19321
24
24
  wcp_library/sql/postgres.py,sha256=cLOurfmad3WqJcE7FiSxUyzo_0patpfMcTfQAoiteuU,18525
25
25
  wcp_library/time.py,sha256=ktSzhK7SZnGPNXobFexnhFGQAcriLCJQKxnO0fed8fQ,1740
26
- wcp_library-1.6.6.dist-info/METADATA,sha256=it5SD45PMZplcIY5Zmh6EAR7dPmY74L7DF9Q4AupgUI,1393
27
- wcp_library-1.6.6.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
28
- wcp_library-1.6.6.dist-info/RECORD,,
26
+ wcp_library-1.6.7.dist-info/METADATA,sha256=_FkNZq1tCOWJKjspLLaKwIAZomtBF47t0CStm1dWl-0,1393
27
+ wcp_library-1.6.7.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
28
+ wcp_library-1.6.7.dist-info/RECORD,,