Repository navigation
feat: sandbox environment for testing dataset uploads - #26
Merged
Merged
Conversation
Sandbox Training:
- Add sandbox training command for first-time users
- Create sample BIDS dataset with EDF files
- Guide users through upload workflow before real datasets
- Require sandbox completion before first upload
npm CI Publishing:
- Add OIDC trusted publishing workflow (npm-publish.yml)
- Publish dev tag on dev branch push
- Publish PR{number} tag on feature branch push (with PR)
- Auto-comment on PRs with install instructions
- Upgrade npm to v11+ for OIDC support
Backend:
- Add sandbox dataset validation and filtering
- Improve error handling with warnings array
- Filter sandbox datasets from public listings
…trictions * feat: add E2E sandbox tests and regenerate-iam endpoint E2E Tests: - Add e2e-sandbox.test.ts that installs CLI from npm and tests - Update test workflow to run on PRs to dev and main - Test basic CLI commands, validation, and sandbox training Admin Endpoint: - Add POST /admin/regenerate-iam/:username endpoint - Regenerates IAM credentials for existing users - Restores access to all existing datasets - Useful for fixing IAM setup issues or rotating credentials API: - Add regenerateUserIam function to CLI API lib * fix: correct E2E test config and BIDS validation - Fix config directory path (nemar-cli -> nemar) - Fix config key name (apiToken -> apiKey) - Add username to config for --mine filter - Simplify BIDS dataset to minimal valid structure * fix: add Deno setup and improve E2E test debugging - Add Deno setup to e2e-sandbox job for BIDS validation - Add retry loop to wait for npm publish before installing - Add stderr output on test failures for debugging * fix: use NEMAR_CONFIG_DIR for reliable config path in E2E tests * feat: add sandbox file size limit and block DOI creation for sandbox - Limit sandbox datasets to 10MB total file size - Return 400 error if sandbox file size exceeds limit - Block DOI concept creation for sandbox datasets (xx prefix) - Block DOI version publishing for sandbox datasets - Sandbox datasets are for testing only, not real data storage * fix: address PR review findings - Add warning annotation for workflow fallback to dev tag - Log actual error in test cleanup catch block - Add missing datasets_restored field to RegenerateIamResponse * feat: add sandbox upload support to e2e-upload tests - Add TEST_SANDBOX_DATASET_ID env var to target specific sandbox dataset - Add TEST_CREATE_SANDBOX env var to enable actual sandbox uploads - Add test for sandbox upload with xx prefix datasets - Default behavior remains dry-run only (safe for CI)
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements sandbox environment for testing dataset uploads, resolving #16.
What's included:
Sandbox Training (PR #24)
nemar sandboxcommand for mandatory training before real uploadss3://nemar/sandbox/xx000xxx/)E2E Testing & Sandbox Restrictions (PR #25)
POST /admin/regenerate-iam/:usernameendpoint for IAM recoveryImplementation Checklist from #16
Backend:
CLI:
nemar sandboxcommandnemar sandbox status/nemar sandbox resetTesting:
Basic Functions Tested:
nemar auth statusnemar dataset validatenemar dataset upload(via sandbox)nemar dataset list --mineTest plan
Closes #16