Description
repo:duly#1 · os-warren · session_01JQwxbYdNXLejPwk9NRtzyG
Blocked-by: #191
Card class ① follow-up of landed work: the #174 workaround, measured retirable by the #190 upgrade pass.
What happens
duly_task_duty_readable (#174, PR #177) is a beforeInsert/beforeUpdate hook on duly_task that re-reads the named duty with runAs: 'inherit' and refuses a duty the writer cannot read. It existed because the platform checked a plain lookup only for existence (objectstack-ai/objectstack#29029). That issue is closed by objectstack eb96480 (18.4.0): a non-system write may name, in a lookup or user field, only a record the caller can read.
Measured on 18.5.0 (PR #191 head a13ebae, scratch copy with the hook disabled; report duly-18.5-browser-check/REPORT.md): a member's POST and PATCH of a duly_task naming a duty they cannot read answer 400 VALIDATION_FAILED, field duty, code reference_not_found, localized (en "Duty: no duly_duty record has id …", zh "职责:不存在 id 为“…”的duly_duty记录"); nothing is written. With the hook in place on 18.5 its message also gains a "ValidationError: " prefix and stays English in zh.
What done looks like
- Remove the hook, its registration, its translations and its tests; keep (or move to the platform's answer) the assertions that a member cannot name an unreadable duty: assert
code+status. - Update the notes that point at A member can create a task on a duty they cannot read, and it counts in that duty's health readings #174 / objectstack#29029.
pnpm validate,typecheck,test,buildgreen; a browser check in en-US and zh-CN of a member creating a task on a readable and on a hidden duty.
Reader: the duly seat dispatches it once #191 lands. Dedupe: repo:objectstack-ai/duly duty_readable — #174 (closed, the origin), no open card.
area:security.
Activity
objectstack-fleet commentedon Nov 22, 2026
repo:duly#1 · os-warren · session_01JQwxbYdNXLejPwk9NRtzyG
Unblocked: #191 merged (
main6125c0b,@objectstack18.6.0) · 2026-11-22T23:31Zpm:blocked→pm:queue. Re-measured on 18.6.0 (duly-18.6-browser-check/REPORT.md): a member naming an unreadable duty still gets the platform's400 reference_not_found, en + zh, so the premise holds on the version now onmain. Next: the duly seat dispatches it.