bigdata-smart-batching 1.4.0__tar.gz → 1.4.1__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.
Files changed (22) hide show
  1. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/CHANGELOG.md +6 -0
  2. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/PKG-INFO +1 -1
  3. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/pyproject.toml +1 -1
  4. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/src/bigdata_smart_batching/smart_batching.py +13 -19
  5. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/uv.lock +1 -1
  6. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/.gitignore +0 -0
  7. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/LICENSE +0 -0
  8. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/Makefile +0 -0
  9. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/README.md +0 -0
  10. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/docs/smart-batching-architecture.md +0 -0
  11. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/examples/example.py +0 -0
  12. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/examples/example_non_determinism.py +0 -0
  13. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/examples/example_overlapping.py +0 -0
  14. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/src/bigdata_smart_batching/__init__.py +0 -0
  15. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/src/bigdata_smart_batching/output_converter.py +0 -0
  16. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/src/bigdata_smart_batching/search_function.py +0 -0
  17. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/src/bigdata_smart_batching/smart_batching_config.py +0 -0
  18. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/tests/__init__.py +0 -0
  19. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/tests/test_config.py +0 -0
  20. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/tests/test_output_converter.py +0 -0
  21. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/tests/test_rate_limiter.py +0 -0
  22. {bigdata_smart_batching-1.4.0 → bigdata_smart_batching-1.4.1}/tests/test_validation.py +0 -0
@@ -6,6 +6,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
8
 
9
+ ## [1.4.1] - 2026-06-02
10
+
11
+ ### Fixed
12
+
13
+ - `SmartBatchingPlanner._post_with_retry`: retry with exponential backoff on any non-200 HTTP status or transient network error. Previously only `429` and `403` were retried; other statuses (e.g. `500`) failed immediately.
14
+
9
15
  ## [1.4.0] - 2026-05-20
10
16
 
11
17
  ### Added
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: bigdata-smart-batching
3
- Version: 1.4.0
3
+ Version: 1.4.1
4
4
  Summary: High-performance semantic search with intelligent company grouping and parallel execution
5
5
  Project-URL: homepage, https://bigdata.com/api
6
6
  Author-email: "Bigdata.com" <support@ravenpack.com>
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "bigdata-smart-batching"
3
- version = "1.4.0"
3
+ version = "1.4.1"
4
4
  description = "High-performance semantic search with intelligent company grouping and parallel execution"
5
5
  readme = "README.md"
6
6
  authors = [{ name = "Bigdata.com", email = "support@ravenpack.com" }]
@@ -695,8 +695,8 @@ class SmartBatchingPlanner:
695
695
  ) -> dict:
696
696
  """POST through the shared rate limiter and concurrency semaphore.
697
697
 
698
- Uses exponential backoff between retries on 429, 403, and transient
699
- network errors. All sleeps between retries happen *outside* the
698
+ Uses exponential backoff between retries on any non-200 HTTP status or
699
+ transient network error. All sleeps between retries happen *outside* the
700
700
  concurrency semaphore so a backing-off thread doesn't pin a slot that
701
701
  another worker could use.
702
702
 
@@ -711,8 +711,7 @@ class SmartBatchingPlanner:
711
711
  Parsed JSON response on a 200 response.
712
712
 
713
713
  Raises:
714
- RuntimeError: On a non-retriable HTTP error status, or after retries
715
- are exhausted.
714
+ RuntimeError: After retries are exhausted.
716
715
  """
717
716
  for retry_count in range(max_retries):
718
717
  retry_wait: float | None = None
@@ -728,22 +727,17 @@ class SmartBatchingPlanner:
728
727
  if response.status_code == 200:
729
728
  return response.json()
730
729
 
731
- if response.status_code in (429, 403):
732
- retry_wait = exponential_backoff(retry_count)
733
- last_error = (
734
- f"API error {response.status_code}: {response.text[:500]}"
730
+ retry_wait = exponential_backoff(retry_count)
731
+ error_msg = f"API error {response.status_code}"
732
+ try:
733
+ error_details = response.json()
734
+ error_msg = (
735
+ f"{error_msg}\nResponse: {json.dumps(error_details, indent=2)}"
735
736
  )
736
- else:
737
- error_msg = f"API error {response.status_code}"
738
- try:
739
- error_details = response.json()
740
- error_msg = f"{error_msg}\nResponse: {json.dumps(error_details, indent=2)}"
741
- except ValueError:
742
- error_msg = f"{error_msg}\nResponse: {response.text[:500]}"
743
- raise RuntimeError(f"{error_prefix}: {error_msg}")
744
-
745
- except RuntimeError:
746
- raise
737
+ except ValueError:
738
+ error_msg = f"{error_msg}\nResponse: {response.text[:500]}"
739
+ last_error = error_msg
740
+
747
741
  except requests.exceptions.Timeout as e:
748
742
  retry_wait = exponential_backoff(retry_count)
749
743
  last_error = str(e)
@@ -12,7 +12,7 @@ resolution-markers = [
12
12
 
13
13
  [[package]]
14
14
  name = "bigdata-smart-batching"
15
- version = "1.3.1"
15
+ version = "1.4.1"
16
16
  source = { editable = "." }
17
17
  dependencies = [
18
18
  { name = "matplotlib" },