You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-**Build & Install:** Use `maturin develop` (optionally with `--uv`) to build Rust and install the Python extension.
13
+
-**Testing:** Run `pytest` in the root or `python/tests/` for Python tests. Rust code is tested via `cargo test`.
14
+
-**Linting:** Use `ruff` for Python (`./ci/scripts/python_lint.sh`), `rustfmt` and `clippy` for Rust (`./ci/scripts/rust_fmt.sh`, `./ci/scripts/rust_clippy.sh`).
15
+
-**Pre-commit:** Install with `pre-commit install` and run checks before pushing.
2
16
3
17
## Python Code Style
4
18
@@ -38,6 +52,26 @@ When generating Python code for the DataFusion Python project, adhere to the fol
38
52
- Group related tests in classes
39
53
- Use pytest style assertions instead of unittest style
40
54
55
+
## Patterns & Examples
56
+
57
+
-**SessionContext**: Central objectfor query execution. See `examples/create-context.py`.
58
+
-**DataFrame**: Immutable, chainable APIfor query building. See `examples/dataframe-parquet.py`.
59
+
-**UDF/UDAF/UDWF**: Register Python functions for use inSQL/DataFrame queries. See `examples/python-udf.py`, `examples/python-udaf.py`.
60
+
-**PyArrow**: Used forall data interchange; prefer Arrow types in UDFs and DataFrame construction.
0 commit comments