feldera 0.130.0__tar.gz → 0.131.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.130.0 → feldera-0.131.0}/PKG-INFO +1 -68
- feldera-0.131.0/README.md +79 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera.egg-info/PKG-INFO +1 -68
- {feldera-0.130.0 → feldera-0.131.0}/feldera.egg-info/SOURCES.txt +1 -7
- {feldera-0.130.0 → feldera-0.131.0}/pyproject.toml +1 -1
- feldera-0.130.0/README.md +0 -146
- feldera-0.130.0/tests/test_checkpoint_sync.py +0 -320
- feldera-0.130.0/tests/test_issue4457.py +0 -57
- feldera-0.130.0/tests/test_pipeline_builder.py +0 -53
- feldera-0.130.0/tests/test_shared_pipeline.py +0 -647
- feldera-0.130.0/tests/test_shared_pipeline_stress.py +0 -26
- feldera-0.130.0/tests/test_udf.py +0 -311
- {feldera-0.130.0 → feldera-0.131.0}/feldera/__init__.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/_callback_runner.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/_helpers.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/enums.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/output_handler.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/pipeline.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/pipeline_builder.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/__init__.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/_helpers.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/_httprequests.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/config.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/errors.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/feldera_client.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/feldera_config.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/pipeline.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/sql_table.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/rest/sql_view.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/runtime_config.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera/stats.py +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera.egg-info/dependency_links.txt +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera.egg-info/requires.txt +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/feldera.egg-info/top_level.txt +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/setup.cfg +0 -0
- {feldera-0.130.0 → feldera-0.131.0}/tests/test_uda.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: feldera
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.131.0
|
|
4
4
|
Summary: The feldera python client
|
|
5
5
|
Author-email: Feldera Team <dev@feldera.com>
|
|
6
6
|
License: MIT
|
|
@@ -84,73 +84,6 @@ make html
|
|
|
84
84
|
|
|
85
85
|
To clean the build, run `make clean`.
|
|
86
86
|
|
|
87
|
-
## Testing
|
|
88
|
-
|
|
89
|
-
To run unit tests:
|
|
90
|
-
|
|
91
|
-
```bash
|
|
92
|
-
cd python && python3 -m pytest tests/
|
|
93
|
-
```
|
|
94
|
-
|
|
95
|
-
- This will detect and run all test files that match the pattern `test_*.py` or
|
|
96
|
-
`*_test.py`.
|
|
97
|
-
- By default, the tests expect a running Feldera instance at `http://localhost:8080`.
|
|
98
|
-
To override the default endpoint, set the `FELDERA_HOST` environment variable.
|
|
99
|
-
|
|
100
|
-
To run tests from a specific file:
|
|
101
|
-
|
|
102
|
-
```bash
|
|
103
|
-
(cd python && python3 -m pytest ./tests/path-to-file.py)
|
|
104
|
-
```
|
|
105
|
-
|
|
106
|
-
To run a specific test:
|
|
107
|
-
|
|
108
|
-
```bash
|
|
109
|
-
uv run python -m pytest tests/test_shared_pipeline.py::TestPipeline::test_adhoc_query_hash -v
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
#### Running All Tests
|
|
113
|
-
|
|
114
|
-
The tests validate end-to-end correctness of SQL functionality. To
|
|
115
|
-
run the tests use:
|
|
116
|
-
|
|
117
|
-
```bash
|
|
118
|
-
cd python
|
|
119
|
-
PYTHONPATH=`pwd` ./tests/run-all-tests.sh
|
|
120
|
-
```
|
|
121
|
-
|
|
122
|
-
### Reducing Compilation Cycles
|
|
123
|
-
|
|
124
|
-
To reduce redundant compilation cycles during testing:
|
|
125
|
-
|
|
126
|
-
* **Inherit from `SharedTestPipeline`** instead of `unittest.TestCase`.
|
|
127
|
-
* **Define DDLs** (e.g., `CREATE TABLE`, `CREATE VIEW`) in the **docstring** of each test method.
|
|
128
|
-
* All DDLs from all test functions in the class are combined and compiled into a single pipeline.
|
|
129
|
-
* If a table or view is already defined in one test, it can be used directly in others without redefinition.
|
|
130
|
-
* Ensure that all table and view names are unique within the class.
|
|
131
|
-
* Use `@enterprise_only` on tests that require Enterprise features. Their DDLs will be skipped on OSS builds.
|
|
132
|
-
* Use `self.set_runtime_config(...)` to override the default pipeline config.
|
|
133
|
-
* Reset it at the end using `self.reset_runtime_config()`.
|
|
134
|
-
* Access the shared pipeline via `self.pipeline`.
|
|
135
|
-
|
|
136
|
-
#### Example
|
|
137
|
-
|
|
138
|
-
```python
|
|
139
|
-
from tests.shared_test_pipeline import SharedTestPipeline
|
|
140
|
-
|
|
141
|
-
class TestAverage(SharedTestPipeline):
|
|
142
|
-
def test_average(self):
|
|
143
|
-
"""
|
|
144
|
-
CREATE TABLE students(id INT, name STRING);
|
|
145
|
-
CREATE MATERIALIZED VIEW v AS SELECT * FROM students;
|
|
146
|
-
"""
|
|
147
|
-
...
|
|
148
|
-
self.pipeline.start()
|
|
149
|
-
self.pipeline.input_pandas("students", df)
|
|
150
|
-
self.pipeline.wait_for_completion(True)
|
|
151
|
-
...
|
|
152
|
-
```
|
|
153
|
-
|
|
154
87
|
## Linting and formatting
|
|
155
88
|
|
|
156
89
|
Use [Ruff] to run the lint checks that will be executed by the
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# Feldera Python SDK
|
|
2
|
+
|
|
3
|
+
Feldera Python is the Feldera SDK for Python developers.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
uv pip install feldera
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
### Installing from Github
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
uv pip install git+https://github.com/feldera/feldera#subdirectory=python
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Similarly, to install from a specific branch:
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
uv pip install git+https://github.com/feldera/feldera@{BRANCH_NAME}#subdirectory=python
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
Replace `{BRANCH_NAME}` with the name of the branch you want to install from.
|
|
24
|
+
|
|
25
|
+
### Installing from Local Directory
|
|
26
|
+
|
|
27
|
+
If you have cloned the Feldera repo, you can install the python SDK as follows:
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
# the Feldera Python SDK is present inside the python/ directory
|
|
31
|
+
cd python
|
|
32
|
+
# If you don't have a virtual environment, create one
|
|
33
|
+
uv venv
|
|
34
|
+
source .venv/activate
|
|
35
|
+
# Install the SDK in editable mode
|
|
36
|
+
uv pip install .
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
You also have to install the `pytest` module:
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
python3 -m pip install pytest
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
## Documentation
|
|
46
|
+
|
|
47
|
+
The Python SDK documentation is available at
|
|
48
|
+
[Feldera Python SDK Docs](https://docs.feldera.com/python).
|
|
49
|
+
|
|
50
|
+
To build the html documentation run:
|
|
51
|
+
|
|
52
|
+
Ensure that you have sphinx installed. If not, install it using `uv pip install sphinx`.
|
|
53
|
+
|
|
54
|
+
Then run the following commands:
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
cd docs
|
|
58
|
+
sphinx-apidoc -o . ../feldera
|
|
59
|
+
make html
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
To clean the build, run `make clean`.
|
|
63
|
+
|
|
64
|
+
## Linting and formatting
|
|
65
|
+
|
|
66
|
+
Use [Ruff] to run the lint checks that will be executed by the
|
|
67
|
+
precommit hook when a PR is submitted:
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
ruff check python/
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
To reformat the code in the same way as the precommit hook:
|
|
74
|
+
|
|
75
|
+
```bash
|
|
76
|
+
ruff format
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
[Ruff]: https://github.com/astral-sh/ruff
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: feldera
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.131.0
|
|
4
4
|
Summary: The feldera python client
|
|
5
5
|
Author-email: Feldera Team <dev@feldera.com>
|
|
6
6
|
License: MIT
|
|
@@ -84,73 +84,6 @@ make html
|
|
|
84
84
|
|
|
85
85
|
To clean the build, run `make clean`.
|
|
86
86
|
|
|
87
|
-
## Testing
|
|
88
|
-
|
|
89
|
-
To run unit tests:
|
|
90
|
-
|
|
91
|
-
```bash
|
|
92
|
-
cd python && python3 -m pytest tests/
|
|
93
|
-
```
|
|
94
|
-
|
|
95
|
-
- This will detect and run all test files that match the pattern `test_*.py` or
|
|
96
|
-
`*_test.py`.
|
|
97
|
-
- By default, the tests expect a running Feldera instance at `http://localhost:8080`.
|
|
98
|
-
To override the default endpoint, set the `FELDERA_HOST` environment variable.
|
|
99
|
-
|
|
100
|
-
To run tests from a specific file:
|
|
101
|
-
|
|
102
|
-
```bash
|
|
103
|
-
(cd python && python3 -m pytest ./tests/path-to-file.py)
|
|
104
|
-
```
|
|
105
|
-
|
|
106
|
-
To run a specific test:
|
|
107
|
-
|
|
108
|
-
```bash
|
|
109
|
-
uv run python -m pytest tests/test_shared_pipeline.py::TestPipeline::test_adhoc_query_hash -v
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
#### Running All Tests
|
|
113
|
-
|
|
114
|
-
The tests validate end-to-end correctness of SQL functionality. To
|
|
115
|
-
run the tests use:
|
|
116
|
-
|
|
117
|
-
```bash
|
|
118
|
-
cd python
|
|
119
|
-
PYTHONPATH=`pwd` ./tests/run-all-tests.sh
|
|
120
|
-
```
|
|
121
|
-
|
|
122
|
-
### Reducing Compilation Cycles
|
|
123
|
-
|
|
124
|
-
To reduce redundant compilation cycles during testing:
|
|
125
|
-
|
|
126
|
-
* **Inherit from `SharedTestPipeline`** instead of `unittest.TestCase`.
|
|
127
|
-
* **Define DDLs** (e.g., `CREATE TABLE`, `CREATE VIEW`) in the **docstring** of each test method.
|
|
128
|
-
* All DDLs from all test functions in the class are combined and compiled into a single pipeline.
|
|
129
|
-
* If a table or view is already defined in one test, it can be used directly in others without redefinition.
|
|
130
|
-
* Ensure that all table and view names are unique within the class.
|
|
131
|
-
* Use `@enterprise_only` on tests that require Enterprise features. Their DDLs will be skipped on OSS builds.
|
|
132
|
-
* Use `self.set_runtime_config(...)` to override the default pipeline config.
|
|
133
|
-
* Reset it at the end using `self.reset_runtime_config()`.
|
|
134
|
-
* Access the shared pipeline via `self.pipeline`.
|
|
135
|
-
|
|
136
|
-
#### Example
|
|
137
|
-
|
|
138
|
-
```python
|
|
139
|
-
from tests.shared_test_pipeline import SharedTestPipeline
|
|
140
|
-
|
|
141
|
-
class TestAverage(SharedTestPipeline):
|
|
142
|
-
def test_average(self):
|
|
143
|
-
"""
|
|
144
|
-
CREATE TABLE students(id INT, name STRING);
|
|
145
|
-
CREATE MATERIALIZED VIEW v AS SELECT * FROM students;
|
|
146
|
-
"""
|
|
147
|
-
...
|
|
148
|
-
self.pipeline.start()
|
|
149
|
-
self.pipeline.input_pandas("students", df)
|
|
150
|
-
self.pipeline.wait_for_completion(True)
|
|
151
|
-
...
|
|
152
|
-
```
|
|
153
|
-
|
|
154
87
|
## Linting and formatting
|
|
155
88
|
|
|
156
89
|
Use [Ruff] to run the lint checks that will be executed by the
|
|
@@ -24,10 +24,4 @@ feldera/rest/feldera_config.py
|
|
|
24
24
|
feldera/rest/pipeline.py
|
|
25
25
|
feldera/rest/sql_table.py
|
|
26
26
|
feldera/rest/sql_view.py
|
|
27
|
-
tests/
|
|
28
|
-
tests/test_issue4457.py
|
|
29
|
-
tests/test_pipeline_builder.py
|
|
30
|
-
tests/test_shared_pipeline.py
|
|
31
|
-
tests/test_shared_pipeline_stress.py
|
|
32
|
-
tests/test_uda.py
|
|
33
|
-
tests/test_udf.py
|
|
27
|
+
tests/test_uda.py
|
feldera-0.130.0/README.md
DELETED
|
@@ -1,146 +0,0 @@
|
|
|
1
|
-
# Feldera Python SDK
|
|
2
|
-
|
|
3
|
-
Feldera Python is the Feldera SDK for Python developers.
|
|
4
|
-
|
|
5
|
-
## Installation
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
uv pip install feldera
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
### Installing from Github
|
|
12
|
-
|
|
13
|
-
```bash
|
|
14
|
-
uv pip install git+https://github.com/feldera/feldera#subdirectory=python
|
|
15
|
-
```
|
|
16
|
-
|
|
17
|
-
Similarly, to install from a specific branch:
|
|
18
|
-
|
|
19
|
-
```bash
|
|
20
|
-
uv pip install git+https://github.com/feldera/feldera@{BRANCH_NAME}#subdirectory=python
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
Replace `{BRANCH_NAME}` with the name of the branch you want to install from.
|
|
24
|
-
|
|
25
|
-
### Installing from Local Directory
|
|
26
|
-
|
|
27
|
-
If you have cloned the Feldera repo, you can install the python SDK as follows:
|
|
28
|
-
|
|
29
|
-
```bash
|
|
30
|
-
# the Feldera Python SDK is present inside the python/ directory
|
|
31
|
-
cd python
|
|
32
|
-
# If you don't have a virtual environment, create one
|
|
33
|
-
uv venv
|
|
34
|
-
source .venv/activate
|
|
35
|
-
# Install the SDK in editable mode
|
|
36
|
-
uv pip install .
|
|
37
|
-
```
|
|
38
|
-
|
|
39
|
-
You also have to install the `pytest` module:
|
|
40
|
-
|
|
41
|
-
```bash
|
|
42
|
-
python3 -m pip install pytest
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
## Documentation
|
|
46
|
-
|
|
47
|
-
The Python SDK documentation is available at
|
|
48
|
-
[Feldera Python SDK Docs](https://docs.feldera.com/python).
|
|
49
|
-
|
|
50
|
-
To build the html documentation run:
|
|
51
|
-
|
|
52
|
-
Ensure that you have sphinx installed. If not, install it using `uv pip install sphinx`.
|
|
53
|
-
|
|
54
|
-
Then run the following commands:
|
|
55
|
-
|
|
56
|
-
```bash
|
|
57
|
-
cd docs
|
|
58
|
-
sphinx-apidoc -o . ../feldera
|
|
59
|
-
make html
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
To clean the build, run `make clean`.
|
|
63
|
-
|
|
64
|
-
## Testing
|
|
65
|
-
|
|
66
|
-
To run unit tests:
|
|
67
|
-
|
|
68
|
-
```bash
|
|
69
|
-
cd python && python3 -m pytest tests/
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
- This will detect and run all test files that match the pattern `test_*.py` or
|
|
73
|
-
`*_test.py`.
|
|
74
|
-
- By default, the tests expect a running Feldera instance at `http://localhost:8080`.
|
|
75
|
-
To override the default endpoint, set the `FELDERA_HOST` environment variable.
|
|
76
|
-
|
|
77
|
-
To run tests from a specific file:
|
|
78
|
-
|
|
79
|
-
```bash
|
|
80
|
-
(cd python && python3 -m pytest ./tests/path-to-file.py)
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
To run a specific test:
|
|
84
|
-
|
|
85
|
-
```bash
|
|
86
|
-
uv run python -m pytest tests/test_shared_pipeline.py::TestPipeline::test_adhoc_query_hash -v
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
#### Running All Tests
|
|
90
|
-
|
|
91
|
-
The tests validate end-to-end correctness of SQL functionality. To
|
|
92
|
-
run the tests use:
|
|
93
|
-
|
|
94
|
-
```bash
|
|
95
|
-
cd python
|
|
96
|
-
PYTHONPATH=`pwd` ./tests/run-all-tests.sh
|
|
97
|
-
```
|
|
98
|
-
|
|
99
|
-
### Reducing Compilation Cycles
|
|
100
|
-
|
|
101
|
-
To reduce redundant compilation cycles during testing:
|
|
102
|
-
|
|
103
|
-
* **Inherit from `SharedTestPipeline`** instead of `unittest.TestCase`.
|
|
104
|
-
* **Define DDLs** (e.g., `CREATE TABLE`, `CREATE VIEW`) in the **docstring** of each test method.
|
|
105
|
-
* All DDLs from all test functions in the class are combined and compiled into a single pipeline.
|
|
106
|
-
* If a table or view is already defined in one test, it can be used directly in others without redefinition.
|
|
107
|
-
* Ensure that all table and view names are unique within the class.
|
|
108
|
-
* Use `@enterprise_only` on tests that require Enterprise features. Their DDLs will be skipped on OSS builds.
|
|
109
|
-
* Use `self.set_runtime_config(...)` to override the default pipeline config.
|
|
110
|
-
* Reset it at the end using `self.reset_runtime_config()`.
|
|
111
|
-
* Access the shared pipeline via `self.pipeline`.
|
|
112
|
-
|
|
113
|
-
#### Example
|
|
114
|
-
|
|
115
|
-
```python
|
|
116
|
-
from tests.shared_test_pipeline import SharedTestPipeline
|
|
117
|
-
|
|
118
|
-
class TestAverage(SharedTestPipeline):
|
|
119
|
-
def test_average(self):
|
|
120
|
-
"""
|
|
121
|
-
CREATE TABLE students(id INT, name STRING);
|
|
122
|
-
CREATE MATERIALIZED VIEW v AS SELECT * FROM students;
|
|
123
|
-
"""
|
|
124
|
-
...
|
|
125
|
-
self.pipeline.start()
|
|
126
|
-
self.pipeline.input_pandas("students", df)
|
|
127
|
-
self.pipeline.wait_for_completion(True)
|
|
128
|
-
...
|
|
129
|
-
```
|
|
130
|
-
|
|
131
|
-
## Linting and formatting
|
|
132
|
-
|
|
133
|
-
Use [Ruff] to run the lint checks that will be executed by the
|
|
134
|
-
precommit hook when a PR is submitted:
|
|
135
|
-
|
|
136
|
-
```bash
|
|
137
|
-
ruff check python/
|
|
138
|
-
```
|
|
139
|
-
|
|
140
|
-
To reformat the code in the same way as the precommit hook:
|
|
141
|
-
|
|
142
|
-
```bash
|
|
143
|
-
ruff format
|
|
144
|
-
```
|
|
145
|
-
|
|
146
|
-
[Ruff]: https://github.com/astral-sh/ruff
|