feldera 0.123.0__tar.gz → 0.124.0__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.

Potentially problematic release.


This version of feldera might be problematic. Click here for more details.

Files changed (33) hide show
  1. {feldera-0.123.0 → feldera-0.124.0}/PKG-INFO +1 -1
  2. {feldera-0.123.0 → feldera-0.124.0}/feldera/pipeline.py +39 -2
  3. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/feldera_client.py +16 -2
  4. {feldera-0.123.0 → feldera-0.124.0}/feldera.egg-info/PKG-INFO +1 -1
  5. {feldera-0.123.0 → feldera-0.124.0}/pyproject.toml +1 -1
  6. {feldera-0.123.0 → feldera-0.124.0}/tests/test_shared_pipeline.py +45 -1
  7. {feldera-0.123.0 → feldera-0.124.0}/README.md +0 -0
  8. {feldera-0.123.0 → feldera-0.124.0}/feldera/__init__.py +0 -0
  9. {feldera-0.123.0 → feldera-0.124.0}/feldera/_callback_runner.py +0 -0
  10. {feldera-0.123.0 → feldera-0.124.0}/feldera/_helpers.py +0 -0
  11. {feldera-0.123.0 → feldera-0.124.0}/feldera/enums.py +0 -0
  12. {feldera-0.123.0 → feldera-0.124.0}/feldera/output_handler.py +0 -0
  13. {feldera-0.123.0 → feldera-0.124.0}/feldera/pipeline_builder.py +0 -0
  14. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/__init__.py +0 -0
  15. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/_helpers.py +0 -0
  16. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/_httprequests.py +0 -0
  17. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/config.py +0 -0
  18. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/errors.py +0 -0
  19. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/feldera_config.py +0 -0
  20. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/pipeline.py +0 -0
  21. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/sql_table.py +0 -0
  22. {feldera-0.123.0 → feldera-0.124.0}/feldera/rest/sql_view.py +0 -0
  23. {feldera-0.123.0 → feldera-0.124.0}/feldera/runtime_config.py +0 -0
  24. {feldera-0.123.0 → feldera-0.124.0}/feldera/stats.py +0 -0
  25. {feldera-0.123.0 → feldera-0.124.0}/feldera.egg-info/SOURCES.txt +0 -0
  26. {feldera-0.123.0 → feldera-0.124.0}/feldera.egg-info/dependency_links.txt +0 -0
  27. {feldera-0.123.0 → feldera-0.124.0}/feldera.egg-info/requires.txt +0 -0
  28. {feldera-0.123.0 → feldera-0.124.0}/feldera.egg-info/top_level.txt +0 -0
  29. {feldera-0.123.0 → feldera-0.124.0}/setup.cfg +0 -0
  30. {feldera-0.123.0 → feldera-0.124.0}/tests/test_checkpoint_sync.py +0 -0
  31. {feldera-0.123.0 → feldera-0.124.0}/tests/test_pipeline_builder.py +0 -0
  32. {feldera-0.123.0 → feldera-0.124.0}/tests/test_shared_pipeline_stress.py +0 -0
  33. {feldera-0.123.0 → feldera-0.124.0}/tests/test_udf.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: feldera
3
- Version: 0.123.0
3
+ Version: 0.124.0
4
4
  Summary: The feldera python client
5
5
  Author-email: Feldera Team <dev@feldera.com>
6
6
  License: MIT
@@ -1061,7 +1061,18 @@ pipeline '{self.name}' to sync checkpoint '{uuid}'"""
1061
1061
  errors.append(derr)
1062
1062
  return errors
1063
1063
 
1064
- def support_bundle(self, output_path: Optional[str] = None) -> bytes:
1064
+ def support_bundle(
1065
+ self,
1066
+ output_path: Optional[str] = None,
1067
+ *,
1068
+ circuit_profile: bool = True,
1069
+ heap_profile: bool = True,
1070
+ metrics: bool = True,
1071
+ logs: bool = True,
1072
+ stats: bool = True,
1073
+ pipeline_config: bool = True,
1074
+ system_config: bool = True,
1075
+ ) -> bytes:
1065
1076
  """
1066
1077
  Generate a support bundle containing diagnostic information from this pipeline.
1067
1078
 
@@ -1071,11 +1082,37 @@ pipeline '{self.name}' to sync checkpoint '{uuid}'"""
1071
1082
 
1072
1083
  :param output_path: Optional path to save the support bundle file. If None,
1073
1084
  the support bundle is only returned as bytes.
1085
+ :param circuit_profile: Whether to collect circuit profile data (default: True)
1086
+ :param heap_profile: Whether to collect heap profile data (default: True)
1087
+ :param metrics: Whether to collect metrics data (default: True)
1088
+ :param logs: Whether to collect logs data (default: True)
1089
+ :param stats: Whether to collect stats data (default: True)
1090
+ :param pipeline_config: Whether to collect pipeline configuration data (default: True)
1091
+ :param system_config: Whether to collect system configuration data (default: True)
1074
1092
  :return: The support bundle as bytes (ZIP archive)
1075
1093
  :raises FelderaAPIError: If the pipeline does not exist or if there's an error
1076
1094
  """
1077
1095
 
1078
- support_bundle_bytes = self.client.get_pipeline_support_bundle(self.name)
1096
+ # Build query parameters
1097
+ params = {}
1098
+ if not circuit_profile:
1099
+ params["circuit_profile"] = "false"
1100
+ if not heap_profile:
1101
+ params["heap_profile"] = "false"
1102
+ if not metrics:
1103
+ params["metrics"] = "false"
1104
+ if not logs:
1105
+ params["logs"] = "false"
1106
+ if not stats:
1107
+ params["stats"] = "false"
1108
+ if not pipeline_config:
1109
+ params["pipeline_config"] = "false"
1110
+ if not system_config:
1111
+ params["system_config"] = "false"
1112
+
1113
+ support_bundle_bytes = self.client.get_pipeline_support_bundle(
1114
+ self.name, params=params
1115
+ )
1079
1116
 
1080
1117
  if output_path is not None:
1081
1118
  path = pathlib.Path(output_path)
@@ -138,7 +138,17 @@ class FelderaClient:
138
138
  err_msg += f"Code snippet:\n{sql_error['snippet']}"
139
139
  raise RuntimeError(err_msg)
140
140
 
141
- raise RuntimeError(f"The program failed to compile: {status}")
141
+ error_message = f"The program failed to compile: {status}\n"
142
+
143
+ rust_error = p.program_error.get("rust_compilation")
144
+ if rust_error is not None:
145
+ error_message += f"Rust Error: {rust_error}\n"
146
+
147
+ system_error = p.program_error.get("system_error")
148
+ if system_error is not None:
149
+ error_message += f"System Error: {system_error}"
150
+
151
+ raise RuntimeError(error_message)
142
152
 
143
153
  logging.debug("still compiling %s, waiting for 100 more milliseconds", name)
144
154
  time.sleep(0.1)
@@ -952,7 +962,9 @@ Reason: The pipeline is in a STOPPED state due to the following error:
952
962
 
953
963
  return FelderaConfig(resp)
954
964
 
955
- def get_pipeline_support_bundle(self, pipeline_name: str) -> bytes:
965
+ def get_pipeline_support_bundle(
966
+ self, pipeline_name: str, params: Optional[Dict[str, Any]] = None
967
+ ) -> bytes:
956
968
  """
957
969
  Generate a support bundle containing diagnostic information from a pipeline.
958
970
 
@@ -961,12 +973,14 @@ Reason: The pipeline is in a STOPPED state due to the following error:
961
973
  and packages them into a single ZIP file for support purposes.
962
974
 
963
975
  :param pipeline_name: The name of the pipeline
976
+ :param params: Optional query parameters to control data collection
964
977
  :return: The support bundle as bytes (ZIP file)
965
978
  :raises FelderaAPIError: If the pipeline does not exist or if there's an error
966
979
  """
967
980
 
968
981
  resp = self.http.get(
969
982
  path=f"/pipelines/{pipeline_name}/support_bundle",
983
+ params=params,
970
984
  stream=True,
971
985
  )
972
986
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: feldera
3
- Version: 0.123.0
3
+ Version: 0.124.0
4
4
  Summary: The feldera python client
5
5
  Author-email: Feldera Team <dev@feldera.com>
6
6
  License: MIT
@@ -6,7 +6,7 @@ build-backend = "setuptools.build_meta"
6
6
  name = "feldera"
7
7
  readme = "README.md"
8
8
  description = "The feldera python client"
9
- version = "0.123.0"
9
+ version = "0.124.0"
10
10
  license = { text = "MIT" }
11
11
  requires-python = ">=3.10"
12
12
  authors = [
@@ -555,7 +555,7 @@ class TestPipeline(SharedTestPipeline):
555
555
  def test_support_bundle(self):
556
556
  self.pipeline.start()
557
557
 
558
- # Test getting support bundle as bytes
558
+ # Test getting support bundle as bytes (all collections enabled)
559
559
  support_bundle_bytes = self.pipeline.support_bundle()
560
560
  assert isinstance(support_bundle_bytes, bytes)
561
561
  assert len(support_bundle_bytes) > 0
@@ -587,6 +587,50 @@ class TestPipeline(SharedTestPipeline):
587
587
  if os.path.exists(temp_path):
588
588
  os.unlink(temp_path)
589
589
 
590
+ def test_support_bundle_with_selectors(self):
591
+ self.pipeline.start()
592
+
593
+ # Test with all collections disabled
594
+ support_bundle_bytes = self.pipeline.support_bundle(
595
+ circuit_profile=False,
596
+ heap_profile=False,
597
+ metrics=False,
598
+ logs=False,
599
+ stats=False,
600
+ pipeline_config=False,
601
+ system_config=False,
602
+ )
603
+
604
+ assert isinstance(support_bundle_bytes, bytes)
605
+ assert len(support_bundle_bytes) > 0
606
+
607
+ # Verify it's a valid ZIP file
608
+ with zipfile.ZipFile(io.BytesIO(support_bundle_bytes), "r") as zip_file:
609
+ file_list = zip_file.namelist()
610
+ # Should only contain manifest.txt when all collections are disabled
611
+ assert len(file_list) == 1
612
+ assert "manifest.txt" in file_list
613
+
614
+ # Test with partial collections enabled
615
+ support_bundle_bytes = self.pipeline.support_bundle(
616
+ circuit_profile=True,
617
+ heap_profile=False,
618
+ metrics=True,
619
+ logs=False,
620
+ stats=True,
621
+ pipeline_config=False,
622
+ system_config=True,
623
+ )
624
+
625
+ assert isinstance(support_bundle_bytes, bytes)
626
+ assert len(support_bundle_bytes) > 0
627
+
628
+ # Verify it's a valid ZIP file
629
+ with zipfile.ZipFile(io.BytesIO(support_bundle_bytes), "r") as zip_file:
630
+ file_list = zip_file.namelist()
631
+ assert len(file_list) >= 2
632
+ assert "manifest.txt" in file_list
633
+
590
634
 
591
635
  if __name__ == "__main__":
592
636
  unittest.main()
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes