Repository navigation
Actionable v1.8.2 — review fixes
Three fixes found by a mutation-driven review, plus upgrade-guide answers from
a dry run against a large app. All three change what an app can see, so read
UPGRADING.md "1.8.1 → 1.8.2" before bumping. case_step branches now honour
if: / unless:: a guarded-out branch does nothing, silently, where the guard
used to be ignored. Actionable::RBS generates valid class names for ? / !
codes and raises on colliding ones. The first-run verb check sees through
alias_method, so it can raise on an aliased step it used to skip.
Fixed
case_stepbranches honourif:/unless:.on 'x', :handle, if: :ready?(anddefault :y, unless: …) accepted the guard and then ignored
it, so the branch always ran. The branch is still picked by value alone; its
guard now decides whether the target runs, as for a plain step. A matched
branch whose guard opts out does nothing: no fall-through to the next branch
or thedefault. Upgrade note: a branch you guarded now really skips.Actionable::RBSnames output classes for?/!codes validly.
Undertyped_outcomes,fails(:expired?) { … }emittedclass Expired?FailureOutput, which RBS can't parse. A trailing?/!now
becomesPredicate/Bang(ExpiredPredicateFailureOutput,
DoneBangSkipOutput), so:xand:x?get different classes.generate
now raisesArgumentErrorwhen two codes of one kind would share a class
name (:ready/:ready_), which silently emitted one class for two
schemas, or when a code can't start a class name. Upgrade note: rename
one of two clashing codes.- The first-run verb check sees through
alias_method. A step naming an
alias (step :chargewithalias_method :charge, :do_charge) looked up
the def by the alias name, found none, and skipped the check; it now reads
the originaldef, so a misplaced verb there raisesDefinitionErrorlike
any other step. Documented limit: a moduleprepended over a step method
hides the class's owndeffrom the check. Upgrade note: fix the
reported verb, as for any verb-position offense.
Documentation
- UPGRADING.md, from a dry run against a large app (133 actions). The guide
now says which six Finds must run on a green suite (silent behaviour changes)
and that the rest cover code the suite doesn't reach. ThedescribeFind skips
RSpec.describe(1,552 hits before). The code Finds skip receivers and
non-Ruby files. The@resultentry says aResultyou build yourself is still
allowed, withhalt!. A new section lists the class-level API unchanged since
1.5.1. The cop entry says to list every base class defined in its own file. The
opt-out goes inspec_helper, not an initializer. The effort estimate counts
suite runs, and there is a PCRE2 check. AGENTS.md and the skill follow.