Publication dateNov 3, 2025
Confidentiality public Public
Migrate gws_project data from Space
TASK
timer
2 minutes, 53 seconds
Typing name : TASK.gws_project.MigrateProjectDataFromSpace Brick : gws_project One-off migration: copy project/task documents from Space to local storage
One-off, idempotent migration of gws_project data out of Space.
For each project that still has a space_folder_id, this task copies the
content of its Space folders into local storage:
- Space
DOCUMENT objects are downloaded and stored as FILE documents in
the brick's dedicated file store.
- Space
CONSTELLAB_DOCUMENT objects are converted to local rich-text
NOTE documents (content fetched via the Space API).
- Task documents (identified by the Space tag
task:<task_id> in the
root task's folder) are attached to the exact task; documents in a task
folder whose tag matches no existing task are attached to the root task
and flagged as orphans in the report.
- Other object types (lab notes, scenarios, resources, ...) are skipped and
listed in the report: they are lab objects synced to Space and stay
accessible; only the app's aggregated view of them disappears.
The task is idempotent: every migrated document records its Space id
(space_document_id), and already-migrated ids are skipped on re-run. It
never writes to Space — the Space folders are left untouched as an
archive. Per-document errors are reported and never abort the run.
Config:
dry_run (default True): only report what would be migrated, without
downloading or writing anything. Run once with dry_run=True, review
the report (including the total byte size against the lab's disk space),
then re-run with dry_run=False.
Output: a JSON report with per-project counts and details (migrated files
and notes, already-migrated, orphans, skipped objects, errors, byte size).
logout
Output
Migration report
Resource that holds a JSON dict
settings
Configuration
Only report what would be migrated, without writing anything
Type : boolDefault value : trueTechnical bricks to reuse or customize Have you developed a brick?
Share it to accelerate projects for the entire community.