feldera 0.45.0__tar.gz → 0.47.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.
- {feldera-0.45.0 → feldera-0.47.0}/PKG-INFO +1 -1
- {feldera-0.45.0 → feldera-0.47.0}/feldera/pipeline.py +24 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera.egg-info/PKG-INFO +1 -1
- {feldera-0.45.0 → feldera-0.47.0}/pyproject.toml +1 -1
- {feldera-0.45.0 → feldera-0.47.0}/tests/test_pipeline.py +3 -1
- {feldera-0.45.0 → feldera-0.47.0}/tests/test_pipeline_builder.py +45 -0
- {feldera-0.45.0 → feldera-0.47.0}/README.md +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/__init__.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/_callback_runner.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/_helpers.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/enums.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/output_handler.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/pipeline_builder.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/__init__.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/_httprequests.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/config.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/errors.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/feldera_client.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/pipeline.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/sql_table.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/rest/sql_view.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera/runtime_config.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera.egg-info/SOURCES.txt +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera.egg-info/dependency_links.txt +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera.egg-info/requires.txt +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/feldera.egg-info/top_level.txt +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/setup.cfg +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/tests/test_udf.py +0 -0
- {feldera-0.45.0 → feldera-0.47.0}/tests/test_variant.py +0 -0
|
@@ -807,3 +807,27 @@ resume a paused pipeline."""
|
|
|
807
807
|
|
|
808
808
|
self.refresh()
|
|
809
809
|
return self._inner.program_info
|
|
810
|
+
|
|
811
|
+
def program_error(self) -> Mapping[str, Any]:
|
|
812
|
+
"""
|
|
813
|
+
Return the program error of the pipeline.
|
|
814
|
+
If there are no errors, the `exit_code` field inside both `sql_compilation` and `rust_compilation` will be 0.
|
|
815
|
+
"""
|
|
816
|
+
|
|
817
|
+
self.refresh()
|
|
818
|
+
return self._inner.program_error
|
|
819
|
+
|
|
820
|
+
def errors(self) -> List[Mapping[str, Any]]:
|
|
821
|
+
"""
|
|
822
|
+
Returns a list of all errors in this pipeline.
|
|
823
|
+
"""
|
|
824
|
+
errors = []
|
|
825
|
+
perr = self.program_error()
|
|
826
|
+
for e in perr.keys():
|
|
827
|
+
err = perr.get(e)
|
|
828
|
+
if err and err.get("exit_code", 0) != 0:
|
|
829
|
+
errors.append({e: err})
|
|
830
|
+
derr = self.deployment_error()
|
|
831
|
+
if derr:
|
|
832
|
+
errors.append(derr)
|
|
833
|
+
return errors
|
|
@@ -106,7 +106,9 @@ class TestPipeline(unittest.TestCase):
|
|
|
106
106
|
stats = TEST_CLIENT.get_pipeline_stats(name)
|
|
107
107
|
|
|
108
108
|
assert stats is not None
|
|
109
|
-
assert stats.get("
|
|
109
|
+
assert stats.get("global_metrics") is not None
|
|
110
|
+
assert stats.get("inputs") is not None
|
|
111
|
+
assert stats.get("outputs") is not None
|
|
110
112
|
|
|
111
113
|
TEST_CLIENT.pause_pipeline(name)
|
|
112
114
|
TEST_CLIENT.shutdown_pipeline(name)
|
|
@@ -1141,6 +1141,51 @@ CREATE MATERIALIZED VIEW v AS SELECT * FROM map_tbl;
|
|
|
1141
1141
|
pipeline.shutdown()
|
|
1142
1142
|
pipeline.delete()
|
|
1143
1143
|
|
|
1144
|
+
def test_program_error0(self):
|
|
1145
|
+
sql = "create taabl;"
|
|
1146
|
+
name = "test_program_error0"
|
|
1147
|
+
|
|
1148
|
+
try:
|
|
1149
|
+
_ = PipelineBuilder(TEST_CLIENT, name, sql).create_or_replace()
|
|
1150
|
+
except Exception:
|
|
1151
|
+
pass
|
|
1152
|
+
|
|
1153
|
+
pipeline = Pipeline.get(name, TEST_CLIENT)
|
|
1154
|
+
err = pipeline.program_error()
|
|
1155
|
+
|
|
1156
|
+
assert err["sql_compilation"] != 0
|
|
1157
|
+
|
|
1158
|
+
pipeline.shutdown()
|
|
1159
|
+
pipeline.delete()
|
|
1160
|
+
|
|
1161
|
+
def test_program_error1(self):
|
|
1162
|
+
sql = ""
|
|
1163
|
+
name = "test_program_error1"
|
|
1164
|
+
|
|
1165
|
+
_ = PipelineBuilder(TEST_CLIENT, name, sql).create_or_replace()
|
|
1166
|
+
|
|
1167
|
+
pipeline = Pipeline.get(name, TEST_CLIENT)
|
|
1168
|
+
err = pipeline.program_error()
|
|
1169
|
+
|
|
1170
|
+
assert err["sql_compilation"]["exit_code"] == 0
|
|
1171
|
+
assert err["rust_compilation"]["exit_code"] == 0
|
|
1172
|
+
|
|
1173
|
+
pipeline.shutdown()
|
|
1174
|
+
pipeline.delete()
|
|
1175
|
+
|
|
1176
|
+
def test_errors0(self):
|
|
1177
|
+
sql = "SELECT invalid"
|
|
1178
|
+
name = "test_errors0"
|
|
1179
|
+
|
|
1180
|
+
try:
|
|
1181
|
+
_ = PipelineBuilder(TEST_CLIENT, name, sql).create_or_replace()
|
|
1182
|
+
except Exception:
|
|
1183
|
+
pass
|
|
1184
|
+
|
|
1185
|
+
pipeline = Pipeline.get(name, TEST_CLIENT)
|
|
1186
|
+
|
|
1187
|
+
assert pipeline.errors()[0]["sql_compilation"]["exit_code"] != 0
|
|
1188
|
+
|
|
1144
1189
|
|
|
1145
1190
|
if __name__ == "__main__":
|
|
1146
1191
|
unittest.main()
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|