Skip to content

Release v0.7.17 - #278

Merged
neuromechanist merged 9 commits into
mainfrom
dev
Mar 10, 2026
Merged

neuromechanist merged 9 commits into
mainfrom
dev

Conversation

@neuromechanist

@neuromechanist neuromechanist commented Mar 10, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Test plan

  • All changes merged to dev via individual PRs
  • CI passes on main after merge

* Fix BIDS CI failures from annex pointers and branch naming

- Filter out validation errors from git-annex pointer files in
  the BIDS validation workflow (#267). Detects both symlinks
  (locked repos) and pointer content (unlocked repos), excludes
  their errors from the failure count.

- Rename non-main branches to main after OpenNeuro clone (#266).
  Prevents the import flow from pushing to master while CI
  workflows are deployed on main.

Closes #266
Closes #267

* Address review: reuse ensureLocalMainBranch instead of inline
* Standardize config path to ~/.config/nemar/

Force config to ~/.config/nemar/config.json on all platforms
instead of OS-native paths. Migrates existing config on first run.
Migration skipped when NEMAR_CONFIG_DIR is set (test isolation).

Closes #269

* Address review: fix doc comment, add Windows migration path
Zenodo is no longer used; EZID is the DOI provider.
The step is skipped (not removed) to preserve DB compatibility.

Closes #268
* Block publication requests when BIDS CI is failing

Run readiness checks on publish request: deploy CI if missing,
check BIDS validation status. Block request if CI is failing
with clear message to user. Re-checking unblocks when fixed.

Also reject publish requests for already-published datasets.

Closes #270

* Address review: fix CHECK constraint, block edge cases, HTTP 422

- Recreate publication_requests table to add 'blocked' to CHECK
  constraint (SQLite cannot ALTER CHECK constraints)
- Block when no CI runs exist (pending) or run is in-progress
- Return HTTP 422 for blocked requests instead of 200
- Allow admin approve/deny to find blocked requests
* Block on-prefix datasets from nemar.org sync

OpenNeuro-imported datasets (on00xxxx) need alternate_id mapping
before they can be synced to nemar.org. Add guards in both the
publish pipeline sync_nemar step and the manual sync endpoint.

Closes #265

* Address review: mark skipped sync as completed

- Call updateProgress without error arg so skipped steps are
  marked completed (not failed), fixing resume behavior
- Move credential variables inside else block for natural
  type narrowing, removing non-null assertions
- Move variable declarations after early return guard
* Add admin email notification preferences

- Add email_preferences column to users table (migration 0015)
- Add getAdminEmailsForCategory() to filter admin recipients
- Add GET/PUT /admin/email-preferences API endpoints
- Add CLI commands: nemar admin email-preferences show/update
- Wire auth and dataset routes to use filtered email lists
- Fix TEST_API_URL env var leaking into manifest tests

* Address review: fix error handling and dedup

- Add try/catch around email send in /publish/resend endpoint
- Log corrupt email_preferences JSON instead of silently defaulting
- Log safety fallback when all admins opted out of a category
- Reuse parseEmailPreferences() and DEFAULT_EMAIL_PREFERENCES in admin routes
- Derive EmailCategory from EmailPreferences with keyof
- Distinguish missing user from missing preferences in GET handler
- Check ensureLocalMainBranch return value in OpenNeuro import
- Return 500 on publish resend email failure instead of success
- Block publish request on CI infrastructure failure instead of
  bypassing validation; warn when CI checks are skipped
- Rename duplicate migration 0015 to 0016 for email_preferences
- Fix misleading JSDoc on getAdminEmailsForCategory
- Fix "opt-in" terminology in migration comment
- Update stale module JSDoc in email.ts
- Complete doi subcommand list in admin.ts JSDoc
- Standardize config path in test helper (was still old path)
- Improve config migration failure message with manual recovery hint
- Extract BLOCK_MESSAGES constant; fix publish/status using wrong
  message for pending/in-progress block reasons
- Remove unused DEFAULT_EMAIL_PREFERENCES import
- Remove redundant as const assertion
- Add unit tests for parseEmailPreferences (15 cases)
- Add CLI smoke tests for admin email-preferences commands
The 0015_email_preferences migration was already applied to D1.
Renaming to 0016 made D1 treat it as new, failing with
"duplicate column name". Both 0015-prefixed migrations work
fine since D1 applies them alphabetically.
@neuromechanist
neuromechanist merged commit c90d8cc into main Mar 10, 2026
18 checks passed

This branch was previously deployed

2 inactive deployments
npm — fa7870f7 Deployed Mar 11, 2026 by neuromechanist via publish #478
development — fa7870f7 Deployed Mar 10, 2026 by neuromechanist via deploy-dev #136
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