Persisted outputs cannot be read after a spec version bump
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
Direzione di ricerca
Start by reading the workspace output lookup and Store.read behavior described in the issue, then inspect the four options and their tradeoffs. The issue identifies no source files or tests; first locate the workspace and folder store implementations. Done means choosing and implementing a way to read persisted outputs across spec versions or workspaces, with tests that cover the selected behavior.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Since #174, Store.read(record, output, tp) takes the type that the spec declares for the output, and the workspace passes it from the binding of the record's spec:
spec_id = self._views.records.spec(ref.record) # SpecId(name, version)
binding = self._bindings.get(spec_id) # None -> NotReadable
tp = binding.spec.outputs.model_fields[ref.output].annotation
value = self._store.read(ref.record, ref.output, tp)
The reason: the folder store writes scipp HDF5, which holds no Python types, so a group (a pydantic model) can only be rebuilt from the declared type.
Consequence: a workspace reads the persisted outputs only of the specs it binds, by name and version.
bindings = [IOFQ v1] -> persists record r1
upgrade: bindings = [IOFQ v2]
client.output(r1) -> NotReadable: the workspace does not run loki-iofq v1
So after a version bump, the outputs persisted under the old version cannot be read, although the files are intact, and a request cannot reference them. The same holds for a second workspace that shares the store but runs other specs, which contradicts "workspaces share values only through the store" unless both bind the spec.
Options:
- Keep old versions bound. The deployment lists the bindings of every version whose outputs it still wants to read. No code change; the cost moves to whoever maintains the list.
- Bind specs for reading without a workflow. A workspace takes specs it only reads (
WorkflowSpecwithout a binding). Reading then needs the spec's package, not its workflow's dependencies. - Store the type with the value, e.g. the qualified class name as an attribute. Reading then needs neither binding nor spec, but imports a class by a name read from a file, and a renamed or moved class breaks old files.
- Read without the type, as plain
DataGroup/dict, when the spec is not bound. The value is then not what the workflow returned, socheck_fitand typed consumers do not apply.
I lean to 2: it keeps the rule that the spec says what an output is, and separates "can describe" from "can run".
- Lingua principale
- Python
- Stelle
- 0
- Fork
- 1
- Merge medio
- 8h 48m
- PR unite (30g)
- 70
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di scipp/essapps
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
I maintainer di solito rispondono entro 1 giorno
-
A number that is not finite is stored as None at a field that accepts NoneForse già presa @jeevanabhi-r l’ha presa 6 giorni fa. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
scipp/essapps#140 · 3 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 32/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di scipp/essapps
Issue simili
-
question
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 68/100
vllm-project/vime#524 ·
I maintainer di solito rispondono entro 7 giorni
-
WOPI editor page is scrollable by a few pixels, which breaks scrolling in the document (Firefox)Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
suitenumerique/drive#969 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
theupdateframework/python-tuf#3044 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
FAIRmat-NFDI/pynxtools#861 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
NVIDIA/nsight-python#88 ·
I maintainer di solito rispondono entro 1 giorno