Bug Fix #3601: passed resets and session evidence in the rotator¶
Logins whose stored reset has passed¶
A plan login's stored reading can show a window at its threshold with a reset
that has already passed. Such a reading shows nothing about the login's room.
Before the rotator writes a capacity ALERT, or moves onto a plan login at or
above --session-at, it reads each such login again. It does so whether or
not a credit login is usable, when the live probe failed, and when the ALERT
comes from the live login's outlook rather than its reading.
Each login is read once a cycle. A read that fails leaves the login unknown for that cycle. A move that a failed live probe gives still waits for the failed-probe count, the hold after a swap and the home-key rule.
Processes that are not sessions¶
A process with CLAUDE_CONFIG_DIR set to a profile's directory makes the
profile session running, and the rotator does not move onto it. Two kinds
of process do not count. One is a child that amplihack starts for a usage
probe, a control request or an accepted-call check; each such child has
AMPLIHACK_PROFILE_PROBE_CHILD=1 in its environment. The other is an
amplihack profile usage, statusline, list or show command, whether or
not its environment can be read. A launcher, an unfamiliar command and other
non-interactive work still make the profile session running.
A credit login with a running session¶
A credit login with a running session is not a target. After a swap, the
session and the live login would both use the same login, and either could
refresh its token. When no other login can be used, the ALERT reads
credit logins unavailable (session running): <profiles>. Other ALERTs end
with the same text in that case.
A move onto a plan login near its limit¶
With the live login blocked and no usable credit login, the rotator still
moves onto a plan login at or above --session-at. The swap line ends with
no credit login was usable, or with credit move deferred by overflow
policy when an overflow rule kept the rotator off an eligible credit login.
Either is followed by plan target at or above --session-at.
Usage records¶
Parallel probes in one process record their usage one at a time, so one probe's record does not discard another's as busy. Other processes still use the bounded file lock. The probes run in parallel.
Installation¶
Restart each running rotator. The lines are listed in the profile command reference.