🚧 Sprout is still in active development and evolving quickly, so the documentation and functionality may not work as described and could undergo substantial changes 🚧
Use this any time you want to update the package’s properties. When you need to update the datapackage.json file, use this function to ensure the properties are correctly structured before they’re written. It only updates the properties of the package itself, not of the data resources contained within the package.
If the properties in the update_properties argument are correct (i.e., they pass the properties checks), they will overwrite any pre-existing properties within the current properties.
Parameters
current_properties:PackageProperties
The current properties found in the datapackage.json file. Use read_properties() to get the current properties.
update_properties:PackageProperties
The new package properties to update from the current ones. Use PackageProperties to provide a correctly structured properties dictionary. See help(PackageProperties) for details on how to use it.
Returns
PackageProperties
The updated package properties as a PackageProperties object. Use
PackageProperties
write_package_properties() to save it back to the datapackage.json
PackageProperties
file.
Raises
ExceptionGroup
If there is an error in the current, incoming, or resulting package properties. A group of CheckErrors, one error for each failed check.