huskies: merge 988
This commit is contained in:
@@ -22,7 +22,7 @@ pub(super) fn read_story_front_matter_agent(story_id: &str) -> Option<String> {
|
||||
/// `tool_approve_qa`).
|
||||
pub(super) fn has_review_hold(story_id: &str) -> bool {
|
||||
crate::crdt_state::read_item(story_id)
|
||||
.map(|w| w.stage().is_review_hold())
|
||||
.map(|w| matches!(w.stage(), crate::pipeline_state::Stage::ReviewHold { .. }))
|
||||
.unwrap_or(false)
|
||||
}
|
||||
|
||||
@@ -35,7 +35,18 @@ pub(super) fn is_story_blocked(story_id: &str) -> bool {
|
||||
crate::pipeline_state::read_typed(story_id)
|
||||
.ok()
|
||||
.flatten()
|
||||
.map(|item| item.stage.is_blocked())
|
||||
.map(|item| {
|
||||
matches!(
|
||||
item.stage,
|
||||
crate::pipeline_state::Stage::Blocked { .. }
|
||||
| crate::pipeline_state::Stage::MergeFailure { .. }
|
||||
| crate::pipeline_state::Stage::MergeFailureFinal { .. }
|
||||
| crate::pipeline_state::Stage::Archived {
|
||||
reason: crate::pipeline_state::ArchiveReason::Blocked { .. },
|
||||
..
|
||||
}
|
||||
)
|
||||
})
|
||||
.unwrap_or(false)
|
||||
}
|
||||
|
||||
@@ -70,7 +81,12 @@ pub(super) fn has_content_conflict_failure(story_id: &str) -> bool {
|
||||
/// the same story after a failed mergemaster session.
|
||||
pub(super) fn has_mergemaster_attempted(story_id: &str) -> bool {
|
||||
crate::crdt_state::read_item(story_id)
|
||||
.map(|view| view.stage().is_mergemaster_attempted())
|
||||
.map(|view| {
|
||||
matches!(
|
||||
view.stage(),
|
||||
crate::pipeline_state::Stage::MergeFailureFinal { .. }
|
||||
)
|
||||
})
|
||||
.unwrap_or(false)
|
||||
}
|
||||
|
||||
@@ -95,7 +111,7 @@ pub(super) fn check_archived_dependencies(story_id: &str) -> Vec<u32> {
|
||||
/// `resume_to`.
|
||||
pub(super) fn is_story_frozen(story_id: &str) -> bool {
|
||||
crate::crdt_state::read_item(story_id)
|
||||
.map(|view| view.stage().is_frozen())
|
||||
.map(|view| matches!(view.stage(), crate::pipeline_state::Stage::Frozen { .. }))
|
||||
.unwrap_or(false)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user