Repository navigation
Logs an onboarding child id with a bad pass suffix - #284
Merged
Merged
Conversation
The onboarding focus picks the newest pass's child by parsing the suffix after "@" in the child's execution id. statifier_persistence exposes no function that reads a pass back out of an id, so the parse stays here. An id whose suffix is not "<macrostep>.<round>" was read as the first pass without a sign, so a change to the id shape would have degraded the pick silently. Such an id is still read as the first pass, and is now logged as a warning that names the id. An id with no "@" is the first pass's and logs nothing. A test creates a child whose suffix does not parse and checks the warning. Refs: se-hfxf
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.
What
The onboarding page's focus (
Onboarding.focus/1) picks the newest pass's child by parsing the pass suffix of each active child's execution id. An id whose suffix did not parse was read as the first pass without any sign.An unparseable suffix is now logged as a warning naming the child id, and is still read as the first pass. An id with no
@is the first pass's own and logs nothing. The page's behaviour for every parseable id is unchanged.Which acceptance branch, and why
The bead accepts either a pick that reads a pass order the persistence package exposes, or a surfaced unparseable suffix with a test. The pinned
statifier_persistence(0.28.0 inmix.lock) builds the id inLinkage.child_execution_id/4and the token inLinkage.invocation/1, but exposes no function that reads a pass back out of an id or orders two ids. So the first branch is not available here, and this PR takes the second.Logged rather than refused: a refusal would turn a degraded pick into a page error, and the focus's documented errors are the storage layer's and the unknown-setup case.
Test
a child id whose pass suffix does not parse is logged and read as the first passcreates a child under a suffix that is not<macrostep>.<round>, callsfocus/1, and checks the warning names that id. Sabotage: replacing the warning with a no-op turns this test red.Gate
mix qualitygreen on the committed tree (format, compile, credo, dialyzer, tests).Provenance
Engineering choice: log, do not refuse (above).