Repository navigation
Compute decision dialog: notice to the person - #583
Merged
Merged
Conversation
Deploying nemar-website with
|
| Latest commit: |
66bfd0a
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://b2efbcce.nemar-website.pages.dev |
| Branch Preview URL: | https://feature-compute-decision-not.nemar-website.pages.dev |
This was referenced Nov 22, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The website half of nemarOrg/nemar-cli#2300, which adds a person-facing
noticeto the admin compute-access decision: required for suspend and revoke, optional for deny, refused for grant (COMPUTE_ACCESS_NOTICE_RULE/computeAccessNoticeProblemin nemar-clishared/contract/compute-access.ts).Without this, the Compute tab's Suspend and Revoke would get
400 invalid_body(notice: notice_required) once #2300 deploys.Merge order (website ADR 0030 addendum)
This is a coupled change and merges as a pair:
stagingfirst.devimmediately after.Each side's parity check reads the other's pre-release branch, so
test/account-copy-drift.test.tsandtest/compute-admin-contract-drift.test.tshere are red against nemar-clidevuntil #2300 lands there, and nemar-cli'saccount-copy-parityis red againststaginguntil this lands.Changes
src/lib/account-copy.ts: mirrors the new shared keys string for string (compute_admin.dialog.notice_label,notice_label_optional,notice_help,notice_required_hint;compute_admin.error.notice_required,notice_refused,notice_too_long,notice_control_char).src/lib/compute-admin-contract.ts: transcribesCOMPUTE_ACCESS_NOTICE_MAX_CHARS(1000),COMPUTE_ACCESS_NOTICE_RULE, the four notice words, andcomputeAccessNoticeProblem/hasPurposeControlCharwith bodies identical to nemar-cli's.test/compute-admin-contract-drift.test.ts: holds the bound, the rule record, the word union and both function bodies (token for token) to nemar-cli; new pure extractorsextractStringUnionandextractFunctionBodyintest/compute-contract-drift.ts, tested on inline sources. Same sparse checkout andNEMAR_CLI_COMPUTE_ADMIN_CONTRACT(the file was already in the list); theci.ymlcomment says so.decideComputeAccess(id, decision, reason, notice, init): sendsnoticetrimmed, omits an empty optional one, and refuses a notice the rule refuses before sending (400 invalid_bodywithfields: [{ path: "notice", code }]), so nothing is posted.readComputeErrornow returns a 400'sfields;ComputeAdminApiError.fields,noticeProblemOfandnoticeProblemTextword a backend notice refusal from the copy instead of the rawnotice: notice_requiredsentence. It is classifiedrefused(no re-read, row restored).ComputeDecisionDialog.astro: a "Notice to the person" textarea for suspend and revoke (required) and deny (optional), hidden for grant, which sends nonoticekey at all. The count is in code points after trimming. The line under the field shows the required hint or the problem in copy words, and the confirm button stays disabled until the rule accepts the notice. The page passesnoticethrough the decide flow.scripts/capture-compute-admin-fixtures.mjs: suspend and revoke now send a notice, and new captures coverdeny_with_noticeand the five notice refusals. The fixtures were re-captured from nemar-cli#2300 head485352dd; the change is additions only, and existing ids are unchanged.Testing
bun run typecheck: 0 errorsbun run lint: cleanbun run testwith everyNEMAR_CLI_*drift variable fromci.ymlpointed at a detached worktree of nemar-cli#2300 head (485352dd): 238 files, 6655 tests passedbun run build: passes (public/og-image.pngrestored afterwards)account-copy-parityandpublication-review-copy-paritywithNEMAR_WEBSITE_*pointed at this branch, plus contract-schemas and the compute-access tests: 156 pass