Skip to content

[codex] Add project manager core#168

Merged
akgohain merged 8 commits into
mainfrom
codex/pr136-merge-sandbox
Apr 21, 2026
Merged

[codex] Add project manager core#168
akgohain merged 8 commits into
mainfrom
codex/pr136-merge-sandbox

Conversation

@akgohain
Copy link
Copy Markdown
Collaborator

What changed

This is an intermediate merge candidate that brings the core Project Manager feature into main without pulling in the entire original PR payload.

It adds:

  • a new Project Manager tab in the app shell
  • a JSON-backed Project Manager backend under /api/pm
  • runtime project configuration for metadata JSON and storage root
  • first-run setup flow with modal settings, existing JSON loading, and fresh-project initialization
  • volume ingestion from storage into the active metadata JSON
  • admin/worker login flows and role-aware PM views
  • assignment and status tracking for volumes
  • schema/template support for PM JSON generation and interpretation
  • broader PM volume discovery for .h5, .hdf5, .tif, .tiff, .nii, .nii.gz, .mrc, .zarr, .n5, and image-stack directories

Why

PR #136 had the right semantic direction, but the original branch had become too broad to merge cleanly as one artifact. This draft captures the operational core:

  • Project Manager as an additive module
  • mutable project state backed by JSON
  • configurable project source and storage root
  • real ingest/assign/status workflow

User impact

Users can now:

  • open a dedicated Project Manager module
  • load an existing PM JSON or start a fresh project
  • point the PM module at a storage root
  • ingest supported project volumes into the active JSON
  • assign owners and track volume status
  • log in as admin or worker and see role-appropriate PM views

Validation

Ran:

  • uv run --with pytest python -m pytest tests/test_project_manager_routes.py tests/test_project_manager_discovery.py -q
  • npm run build

Notes

This is intentionally scoped as an initial mergeable PM core, not the full original PR. Additional follow-up cleanup and expansion can land separately once this base is in main.

sam4coding and others added 8 commits April 10, 2026 09:52
- Implemented Login UI and Auth context with localStorage persistence.
- Added Admin/Worker role-based view gating.
- Integrated mock data for 19 real volumes from cluster export.
- Resolved merge conflicts with upstream/main and handled WorkflowSelector sunset.
- Implemented Login UI and Auth context with localStorage persistence.
- Added Admin/Worker role-based view gating.
- Integrated mock data for 1000 volumes (real data ingestion pending).
- Resolved merge conflicts with upstream/main.
@akgohain akgohain marked this pull request as ready for review April 21, 2026 20:11
@akgohain akgohain merged commit f2e620c into main Apr 21, 2026
0 of 2 checks passed
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9973906b2e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

}


@router.patch("/volumes/{volume_id}")
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Handle slash-containing IDs in volume patch route

The patch endpoint is declared as /volumes/{volume_id}, which only matches a single path segment, but ingested IDs are built from rel_path and can include / for nested files (for example dataset_a/subdir/vol.h5). In those common cases, status/assignee updates will 404 even though the volume exists, so admins/workers cannot update many discovered volumes.

Useful? React with 👍 / 👎.

try {
const res = await apiClient.post("/api/pm/data/ingest");
if (res.data.ok) {
setPmState(res.data.data);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Preserve global progress after ingestion

After POST /api/pm/data/ingest, this code stores res.data.data directly into pmState, but that payload comes from _read_data() and does not include global_progress. Because provider values fall back to zeros when pmState.global_progress is missing, the UI continues to show 0 tracked volumes / “needs sync” immediately after a successful ingest until a later refresh or per-volume update.

Useful? React with 👍 / 👎.

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.

2 participants