Function reference
Data resource functions
Functions to work with and manage data resources found within a data package.
| join_staging | Join DataFrames from staging/ into a single (Polars) DataFrame. |
| read_staging | Read all staging file(s) into a list of (Polars) DataFrames. |
| write_resource_data | Check and write the resource data into a file. |
| DataResourceError | Error listing issues in a data resource. |
Package property dataclasses
Dataclasses to help create properties at the package level.
| ContributorProperties | The people or organizations who contributed to this data package. |
| LicenseProperties | The license(s) under which the package or resource is provided. |
| SproutProperties | Properties for a data package. |
| SourceProperties | The raw sources for this data package. |
Resource property dataclasses
Dataclasses to help create properties at the resource level.
| ConstraintsProperties | A dataclass that expresses constraints for validating field values. |
| FieldProperties | A field in a table schema. |
| ReferenceProperties | The destination part of a foreign key. |
| ResourceProperties | A data resource. |
| TableSchemaForeignKeyProperties | A foreign key in a table schema. |
| TableSchemaProperties | A table schema for a data resource. |
Property functions
Functions used to work with properties.
| check_data | Checks that the DataFrame matches the requirements in the properties. |
| read_properties | Read in the properties from the datapackage.json file. |
| write_properties | Write the properties to the datapackage.json file. |
Helper functions
Functions to support working with data packages and running code within Seedcase Sprout.
| example_package_properties | Generate an example package properties object. |
| example_resource_properties | An example resource properties object. |
| example_resource_properties_all_types | An example resource properties with all Data Package types. |
| example_data | An example Polars data frame. |
| example_data_all_types | An example Polars data frame with all Data Package types. |
CLI functions
Functions available via the command line interface.
| extract_metadata | Extract metadata from a Parquet file. |
| init_metadata | Create a Python script with empty metadata fields. |