Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/michaelhatherly/plutoserialization.jl
A Julia package for serialization in Pluto notebooks.
https://github.com/michaelhatherly/plutoserialization.jl
julia pluto-notebooks serialization
Last synced: 2 months ago
JSON representation
A Julia package for serialization in Pluto notebooks.
- Host: GitHub
- URL: https://github.com/michaelhatherly/plutoserialization.jl
- Owner: MichaelHatherly
- License: mit
- Created: 2021-10-05T20:35:36.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2024-04-02T09:17:34.000Z (9 months ago)
- Last Synced: 2024-11-02T15:15:01.751Z (2 months ago)
- Topics: julia, pluto-notebooks, serialization
- Language: Julia
- Homepage:
- Size: 38.1 KB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PlutoSerialization
This package provides `serialize` and `deserialize` functions which are
compatible with the standard library `Serialization` module's function, but are
able to handle serializing/deserializing data from/to `Pluto` notebooks.## Details
Standard `Serialization` does not work inside `Pluto` notebooks since
evaluation of cells will increment the current "workspace" `Module` into which
definitions are evaluated. This is done to allow for re-definition of constants
such as type definitions, but means that `Serialization.serialize` will save
`Module` references that may not exist when we `deserialize` the file in a new
notebook session since the workspace number will not likely be the same.This package implements a custom `Serialization.AbstractSerializer` that
searches all defined workspaces for valid definitions during `deserialize`
allowing it to not have to rely on fixed `Module` references. Aside from the
changes required for searching workspaces it should replicate the behaviour of
`Serialization`.