Skip to content

Say what the permit observer's Bad floor does and does not catch at restart - #688

Open
xmap wants to merge 1 commit into
mainfrom
docs/permit-floor-restart-window
Open

Say what the permit observer's Bad floor does and does not catch at restart#688
xmap wants to merge 1 commit into
mainfrom
docs/permit-floor-restart-window

Conversation

@xmap

@xmap xmap commented Aug 19, 2026

Copy link
Copy Markdown
Owner

Docstring only, no behaviour change.

permit_status_from_reading spends twenty lines justifying its Bad-not-Good quality floor, because 2-BM's SecureM sits at MAJOR whenever the hutch is unsecured. It never said what else that floor is or is not holding.

My first draft of this claimed the floor guards the IOC-restart window outright. Measurement says otherwise, so the note records the limit instead:

  • A record that has never had a value assigned reports STAT=UDF with SEVR=INVALID, arrives as Bad, and closes the gate.
  • A record given a value without processing does not. A field(VAL, ...) default at load, or an autosave restore at boot, clears UDF and leaves SEVR=NO_ALARM, so it reads Good while still carrying no substrate timestamp.

Measured on a scratch IOC (EPICS base 7.0.8, autosave R5-11) rather than inferred. Which group SecureM falls into is unconfirmed, so the floor must not be treated as a restart guard, and the docstring now says so. produced_at is the only signal separating the two cases, and this path carries it as evidence without gating on it.

Mechanism established in tomography/tomoscan#182.

🤖 Generated with Claude Code

…estart

The floor's docstring argued at length for Bad-not-Good, because 2-BM's
SecureM sits at MAJOR whenever the hutch is unsecured, but never said
what else the floor is holding. An earlier draft of this commit claimed
it guards the IOC-restart window outright. Measurement says otherwise,
so the note now records the limit instead of the reassurance.

A record that has never had a value assigned reports STAT=UDF with
SEVR=INVALID, arrives as Bad, and closes the gate. A record given a
value without processing does not: a field(VAL, ...) default at load,
or an autosave restore at boot, clears UDF and leaves SEVR=NO_ALARM, so
it reads Good while still carrying no substrate timestamp. Measured on
a scratch IOC, base 7.0.8 with autosave R5-11.

Which group SecureM falls into is unconfirmed, so the floor must not be
treated as a restart guard. produced_at is the only signal that
separates the two, and this path carries it as evidence without gating
on it.

Mechanism confirmed on tomography/tomoscan#182.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  apps/api/src/cora/api
  _enclosure_permit_observer.py
Project Total  

This report was generated by python-coverage-comment-action

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant