Dagster library for ser/de of data
Project description
dagster-serde
Type-aware ser/de library for Dagster.
@dataclass
class MyStruct:
foo: str
my_struct = MyStruct(foo="bar")
@asset(
io_manager_key="json_io_manager",
)
def upstream() -> MyStruct:
return my_struct # my_struct is serialized to a json file
@asset
def downstream(
upstream: MyStruct,
): # my_struct is loaded as MyStruct based on the type hint
assert upstream == my_struct
Installation
pip install dagster-serde
IOManagers
BaseSerdeUPathIOManager
Base class for IOManagers that ser/de to/from filesystems.
JsonIOManager
Implements BaseSerdeUPathIOManager
for JSON files.
Examples
See examples.
Development
Installation
poetry install
poetry run pre-commit install
Testing
poetry run pytest
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
dagster_serde-0.0.0.tar.gz
(8.3 kB
view hashes)
Built Distribution
Close
Hashes for dagster_serde-0.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d9bdf6d0a943b9455572a259b7dcdf39359d3e50206626f45fb1d817d03d6057 |
|
MD5 | 16756c1a199fb402be89b3a169a4f463 |
|
BLAKE2b-256 | c2afca12183a49e76ca3c0c8b4fc351af1bec370b76a3b029341fd465253fc1f |