Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 10 additions & 6 deletions src/abstract/RainDeploySuitesBase.sol
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,12 @@ error UnknownDeploymentSuite(string requested, string validSuites);
/// to declare. When the candidate was a single struct this was true by
/// construction; a list has to say it.
///
/// Raised from `allSuites`, which is the only way anything reads the
/// declaration — `suiteNames` and `suiteByName` both go through it — so there
/// is no reader that answers from an empty one.
/// Raised from `checkedCandidateSuites` — see there for why the guard sits at
/// that one read rather than at each reader.
///
/// `releasedSuites` is read directly by the chain group and by the frozen
/// record check, and is untouched by this: a repo with no release is an
/// ordinary state, and it is the CANDIDATE that the source anchor needs.
error NoDeployCandidates();

/// One deployable unit: a named snapshot of one contract.
Expand Down Expand Up @@ -139,9 +142,10 @@ abstract contract RainDeploySuitesBase {
/// override this, and a repo inherits exactly one declaration. So the list
/// is here rather than left to the consumer to assemble.
///
/// MUST NOT be empty, which `allSuites` enforces. A deploy repo always
/// compiles a current source, so there is always something to anchor to —
/// see `NoDeployCandidates` for why an empty list is worse than it looks.
/// MUST NOT be empty, which `checkedCandidateSuites` enforces. A deploy
/// repo always compiles a current source, so there is always something to
/// anchor to — see `NoDeployCandidates` for why an empty list is worse
/// than it looks.
/// @return The candidates.
function candidateSuites() internal pure virtual returns (DeployCandidate[] memory);

Expand Down
2 changes: 1 addition & 1 deletion test/src/abstract/RainDeploySuitesBase.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ contract RainDeploySuitesBaseTest is Test {
/// An empty candidate list reads as a repo with nothing left to declare and
/// is a repo whose source anchor — the only check that catches a snapshot
/// of the wrong contract — has been handed nothing to run over. It is
/// refused rather than tolerated, and refused on all three readers, because
/// refused rather than tolerated, and refused on all four readers, because
/// a reader that answers from an empty declaration is a reader through
/// which the whole registry can be empty and green.
function testNoCandidateReverts() external {
Expand Down
Loading