Warning
🚧 Sprout is still in active development and evolving quickly, so the documentation and functionality may not work as described and could undergo substantial changes 🚧
Function reference
Core functions
Core functions that support the creation and management of data packages and data resources.
Data package functions
Functions to work with and manage data packages, but not the data resources within them.
create_package_structure | Sets up the folder structure for a new package. |
edit_package_properties | Edits the properties of an existing package. |
Data resource functions
Functions to work with and manage data resources found within a data package.
write_resource_properties | Writes the specified resource properties to the datapackage.json file. |
create_resource_properties | Creates a valid properties object for the specified resource. |
create_resource_structure | Creates the directory structure of a new resource. |
Property dataclasses
Dataclasses that support creating correct data package properties.
ConstraintsProperties | A class that expresses constraints for validating field values. |
ContributorProperties | The people or organizations who contributed to this data package. |
FieldProperties | A field in a table schema. |
LicenseProperties | The license(s) under which the package or resource is provided. |
MissingValueProperties | Values that, when encountered in the source, should be considered as not present. |
PackageProperties | A data package. |
ReferenceProperties | The destination part of a foreign key. |
ResourceProperties | A data resource. |
SourceProperties | The raw sources for this data package. |
TableDialectProperties | Table dialect describes how tabular data is stored in a file. |
TableSchemaForeignKeyProperties | A foreign key in a table schema. |
TableSchemaProperties | A table schema for a data resource. |
Path functions
Functions to support providing the correct file paths to data package and data resource functions.
path_package | Gets the absolute path to the specified package. |
path_package_database | Gets the absolute path to the specified package’s SQL database. |
path_package_properties | Gets the absolute path to the specified package’s properties file. |
path_packages | Gets the absolute path to the packages folder. |
path_resource | Gets the absolute path to the specified resource. |
path_resource_data | Gets the absolute path to the specified resource’s data (i.e., parquet) file. |
path_resource_raw | Gets the absolute path to the specified resource’s raw folder. |
path_resource_raw_files | Gets the absolute path to the raw files of the specified resource. |
path_resources | Gets the absolute path to the resources of the specified package. |
path_sprout_global | Gets Sprout’s global path location. |