nemar-cli 0.10.39 → 0.10.40-PR2277.5ec888a

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -131,7 +131,7 @@ sequenceDiagram
131
131
  API-->>U: Verification email
132
132
  U->>API: Click verification link
133
133
  API->>Admin: Notification: new user pending
134
- Admin->>CLI: nemar admin approve <user>
134
+ Admin->>CLI: nemar admin users approve <user>
135
135
  CLI->>API: POST /admin/approve
136
136
  API-->>U: Approval email with instructions
137
137
  U->>CLI: nemar auth login
@@ -253,7 +253,7 @@ sequenceDiagram
253
253
  participant GH as GitHub
254
254
 
255
255
  Note over A: First release: Admin creates concept DOI
256
- A->>CLI: nemar admin doi create nm000104
256
+ A->>CLI: nemar admin dataset doi create nm000104
257
257
  CLI->>API: POST /admin/doi/create
258
258
  API->>ZEN: Pre-reserve DOI
259
259
  API->>GH: Update dataset_description.json
@@ -323,35 +323,35 @@ nemar dataset publish resend <dataset-id> # Resend admin notification
323
323
  nemar dataset publish withdraw <dataset-id> # Take back your request (a withdrawn request; no admin step)
324
324
 
325
325
  # Admin: Manage publication requests
326
- nemar admin repo publish list # List active publication requests
327
- nemar admin repo publish list --all # Every request, whatever its state
328
- nemar admin repo publish list --denied # One state (also --published, --requested, ...)
329
- nemar admin repo publish list -s denied # Same as --denied (--status, as before)
330
- nemar admin repo publish list --search nm099999 --all
326
+ nemar admin dataset publish list # List active publication requests
327
+ nemar admin dataset publish list --all # Every request, whatever its state
328
+ nemar admin dataset publish list --denied # One state (also --published, --requested, ...)
329
+ nemar admin dataset publish list -s denied # Same as --denied (--status, as before)
330
+ nemar admin dataset publish list --search nm099999 --all
331
331
  # Look up a dataset by ID, user or name
332
- nemar admin repo publish list --needs-me # Only the requests you can act on now
333
- nemar admin repo publish show <dataset-id> # The automated review of one request, in full
334
- nemar admin repo publish start <dataset-id> # Start the automated review (--all: every request waiting)
335
- nemar admin repo publish next # One card per request that needs you: y approves, n denies, c comments
336
- nemar admin repo publish approve <dataset-id> # Approve and publish dataset
337
- nemar admin repo publish approve <dataset-id> --force
332
+ nemar admin dataset publish list --needs-me # Only the requests you can act on now
333
+ nemar admin dataset publish show <dataset-id> # The automated review of one request, in full
334
+ nemar admin dataset publish start <dataset-id> # Start the automated review (--all: every request waiting)
335
+ nemar admin dataset publish next # One card per request that needs you: y approves, n denies, c comments
336
+ nemar admin dataset publish approve <dataset-id> # Approve and publish dataset
337
+ nemar admin dataset publish approve <dataset-id> --force
338
338
  # Approve over a review that is not a pass
339
- nemar admin repo publish approve <dataset-id> --acknowledge-identifier-screen "<reason>"
339
+ nemar admin dataset publish approve <dataset-id> --acknowledge-identifier-screen "<reason>"
340
340
  # Approve over a screen that needs review
341
- nemar admin repo publish approve <dataset-id> --request-id <n>
341
+ nemar admin dataset publish approve <dataset-id> --request-id <n>
342
342
  # Approve only if request n is the one in force
343
- nemar admin repo publish deny <dataset-id> # Deny publication request
344
- nemar admin repo publish deny <dataset-id> --request-id <n>
343
+ nemar admin dataset publish deny <dataset-id> # Deny publication request
344
+ nemar admin dataset publish deny <dataset-id> --request-id <n>
345
345
  # Deny only if request n is the one in force
346
- nemar admin repo publish screen <dataset-id> # Re-run the identifier screen
346
+ nemar admin dataset publish screen <dataset-id> # Re-run the identifier screen
347
347
  ```
348
348
 
349
349
  A publication request is screened for identifying information before the
350
- admins are mailed; the mail, `publish status` and `admin repo publish list` state
350
+ admins are mailed; the mail, `publish status` and `admin dataset publish list` state
351
351
  the result, and approval waits for a screen that is clear for the current
352
352
  `main`.
353
353
  Each request also gets an automated review of what the depositor submitted,
354
- which `admin repo publish list` and `admin repo publish show` state.
354
+ which `admin dataset publish list` and `admin dataset publish show` state.
355
355
  An approval over a review that is not a pass needs `--force` and is recorded
356
356
  with your account.
357
357
  An approval is for the request it showed, and the API refuses it when that
@@ -366,7 +366,7 @@ approver, and `--force`, `--acknowledge-identifier-screen`, `--skip-ci-check`
366
366
  and `--sandbox` are refused.
367
367
  Without the variable the command is your own approval, recorded under your
368
368
  account, and `next` never reads it.
369
- Every failure of `admin repo publish` exits 1, and so does an outcome that is not
369
+ Every failure of `admin dataset publish` exits 1, and so does an outcome that is not
370
370
  what was asked: `publish screen` exits 1 when the API accepted the call but
371
371
  could not start the screen (the dispatch failed), and `publish approve` exits 1
372
372
  when the API's answer is not `published` (a tail job's warning leaves the
@@ -379,27 +379,51 @@ request `approving`; run it again once the cause the warning names is fixed).
379
379
  # User management
380
380
  nemar admin users # List all users
381
381
  nemar admin users --pending # List pending approvals
382
- nemar admin approve <username> # Approve user
383
- nemar admin revoke <username> # Revoke user access
384
- nemar admin role <username> <role> # Change user role
385
-
386
- # Dataset management
387
- nemar admin repo unpublish <id> # Authors pull a published dataset back to private (DOIs untouched, can publish again)
388
- nemar admin repo withdraw <id> # Broken or removed dataset: private and DOIs tombstoned
389
- nemar admin repo restore <id> # Reverse a withdraw
390
- nemar admin ci check <id> # Check CI status
391
- nemar admin ci add <id> # Deploy CI workflows
392
- nemar admin s3 regenerate-iam <user> # Regenerate AWS credentials
393
- nemar admin make-public <id> # Make a dataset public (publication can be pulled back with `repo unpublish`)
394
- nemar admin delete-dataset <id> # Delete dataset
382
+ nemar admin users approve <username> # Approve user
383
+ nemar admin users revoke <username> # Revoke user access
384
+ nemar admin users role <username> <role> # Change user role
385
+ nemar admin users kind <username> <kind> # Change account kind (person, service, test)
386
+ nemar admin users keys list <username> # API keys of a service or test account
387
+
388
+ # Dataset management (`admin dataset`; `admin repo` is an alias)
389
+ nemar admin dataset unpublish <id> # Authors pull a published dataset back to private (DOIs untouched, can publish again)
390
+ nemar admin dataset withdraw <id> # Broken or removed dataset: private and DOIs tombstoned
391
+ nemar admin dataset restore <id> # Reverse a withdraw
392
+ nemar admin dataset ci check <id> # Check CI status
393
+ nemar admin dataset ci add <id> # Deploy CI workflows
394
+ nemar admin dataset s3 lock <id> # Apply S3 Object Lock to a dataset
395
+ nemar admin dataset delete <id> # Delete dataset
396
+ nemar admin dataset reindex <id> # Refresh a dataset's metadata
397
+ nemar admin dataset doctor scan # Diagnose stuck-dataset patterns (read-only)
398
+ nemar admin dataset doctor fix <check> # Preview a check's remediation; --apply runs it
395
399
 
396
400
  # DOI management
397
- nemar admin doi create <id> # Create concept DOI
398
- nemar admin doi info <id> # Get DOI info
399
- nemar admin doi update <id> # Update DOI metadata
400
- nemar admin doi enrich <id> # Enrich DOI metadata
401
+ nemar admin dataset doi create <id> # Create concept DOI
402
+ nemar admin dataset doi info <id> # Get DOI info
403
+ nemar admin dataset doi update <id> # Update DOI metadata
404
+ nemar admin dataset doi enrich <id> # Enrich DOI metadata
405
+
406
+ # Changes to an existing dataset
407
+ nemar admin rework revert <id> # Revert a dataset to a previous version (via PR)
408
+ nemar admin rework annex normalize <id> # Move data kept in git into the annex; --apply makes the change
409
+
410
+ # Imports and upstream re-pulls
411
+ nemar admin import openneuro <ds-ids> # Import an OpenNeuro dataset
412
+ nemar admin import status [id] # Follow an import job
413
+ nemar admin repull plan <id> # Plan a re-pull of a newer upstream snapshot
414
+ nemar admin repull upstream-status # Which mirrors are behind upstream
415
+
416
+ # Across all datasets
417
+ nemar admin fleet drift # Repositories off the governance spec
418
+ nemar admin fleet sweep hed # A metadata sweep (also recording-stats, signal-defaults, ...)
419
+ nemar admin fleet summary check # summary.json coverage; --apply dispatches repairs
420
+ nemar admin fleet e2e-test # End-to-end test against nm099999
401
421
  ```
402
422
 
423
+ `nemar admin --help` lists the fourteen groups (ADR 0135).
424
+ `--apply` is the one flag that makes a dry-run-by-default command write; the spellings commands had before (`--execute`, `--write`, `--fix`) still work as hidden aliases.
425
+ A moved admin command, such as `nemar admin ci check`, exits 1 and names its new path; the CHANGELOG lists every one.
426
+
403
427
  ## Access Control
404
428
 
405
429
  | Role | Push Branches | Merge PRs | Delete Repos | Create DOI |
@@ -593,7 +617,7 @@ nemar auth login
593
617
 
594
618
  **"Branch protection not applied after upload"**
595
619
  - This is expected for new private datasets
596
- - Protection is applied when admin creates a DOI (`nemar admin doi create`)
620
+ - Protection is applied when admin creates a DOI (`nemar admin dataset doi create`)
597
621
  - Allows owners to freely modify their private workspace
598
622
 
599
623
  ## Development
@@ -23,13 +23,13 @@ ${t}`,QM,ZM,eL=(e,t,r)=>{let n=r===""?"":`with ${r.trim()}() `,s=JM.bind(null,n,
23
23
  `)}var Vl=!1;var{spawn:nV}=globalThis.Bun;function zl(e,t=[]){let r=e.replace(sV,'("$1","<redacted>")');for(let n of t)if(n.length>=oV)r=r.split(n).join("<redacted>");return r}function iV(e){let t=["AWS_SESSION_TOKEN","AWS_SECRET_ACCESS_KEY","AWS_ACCESS_KEY_ID"],r=new Set;for(let n of[process.env,e??{}])for(let s of t){let o=n[s];if(typeof o==="string"&&o.length>0)r.add(o)}return[...r]}async function hE(e,t){let r=e.getReader(),n=new TextDecoder,s="";while(!0){let{done:o,value:a}=await r.read();if(o)break;if(a.byteLength===0)continue;t(),s+=n.decode(a,{stream:!0})}return s+n.decode()}async function gE(e,t={}){let r={...process.env,GIT_TERMINAL_PROMPT:"0",...t.env};for(let y of t.unsetEnv??[])delete r[y];let n=nV({cmd:e,cwd:t.cwd,...t.stdin===void 0?{}:{stdin:new TextEncoder().encode(t.stdin)},stdout:"pipe",stderr:"pipe",env:r}),s=!1,o,a,i=performance.now(),c=()=>{if(a!==void 0)clearTimeout(a),a=void 0},u=()=>{if(!t.onInactivityWarning)return;c(),a=setTimeout(()=>{a=void 0;try{t.onInactivityWarning?.(performance.now()-i)}catch{console.error("Could not display subprocess inactivity warning; the child result is unaffected.")}},t.inactivityWarningAfterMs??aV)};if(u(),t.timeout)o=setTimeout(()=>{s=!0,c(),n.kill()},t.timeout);let l=cc()?[...iV(r),...t.redact??[]]:[];if(cc()){let y=t.cwd?` (cwd=${t.cwd})`:"";Ls(Pt.dim(zl(`$ ${e.join(" ")}${y}`,l)))}let d=()=>{i=performance.now(),u()},m,f,p,h=n.exited.then((y)=>(c(),y));try{[m,f,p]=await Promise.all([hE(n.stdout,d),hE(n.stderr,d),h])}finally{if(c(),o)clearTimeout(o)}if(cc()){if(t.sensitiveOutput)Ls(Pt.dim("[sensitive subprocess output suppressed]"));else{if(m.trim())Ls(Pt.dim(zl(m.trimEnd(),l)));if(f.trim())Ls(Pt.yellow(zl(f.trimEnd(),l)))}Ls(Pt.dim(`(exit ${p})`))}if(s)return{stdout:m,stderr:f||`Command timed out after ${Math.round(t.timeout/1000)}s`,exitCode:p??1,timedOut:!0};return{stdout:m,stderr:f,exitCode:p,timedOut:!1}}var sV,oV=8,aV=120000;var yE=L(()=>{Fl();sV=/\(\s*"((?:x-amz-)[^"]*|authorization|proxy-authorization)"\s*,\s*"[^"]*"\s*\)/gi});function uV(){if(process.platform==="darwin")return"macos";if(process.platform==="win32")return"windows";return"linux"}function vE(e,t=uV()){return e.installInstructions[t]}function lV(e){let t=e.match(/(\d+\.\d+(?:\.\d+)?)/);return t?t[1]:void 0}function fV(){let e=Number(process.env.TEST_PROBE_TIMEOUT_MS);return Number.isFinite(e)&&e>0?e:dV}async function bE(e){try{let{exitCode:t,stdout:r,timedOut:n}=await gE(e.cmd,{timeout:fV()});if(n)return{available:!1,timedOut:!0};if(t!==0)return{available:!1};return{available:!0,version:lV(r)}}catch(t){let r=t instanceof Error?t.message:String(t);if(!r.includes("ENOENT")&&!r.includes("not found"))console.error(` Warning: ${e.name} check failed unexpectedly: ${r}`);return{available:!1}}}async function Gl(){let e=Object.entries(_E);return Promise.all(e.map(async([t,r])=>{let{available:n,version:s,timedOut:o}=await bE(r);return{key:t,name:r.name,purpose:r.purpose,required:r.required,available:n,version:s,timedOut:o,installInstruction:vE(r)}}))}async function bB(){let t=(await Gl()).filter((r)=>r.required&&!r.available);if(t.length===0)return[];console.warn(`
24
24
  Heads up: some tools NEMAR needs for uploading/validating aren't installed yet:`);for(let r of t)console.warn(` - ${r.name} (${r.purpose})`),console.warn(` Install: ${r.installInstruction}`);return console.warn("Run `nemar doctor` anytime to re-check. You can finish signup without them.\n"),t}async function wB(e){let r=cV[e].map((a)=>_E[a]).filter(Boolean),n=await Promise.all(r.map(async(a)=>{let i=await bE(a);return{check:a,available:i.available,timedOut:i.timedOut}}));for(let a of n)if(a.timedOut&&a.check.required)console.warn(`Warning: ${a.check.name} did not respond to a version check in time; continuing anyway.`);let s=n.filter((a)=>!a.available&&!a.timedOut&&a.check.required).map((a)=>({tool:a.check.name,installInstruction:vE(a.check)}));if(s.length===0)return;let o=[`
25
25
  Missing required tools:`];for(let a of s)o.push(` ${a.tool} not installed`),o.push(` Install: ${a.installInstruction}`);throw Error(o.join(`
26
- `))}var _E,cV,dV=4000;var wE=L(()=>{yE();_E={git:{name:"git",purpose:"version control for dataset metadata",cmd:["git","--version"],required:!0,installInstructions:{macos:"brew install git (or install Xcode Command Line Tools)",linux:"sudo apt-get install git OR sudo dnf install git",windows:"winget install Git.Git (or https://git-scm.com/download/win)"}},"git-annex":{name:"git-annex",purpose:"large-file data transfer (upload/download)",cmd:["git-annex","version"],required:!0,installInstructions:{macos:"brew install git-annex",linux:"sudo apt-get install git-annex OR sudo dnf install git-annex",windows:"Download the installer from https://git-annex.branchable.com/install/Windows/"}},gh:{name:"GitHub CLI (gh)",purpose:"GitHub authentication + repository operations",cmd:["gh","--version"],required:!0,installInstructions:{macos:"brew install gh",linux:"See https://cli.github.com/manual/installation",windows:"winget install GitHub.cli (or: scoop install gh)"}},aws:{name:"AWS CLI",purpose:"S3 data upload/download",cmd:["aws","--version"],required:!0,installInstructions:{macos:"brew install awscli",linux:"pip install awscli OR sudo snap install aws-cli --classic",windows:"winget install Amazon.AWSCLI (or the MSI from https://aws.amazon.com/cli/)"}},deno:{name:"Deno",purpose:"BIDS validation",cmd:["deno","--version"],required:!0,installInstructions:{macos:"brew install deno (or: curl -fsSL https://deno.land/install.sh | sh)",linux:"curl -fsSL https://deno.land/install.sh | sh",windows:"winget install DenoLand.Deno (or: irm https://deno.land/install.ps1 | iex)"}}},cV={upload:["git-annex","gh","aws","deno"],download:["gh"],clone:["git","gh"],push:["git-annex","gh"],publish:["gh","aws"],update:["git","gh"],release:["git","gh"]}});var EE;var $E=L(()=>{EE={name:"nemar-cli",packageManager:"bun@1.4.3",version:"0.10.39",description:"CLI for NEMAR (Neuroelectromagnetic Data Archive and Tools Resource) dataset management",type:"module",main:"dist/index.js",bin:{nemar:"dist/index.js","git-annex-remote-nemar":"dist/git-annex-remote-nemar.js"},scripts:{dev:"bun run src/index.ts",build:"bun build src/index.ts src/git-annex-remote-nemar.ts --outdir dist --target bun --minify && sed '1s|#!/usr/bin/env node|#!/usr/bin/env bun|' dist/index.js > dist/index.js.tmp && mv dist/index.js.tmp dist/index.js",test:"bun test",lint:"biome check src/","lint:scrub":"biome check scripts/scrub shared/identifier-scrub.ts test/scrub","test:scrub":"bun test --preload ./test/scrub/helpers/temp-dirs-preload.ts --path-ignore-patterns='__run_every_scrub_suite__' test/scrub test/identifier-scan.test.ts test/identifier-scrub.test.ts test/identifier-dates.test.ts test/identifier-fleet.test.ts","migrations:d1-check":"bun run scripts/d1-migration-check.ts","zarr:geometry-check":"bun run backend/scripts/zarr-geometry-conformance.ts","lint:fix":"biome check --fix src/",format:"biome format --write src/",typecheck:"tsc --noEmit && tsc --noEmit -p backend","generate-openapi":"bun run scripts/generate-openapi.ts",prepublishOnly:"bun run build",prepare:"husky",postinstall:"bun scripts/postinstall-check.mjs",deploy:"wrangler deploy",preview:"wrangler dev"},keywords:["nemar","bids","neuroimaging","eeg","emg","datalad","cli"],author:"NEMAR Team",license:"CC-BY-NC-ND-4.0",repository:{type:"git",url:"git+https://github.com/nemarOrg/nemar-cli.git"},bugs:{url:"https://github.com/nemarOrg/nemar-cli/issues"},homepage:"https://docs.nemar.org",engines:{bun:">=1.0.0"},files:["dist","scripts/postinstall-check.mjs","scripts/recover-datasets.json","scripts/withdrawn-datasets.json","README.md","LICENSE"],dependencies:{chalk:"^5.3.0",commander:"^12.1.0",conf:"^13.0.1",inquirer:"^9.2.15",ora:"^8.0.1",semver:"^7.8.5",zod:"^3.23.8"},"lint-staged":{"src/**/*.{ts,tsx}":["biome check --fix"],"backend/src/**/*.{ts,tsx}":["biome check --fix"]},trustedDependencies:["@biomejs/biome"],devDependencies:{"@anthropic-ai/sdk":"^0.132.1","@asteasolutions/zod-to-openapi":"^7.3.4","@biomejs/biome":"1.9.4","@types/bun":"latest","@types/inquirer":"^9.0.7","@types/semver":"^7.8.0",ajv:"^8.20.0","ajv-formats":"^3.0.1",husky:"^9.1.7",jose:"6.2.12","lint-staged":"^16.3.2",oauth4webapi:"3.8.8","openid-client":"6.8.9",typescript:"^5.5.4",wrangler:"^4.70.0",yaml:"^2.8.4"}}});var uc;var Kl=L(()=>{$E();uc=EE.version});import{mkdirSync as mV,readdirSync as hV,unlinkSync as gV,writeFileSync as yV}from"fs";import{join as Hl}from"path";function PB(){Us=!0}function fc(){return Us}function CB(e,t=process.env){return e.includes("--debug")||t.NEMAR_DEBUG==="1"}function IB(e){TE=e,mr(`Step: ${e}`)}function jB(){RE=!0}function qB(){return RE}function DB(){if(kE)return;Wl=!0}function MB(){Wl=!1,kE=!0}function LB(){return Wl}function mr(e){if(Us)process.stderr.write(`[debug] ${e}
26
+ `))}var _E,cV,dV=4000;var wE=L(()=>{yE();_E={git:{name:"git",purpose:"version control for dataset metadata",cmd:["git","--version"],required:!0,installInstructions:{macos:"brew install git (or install Xcode Command Line Tools)",linux:"sudo apt-get install git OR sudo dnf install git",windows:"winget install Git.Git (or https://git-scm.com/download/win)"}},"git-annex":{name:"git-annex",purpose:"large-file data transfer (upload/download)",cmd:["git-annex","version"],required:!0,installInstructions:{macos:"brew install git-annex",linux:"sudo apt-get install git-annex OR sudo dnf install git-annex",windows:"Download the installer from https://git-annex.branchable.com/install/Windows/"}},gh:{name:"GitHub CLI (gh)",purpose:"GitHub authentication + repository operations",cmd:["gh","--version"],required:!0,installInstructions:{macos:"brew install gh",linux:"See https://cli.github.com/manual/installation",windows:"winget install GitHub.cli (or: scoop install gh)"}},aws:{name:"AWS CLI",purpose:"S3 data upload/download",cmd:["aws","--version"],required:!0,installInstructions:{macos:"brew install awscli",linux:"pip install awscli OR sudo snap install aws-cli --classic",windows:"winget install Amazon.AWSCLI (or the MSI from https://aws.amazon.com/cli/)"}},deno:{name:"Deno",purpose:"BIDS validation",cmd:["deno","--version"],required:!0,installInstructions:{macos:"brew install deno (or: curl -fsSL https://deno.land/install.sh | sh)",linux:"curl -fsSL https://deno.land/install.sh | sh",windows:"winget install DenoLand.Deno (or: irm https://deno.land/install.ps1 | iex)"}}},cV={upload:["git-annex","gh","aws","deno"],download:["gh"],clone:["git","gh"],push:["git-annex","gh"],publish:["gh","aws"],update:["git","gh"],release:["git","gh"]}});var EE;var $E=L(()=>{EE={name:"nemar-cli",packageManager:"bun@1.4.3",version:"0.10.40-PR2277.5ec888a",description:"CLI for NEMAR (Neuroelectromagnetic Data Archive and Tools Resource) dataset management",type:"module",main:"dist/index.js",bin:{nemar:"dist/index.js","git-annex-remote-nemar":"dist/git-annex-remote-nemar.js"},scripts:{dev:"bun run src/index.ts",build:"bun build src/index.ts src/git-annex-remote-nemar.ts --outdir dist --target bun --minify && sed '1s|#!/usr/bin/env node|#!/usr/bin/env bun|' dist/index.js > dist/index.js.tmp && mv dist/index.js.tmp dist/index.js",test:"bun test",lint:"biome check src/","lint:scrub":"biome check scripts/scrub shared/identifier-scrub.ts test/scrub","test:scrub":"bun test --preload ./test/scrub/helpers/temp-dirs-preload.ts --path-ignore-patterns='__run_every_scrub_suite__' test/scrub test/identifier-scan.test.ts test/identifier-scrub.test.ts test/identifier-dates.test.ts test/identifier-fleet.test.ts","migrations:d1-check":"bun run scripts/d1-migration-check.ts","zarr:geometry-check":"bun run backend/scripts/zarr-geometry-conformance.ts","lint:fix":"biome check --fix src/",format:"biome format --write src/",typecheck:"tsc --noEmit && tsc --noEmit -p backend","generate-openapi":"bun run scripts/generate-openapi.ts",prepublishOnly:"bun run build",prepare:"husky",postinstall:"bun scripts/postinstall-check.mjs",deploy:"wrangler deploy",preview:"wrangler dev"},keywords:["nemar","bids","neuroimaging","eeg","emg","datalad","cli"],author:"NEMAR Team",license:"CC-BY-NC-ND-4.0",repository:{type:"git",url:"git+https://github.com/nemarOrg/nemar-cli.git"},bugs:{url:"https://github.com/nemarOrg/nemar-cli/issues"},homepage:"https://docs.nemar.org",engines:{bun:">=1.0.0"},files:["dist","scripts/postinstall-check.mjs","scripts/recover-datasets.json","scripts/withdrawn-datasets.json","README.md","LICENSE"],dependencies:{chalk:"^5.3.0",commander:"^12.1.0",conf:"^13.0.1",inquirer:"^9.2.15",ora:"^8.0.1",semver:"^7.8.5",zod:"^3.23.8"},"lint-staged":{"src/**/*.{ts,tsx}":["biome check --fix"],"backend/src/**/*.{ts,tsx}":["biome check --fix"]},trustedDependencies:["@biomejs/biome"],devDependencies:{"@anthropic-ai/sdk":"^0.132.1","@asteasolutions/zod-to-openapi":"^7.3.4","@biomejs/biome":"1.9.4","@types/bun":"latest","@types/inquirer":"^9.0.7","@types/semver":"^7.8.0",ajv:"^8.20.0","ajv-formats":"^3.0.1",husky:"^9.1.7",jose:"6.2.12","lint-staged":"^16.3.2",oauth4webapi:"3.8.8","openid-client":"6.8.9",typescript:"^5.5.4",wrangler:"^4.70.0",yaml:"^2.8.4"}}});var uc;var Kl=L(()=>{$E();uc=EE.version});import{mkdirSync as mV,readdirSync as hV,unlinkSync as gV,writeFileSync as yV}from"fs";import{join as Hl}from"path";function PB(){Us=!0}function fc(){return Us}function CB(e,t=process.env){return e.includes("--debug")||t.NEMAR_DEBUG==="1"}function IB(e){TE=e,mr(`Step: ${e}`)}function jB(){RE=!0}function qB(){return RE}function DB(){if(kE)return;Wl=!0}function MB(){Wl=!1,kE=!0}function LB(){return Wl}function mr(e){if(Us)process.stderr.write(`[debug] ${e}
27
27
  `)}function wV(e){let t={};for(let[r,n]of Object.entries(e))t[r]=bV.has(r.toLowerCase())?"[REDACTED]":n;return t}function OE(e){let t=e.indexOf("@");if(t<=0)return"***";return`${e[0]}***${e.slice(t)}`}function Bl(e,t,r=0){if(r>EV)return"[REDACTED: depth]";if(Array.isArray(t))return t.map((n)=>Bl(e,n,r+1));if(t&&typeof t==="object"){let n={};for(let[s,o]of Object.entries(t))n[s]=Bl(s,o,r+1);return n}if(typeof t==="string"){if($V.test(e))return"[REDACTED]";return t.replace(AE,OE)}return t}function Yl(e){return e.replace(SV,"Bearer [REDACTED]").replace(xV,"[REDACTED_AWS_KEY]").replace(RV,"$1[REDACTED]").replace(kV,"$1$2=[REDACTED]").replace(AE,OE)}function TV(e){return Yl(e)}function SE(e,t=vV){if(e===void 0)return;let r=e;try{let n=JSON.parse(e);r=JSON.stringify(Bl("",n))}catch{}if(r=Yl(r),Buffer.byteLength(r,"utf8")>t)r=`${Buffer.from(r,"utf8").subarray(0,t).toString("utf8")}... [truncated]`;return r}function pc(e){if(!Us)return;let t=TV(e.url);try{let r={...e,url:t,requestHeaders:e.requestHeaders?wV(e.requestHeaders):void 0,requestBody:SE(e.requestBody),responseBody:SE(e.responseBody)};dc.push(r),mr(`${e.method} ${t} -> ${e.status??"ERROR"} (${e.durationMs}ms)`)}catch(r){let n=fr(r);dc.push({method:e.method,url:t,status:e.status,durationMs:e.durationMs,note:`redaction failed: ${n}`}),mr(`redaction failed for ${e.method} ${t}: ${n}`)}}async function AV(){let e=[];try{let t=process.versions.bun?`Bun ${process.versions.bun}`:`Node ${process.version}`;e.push(`CLI version: ${uc}`),e.push(`OS/Arch: ${process.platform}/${process.arch}`),e.push(`Runtime: ${t}`)}catch(t){e.push(`(could not read CLI/OS/runtime info: ${fr(t)})`)}e.push(""),e.push("Active account:");try{let t=vn();if(t.apiKey){if(t.username)e.push(` Username: ${t.username}`);if(e.push(` API URL: ${t.apiUrl}`),t.role)e.push(` Role: ${t.role}`);e.push(` Sandbox completed: ${!!t.sandboxCompleted}`)}else e.push(" (not authenticated)")}catch(t){e.push(` (could not read account config: ${fr(t)})`)}e.push(""),e.push("External tools:");try{let t=await Gl();for(let r of t){let n=r.available?r.version??"installed":r.timedOut?"(timed out)":"not installed";e.push(` ${r.name}: ${n}`)}}catch(t){e.push(` (could not probe external tools: ${fr(t)})`)}return e}async function OV(){return(await AV()).join(`
28
28
  `)}async function UB(){if(!Us||lc!==void 0)return;try{lc=await OV()}catch(e){let t=fr(e);lc=`(could not build environment report: ${t})`,mr(`environment snapshot failed: ${t}`)}}function NE(e){if(xE.has(e))return{flag:e};for(let t of xE){if(!e.startsWith(t)||e.length<=t.length)continue;if(t.length===2)return{flag:t,kind:"short-attached"};if(e[t.length]==="=")return{flag:t,kind:"long-eq"}}return null}function NV(e){let t=[];for(let r=0;r<e.length;r++){let n=e[r],s=NE(n);if(!s){t.push(n);continue}if(s.kind==="long-eq")t.push(`${s.flag}=[REDACTED]`);else if(s.kind==="short-attached")t.push(`${s.flag}[REDACTED]`);else if(t.push(n),r+1<e.length)t.push("[REDACTED]"),r++}return t}function PV(e){let t=[];for(let r=0;r<e.length;r++){let n=e[r],s=NE(n);if(!s){t.push(n);continue}if(!s.kind&&r+1<e.length)r++}return t}function CV(e){let t=[];for(let n of PV(e)){if(n.startsWith("-"))continue;if(t.push(n),t.length===2)break}return(t.length>0?t.join("-"):"nemar").replace(/[^a-zA-Z0-9_-]/g,"_")}function IV(e,t){let r=[];if(r.push("NEMAR CLI Debug Log"),r.push(`Generated: ${new Date().toISOString()}`),r.push(`Command: nemar ${Yl(NV(e).join(" "))}`),r.push(""),r.push(lc??"(environment snapshot unavailable)"),r.push(""),r.push("HTTP requests:"),dc.length===0)r.push(" (none)");else dc.forEach((n,s)=>{if(r.push(` [${s+1}] ${n.method} ${n.url} -> ${n.status??"ERROR"} (${n.durationMs}ms)`),n.error)r.push(` Error: ${n.error}`);if(n.note)r.push(` Note: ${n.note}`);if(n.requestHeaders)r.push(` Request headers: ${JSON.stringify(n.requestHeaders)}`);if(n.requestBody)r.push(` Request body: ${n.requestBody}`);if(n.responseBody)r.push(` Response body: ${n.responseBody}`)});return r.push(""),r.push(`Failing step: ${TE??"(none recorded)"}`),r.push(`Exit code: ${t}`),`${r.join(`
29
29
  `)}
30
30
  `}function jV(e,t){let r;try{r=hV(e).filter((s)=>s.startsWith("nemar-")&&s.endsWith(".log"))}catch(s){if(s.code!=="ENOENT")mr(`could not list ${e} for log rotation: ${fr(s)}`);return}r.sort();let n=r.length-t;for(let s=0;s<n;s++)try{gV(Hl(e,r[s]))}catch(o){if(o.code!=="ENOENT")mr(`could not remove old log ${r[s]}: ${fr(o)}`)}}function FB(){return Go}function VB(e,t){if(!Us)return null;let r=Hl(Jl(),"logs");try{mV(r,{recursive:!0})}catch(a){return Go=fr(a),mr(`could not create log directory ${r}: ${Go}`),null}let s=`nemar-${new Date().toISOString().replace(/[:.]/g,"-")}-${CV(e)}.log`,o=Hl(r,s);try{yV(o,IV(e,t),"utf8")}catch(a){return Go=fr(a),mr(`could not write log file ${o}: ${Go}`),null}return jV(r,_V),o}var _V=10,vV=2048,Us=!1,RE=!1,Wl=!1,kE=!1,TE,lc,dc,bV,$V,AE,EV=32,SV,xV,RV,kV,xE,Go;var Xl=L(()=>{jl();mc();wE();Kl();dc=[];bV=new Set(["authorization","cookie","set-cookie","x-api-key","x-approval-dispatch-token"]);$V=/^(api[_-]?key|apikey|password|token|secret|access[_-]?key(_id)?|secret[_-]?access[_-]?key|session|session[_-]?token|authorization|ssh[_-]?key|private[_-]?key|device[_-]?code|dispatch[_-]?token|client[_-]?secret)$/i,AE=/[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}/g;SV=/Bearer\s+[A-Za-z0-9\-._~+/=]+/gi,xV=/\b(?:AKIA|ASIA)[0-9A-Z]{16}\b/g,RV=/((?:aws_)?secret_access_key["']?\s*[:=]\s*["']?)[A-Za-z0-9/+=]{20,}/gi,kV=/([?&])(X-Amz-Signature|X-Amz-Security-Token|X-Amz-Credential|Signature|AWSAccessKeyId)=[^&\s"']+/gi;xE=new Set(["-k","--key","--password","--api-key"])});import{chmodSync as qV,copyFileSync as DV,existsSync as Ql,mkdirSync as MV,statSync as LV}from"fs";import{homedir as hc}from"os";import{join as Fs}from"path";function FV(e){let t=e.trim().replace(/\/+$/,"");try{let r=new URL(t);return r.protocol=r.protocol.toLowerCase(),r.host=r.host.toLowerCase(),r.toString().replace(/\/+$/,"")}catch{return console.error(`[nemar] could not parse stored apiUrl ${JSON.stringify(e)}; leaving as-is`),t}}function Jl(){return process.env.NEMAR_CONFIG_DIR||Fs(hc(),".config","nemar")}function zV(e){if(process.env.NEMAR_CONFIG_DIR)return;let t=Fs(e,"config.json");if(Ql(t))return;let r=[];if(process.platform==="darwin")r.push(Fs(hc(),"Library","Preferences","nemar-nodejs","config.json"));if(process.platform==="win32"){let n=process.env.APPDATA||Fs(hc(),"AppData","Roaming");r.push(Fs(n,"nemar-nodejs","config.json"))}r.push(Fs(hc(),".config","nemar-nodejs","config.json"));for(let n of r)if(Ql(n))try{MV(e,{recursive:!0}),DV(n,t),console.error(`[nemar] Config migrated from ${n} to ${t}
31
31
  [nemar] You can safely remove the old file.`);return}catch(s){console.error(`[nemar] Failed to migrate config from ${n}:`,s,`
32
- [nemar] You can manually copy ${n} to ${t}`)}}function St(){let e=Jl();if(Ko&&PE===e)return Ko;if(zV(e),Ko=new Bi({projectName:"nemar",configFileMode:Zl,schema:{activeAccount:{type:"string"},accounts:{type:"object"},apiKey:{type:"string"},apiUrl:{type:"string"},username:{type:"string"},email:{type:"string"},githubUsername:{type:"string"},sandboxCompleted:{type:"boolean"},sandboxDatasetId:{type:"string"}},cwd:e}),PE=e,!CE.has(e))CE.add(e),GV(Ko.path),HV(),BV();return Ko}function GV(e){if(process.platform==="win32")return;if(!Ql(e))return;try{if((LV(e).mode&511)!==Zl)qV(e,Zl)}catch(t){console.error(`[nemar] could not secure config file permissions for ${e}:`,t)}}function HV(){let e=St(),t=e.get("accounts");if(t&&Object.keys(t).length>0)return;let r=e.get("apiKey"),n=e.get("username");if(!r&&!n)return;try{let s=n||"default",o={};for(let a of KV){let i=e.get(a);if(i!==void 0)o[a]=i}e.store={activeAccount:s,accounts:{[s]:o}}}catch(s){console.error("Config migration failed (legacy config preserved):",s)}}function BV(){let e=St(),t=e.store,r=t.accounts,n=!1;if(r)for(let[o,a]of Object.entries(r)){let i=a?.apiUrl;if(!i)continue;if(UV.has(FV(i)))r[o]={...a,apiUrl:Vs},console.error(`[nemar] migrated stored apiUrl for account "${o}": ${i} -> ${Vs}`),n=!0}let s=t.apiUrl;if(r&&Object.keys(r).length>0&&s!==void 0){let{apiUrl:o,...a}=t;try{e.store=a,console.error(`[nemar] removed stale top-level apiUrl from config (was: ${s})`),n=!1}catch(i){console.error("API URL cleanup failed (config file unchanged):",i)}}if(n)try{e.store={...e.store,accounts:r}}catch(o){console.error("API URL migration failed (config file unchanged):",o)}}function Ho(){return St().get("activeAccount")}function bn(){return St().get("accounts")||{}}function vn(){let e={apiUrl:Vs},t=Ho();if(!t)return e;return bn()[t]||e}function QB(e,t){let r=St(),n=r.get("activeAccount")||"default",s=r.get("accounts")||{};if(!s[n])s[n]={apiUrl:Vs};s[n][e]=t,r.store={...r.store,accounts:s,activeAccount:n}}function ZB(e){let t=Ho();if(!t)return;let r=bn();if(r[t])delete r[t][e],St().set("accounts",r)}function e6(){let e=St(),t=Ho();if(!t){e.clear();return}let r=bn();delete r[t];let n=Object.keys(r);if(n.length>0)e.store={...e.store,accounts:r,activeAccount:n[0]};else e.clear()}function t6(){St().clear()}function r6(){return!!vn().apiKey}function n6(){return St().path}function s6(){let e=bn(),t=Ho();return Object.entries(e).map(([r,n])=>({key:r,username:n.username,email:n.email,githubUsername:n.githubUsername,active:r===t,keySource:n.keySource}))}function o6(e){return e.username?.trim()||e.email}function WV(e){let t=e.trim().toLowerCase();if(!t)return;let r=Object.entries(bn()).filter(([,n])=>n.email&&n.email.toLowerCase()===t).map(([n])=>n);if(r.length>1){mr(`findAccountKeyByEmail: ${r.length} accounts share email ${t}: ${r.join(", ")}`);return}return r[0]}function a6(e,t){let r=St(),n=bn(),s;if(n[e])s=e;else if(t.email)s=WV(t.email);let o=s?n[s]:void 0,a={...o??{apiUrl:Vs},...t};if(s&&s!==e)delete n[s];return n[e]=a,r.store={...r.store,accounts:n,activeAccount:e},{key:e,previous:o}}function i6(e){let t=e.trim();if(!t)return"unchanged";let r=St(),n=Ho();if(!n||n===t)return"unchanged";let s=bn(),o=s[n];if(!o)return"unchanged";if(s[t])return"key_taken";return delete s[n],s[t]={...o,username:t},r.store={...r.store,accounts:s,activeAccount:t},"renamed"}function c6(e){let t=St(),r=bn();if(r[e])return t.store={...t.store,activeAccount:e},r[e];for(let[n,s]of Object.entries(r))if(s.githubUsername===e)return t.store={...t.store,activeAccount:n},s;return null}var Vs="https://api.nemar.org",Zl=384,UV,VV,JB,Ko=null,PE=null,CE,KV;var mc=L(()=>{V$();_n();oc();Xl();UV=new Set(["https://api.osc.earth/nemar","https://nemar-api.neuromechanist.workers.dev","https://nemar-api-dev.shirazi-10f.workers.dev"]);VV=Z({field:_(),blocks:Ye(_()).optional(),set_on:Ye(_()).optional()}).passthrough(),JB=Z({apiKey:_().optional(),apiUrl:_().url().default(Vs),username:_().optional(),email:_().email().optional(),githubUsername:_().optional(),sandboxCompleted:Ie().optional(),sandboxDatasetId:_().optional(),dismissedNoticeIds:Ye(ne()).optional(),serviceAccess:Ie().optional(),profileGaps:Ye(VV).optional(),orcidVerified:Ie().optional(),role:_().optional(),accountKind:Mn.optional(),pendingEmailChange:_().email().optional()});CE=new Set;KV=["apiKey","apiUrl","username","email","githubUsername","sandboxCompleted","sandboxDatasetId","dismissedNoticeIds"]});var YV,XV,f6,JV,p6,QV,IE,m6,h6=8,g6=100,jE,y6,ZV,_6;var qE=L(()=>{_n();oc();YV=["given_name","family_name","affiliation","city","country"],XV=["username","github_username","email","orcid"],f6=[...YV,...XV],JV={given_name:_().max(200).optional(),family_name:_().max(200).optional(),affiliation:_().max(500).optional(),city:_().max(200).optional(),country:_().max(200).optional(),username:_().max(100).optional(),github_username:_().max(100).optional(),email:_().max(320).optional(),orcid:_().max(40).optional()},p6=Z(JV),QV=Fe(["field_not_editable","owner_only_field","edit_own_account","owner_account","system_account","invalid_edit","orcid_already_proven","invalid_search","invalid_user_id"]),IE=QV.options,m6=["exact","name","prefix","substring","fuzzy"],jE=Z({id:ne().int(),username:_().nullable(),email:_(),github_username:_().nullable(),status:_(),role:_().nullable(),account_kind:Mn.optional(),email_verified:ne().int().nullable().optional(),orcid:_().nullable().optional(),orcid_verified:ne().int().nullable().optional(),given_name:_().nullable().optional(),family_name:_().nullable().optional(),affiliation:_().nullable().optional(),city:_().nullable().optional(),country:_().nullable().optional(),description:_().nullable().optional(),signup_source:_().nullable().optional(),created_at:_(),updated_at:_().nullable().optional(),approved_at:_().nullable().optional(),revoked_at:_().nullable().optional(),deleted_at:_().nullable().optional(),service_access:ne().int().nullable().optional(),service_access_granted_at:_().nullable().optional(),service_access_granted_by:ne().int().nullable().optional(),upload_access_requested_at:_().nullable().optional(),upload_access_notified_at:_().nullable().optional(),compute_access:_().optional(),compute_access_requested_at:_().nullable().optional(),compute_access_notified_at:_().nullable().optional(),compute_access_granted_at:_().nullable().optional(),compute_access_granted_by:ne().int().nullable().optional(),compute_terms_version:_().nullable().optional(),compute_terms_accepted_at:_().nullable().optional(),identity_conflict:ne().int().nullable().optional(),username_auto_assigned:ne().int().nullable().optional(),sandbox_completed:ne().int().nullable().optional(),sandbox_completed_at:_().nullable().optional(),sandbox_dataset_id:_().nullable().optional(),aws_iam_username:_().nullable().optional(),dataset_count:ne().int().optional(),active_tokens:ne().int().optional(),linked_identities:Ye(_()).optional()}).passthrough(),y6=Z({user:jE}).passthrough(),ZV=Z({from:_().nullable(),to:_().nullable()}),_6=Z({message:_(),changed:NF(_(),ZV),notes:Ye(_()).optional(),old_address_notified:Ie().optional(),user:jE}).passthrough()});function t9(e){for(let t=0;t<e.length;t++){let r=e.charCodeAt(t);if(r<32&&r!==9&&r!==10||r===127)return!0}return!1}function x6(e,t){let r=s9[e];if(r==="refused")return t===void 0?null:"notice_refused";let n=t?.trim()??"";if(n==="")return r==="required"?"notice_required":null;if([...n].length>ME)return"notice_too_long";if(t9(n))return"notice_control_char";return null}var w6=20,e9=1000,$6,r9,DE,E6,n9=500,S6=200,ME=1000,s9,R6,LE,k6,o9,T6;var UE=L(()=>{_n();$6=Z({purpose:_().max(e9*4).optional().default(""),accept_terms_version:_().max(64).optional().default("")}),r9=Fe(["purpose_required","terms_not_accepted","email_not_verified","orcid_not_proven","profile_incomplete","access_closed","already_active","terms_unpublished"]),DE=r9.options,E6=Z({ok:gn(!0),already_requested:Ie(),requested_at:_().nullable().optional(),email_sent:Ie().optional(),admins_notified:ne().int().nullable().optional()}).passthrough(),s9={grant:"refused",deny:"optional",suspend:"required",revoke:"required"};R6={reason:_().max(n9).optional(),notice:_().max(ME*4,{message:"notice_too_long"}).optional()},LE=Z({id:ne().int(),username:_().nullable(),email:_(),given_name:_().nullable().optional(),family_name:_().nullable().optional(),affiliation:_().nullable().optional(),city:_().nullable().optional(),country:_().nullable().optional(),orcid:_().nullable().optional(),account_kind:_().optional(),compute_access:_(),compute_access_requested_at:_().nullable().optional(),compute_access_notified_at:_().nullable().optional(),compute_access_granted_at:_().nullable().optional(),compute_access_granted_by:ne().int().nullable().optional(),compute_purpose:_().nullable().optional(),compute_terms_version:_().nullable().optional(),compute_terms_accepted_at:_().nullable().optional()}).passthrough(),k6=Z({accounts:Ye(LE),next_after:ne().int().nullable().optional()}).passthrough(),o9=Z({granted:Ie(),cpu_milli:ne().int(),gpu_milli:ne().int(),reason:_().nullable().optional(),policy_version:ne().int().nullable().optional()}).passthrough(),T6=Z({decision:_(),from:_(),to:_(),account:LE,allocation:o9.optional(),email_sent:Ie().optional()}).passthrough()});var N6=120,P6=64,C6="unnamed machine",a9=25,FE,I6,zs,VE,j6,q6,D6,i9,c9,M6,ed,L6,U6,F6,V6,z6;var zE=L(()=>{_n();FE=Fe(["authorization_pending","slow_down","expired_token","access_denied","invalid_grant"]),I6={authorization_pending:"Waiting for you to authorize this machine in the browser.",slow_down:"Polling too quickly; the CLI will slow down automatically.",expired_token:"The code expired. Run `nemar auth login` again for a new one.",access_denied:"This sign-in was declined in the browser. Run `nemar auth login` again if that was a mistake.",invalid_grant:"That code is no longer valid. Run `nemar auth login` again for a new one."},zs=Fe(["device_code_unknown","device_code_expired","device_code_used","device_code_denied","account_pending","account_revoked","identity_conflict","service_account","person_account","too_many_keys","key_not_found"]),VE=zs.options,j6={device_code_unknown:"That code was not found. Check the code shown in your terminal, or run `nemar auth login` again for a new one.",device_code_expired:"The code expired. Run `nemar auth login` again for a new one.",device_code_used:"That code has already been used. Run `nemar auth login` again for a new one.",device_code_denied:"This sign-in was declined in the browser. Run `nemar auth login` again if that was a mistake.",account_pending:"Verify your email address first. Check your inbox for the NEMAR verification code, then authorize again.",account_revoked:"Your NEMAR account access has been revoked. Contact the NEMAR team if you think this is a mistake.",identity_conflict:"This account shares an identifier with another NEMAR account and cannot sign in until that is resolved. Fix it in Settings on nemar.org or contact the NEMAR team.",service_account:"This is a service or test account, and it cannot sign in this way. Ask an owner to create a key for it with `nemar admin keys create`.",person_account:"This account belongs to a person. A person creates their own keys with `nemar auth login` or in Settings on nemar.org.",too_many_keys:`This account already has ${a9} active keys. Revoke one in Settings on nemar.org or with \`nemar auth keys\`, then try again.`,key_not_found:"That key was not found on this account, or it is already revoked. Run `nemar auth keys` to see the active ones."},q6=Z({error:zs,message:_()}).passthrough(),D6=Z({device_code:_(),user_code:_(),verification_uri:_(),verification_uri_complete:_(),expires_in:ne().int(),interval:ne().int()}).passthrough(),i9=X$("error",[Z({error:gn("authorization_pending"),message:_()}).passthrough(),Z({error:gn("slow_down"),message:_()}).passthrough()]),c9=X$("error",[Z({error:gn("expired_token"),reason:zs,message:_()}).passthrough(),Z({error:gn("access_denied"),reason:zs,message:_()}).passthrough(),Z({error:gn("invalid_grant"),reason:zs,message:_()}).passthrough()]),M6=OF([i9,c9]),ed=Z({id:ne().int(),name:_().nullable(),prefix:_(),created_at:_(),last_used_at:_().nullable(),current:Ie()}).passthrough(),L6=Z({api_key:_(),key:ed,user:Z({username:_().nullable(),email:_(),github_username:_().nullable(),role:_(),sandbox_completed:Ie(),sandbox_dataset_id:_().nullable()}).passthrough()}).passthrough(),U6=Z({user_code:_(),machine_name:_(),requested_at:_(),expires_in:ne().int(),account:Z({username:_().nullable(),email_masked:_()}).passthrough(),refusal:Z({code:zs,message:_()}).passthrough().nullable()}).passthrough(),F6=Z({ok:gn(!0),machine_name:_()}).passthrough(),V6=Z({keys:Ye(ed)}).passthrough(),z6=Z({api_key:_(),key:ed}).passthrough()});var u9,GE,Bo="https://nemar.org/settings",H6,l9,d9,f9,B6,W6;var KE=L(()=>{_n();u9=Fe(["orcid_in_use","orcid_already_linked","orcid_linked_other","email_in_use","github_in_use","identity_conflict_remains"]),GE=u9.options,H6={orcid_in_use:`That ORCID iD already belongs to a NEMAR account. Sign in to that account instead; if you want the iD on a different account, unlink it there first (Settings, ${Bo}).`,orcid_already_linked:`That ORCID iD already belongs to a NEMAR account. Sign in to that account instead; if you want the iD on a different account, unlink it there first (Settings, ${Bo}).`,orcid_linked_other:`That ORCID iD is linked to a different NEMAR account. Unlink it there first (Settings, ${Bo}), then link it here.`,email_in_use:`That email address already belongs to a NEMAR account. Sign in to that account instead, or change its address first (Settings, ${Bo}).`,github_in_use:`That GitHub account is already linked to a NEMAR account. Sign in to that account instead, or change its GitHub username first (Settings, ${Bo}).`,identity_conflict_remains:"The collision that flagged this account is still there. Resolve it on the other account first (change its email or GitHub username, or unlink its ORCID iD), or delete that account, then clear the flag."},l9=Fe(["orcid","email","github"]),d9=Z({id:ne().int(),username:_().nullable(),email:_(),created_at:_(),has_oauth_identity:Ie(),dataset_count:ne().int(),identity_conflict:ne().int(),canonical:Ie()}).passthrough(),f9=Z({kind:l9,value:_(),canonical_user_id:ne().int(),accounts:Ye(d9)}).passthrough(),B6=Z({groups:Ye(f9),group_count:ne().int(),flagged_count:ne().int()}).passthrough(),W6=Z({ok:gn(!0),id:ne().int(),cleared:Ie()}).passthrough()});function X6(e){return Wo[e]}function J6(e,t){return e.replace(/\{(\w+)\}/g,(r,n)=>Object.hasOwn(t,n)?t[n]:r)}var Wo;var HE=L(()=>{Wo={"tier.unverified.label":"Email not verified","tier.base.label":"Base access","tier.upload.label":"Upload access","tier.unverified.lede":"Verify your email address to activate your account.","upload_access.section.title":"Upload access","upload_access.section.lede":"A one-time admin grant. Reviewed against export-control and local-jurisdiction rules.","upload_access.state.granted":"Granted","upload_access.state.requested":"Requested","upload_access.state.not_requested":"Not requested","upload_access.invite.title":"Want to contribute a dataset?","upload_access.invite.body":"Browsing, searching and downloading are open to your account already. Uploading, or being added as a collaborator on someone else\u2019s dataset, needs one extra grant: an admin checks your GitHub handle and location against export-control and local-jurisdiction rules, once. Your email address must be verified first.","upload_access.gate.title":"Ask for upload access first","upload_access.gate.body":"Your account can browse, search and download everything public already. Uploading, or being added as a collaborator on someone else\u2019s dataset, needs one extra grant, and your email address must be verified first: an admin checks your GitHub handle and where you\u2019re based against export-control and local-jurisdiction rules. You ask once, and it is answered by email.","upload_access.request.cta":"Request upload access","upload_access.request.form_body":"Tell us what you plan to deposit, or which dataset you want to collaborate on. An admin reviews this alongside your name, username, GitHub handle and location, then grants access once.","upload_access.request.why_label":"What do you intend to upload?","upload_access.request.why_hint":"Describe what you intend to upload in 20-500 characters","upload_access.requested.title":"Your request is with an admin","upload_access.requested.lede":"An admin is reviewing your request.","upload_access.requested.lede_dated":"An admin is reviewing your request from {date}.","upload_access.requested.body.upload":"We\u2019ll email you when there\u2019s a decision, and this page will let you upload as soon as it\u2019s granted.","upload_access.requested.body":"We\u2019ll email you when there\u2019s a decision. Everything else on your account keeps working in the meantime.","upload_access.requested.cta":"See the request","upload_access.granted.body":"You can upload datasets from the upload page. Publishing one is a separate, per-dataset review you start from your dashboard.","upload_access.unverified.body":"Verify your email address first \u2014 the review happens over email.","upload_access.docs_link":"How upload access works","compute_access.section.title":"Compute access","compute_access.section.lede":"A separate grant from upload access. An admin reviews each request against export-control and local-jurisdiction rules and the purpose you state, and a grant lets you use compute within the limits an administrator sets.","compute_access.state.none":"Not requested","compute_access.state.requested":"Requested","compute_access.state.active":"Active","compute_access.state.suspended":"Suspended","compute_access.state.denied":"Not granted","compute_access.state.revoked":"Ended","compute_access.request.cta":"Request compute access","compute_access.request.form_body":"Tell us what you plan to compute. An admin reviews this alongside your name, affiliation and location, then answers once. You also accept the compute terms.","compute_access.request.purpose_label":"What do you intend to compute?","compute_access.request.purpose_hint":"Describe what you intend to compute in 20-1000 characters","compute_access.request.terms_label":"I accept the compute terms","compute_access.requested.title":"Your compute request is with an admin","compute_access.requested.lede":"An admin is reviewing your request.","compute_access.requested.lede_dated":"An admin is reviewing your request from {date}.","compute_access.requested.body":"We\u2019ll email you when there\u2019s a decision. Everything else on your account keeps working in the meantime.","compute_access.granted.body":"Compute access is active. Your balances are on your compute page, and you submit jobs with the `nemar compute` command line.","compute_access.granted.link":"Open your compute page","compute_access.closed.body":"This request has been answered and cannot be asked again. If you think that is a mistake, contact support and an admin will take another look.","compute_access.suspended.body":"Your compute access is paused. Contact support to find out why or to ask for it to be lifted.","compute_access.terms_unpublished.body":"Compute access is not open yet: the compute terms are not published. Please check back later.","compute_access.docs_link":"How compute access works","compute_page.frozen.body":"Your pools are frozen, so new jobs are refused. Contact support to find out why.","compute_page.units_note":"Amounts are service units (SU).","compute_page.available_note":"Available is granted minus held minus charged and can be negative after an overrun.","compute_page.queue_note":"It describes the queue of the whole platform, not yours, and it is a recent average, not a promise.","compute_page.usage_note":"Net charge by UTC day of the charge, not the day a job was created. A day with no charge has no bar.","compute_page.unreported_note":"NEMAR has not heard from the cluster about this job for a while. It may still finish.","compute_admin.page.title":"Compute","compute_admin.page.lede":"Compute access requests, and a read-only view of pools, usage, flagged jobs and reconciliation. A grant opens an allocation the person can spend, so each request is decided by a person, one at a time.","compute_admin.page.cli_note":"Owner policy, legal holds, record reads, moving a charge, pool grants and adjustments, and canceling a job are done with the nemar admin compute command in the command line, not here.","compute_admin.page.order_note":"Accounts are listed in the order they were created, not the order they asked in.","compute_admin.view.nav":"Compute views","compute_admin.view.requests":"Requests","compute_admin.view.pools":"Pools","compute_admin.view.usage":"Usage","compute_admin.view.flagged":"Flagged jobs","compute_admin.view.drift":"Reconciliation","compute_admin.state.nav":"Filter requests by state","compute_admin.state.requested":"Requested","compute_admin.state.active":"Active","compute_admin.state.suspended":"Suspended","compute_admin.state.denied":"Denied","compute_admin.state.revoked":"Revoked","compute_admin.state.all":"All","compute_admin.requests.none":"No accounts in this view.","compute_admin.pager.next":"Next page","compute_admin.pager.first":"First page","compute_admin.row.not_set":"not set","compute_admin.row.no_username":"no username","compute_admin.row.account_kind":"{kind} account","compute_admin.row.stated_country":"Stated country","compute_admin.row.stated_country_hint":"Check this against the export-control rules before granting. This page does not rule on it.","compute_admin.row.city":"City","compute_admin.row.affiliation":"Affiliation","compute_admin.row.email":"Email","compute_admin.row.orcid":"ORCID iD","compute_admin.row.requested":"Requested","compute_admin.row.terms":"Terms accepted","compute_admin.row.terms_value":"{version}, {date}","compute_admin.row.purpose":"Stated purpose","compute_admin.row.show_full_purpose":"Show full purpose","compute_admin.row.granted":"Granted {date} by account #{id}","compute_admin.row.not_notified":"No administrator has been emailed about this request yet.","compute_admin.row.open_in_users":"Open in Users","compute_admin.action.grant":"Grant","compute_admin.action.grant_again":"Grant again","compute_admin.action.lift_suspension":"Lift suspension","compute_admin.action.deny":"Deny","compute_admin.action.suspend":"Suspend","compute_admin.action.revoke":"Revoke","compute_admin.self_grant.disabled":"You cannot grant your own compute access. Ask another administrator or an owner.","compute_admin.dialog.title.grant":"Grant compute access?","compute_admin.dialog.title.deny":"Deny this request?","compute_admin.dialog.title.suspend":"Suspend compute access?","compute_admin.dialog.title.revoke":"Revoke compute access?","compute_admin.dialog.consequence.grant":"Opens the owner\u2019s default allocation once for this account (a repeat grant adds nothing), unfreezes the account\u2019s pools, and allows the person to use compute when it is available. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.consequence.deny":"Closes this request. The person cannot ask again; only an administrator can grant later. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.consequence.suspend":"Freezes the account\u2019s pools, cancels its live jobs and ends its compute sign-ins. A partner reservation that has no job reported under it is not canceled here: it is released after it expires, and a job reported under it is refused. A grant lifts the suspension. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.consequence.revoke":"Freezes the account\u2019s pools, cancels its live jobs and ends its compute sign-ins. A partner reservation that has no job reported under it is not canceled here: it is released after it expires, and a job reported under it is refused. Only a new grant restores access. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.reason_label":"Reason (optional)","compute_admin.dialog.reason_hint":"Recorded in the audit log. The person is not sent it.","compute_admin.dialog.reason_count":"{count} of {max}","compute_admin.dialog.notice_label":"Notice to the person","compute_admin.dialog.notice_label_optional":"Notice to the person (optional)","compute_admin.dialog.notice_help":"Emailed to the person under a fixed heading, with how to ask for a review. Write it for them. It is not the reason, which stays in the audit log.","compute_admin.dialog.notice_required_hint":"A suspension or a revocation tells the person why. Write the notice to confirm.","compute_admin.dialog.ack_export_review":"Confirm that you have reviewed this person\u2019s name, affiliation and stated country against the export-control rules","compute_admin.dialog.type_word":"Type {word} to confirm","compute_admin.dialog.cancel":"Cancel","compute_admin.result.working":"Working","compute_admin.result.granted":"Granted.","compute_admin.result.granted_opened":"Granted. Opened {cpu} CPU SU and {gpu} GPU SU.","compute_admin.result.granted_zero_default":"Granted. The owner\u2019s default allocation is zero, so nothing was opened.","compute_admin.result.granted_already":"Granted. An earlier grant already opened the default allocation, so nothing more was opened.","compute_admin.result.granted_other":"Granted. The allocation answered: {reason}.","compute_admin.result.denied":"Denied.","compute_admin.result.suspended":"Suspended. The account\u2019s pools are frozen and its live jobs are being canceled. A partner reservation with no job reported under it is left to expire.","compute_admin.result.revoked":"Revoked. The account\u2019s pools are frozen and its live jobs are being canceled. A partner reservation with no job reported under it is left to expire.","compute_admin.result.email_not_sent":"The decision stands, but the person could not be emailed. Tell them.","compute_admin.result.state_changed":"Someone else may have decided this first. The row shows the current state.","compute_admin.result.unconfirmed":"The result is not confirmed. The row shows what the server says now.","compute_admin.result.check_email":"The decision is in place, but the answer was lost, so check that the person was emailed and tell them if not.","compute_admin.result.stale":"This account was not found. Reload the page.","compute_admin.result.reread_failed":"The current state could not be read. Reload the page before deciding again.","compute_admin.result.signed_out":"You are signed out. Sign in again, then retry.","compute_admin.error.malformed":"The server sent an answer this page could not read.","compute_admin.error.unreachable":"The server could not be reached. Check your connection and try again.","compute_admin.error.redirect":"The server answered in a way this page cannot follow. Try again later.","compute_admin.error.origin":"This page was not accepted as the source of the request. Reload and try again.","compute_admin.error.rate_limited":"Too many requests. Wait a moment, then try again.","compute_admin.error.timeout":"The server did not answer in time. Try again.","compute_admin.error.failed":"The request failed ({status}). Try again.","compute_admin.error.generic":"Something went wrong. Try again.","compute_admin.error.bad_id":"That is not an account id.","compute_admin.error.bad_decision":"That is not a decision.","compute_admin.error.reason_too_long":"A reason is at most {max} characters.","compute_admin.error.notice_required":"This decision needs a notice to the person.","compute_admin.error.notice_refused":"A grant does not take a notice to the person.","compute_admin.error.notice_too_long":"A notice is at most {max} characters.","compute_admin.error.notice_control_char":"A notice may not contain control characters other than newline and tab.","compute_admin.error.bad_quarter":"A quarter is written like 2026Q4.","compute_admin.section.failed":"Could not load {what}: {reason}","compute_admin.col.holder":"Holder","compute_admin.col.pool":"Pool","compute_admin.col.granted":"Granted (SU)","compute_admin.col.held":"Held (SU)","compute_admin.col.charged":"Charged (SU)","compute_admin.col.available":"Available (SU)","compute_admin.col.frozen":"Frozen","compute_admin.col.updated":"Updated","compute_admin.col.partition":"Partition","compute_admin.col.source":"Front door","compute_admin.col.users":"Distinct people","compute_admin.col.jobs":"Jobs","compute_admin.col.job":"Job","compute_admin.col.account":"Account","compute_admin.col.state":"State","compute_admin.col.flags":"Flags","compute_admin.col.failure":"Failure","compute_admin.col.created":"Created","compute_admin.col.ended":"Ended","compute_admin.col.slurm":"Scheduler job","compute_admin.col.elapsed":"Elapsed (s)","compute_admin.col.resources":"Nodes, CPUs, GPUs","compute_admin.col.ingested":"Ingested","compute_admin.ref.account":"account #{id}","compute_admin.ref.no_account":"no account","compute_admin.pools.platform":"Platform budgets","compute_admin.pools.partner":"Partner pools","compute_admin.pools.account":"Account pools","compute_admin.pools.none_platform":"No platform budgets are recorded.","compute_admin.pools.none":"No pools are recorded in this group.","compute_admin.pools.truncated":"Showing the first {shown} pools of this group; more exist.","compute_admin.pools.frozen":"Frozen","compute_admin.pools.open":"Open","compute_admin.usage.quarter":"Quarter","compute_admin.usage.counts_note":"These are counts of people and jobs, not service units. A person is counted once however many jobs they ran, and jobs that skipped the reservation or could not be attributed are left out.","compute_admin.usage.totals":"Total","compute_admin.usage.none":"No jobs were recorded in this quarter.","compute_admin.flag.nav":"Filter jobs by flag","compute_admin.flag.unreserved":"Unreserved","compute_admin.flag.unattributed":"Unattributed","compute_admin.flag.mismatch":"Mismatch","compute_admin.flag.overrun":"Overrun","compute_admin.flag.meaning.unreserved":"The job skipped the reservation. Its charge went to a partner pool and not to a person.","compute_admin.flag.meaning.unattributed":"The job skipped the reservation and its owner maps to no active account.","compute_admin.flag.meaning.mismatch":"NEMAR\u2019s record and the scheduler\u2019s accounting disagree for this job, or a partner\u2019s report for it was refused or could not be checked, or a partner job used more than its hold and was capped.","compute_admin.flag.meaning.overrun":"The job used more than its hold, and the excess is recorded as an overrun in the ledger.","compute_admin.flag.followup":"Moving the charge of an unreserved job to a person is an owner action in the command line.","compute_admin.flagged.none":"No jobs carry this flag. That is a fact about this read only.","compute_admin.flagged.platform_failure":"NEMAR\u2019s fault","compute_admin.flagged.partner":"Partner: {state}, {flag}","compute_admin.drift.paused":"Reconciliation is paused while compute is off. An empty list below does not mean nothing is unmatched.","compute_admin.drift.pause_unknown":"Whether reconciliation is running is not known, so an empty list does not mean nothing is unmatched.","compute_admin.drift.status":"Status","compute_admin.drift.compute_on":"Compute is on.","compute_admin.drift.compute_off":"Compute is off.","compute_admin.drift.tapis":"Scheduler gateway: token {token}, health {health}.","compute_admin.drift.attention":"Needs a person to look","compute_admin.drift.attention_none":"No attention count is positive.","compute_admin.drift.unmatched":"Accounting rows no job claims","compute_admin.drift.unmatched_shown":"Showing the newest {shown} of {total}.","compute_admin.drift.unmatched_none":"No accounting rows are waiting for a job.","compute_admin.drift.not_priced":"not priced","compute_admin.drift.mismatch":"Jobs flagged mismatch","compute_admin.drift.mismatch_more":"See the Flagged jobs view for the rest","compute_admin.unavailable.title":"Not available yet","compute_admin.unavailable.usage_by_day":"Service units charged by day, partition and front door across the platform are not served by any admin read yet.","compute_admin.unavailable.drift_difference":"The difference between NEMAR\u2019s ledger and the supercomputer\u2019s accounting, per job or per day, and the tolerance it is measured against are not served by any admin read yet. No row is marked over tolerance because this page has no tolerance to apply.","compute_admin.unavailable.link":"Tracking issue","compute_admin.badge.awaiting_decision":"awaiting decision","gap.sentence":"{label} is missing: needed {blocks}.","gap.set_on.both":"Set it in {web} or run `{cli}`.","gap.set_on.web":"Set it in {web}.","gap.blocks.verified":"to activate your account","gap.blocks.upload_access":"to request upload access","gap.blocks.compute_access":"to request compute access","gap.blocks.publication":"to publish a dataset","gap.blocks.unknown":"to finish setting up your account","gap.blocks.noun.verified":"account activation","gap.blocks.noun.upload_access":"upload access","gap.blocks.noun.compute_access":"compute access","gap.blocks.noun.publication":"publication","gap.set_on.default_web":"Settings","gap.field.email_verified.label":"A verified email address","gap.field.username.label":"Username","gap.field.given_name.label":"Given name","gap.field.family_name.label":"Family name","gap.field.orcid_verified.label":"Verified ORCID iD","gap.field.github_username.label":"GitHub handle","gap.field.city.label":"City","gap.field.country.label":"Country","gap.field.affiliation.label":"Affiliation","gap.field.why.label":"A description of what you intend to upload","gap.field.email_verified.set_on.web":"the verify step on your dashboard","gap.field.email_verified.set_on.cli":"nemar auth resend-verification","gap.field.username.set_on.web":"Settings","gap.field.username.set_on.cli":"nemar auth profile set-username","gap.field.given_name.set_on.web":"Settings","gap.field.given_name.set_on.cli":"nemar auth profile set-name","gap.field.family_name.set_on.web":"Settings","gap.field.family_name.set_on.cli":"nemar auth profile set-name","gap.field.given_name.set_on.web.orcid":"your ORCID record at orcid.org, then sign in again","gap.field.family_name.set_on.web.orcid":"your ORCID record at orcid.org, then sign in again","gap.field.orcid_verified.set_on.web":"Settings","gap.field.orcid_verified.set_on.cli":"nemar auth profile orcid link","gap.field.github_username.set_on.web":"Settings","gap.field.github_username.set_on.cli":"nemar auth profile set-github","gap.field.city.set_on.web":"Settings","gap.field.city.set_on.cli":"nemar auth profile set-location","gap.field.country.set_on.web":"Settings","gap.field.country.set_on.cli":"nemar auth profile set-location","gap.field.affiliation.set_on.web":"Settings","gap.field.affiliation.set_on.cli":"nemar auth profile set-affiliation","gap.field.why.set_on.web":"the request form in Settings","gap.field.why.set_on.cli":"nemar auth request-upload-access","gaps.title":"What is still missing","gaps.none":"Nothing outstanding \u2014 every field NEMAR needs is filled in.","gaps.nudge.title":"Your profile isn\u2019t finished yet","gaps.nudge.cta":"Complete your profile","gaps.upload.title":"Before you can ask, your account still needs:","gaps.request.title":"Finish these first:","gaps.admin.title":"Still missing","gaps.admin.item":"{label} \u2014 blocks {blocks}","gaps.admin.none":"Nothing missing \u2014 every field the request needs is filled in.","gaps.admin.not_loaded":"Not loaded \u2014 open the user page to see what is still missing.","onboarding.username.auto_assigned.title":"We chose your username from your name","onboarding.username.auto_assigned.body":"Your account needed a username to be listed as a dataset owner, so one was made from your name when you signed in. You can change it once, here, until an admin grants you upload access.","welcome.unverified.title":"Verify your email address","welcome.unverified.body":"Authorizing with ORCID created your NEMAR account and signed you in. One step left: enter the 6-digit code we emailed you. That activates the account \u2014 no admin approval is involved.","welcome.active.title":"Your account is active","welcome.active.body":"Authorizing with ORCID created your NEMAR account and signed you in. There is no separate sign-up step and no approval queue: browse, search, and your dashboard all work right now.","welcome.upload_access.title":"Ask for upload access when you\u2019re ready to contribute","welcome.upload_access.body":"Reading is open to every verified account. Uploading and compute need one extra grant, because an admin has to check your GitHub handle and location against export-control and local-jurisdiction rules first. You ask once, from Settings.","oidc.consent.title":"{client} wants to use your NEMAR account","oidc.consent.acts_as_you":"If you allow it, {client} can act as you on NEMAR in the ways listed below.","oidc.consent.compute_spend":"If you sign in and run compute with this app, it counts against your NEMAR compute allocation.","oidc.consent.scopes_title":"It is asking to:","oidc.consent.scope.openid":"Know which NEMAR account is yours","oidc.consent.scope.profile":"See your name","oidc.consent.scope.email":"See your email address","oidc.consent.scope.orcid":"See your ORCID iD, and whether you proved it by signing in with ORCID","oidc.consent.scope.nemar.account":"See your account type, status and access level","oidc.consent.scope.offline_access":"Keep this access when you are not using it","oidc.consent.scope.compute.read":"See your compute access, balances, usage and jobs","oidc.consent.scope.compute.reserve":"Reserve compute time, report jobs and release reservations for you","oidc.consent.scope.compute.submit":"Submit compute jobs that NEMAR runs for you","oidc.consent.redirect_host":"Either answer sends you to {redirect_host}.","oidc.consent.allow":"Allow","oidc.consent.deny":"Deny","oidc.rule.title":"You can\u2019t sign in to {client} with this account","oidc.rule.account_inactive":"Your NEMAR account is not active.","oidc.rule.account_not_person":"{client} is only for personal accounts, and this account is not one.","oidc.rule.orcid_not_proven":"{client} needs an ORCID iD you proved by signing in to NEMAR with ORCID. Link your ORCID iD in Settings, then try again.","oidc.rule.return":"Return to {client}","oidc.error.title":"This sign-in can\u2019t continue","oidc.error.invalid_client":"The site that sent you here is not one NEMAR signs people in to.","oidc.error.invalid_redirect_uri":"The site that sent you here asked NEMAR to send you to an address it has not registered, so NEMAR will not send you there.","oidc.error.invalid_request":"The sign-in request is incomplete or malformed. Go back to the site you came from and start again.","oidc.error.consent_invalid":"This page has expired. Go back to the site you came from and start again.","oidc.error.unavailable":"NEMAR could not complete this sign-in right now. Try again in a moment.","oidc.error.rate_limited":"Too many sign-in attempts. Try again in a minute.","mail.category.news.label":"News","mail.category.news.description":"New features, data and events.","mail.category.rfcs.label":"Requests for comments","mail.category.rfcs.description":"A new NEMAR request for comments is open for discussion.","mail.category.maintenance.label":"Maintenance","mail.category.maintenance.description":"Planned downtime and changes to the service.","mail.category.recall.label":"Recalls","mail.category.recall.description":"A dataset, release or credential NEMAR distributed has a problem you need to act on.","mail.recall.why":"Recalls cannot be turned off: they tell you to stop using, delete or replace something NEMAR distributed or issued, because continuing to use it can cause harm.","cli.gaps.section.title":"Profile","cli.gaps.unknown":"not checked: run 'nemar auth status --refresh'","cli.gaps.unreported":"not reported by this backend","cli.gap.set_on.cli_only":"Run `{cli}`.","cli.gap.field.sandbox.label":"Sandbox training","cli.gap.blocks.sandbox":"to upload a dataset from the CLI","cli.gap.field.sandbox.set_on.cli":"nemar sandbox","cli.gaps.sandbox_unchecked":"Sandbox training could not be confirmed with the server. Run `nemar sandbox status --refresh`, then `nemar sandbox` if it is still outstanding.","cli.upload.preflight.title":"Upload access is not granted yet","cli.upload.preflight.body":"Browsing, searching and downloading are open to your account already. Uploading, or being added as a collaborator on someone else\u2019s dataset, needs one extra grant: an admin checks your GitHub handle and location against export-control and local-jurisdiction rules, once. Your email address must be verified first.","cli.upload_access.cta":"Ask for it with `nemar auth request-upload-access`.","cli.compute_access.cta":"Ask for it with `nemar compute request-access`.","cli.upload.preflight.unchecked":"Upload access could not be checked ({reason}); continuing.","cli.upload.preflight.gaps_unknown":"Could not determine what is still missing; run `nemar auth profile` for the list.","cli.upload.preflight.dry_run":"Continuing anyway: --dry-run uploads nothing."}});function tW(e){return typeof e==="string"&&p9.includes(e)}function rW(e){return typeof e==="string"&&BE.includes(e)}function nW(e){return Wo[`mail.category.${e}.label`]}function sW(e){return Wo[`mail.category.${e}.description`]}function oW(){return Wo["mail.recall.why"]}function h9(e){return e.replace(/\r\n?/g,`
32
+ [nemar] You can manually copy ${n} to ${t}`)}}function St(){let e=Jl();if(Ko&&PE===e)return Ko;if(zV(e),Ko=new Bi({projectName:"nemar",configFileMode:Zl,schema:{activeAccount:{type:"string"},accounts:{type:"object"},apiKey:{type:"string"},apiUrl:{type:"string"},username:{type:"string"},email:{type:"string"},githubUsername:{type:"string"},sandboxCompleted:{type:"boolean"},sandboxDatasetId:{type:"string"}},cwd:e}),PE=e,!CE.has(e))CE.add(e),GV(Ko.path),HV(),BV();return Ko}function GV(e){if(process.platform==="win32")return;if(!Ql(e))return;try{if((LV(e).mode&511)!==Zl)qV(e,Zl)}catch(t){console.error(`[nemar] could not secure config file permissions for ${e}:`,t)}}function HV(){let e=St(),t=e.get("accounts");if(t&&Object.keys(t).length>0)return;let r=e.get("apiKey"),n=e.get("username");if(!r&&!n)return;try{let s=n||"default",o={};for(let a of KV){let i=e.get(a);if(i!==void 0)o[a]=i}e.store={activeAccount:s,accounts:{[s]:o}}}catch(s){console.error("Config migration failed (legacy config preserved):",s)}}function BV(){let e=St(),t=e.store,r=t.accounts,n=!1;if(r)for(let[o,a]of Object.entries(r)){let i=a?.apiUrl;if(!i)continue;if(UV.has(FV(i)))r[o]={...a,apiUrl:Vs},console.error(`[nemar] migrated stored apiUrl for account "${o}": ${i} -> ${Vs}`),n=!0}let s=t.apiUrl;if(r&&Object.keys(r).length>0&&s!==void 0){let{apiUrl:o,...a}=t;try{e.store=a,console.error(`[nemar] removed stale top-level apiUrl from config (was: ${s})`),n=!1}catch(i){console.error("API URL cleanup failed (config file unchanged):",i)}}if(n)try{e.store={...e.store,accounts:r}}catch(o){console.error("API URL migration failed (config file unchanged):",o)}}function Ho(){return St().get("activeAccount")}function bn(){return St().get("accounts")||{}}function vn(){let e={apiUrl:Vs},t=Ho();if(!t)return e;return bn()[t]||e}function QB(e,t){let r=St(),n=r.get("activeAccount")||"default",s=r.get("accounts")||{};if(!s[n])s[n]={apiUrl:Vs};s[n][e]=t,r.store={...r.store,accounts:s,activeAccount:n}}function ZB(e){let t=Ho();if(!t)return;let r=bn();if(r[t])delete r[t][e],St().set("accounts",r)}function e6(){let e=St(),t=Ho();if(!t){e.clear();return}let r=bn();delete r[t];let n=Object.keys(r);if(n.length>0)e.store={...e.store,accounts:r,activeAccount:n[0]};else e.clear()}function t6(){St().clear()}function r6(){return!!vn().apiKey}function n6(){return St().path}function s6(){let e=bn(),t=Ho();return Object.entries(e).map(([r,n])=>({key:r,username:n.username,email:n.email,githubUsername:n.githubUsername,active:r===t,keySource:n.keySource}))}function o6(e){return e.username?.trim()||e.email}function WV(e){let t=e.trim().toLowerCase();if(!t)return;let r=Object.entries(bn()).filter(([,n])=>n.email&&n.email.toLowerCase()===t).map(([n])=>n);if(r.length>1){mr(`findAccountKeyByEmail: ${r.length} accounts share email ${t}: ${r.join(", ")}`);return}return r[0]}function a6(e,t){let r=St(),n=bn(),s;if(n[e])s=e;else if(t.email)s=WV(t.email);let o=s?n[s]:void 0,a={...o??{apiUrl:Vs},...t};if(s&&s!==e)delete n[s];return n[e]=a,r.store={...r.store,accounts:n,activeAccount:e},{key:e,previous:o}}function i6(e){let t=e.trim();if(!t)return"unchanged";let r=St(),n=Ho();if(!n||n===t)return"unchanged";let s=bn(),o=s[n];if(!o)return"unchanged";if(s[t])return"key_taken";return delete s[n],s[t]={...o,username:t},r.store={...r.store,accounts:s,activeAccount:t},"renamed"}function c6(e){let t=St(),r=bn();if(r[e])return t.store={...t.store,activeAccount:e},r[e];for(let[n,s]of Object.entries(r))if(s.githubUsername===e)return t.store={...t.store,activeAccount:n},s;return null}var Vs="https://api.nemar.org",Zl=384,UV,VV,JB,Ko=null,PE=null,CE,KV;var mc=L(()=>{V$();_n();oc();Xl();UV=new Set(["https://api.osc.earth/nemar","https://nemar-api.neuromechanist.workers.dev","https://nemar-api-dev.shirazi-10f.workers.dev"]);VV=Z({field:_(),blocks:Ye(_()).optional(),set_on:Ye(_()).optional()}).passthrough(),JB=Z({apiKey:_().optional(),apiUrl:_().url().default(Vs),username:_().optional(),email:_().email().optional(),githubUsername:_().optional(),sandboxCompleted:Ie().optional(),sandboxDatasetId:_().optional(),dismissedNoticeIds:Ye(ne()).optional(),serviceAccess:Ie().optional(),profileGaps:Ye(VV).optional(),orcidVerified:Ie().optional(),role:_().optional(),accountKind:Mn.optional(),pendingEmailChange:_().email().optional()});CE=new Set;KV=["apiKey","apiUrl","username","email","githubUsername","sandboxCompleted","sandboxDatasetId","dismissedNoticeIds"]});var YV,XV,f6,JV,p6,QV,IE,m6,h6=8,g6=100,jE,y6,ZV,_6;var qE=L(()=>{_n();oc();YV=["given_name","family_name","affiliation","city","country"],XV=["username","github_username","email","orcid"],f6=[...YV,...XV],JV={given_name:_().max(200).optional(),family_name:_().max(200).optional(),affiliation:_().max(500).optional(),city:_().max(200).optional(),country:_().max(200).optional(),username:_().max(100).optional(),github_username:_().max(100).optional(),email:_().max(320).optional(),orcid:_().max(40).optional()},p6=Z(JV),QV=Fe(["field_not_editable","owner_only_field","edit_own_account","owner_account","system_account","invalid_edit","orcid_already_proven","invalid_search","invalid_user_id"]),IE=QV.options,m6=["exact","name","prefix","substring","fuzzy"],jE=Z({id:ne().int(),username:_().nullable(),email:_(),github_username:_().nullable(),status:_(),role:_().nullable(),account_kind:Mn.optional(),email_verified:ne().int().nullable().optional(),orcid:_().nullable().optional(),orcid_verified:ne().int().nullable().optional(),given_name:_().nullable().optional(),family_name:_().nullable().optional(),affiliation:_().nullable().optional(),city:_().nullable().optional(),country:_().nullable().optional(),description:_().nullable().optional(),signup_source:_().nullable().optional(),created_at:_(),updated_at:_().nullable().optional(),approved_at:_().nullable().optional(),revoked_at:_().nullable().optional(),deleted_at:_().nullable().optional(),service_access:ne().int().nullable().optional(),service_access_granted_at:_().nullable().optional(),service_access_granted_by:ne().int().nullable().optional(),upload_access_requested_at:_().nullable().optional(),upload_access_notified_at:_().nullable().optional(),compute_access:_().optional(),compute_access_requested_at:_().nullable().optional(),compute_access_notified_at:_().nullable().optional(),compute_access_granted_at:_().nullable().optional(),compute_access_granted_by:ne().int().nullable().optional(),compute_terms_version:_().nullable().optional(),compute_terms_accepted_at:_().nullable().optional(),identity_conflict:ne().int().nullable().optional(),username_auto_assigned:ne().int().nullable().optional(),sandbox_completed:ne().int().nullable().optional(),sandbox_completed_at:_().nullable().optional(),sandbox_dataset_id:_().nullable().optional(),aws_iam_username:_().nullable().optional(),dataset_count:ne().int().optional(),active_tokens:ne().int().optional(),linked_identities:Ye(_()).optional()}).passthrough(),y6=Z({user:jE}).passthrough(),ZV=Z({from:_().nullable(),to:_().nullable()}),_6=Z({message:_(),changed:NF(_(),ZV),notes:Ye(_()).optional(),old_address_notified:Ie().optional(),user:jE}).passthrough()});function t9(e){for(let t=0;t<e.length;t++){let r=e.charCodeAt(t);if(r<32&&r!==9&&r!==10||r===127)return!0}return!1}function x6(e,t){let r=s9[e];if(r==="refused")return t===void 0?null:"notice_refused";let n=t?.trim()??"";if(n==="")return r==="required"?"notice_required":null;if([...n].length>ME)return"notice_too_long";if(t9(n))return"notice_control_char";return null}var w6=20,e9=1000,$6,r9,DE,E6,n9=500,S6=200,ME=1000,s9,R6,LE,k6,o9,T6;var UE=L(()=>{_n();$6=Z({purpose:_().max(e9*4).optional().default(""),accept_terms_version:_().max(64).optional().default("")}),r9=Fe(["purpose_required","terms_not_accepted","email_not_verified","orcid_not_proven","profile_incomplete","access_closed","already_active","terms_unpublished"]),DE=r9.options,E6=Z({ok:gn(!0),already_requested:Ie(),requested_at:_().nullable().optional(),email_sent:Ie().optional(),admins_notified:ne().int().nullable().optional()}).passthrough(),s9={grant:"refused",deny:"optional",suspend:"required",revoke:"required"};R6={reason:_().max(n9).optional(),notice:_().max(ME*4,{message:"notice_too_long"}).optional()},LE=Z({id:ne().int(),username:_().nullable(),email:_(),given_name:_().nullable().optional(),family_name:_().nullable().optional(),affiliation:_().nullable().optional(),city:_().nullable().optional(),country:_().nullable().optional(),orcid:_().nullable().optional(),account_kind:_().optional(),compute_access:_(),compute_access_requested_at:_().nullable().optional(),compute_access_notified_at:_().nullable().optional(),compute_access_granted_at:_().nullable().optional(),compute_access_granted_by:ne().int().nullable().optional(),compute_purpose:_().nullable().optional(),compute_terms_version:_().nullable().optional(),compute_terms_accepted_at:_().nullable().optional()}).passthrough(),k6=Z({accounts:Ye(LE),next_after:ne().int().nullable().optional()}).passthrough(),o9=Z({granted:Ie(),cpu_milli:ne().int(),gpu_milli:ne().int(),reason:_().nullable().optional(),policy_version:ne().int().nullable().optional()}).passthrough(),T6=Z({decision:_(),from:_(),to:_(),account:LE,allocation:o9.optional(),email_sent:Ie().optional()}).passthrough()});var N6=120,P6=64,C6="unnamed machine",a9=25,FE,I6,zs,VE,j6,q6,D6,i9,c9,M6,ed,L6,U6,F6,V6,z6;var zE=L(()=>{_n();FE=Fe(["authorization_pending","slow_down","expired_token","access_denied","invalid_grant"]),I6={authorization_pending:"Waiting for you to authorize this machine in the browser.",slow_down:"Polling too quickly; the CLI will slow down automatically.",expired_token:"The code expired. Run `nemar auth login` again for a new one.",access_denied:"This sign-in was declined in the browser. Run `nemar auth login` again if that was a mistake.",invalid_grant:"That code is no longer valid. Run `nemar auth login` again for a new one."},zs=Fe(["device_code_unknown","device_code_expired","device_code_used","device_code_denied","account_pending","account_revoked","identity_conflict","service_account","person_account","too_many_keys","key_not_found"]),VE=zs.options,j6={device_code_unknown:"That code was not found. Check the code shown in your terminal, or run `nemar auth login` again for a new one.",device_code_expired:"The code expired. Run `nemar auth login` again for a new one.",device_code_used:"That code has already been used. Run `nemar auth login` again for a new one.",device_code_denied:"This sign-in was declined in the browser. Run `nemar auth login` again if that was a mistake.",account_pending:"Verify your email address first. Check your inbox for the NEMAR verification code, then authorize again.",account_revoked:"Your NEMAR account access has been revoked. Contact the NEMAR team if you think this is a mistake.",identity_conflict:"This account shares an identifier with another NEMAR account and cannot sign in until that is resolved. Fix it in Settings on nemar.org or contact the NEMAR team.",service_account:"This is a service or test account, and it cannot sign in this way. Ask an owner to create a key for it with `nemar admin users keys create`.",person_account:"This account belongs to a person. A person creates their own keys with `nemar auth login` or in Settings on nemar.org.",too_many_keys:`This account already has ${a9} active keys. Revoke one in Settings on nemar.org or with \`nemar auth keys\`, then try again.`,key_not_found:"That key was not found on this account, or it is already revoked. Run `nemar auth keys` to see the active ones."},q6=Z({error:zs,message:_()}).passthrough(),D6=Z({device_code:_(),user_code:_(),verification_uri:_(),verification_uri_complete:_(),expires_in:ne().int(),interval:ne().int()}).passthrough(),i9=X$("error",[Z({error:gn("authorization_pending"),message:_()}).passthrough(),Z({error:gn("slow_down"),message:_()}).passthrough()]),c9=X$("error",[Z({error:gn("expired_token"),reason:zs,message:_()}).passthrough(),Z({error:gn("access_denied"),reason:zs,message:_()}).passthrough(),Z({error:gn("invalid_grant"),reason:zs,message:_()}).passthrough()]),M6=OF([i9,c9]),ed=Z({id:ne().int(),name:_().nullable(),prefix:_(),created_at:_(),last_used_at:_().nullable(),current:Ie()}).passthrough(),L6=Z({api_key:_(),key:ed,user:Z({username:_().nullable(),email:_(),github_username:_().nullable(),role:_(),sandbox_completed:Ie(),sandbox_dataset_id:_().nullable()}).passthrough()}).passthrough(),U6=Z({user_code:_(),machine_name:_(),requested_at:_(),expires_in:ne().int(),account:Z({username:_().nullable(),email_masked:_()}).passthrough(),refusal:Z({code:zs,message:_()}).passthrough().nullable()}).passthrough(),F6=Z({ok:gn(!0),machine_name:_()}).passthrough(),V6=Z({keys:Ye(ed)}).passthrough(),z6=Z({api_key:_(),key:ed}).passthrough()});var u9,GE,Bo="https://nemar.org/settings",H6,l9,d9,f9,B6,W6;var KE=L(()=>{_n();u9=Fe(["orcid_in_use","orcid_already_linked","orcid_linked_other","email_in_use","github_in_use","identity_conflict_remains"]),GE=u9.options,H6={orcid_in_use:`That ORCID iD already belongs to a NEMAR account. Sign in to that account instead; if you want the iD on a different account, unlink it there first (Settings, ${Bo}).`,orcid_already_linked:`That ORCID iD already belongs to a NEMAR account. Sign in to that account instead; if you want the iD on a different account, unlink it there first (Settings, ${Bo}).`,orcid_linked_other:`That ORCID iD is linked to a different NEMAR account. Unlink it there first (Settings, ${Bo}), then link it here.`,email_in_use:`That email address already belongs to a NEMAR account. Sign in to that account instead, or change its address first (Settings, ${Bo}).`,github_in_use:`That GitHub account is already linked to a NEMAR account. Sign in to that account instead, or change its GitHub username first (Settings, ${Bo}).`,identity_conflict_remains:"The collision that flagged this account is still there. Resolve it on the other account first (change its email or GitHub username, or unlink its ORCID iD), or delete that account, then clear the flag."},l9=Fe(["orcid","email","github"]),d9=Z({id:ne().int(),username:_().nullable(),email:_(),created_at:_(),has_oauth_identity:Ie(),dataset_count:ne().int(),identity_conflict:ne().int(),canonical:Ie()}).passthrough(),f9=Z({kind:l9,value:_(),canonical_user_id:ne().int(),accounts:Ye(d9)}).passthrough(),B6=Z({groups:Ye(f9),group_count:ne().int(),flagged_count:ne().int()}).passthrough(),W6=Z({ok:gn(!0),id:ne().int(),cleared:Ie()}).passthrough()});function X6(e){return Wo[e]}function J6(e,t){return e.replace(/\{(\w+)\}/g,(r,n)=>Object.hasOwn(t,n)?t[n]:r)}var Wo;var HE=L(()=>{Wo={"tier.unverified.label":"Email not verified","tier.base.label":"Base access","tier.upload.label":"Upload access","tier.unverified.lede":"Verify your email address to activate your account.","upload_access.section.title":"Upload access","upload_access.section.lede":"A one-time admin grant. Reviewed against export-control and local-jurisdiction rules.","upload_access.state.granted":"Granted","upload_access.state.requested":"Requested","upload_access.state.not_requested":"Not requested","upload_access.invite.title":"Want to contribute a dataset?","upload_access.invite.body":"Browsing, searching and downloading are open to your account already. Uploading, or being added as a collaborator on someone else\u2019s dataset, needs one extra grant: an admin checks your GitHub handle and location against export-control and local-jurisdiction rules, once. Your email address must be verified first.","upload_access.gate.title":"Ask for upload access first","upload_access.gate.body":"Your account can browse, search and download everything public already. Uploading, or being added as a collaborator on someone else\u2019s dataset, needs one extra grant, and your email address must be verified first: an admin checks your GitHub handle and where you\u2019re based against export-control and local-jurisdiction rules. You ask once, and it is answered by email.","upload_access.request.cta":"Request upload access","upload_access.request.form_body":"Tell us what you plan to deposit, or which dataset you want to collaborate on. An admin reviews this alongside your name, username, GitHub handle and location, then grants access once.","upload_access.request.why_label":"What do you intend to upload?","upload_access.request.why_hint":"Describe what you intend to upload in 20-500 characters","upload_access.requested.title":"Your request is with an admin","upload_access.requested.lede":"An admin is reviewing your request.","upload_access.requested.lede_dated":"An admin is reviewing your request from {date}.","upload_access.requested.body.upload":"We\u2019ll email you when there\u2019s a decision, and this page will let you upload as soon as it\u2019s granted.","upload_access.requested.body":"We\u2019ll email you when there\u2019s a decision. Everything else on your account keeps working in the meantime.","upload_access.requested.cta":"See the request","upload_access.granted.body":"You can upload datasets from the upload page. Publishing one is a separate, per-dataset review you start from your dashboard.","upload_access.unverified.body":"Verify your email address first \u2014 the review happens over email.","upload_access.docs_link":"How upload access works","compute_access.section.title":"Compute access","compute_access.section.lede":"A separate grant from upload access. An admin reviews each request against export-control and local-jurisdiction rules and the purpose you state, and a grant lets you use compute within the limits an administrator sets.","compute_access.state.none":"Not requested","compute_access.state.requested":"Requested","compute_access.state.active":"Active","compute_access.state.suspended":"Suspended","compute_access.state.denied":"Not granted","compute_access.state.revoked":"Ended","compute_access.request.cta":"Request compute access","compute_access.request.form_body":"Tell us what you plan to compute. An admin reviews this alongside your name, affiliation and location, then answers once. You also accept the compute terms.","compute_access.request.purpose_label":"What do you intend to compute?","compute_access.request.purpose_hint":"Describe what you intend to compute in 20-1000 characters","compute_access.request.terms_label":"I accept the compute terms","compute_access.requested.title":"Your compute request is with an admin","compute_access.requested.lede":"An admin is reviewing your request.","compute_access.requested.lede_dated":"An admin is reviewing your request from {date}.","compute_access.requested.body":"We\u2019ll email you when there\u2019s a decision. Everything else on your account keeps working in the meantime.","compute_access.granted.body":"Compute access is active. Your balances are on your compute page, and you submit jobs with the `nemar compute` command line.","compute_access.granted.link":"Open your compute page","compute_access.closed.body":"This request has been answered and cannot be asked again. If you think that is a mistake, contact support and an admin will take another look.","compute_access.suspended.body":"Your compute access is paused. Contact support to find out why or to ask for it to be lifted.","compute_access.terms_unpublished.body":"Compute access is not open yet: the compute terms are not published. Please check back later.","compute_access.docs_link":"How compute access works","compute_page.frozen.body":"Your pools are frozen, so new jobs are refused. Contact support to find out why.","compute_page.units_note":"Amounts are service units (SU).","compute_page.available_note":"Available is granted minus held minus charged and can be negative after an overrun.","compute_page.queue_note":"It describes the queue of the whole platform, not yours, and it is a recent average, not a promise.","compute_page.usage_note":"Net charge by UTC day of the charge, not the day a job was created. A day with no charge has no bar.","compute_page.unreported_note":"NEMAR has not heard from the cluster about this job for a while. It may still finish.","compute_admin.page.title":"Compute","compute_admin.page.lede":"Compute access requests, and a read-only view of pools, usage, flagged jobs and reconciliation. A grant opens an allocation the person can spend, so each request is decided by a person, one at a time.","compute_admin.page.cli_note":"Owner policy, legal holds, record reads, moving a charge, pool grants and adjustments, and canceling a job are done with the nemar admin compute command in the command line, not here.","compute_admin.page.order_note":"Accounts are listed in the order they were created, not the order they asked in.","compute_admin.view.nav":"Compute views","compute_admin.view.requests":"Requests","compute_admin.view.pools":"Pools","compute_admin.view.usage":"Usage","compute_admin.view.flagged":"Flagged jobs","compute_admin.view.drift":"Reconciliation","compute_admin.state.nav":"Filter requests by state","compute_admin.state.requested":"Requested","compute_admin.state.active":"Active","compute_admin.state.suspended":"Suspended","compute_admin.state.denied":"Denied","compute_admin.state.revoked":"Revoked","compute_admin.state.all":"All","compute_admin.requests.none":"No accounts in this view.","compute_admin.pager.next":"Next page","compute_admin.pager.first":"First page","compute_admin.row.not_set":"not set","compute_admin.row.no_username":"no username","compute_admin.row.account_kind":"{kind} account","compute_admin.row.stated_country":"Stated country","compute_admin.row.stated_country_hint":"Check this against the export-control rules before granting. This page does not rule on it.","compute_admin.row.city":"City","compute_admin.row.affiliation":"Affiliation","compute_admin.row.email":"Email","compute_admin.row.orcid":"ORCID iD","compute_admin.row.requested":"Requested","compute_admin.row.terms":"Terms accepted","compute_admin.row.terms_value":"{version}, {date}","compute_admin.row.purpose":"Stated purpose","compute_admin.row.show_full_purpose":"Show full purpose","compute_admin.row.granted":"Granted {date} by account #{id}","compute_admin.row.not_notified":"No administrator has been emailed about this request yet.","compute_admin.row.open_in_users":"Open in Users","compute_admin.action.grant":"Grant","compute_admin.action.grant_again":"Grant again","compute_admin.action.lift_suspension":"Lift suspension","compute_admin.action.deny":"Deny","compute_admin.action.suspend":"Suspend","compute_admin.action.revoke":"Revoke","compute_admin.self_grant.disabled":"You cannot grant your own compute access. Ask another administrator or an owner.","compute_admin.dialog.title.grant":"Grant compute access?","compute_admin.dialog.title.deny":"Deny this request?","compute_admin.dialog.title.suspend":"Suspend compute access?","compute_admin.dialog.title.revoke":"Revoke compute access?","compute_admin.dialog.consequence.grant":"Opens the owner\u2019s default allocation once for this account (a repeat grant adds nothing), unfreezes the account\u2019s pools, and allows the person to use compute when it is available. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.consequence.deny":"Closes this request. The person cannot ask again; only an administrator can grant later. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.consequence.suspend":"Freezes the account\u2019s pools, cancels its live jobs and ends its compute sign-ins. A partner reservation that has no job reported under it is not canceled here: it is released after it expires, and a job reported under it is refused. A grant lifts the suspension. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.consequence.revoke":"Freezes the account\u2019s pools, cancels its live jobs and ends its compute sign-ins. A partner reservation that has no job reported under it is not canceled here: it is released after it expires, and a job reported under it is refused. Only a new grant restores access. The person is emailed when they have an email address that can receive it.","compute_admin.dialog.reason_label":"Reason (optional)","compute_admin.dialog.reason_hint":"Recorded in the audit log. The person is not sent it.","compute_admin.dialog.reason_count":"{count} of {max}","compute_admin.dialog.notice_label":"Notice to the person","compute_admin.dialog.notice_label_optional":"Notice to the person (optional)","compute_admin.dialog.notice_help":"Emailed to the person under a fixed heading, with how to ask for a review. Write it for them. It is not the reason, which stays in the audit log.","compute_admin.dialog.notice_required_hint":"A suspension or a revocation tells the person why. Write the notice to confirm.","compute_admin.dialog.ack_export_review":"Confirm that you have reviewed this person\u2019s name, affiliation and stated country against the export-control rules","compute_admin.dialog.type_word":"Type {word} to confirm","compute_admin.dialog.cancel":"Cancel","compute_admin.result.working":"Working","compute_admin.result.granted":"Granted.","compute_admin.result.granted_opened":"Granted. Opened {cpu} CPU SU and {gpu} GPU SU.","compute_admin.result.granted_zero_default":"Granted. The owner\u2019s default allocation is zero, so nothing was opened.","compute_admin.result.granted_already":"Granted. An earlier grant already opened the default allocation, so nothing more was opened.","compute_admin.result.granted_other":"Granted. The allocation answered: {reason}.","compute_admin.result.denied":"Denied.","compute_admin.result.suspended":"Suspended. The account\u2019s pools are frozen and its live jobs are being canceled. A partner reservation with no job reported under it is left to expire.","compute_admin.result.revoked":"Revoked. The account\u2019s pools are frozen and its live jobs are being canceled. A partner reservation with no job reported under it is left to expire.","compute_admin.result.email_not_sent":"The decision stands, but the person could not be emailed. Tell them.","compute_admin.result.state_changed":"Someone else may have decided this first. The row shows the current state.","compute_admin.result.unconfirmed":"The result is not confirmed. The row shows what the server says now.","compute_admin.result.check_email":"The decision is in place, but the answer was lost, so check that the person was emailed and tell them if not.","compute_admin.result.stale":"This account was not found. Reload the page.","compute_admin.result.reread_failed":"The current state could not be read. Reload the page before deciding again.","compute_admin.result.signed_out":"You are signed out. Sign in again, then retry.","compute_admin.error.malformed":"The server sent an answer this page could not read.","compute_admin.error.unreachable":"The server could not be reached. Check your connection and try again.","compute_admin.error.redirect":"The server answered in a way this page cannot follow. Try again later.","compute_admin.error.origin":"This page was not accepted as the source of the request. Reload and try again.","compute_admin.error.rate_limited":"Too many requests. Wait a moment, then try again.","compute_admin.error.timeout":"The server did not answer in time. Try again.","compute_admin.error.failed":"The request failed ({status}). Try again.","compute_admin.error.generic":"Something went wrong. Try again.","compute_admin.error.bad_id":"That is not an account id.","compute_admin.error.bad_decision":"That is not a decision.","compute_admin.error.reason_too_long":"A reason is at most {max} characters.","compute_admin.error.notice_required":"This decision needs a notice to the person.","compute_admin.error.notice_refused":"A grant does not take a notice to the person.","compute_admin.error.notice_too_long":"A notice is at most {max} characters.","compute_admin.error.notice_control_char":"A notice may not contain control characters other than newline and tab.","compute_admin.error.bad_quarter":"A quarter is written like 2026Q4.","compute_admin.section.failed":"Could not load {what}: {reason}","compute_admin.col.holder":"Holder","compute_admin.col.pool":"Pool","compute_admin.col.granted":"Granted (SU)","compute_admin.col.held":"Held (SU)","compute_admin.col.charged":"Charged (SU)","compute_admin.col.available":"Available (SU)","compute_admin.col.frozen":"Frozen","compute_admin.col.updated":"Updated","compute_admin.col.partition":"Partition","compute_admin.col.source":"Front door","compute_admin.col.users":"Distinct people","compute_admin.col.jobs":"Jobs","compute_admin.col.job":"Job","compute_admin.col.account":"Account","compute_admin.col.state":"State","compute_admin.col.flags":"Flags","compute_admin.col.failure":"Failure","compute_admin.col.created":"Created","compute_admin.col.ended":"Ended","compute_admin.col.slurm":"Scheduler job","compute_admin.col.elapsed":"Elapsed (s)","compute_admin.col.resources":"Nodes, CPUs, GPUs","compute_admin.col.ingested":"Ingested","compute_admin.ref.account":"account #{id}","compute_admin.ref.no_account":"no account","compute_admin.pools.platform":"Platform budgets","compute_admin.pools.partner":"Partner pools","compute_admin.pools.account":"Account pools","compute_admin.pools.none_platform":"No platform budgets are recorded.","compute_admin.pools.none":"No pools are recorded in this group.","compute_admin.pools.truncated":"Showing the first {shown} pools of this group; more exist.","compute_admin.pools.frozen":"Frozen","compute_admin.pools.open":"Open","compute_admin.usage.quarter":"Quarter","compute_admin.usage.counts_note":"These are counts of people and jobs, not service units. A person is counted once however many jobs they ran, and jobs that skipped the reservation or could not be attributed are left out.","compute_admin.usage.totals":"Total","compute_admin.usage.none":"No jobs were recorded in this quarter.","compute_admin.flag.nav":"Filter jobs by flag","compute_admin.flag.unreserved":"Unreserved","compute_admin.flag.unattributed":"Unattributed","compute_admin.flag.mismatch":"Mismatch","compute_admin.flag.overrun":"Overrun","compute_admin.flag.meaning.unreserved":"The job skipped the reservation. Its charge went to a partner pool and not to a person.","compute_admin.flag.meaning.unattributed":"The job skipped the reservation and its owner maps to no active account.","compute_admin.flag.meaning.mismatch":"NEMAR\u2019s record and the scheduler\u2019s accounting disagree for this job, or a partner\u2019s report for it was refused or could not be checked, or a partner job used more than its hold and was capped.","compute_admin.flag.meaning.overrun":"The job used more than its hold, and the excess is recorded as an overrun in the ledger.","compute_admin.flag.followup":"Moving the charge of an unreserved job to a person is an owner action in the command line.","compute_admin.flagged.none":"No jobs carry this flag. That is a fact about this read only.","compute_admin.flagged.platform_failure":"NEMAR\u2019s fault","compute_admin.flagged.partner":"Partner: {state}, {flag}","compute_admin.drift.paused":"Reconciliation is paused while compute is off. An empty list below does not mean nothing is unmatched.","compute_admin.drift.pause_unknown":"Whether reconciliation is running is not known, so an empty list does not mean nothing is unmatched.","compute_admin.drift.status":"Status","compute_admin.drift.compute_on":"Compute is on.","compute_admin.drift.compute_off":"Compute is off.","compute_admin.drift.tapis":"Scheduler gateway: token {token}, health {health}.","compute_admin.drift.attention":"Needs a person to look","compute_admin.drift.attention_none":"No attention count is positive.","compute_admin.drift.unmatched":"Accounting rows no job claims","compute_admin.drift.unmatched_shown":"Showing the newest {shown} of {total}.","compute_admin.drift.unmatched_none":"No accounting rows are waiting for a job.","compute_admin.drift.not_priced":"not priced","compute_admin.drift.mismatch":"Jobs flagged mismatch","compute_admin.drift.mismatch_more":"See the Flagged jobs view for the rest","compute_admin.unavailable.title":"Not available yet","compute_admin.unavailable.usage_by_day":"Service units charged by day, partition and front door across the platform are not served by any admin read yet.","compute_admin.unavailable.drift_difference":"The difference between NEMAR\u2019s ledger and the supercomputer\u2019s accounting, per job or per day, and the tolerance it is measured against are not served by any admin read yet. No row is marked over tolerance because this page has no tolerance to apply.","compute_admin.unavailable.link":"Tracking issue","compute_admin.badge.awaiting_decision":"awaiting decision","gap.sentence":"{label} is missing: needed {blocks}.","gap.set_on.both":"Set it in {web} or run `{cli}`.","gap.set_on.web":"Set it in {web}.","gap.blocks.verified":"to activate your account","gap.blocks.upload_access":"to request upload access","gap.blocks.compute_access":"to request compute access","gap.blocks.publication":"to publish a dataset","gap.blocks.unknown":"to finish setting up your account","gap.blocks.noun.verified":"account activation","gap.blocks.noun.upload_access":"upload access","gap.blocks.noun.compute_access":"compute access","gap.blocks.noun.publication":"publication","gap.set_on.default_web":"Settings","gap.field.email_verified.label":"A verified email address","gap.field.username.label":"Username","gap.field.given_name.label":"Given name","gap.field.family_name.label":"Family name","gap.field.orcid_verified.label":"Verified ORCID iD","gap.field.github_username.label":"GitHub handle","gap.field.city.label":"City","gap.field.country.label":"Country","gap.field.affiliation.label":"Affiliation","gap.field.why.label":"A description of what you intend to upload","gap.field.email_verified.set_on.web":"the verify step on your dashboard","gap.field.email_verified.set_on.cli":"nemar auth resend-verification","gap.field.username.set_on.web":"Settings","gap.field.username.set_on.cli":"nemar auth profile set-username","gap.field.given_name.set_on.web":"Settings","gap.field.given_name.set_on.cli":"nemar auth profile set-name","gap.field.family_name.set_on.web":"Settings","gap.field.family_name.set_on.cli":"nemar auth profile set-name","gap.field.given_name.set_on.web.orcid":"your ORCID record at orcid.org, then sign in again","gap.field.family_name.set_on.web.orcid":"your ORCID record at orcid.org, then sign in again","gap.field.orcid_verified.set_on.web":"Settings","gap.field.orcid_verified.set_on.cli":"nemar auth profile orcid link","gap.field.github_username.set_on.web":"Settings","gap.field.github_username.set_on.cli":"nemar auth profile set-github","gap.field.city.set_on.web":"Settings","gap.field.city.set_on.cli":"nemar auth profile set-location","gap.field.country.set_on.web":"Settings","gap.field.country.set_on.cli":"nemar auth profile set-location","gap.field.affiliation.set_on.web":"Settings","gap.field.affiliation.set_on.cli":"nemar auth profile set-affiliation","gap.field.why.set_on.web":"the request form in Settings","gap.field.why.set_on.cli":"nemar auth request-upload-access","gaps.title":"What is still missing","gaps.none":"Nothing outstanding \u2014 every field NEMAR needs is filled in.","gaps.nudge.title":"Your profile isn\u2019t finished yet","gaps.nudge.cta":"Complete your profile","gaps.upload.title":"Before you can ask, your account still needs:","gaps.request.title":"Finish these first:","gaps.admin.title":"Still missing","gaps.admin.item":"{label} \u2014 blocks {blocks}","gaps.admin.none":"Nothing missing \u2014 every field the request needs is filled in.","gaps.admin.not_loaded":"Not loaded \u2014 open the user page to see what is still missing.","onboarding.username.auto_assigned.title":"We chose your username from your name","onboarding.username.auto_assigned.body":"Your account needed a username to be listed as a dataset owner, so one was made from your name when you signed in. You can change it once, here, until an admin grants you upload access.","welcome.unverified.title":"Verify your email address","welcome.unverified.body":"Authorizing with ORCID created your NEMAR account and signed you in. One step left: enter the 6-digit code we emailed you. That activates the account \u2014 no admin approval is involved.","welcome.active.title":"Your account is active","welcome.active.body":"Authorizing with ORCID created your NEMAR account and signed you in. There is no separate sign-up step and no approval queue: browse, search, and your dashboard all work right now.","welcome.upload_access.title":"Ask for upload access when you\u2019re ready to contribute","welcome.upload_access.body":"Reading is open to every verified account. Uploading and compute need one extra grant, because an admin has to check your GitHub handle and location against export-control and local-jurisdiction rules first. You ask once, from Settings.","oidc.consent.title":"{client} wants to use your NEMAR account","oidc.consent.acts_as_you":"If you allow it, {client} can act as you on NEMAR in the ways listed below.","oidc.consent.compute_spend":"If you sign in and run compute with this app, it counts against your NEMAR compute allocation.","oidc.consent.scopes_title":"It is asking to:","oidc.consent.scope.openid":"Know which NEMAR account is yours","oidc.consent.scope.profile":"See your name","oidc.consent.scope.email":"See your email address","oidc.consent.scope.orcid":"See your ORCID iD, and whether you proved it by signing in with ORCID","oidc.consent.scope.nemar.account":"See your account type, status and access level","oidc.consent.scope.offline_access":"Keep this access when you are not using it","oidc.consent.scope.compute.read":"See your compute access, balances, usage and jobs","oidc.consent.scope.compute.reserve":"Reserve compute time, report jobs and release reservations for you","oidc.consent.scope.compute.submit":"Submit compute jobs that NEMAR runs for you","oidc.consent.redirect_host":"Either answer sends you to {redirect_host}.","oidc.consent.allow":"Allow","oidc.consent.deny":"Deny","oidc.rule.title":"You can\u2019t sign in to {client} with this account","oidc.rule.account_inactive":"Your NEMAR account is not active.","oidc.rule.account_not_person":"{client} is only for personal accounts, and this account is not one.","oidc.rule.orcid_not_proven":"{client} needs an ORCID iD you proved by signing in to NEMAR with ORCID. Link your ORCID iD in Settings, then try again.","oidc.rule.return":"Return to {client}","oidc.error.title":"This sign-in can\u2019t continue","oidc.error.invalid_client":"The site that sent you here is not one NEMAR signs people in to.","oidc.error.invalid_redirect_uri":"The site that sent you here asked NEMAR to send you to an address it has not registered, so NEMAR will not send you there.","oidc.error.invalid_request":"The sign-in request is incomplete or malformed. Go back to the site you came from and start again.","oidc.error.consent_invalid":"This page has expired. Go back to the site you came from and start again.","oidc.error.unavailable":"NEMAR could not complete this sign-in right now. Try again in a moment.","oidc.error.rate_limited":"Too many sign-in attempts. Try again in a minute.","mail.category.news.label":"News","mail.category.news.description":"New features, data and events.","mail.category.rfcs.label":"Requests for comments","mail.category.rfcs.description":"A new NEMAR request for comments is open for discussion.","mail.category.maintenance.label":"Maintenance","mail.category.maintenance.description":"Planned downtime and changes to the service.","mail.category.recall.label":"Recalls","mail.category.recall.description":"A dataset, release or credential NEMAR distributed has a problem you need to act on.","mail.recall.why":"Recalls cannot be turned off: they tell you to stop using, delete or replace something NEMAR distributed or issued, because continuing to use it can cause harm.","cli.gaps.section.title":"Profile","cli.gaps.unknown":"not checked: run 'nemar auth status --refresh'","cli.gaps.unreported":"not reported by this backend","cli.gap.set_on.cli_only":"Run `{cli}`.","cli.gap.field.sandbox.label":"Sandbox training","cli.gap.blocks.sandbox":"to upload a dataset from the CLI","cli.gap.field.sandbox.set_on.cli":"nemar sandbox","cli.gaps.sandbox_unchecked":"Sandbox training could not be confirmed with the server. Run `nemar sandbox status --refresh`, then `nemar sandbox` if it is still outstanding.","cli.upload.preflight.title":"Upload access is not granted yet","cli.upload.preflight.body":"Browsing, searching and downloading are open to your account already. Uploading, or being added as a collaborator on someone else\u2019s dataset, needs one extra grant: an admin checks your GitHub handle and location against export-control and local-jurisdiction rules, once. Your email address must be verified first.","cli.upload_access.cta":"Ask for it with `nemar auth request-upload-access`.","cli.compute_access.cta":"Ask for it with `nemar compute request-access`.","cli.upload.preflight.unchecked":"Upload access could not be checked ({reason}); continuing.","cli.upload.preflight.gaps_unknown":"Could not determine what is still missing; run `nemar auth profile` for the list.","cli.upload.preflight.dry_run":"Continuing anyway: --dry-run uploads nothing.","cli.admin.owner_name_missing.fix":"An ORCID-linked owner makes the name public on their ORCID record and signs in again; an owner with no verified ORCID link types it into Settings on nemar.org."}});function tW(e){return typeof e==="string"&&p9.includes(e)}function rW(e){return typeof e==="string"&&BE.includes(e)}function nW(e){return Wo[`mail.category.${e}.label`]}function sW(e){return Wo[`mail.category.${e}.description`]}function oW(){return Wo["mail.recall.why"]}function h9(e){return e.replace(/\r\n?/g,`
33
33
  `).trim().split(/\n{2,}/).map((t)=>t.trim()).filter((t)=>t!=="")}function g9(e){let t=/^(#{1,3})\s+(.+)$/.exec(e);if(!t)return null;return{level:t[1].length,text:t[2]}}function aW(e){let t=new Set(h9(e).map((r)=>g9(r)?.text.trim().toLowerCase()).filter((r)=>Boolean(r)));return m9.filter((r)=>!t.has(r.toLowerCase()))}function iW(e){let t=e.trim(),r=y9.exec(t);if(r)return{kind:"dataset",datasetId:r[1],version:r[2]??null,text:t};if(_9.test(t))return{kind:"github",url:t,text:t};return null}var BE,p9,eW="recall",WE,m9,y9,_9,cW="A recall needs a reference: a dataset id with an optional version (nm000104 or nm000104@v1.2.0), or a nemarOrg or nemarDatasets issue, pull request or security advisory URL.";var YE=L(()=>{HE();BE=["news","rfcs","maintenance"],p9=[...BE,"recall"];WE=["recall_cannot_be_turned_off","admin_alert_not_self_service","unknown_mail_preference","invalid_mail_preference"];m9=["What is affected","What to do"];y9=/^([a-z]{2}\d{6})(?:@v?(\d+\.\d+\.\d+))?$/,_9=/^https:\/\/github\.com\/(?:nemarOrg|nemarDatasets)\/[A-Za-z0-9._-]+\/(?:(?:issues|pull)\/\d{1,9}|security\/advisories\/GHSA(?:-[a-z0-9]{4}){3})$/});function mW(e){return typeof e==="string"&&b9.includes(e)}var v9,dW,fW,pW,b9,w9="ci_check_unavailable",XE,JE,QE,hW="X-Approval-Dispatch-Token",gW,yW="Search reflects this at once; the public dataset page and catalog list are cached at the edge and can keep showing the dataset for several minutes.";var ZE=L(()=>{_n();v9=/^\d{4}-\d{4}-\d{4}-\d{3}[\dX]$/,dW=_().regex(v9,"ORCID must be in format 0000-0000-0000-000X"),fW=Fe(["found","no_public_name","lookup_failed"]),pW=Fe(["bids_validation_failed","bids_validation_pending","bids_validation_in_progress","prescreen_failed","min_requirements_failed","owner_name_missing","identifier_screen_findings"]),b9=["bids_validation_pending","bids_validation_in_progress"];XE=[w9],JE=["identifier_screen_pending","identifier_screen_not_clear","identifier_screen_not_applicable"],QE=["publication_review_not_clear","request_blocked","request_changed","request_mismatch","dispatch_superseded","dispatch_expired","decision_with_dispatch_token","approval_in_flight","deny_after_publishing","invalid_dataset_id","approval_closed_during_run"],gW=Fe(["filled","would_fill","no_public_name","lookup_failed","write_failed"])});function tS(e){if(eS)return;eS=!0;let t=Pt.yellow("\u2500".repeat(60)),r=Pt.yellow.bold("[MAINTENANCE]"),n=Pt.dim(`mode: ${e.mode}`),s=e.eta?`
34
34
  ${Pt.dim(`eta: ${e.eta}`)}`:"";process.stderr.write(`${t}
35
35
  ${r} ${e.message}