Skip to content

fix: preserve package split requirements and storage precedence - #56

Draft
jay-m-dev wants to merge 4 commits into
developfrom
fix/package-export-publication-join
Draft

jay-m-dev wants to merge 4 commits into
developfrom
fix/package-export-publication-join

Conversation

@jay-m-dev

@jay-m-dev jay-m-dev commented Nov 10, 2026 •

Copy link
Copy Markdown
Collaborator

Fix four confirmed package and storage correctness defects from the independent review of develop at 31d3631:

  • Package exports fail with AmbiguousForeignKeysError because revisions and protocols have two foreign-key paths. Join explicitly through revision ownership, supporting the selected historical publication.
  • An imported missing pinned split silently becomes an original-only dataset. Retain the unresolved split requirement in durable import provenance and reject configuration acknowledgement until a local split is restored or the dataset is explicitly rebound. Publication stays blocked until configuration succeeds.
  • Split document IDs can disagree with their filenames and pins. Preflight now validates canonical identities for every split document, including unreferenced members, and rejects mismatches before activation.
  • Explicit empty storage overrides lose to environment settings. Distinguish absent keys from empty values so empty overrides select the data root's default child.

Regression coverage compiles actual export-worker SQL, exercises missing-split configuration/publication through the API handlers with repair and rebind paths, inspects complete conflicting-ID archives, and checks empty override precedence through workspace-core and application settings across all storage namespaces.

Validation:

  • Full local backend suite: 2,131 passed, 3 skipped, 14 statistical tests deselected; one CWD-dependent stats test initially failed because the temporary directory lacked scripts/. After linking the repository scripts directory into the credential-file-free working directory, the failed test passed (1 passed). No product code changed for that setup correction.
  • Focused import/export/lifecycle/storage suites: 134 passed against disposable PostgreSQL 16 with pgvector and both database migrations.
  • Repository-wide Ruff (plus changed workspace-core code), uv lock --check, and git diff --check: passed.
  • Mypy (warn-only): 695 errors in 58 files, matching the independent review's recorded backlog.
  • Local environment: Python 3.14; existing installed dependencies reused with unchanged lockfile. Tests run from a credential-file-free temporary working directory with explicit disposable database URLs and storage roots.

PR remains a draft and must not be merged until the maintainer explicitly requests it. Native Motoro continuation after Redis restart and browser behavior remain unverified.

Jay Moran added 2 commits November 10, 2026 12:29
Join revisions through their owning protocol explicitly because the current publication pointer creates a second foreign-key path. Compile the worker queries in the export regression test to catch ambiguous joins.
Retain missing split requirements in durable import provenance and block configuration until a local split is restored or the dataset is explicitly rebound. Reject split document identities that disagree with their canonical filenames and pins, including unreferenced split documents. Honor explicit empty storage overrides ahead of environment values.
@jay-m-dev jay-m-dev changed the title fix: disambiguate package export publication join fix: preserve package split requirements and storage precedence Nov 10, 2026
Jay Moran added 2 commits November 10, 2026 13:03
Reuse the shared file drop field for package imports and disable browsing and drops during upload. Cover dropped-package inspection and prevention of concurrent uploads.
Save the live canvas and prepare the revision returned by publication when users choose to publish before downloading. Keep historical-version downloads available and surface publication failures. Use the compatible request-key helper for imports and broaden gzip file chooser filters.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant