Separate external governance authorities
This commit is contained in:
parent
aba5441194
commit
8f2ccac120
9 changed files with 73 additions and 31 deletions
|
|
@ -275,10 +275,10 @@ fn run_smoke(args: Args) -> Result<Value> {
|
|||
require_text(&request_text, "upstream_sync_authorized = false")?;
|
||||
require_text(&request_text, "hands_action_authorized = false")?;
|
||||
require_text(&request_text, "cross_body_mutation_authorized = false")?;
|
||||
require_text(
|
||||
&request_text,
|
||||
"bifrost_or_maintainer_authority_required = true",
|
||||
)?;
|
||||
require_text(&request_text, "maintainer_review_required = true")?;
|
||||
require_text(&request_text, "bifrost_publication_gate_required = true")?;
|
||||
require_text(&request_text, "hands_execution_required = true")?;
|
||||
require_text(&request_text, "github_provider_receipt_required = true")?;
|
||||
require_text(&request_text, "private_state_exposed = false")?;
|
||||
|
||||
let summary = json!({
|
||||
|
|
|
|||
|
|
@ -220,7 +220,7 @@ fn run_smoke(args: Args) -> Result<Value> {
|
|||
&request_text,
|
||||
"required_reviewers = [\"Maintainer\", \"Soul\", \"Mind\", \"Bifrost\"]",
|
||||
)?;
|
||||
require_text(&request_text, "readiness_approval_owner = \"none\"")?;
|
||||
require_text(&request_text, "readiness_approval_owner = \"Maintainer\"")?;
|
||||
require_text(
|
||||
&request_text,
|
||||
"requested_effect = \"review-redacted-repo-swarm-mvp-proof-bundle\"",
|
||||
|
|
@ -231,7 +231,7 @@ fn run_smoke(args: Args) -> Result<Value> {
|
|||
)?;
|
||||
require_text(
|
||||
&request_text,
|
||||
"review_is_advisory_until_maintainer_or_bifrost_acceptance = true",
|
||||
"maintainer_readiness_acceptance_required = true",
|
||||
)?;
|
||||
require_text(&request_text, "[antecedents]")?;
|
||||
require_text(&request_text, "repo_init_required = true")?;
|
||||
|
|
@ -337,10 +337,7 @@ fn run_smoke(args: Args) -> Result<Value> {
|
|||
require_text(&request_text, "hands_action_authorized = false")?;
|
||||
require_text(&request_text, "cross_body_mutation_authorized = false")?;
|
||||
require_text(&request_text, "private_verse_rummaging = false")?;
|
||||
require_text(
|
||||
&request_text,
|
||||
"maintainer_soul_mind_or_bifrost_review_required = true",
|
||||
)?;
|
||||
require_text(&request_text, "maintainer_review_required = true")?;
|
||||
require_text(&request_text, "private_state_exposed = false")?;
|
||||
|
||||
let summary = json!({
|
||||
|
|
|
|||
|
|
@ -4443,7 +4443,10 @@ fn derive_repo_pr_request_plan(
|
|||
"service_lifecycle_authority = false".to_string(),
|
||||
"cross_body_mutation_authorized = false".to_string(),
|
||||
"private_verse_rummaging = false".to_string(),
|
||||
"bifrost_or_maintainer_authority_required = true".to_string(),
|
||||
"maintainer_review_required = true".to_string(),
|
||||
"bifrost_publication_gate_required = true".to_string(),
|
||||
"hands_execution_required = true".to_string(),
|
||||
"github_provider_receipt_required = true".to_string(),
|
||||
String::new(),
|
||||
"[verification]".to_string(),
|
||||
"asks = [".to_string(),
|
||||
|
|
@ -4737,7 +4740,8 @@ fn derive_repo_artifact_acceptance_request_plan(
|
|||
"service_lifecycle_authority = false".to_string(),
|
||||
"cross_body_mutation_authorized = false".to_string(),
|
||||
"private_verse_rummaging = false".to_string(),
|
||||
"maintainer_or_bifrost_acceptance_authority_required = true".to_string(),
|
||||
"maintainer_acceptance_authority_required = true".to_string(),
|
||||
"bifrost_accounting_required = true".to_string(),
|
||||
String::new(),
|
||||
"[verification]".to_string(),
|
||||
"asks = [".to_string(),
|
||||
|
|
@ -4981,10 +4985,11 @@ fn derive_repo_readiness_review_request_plan(
|
|||
"status = \"awaiting-mvp-readiness-review\"".to_string(),
|
||||
"routing_owner = \"Self\"".to_string(),
|
||||
"required_reviewers = [\"Maintainer\", \"Soul\", \"Mind\", \"Bifrost\"]".to_string(),
|
||||
"readiness_approval_owner = \"none\"".to_string(),
|
||||
"readiness_approval_owner = \"Maintainer\"".to_string(),
|
||||
"requested_effect = \"review-redacted-repo-swarm-mvp-proof-bundle\"".to_string(),
|
||||
"readiness_scope = \"fresh repo init, online swarm, Persona intake, Imagination planning, Self queue-run, Hands branch work, Soul closure, Modeling map update, Mind admission, Bifrost public proof, upstream-main sync, Idunn lifecycle, global tool directory, and private-state redaction\"".to_string(),
|
||||
"review_is_advisory_until_maintainer_or_bifrost_acceptance = true".to_string(),
|
||||
"maintainer_readiness_acceptance_required = true".to_string(),
|
||||
"bifrost_publication_review_required = true".to_string(),
|
||||
String::new(),
|
||||
"[antecedents]".to_string(),
|
||||
"repo_init_required = true".to_string(),
|
||||
|
|
@ -5047,7 +5052,10 @@ fn derive_repo_readiness_review_request_plan(
|
|||
"hands_action_authorized = false".to_string(),
|
||||
"cross_body_mutation_authorized = false".to_string(),
|
||||
"private_verse_rummaging = false".to_string(),
|
||||
"maintainer_soul_mind_or_bifrost_review_required = true".to_string(),
|
||||
"maintainer_review_required = true".to_string(),
|
||||
"soul_verification_required = true".to_string(),
|
||||
"mind_admission_required = true".to_string(),
|
||||
"bifrost_publication_review_required = true".to_string(),
|
||||
String::new(),
|
||||
"[verification]".to_string(),
|
||||
"asks = [".to_string(),
|
||||
|
|
|
|||
|
|
@ -325,7 +325,8 @@ impl RepoArtifactAcceptanceRequest {
|
|||
&& !a.service_lifecycle_authority
|
||||
&& !a.cross_body_mutation_authorized
|
||||
&& !a.private_verse_rummaging
|
||||
&& a.maintainer_or_bifrost_acceptance_authority_required
|
||||
&& a.maintainer_acceptance_authority_required
|
||||
&& a.bifrost_accounting_required
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -387,7 +388,8 @@ struct RepoArtifactAcceptanceAuthority {
|
|||
service_lifecycle_authority: bool,
|
||||
cross_body_mutation_authorized: bool,
|
||||
private_verse_rummaging: bool,
|
||||
maintainer_or_bifrost_acceptance_authority_required: bool,
|
||||
maintainer_acceptance_authority_required: bool,
|
||||
bifrost_accounting_required: bool,
|
||||
}
|
||||
|
||||
pub(super) fn parse_repo_artifact_acceptance_request(
|
||||
|
|
@ -842,7 +844,10 @@ impl RepoPrRequest {
|
|||
&& !a.service_lifecycle_authority
|
||||
&& !a.cross_body_mutation_authorized
|
||||
&& !a.private_verse_rummaging
|
||||
&& a.bifrost_or_maintainer_authority_required
|
||||
&& a.maintainer_review_required
|
||||
&& a.bifrost_publication_gate_required
|
||||
&& a.hands_execution_required
|
||||
&& a.github_provider_receipt_required
|
||||
}
|
||||
}
|
||||
#[derive(Debug, Deserialize)]
|
||||
|
|
@ -903,7 +908,10 @@ struct RepoPrAuthority {
|
|||
service_lifecycle_authority: bool,
|
||||
cross_body_mutation_authorized: bool,
|
||||
private_verse_rummaging: bool,
|
||||
bifrost_or_maintainer_authority_required: bool,
|
||||
maintainer_review_required: bool,
|
||||
bifrost_publication_gate_required: bool,
|
||||
hands_execution_required: bool,
|
||||
github_provider_receipt_required: bool,
|
||||
}
|
||||
pub(super) fn parse_repo_pr_request(text: &str) -> Result<RepoPrRequest> {
|
||||
toml::from_str(text).context("PR request is not valid typed TOML")
|
||||
|
|
@ -1059,9 +1067,10 @@ impl RepoReadinessReviewRequest {
|
|||
r.status == "awaiting-mvp-readiness-review"
|
||||
&& r.routing_owner == "Self"
|
||||
&& r.required_reviewers == ["Maintainer", "Soul", "Mind", "Bifrost"]
|
||||
&& r.readiness_approval_owner == "none"
|
||||
&& r.readiness_approval_owner == "Maintainer"
|
||||
&& r.requested_effect == "review-redacted-repo-swarm-mvp-proof-bundle"
|
||||
&& r.review_is_advisory_until_maintainer_or_bifrost_acceptance
|
||||
&& r.maintainer_readiness_acceptance_required
|
||||
&& r.bifrost_publication_review_required
|
||||
}
|
||||
|
||||
pub(super) fn has_antecedent_contract(&self) -> bool {
|
||||
|
|
@ -1159,10 +1168,10 @@ impl RepoReadinessReviewRequest {
|
|||
denied
|
||||
.iter()
|
||||
.all(|key| self.authority.get(*key) == Some(&false))
|
||||
&& self
|
||||
.authority
|
||||
.get("maintainer_soul_mind_or_bifrost_review_required")
|
||||
== Some(&true)
|
||||
&& self.authority.get("maintainer_review_required") == Some(&true)
|
||||
&& self.authority.get("soul_verification_required") == Some(&true)
|
||||
&& self.authority.get("mind_admission_required") == Some(&true)
|
||||
&& self.authority.get("bifrost_publication_review_required") == Some(&true)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1173,7 +1182,8 @@ struct RepoReadinessReviewBody {
|
|||
required_reviewers: Vec<String>,
|
||||
readiness_approval_owner: String,
|
||||
requested_effect: String,
|
||||
review_is_advisory_until_maintainer_or_bifrost_acceptance: bool,
|
||||
maintainer_readiness_acceptance_required: bool,
|
||||
bifrost_publication_review_required: bool,
|
||||
}
|
||||
|
||||
#[derive(Debug, Deserialize)]
|
||||
|
|
|
|||
|
|
@ -13,9 +13,10 @@ private_state_exposed = false
|
|||
status = "awaiting-mvp-readiness-review"
|
||||
routing_owner = "Self"
|
||||
required_reviewers = ["Maintainer", "Soul", "Mind", "Bifrost"]
|
||||
readiness_approval_owner = "none"
|
||||
readiness_approval_owner = "Maintainer"
|
||||
requested_effect = "review-redacted-repo-swarm-mvp-proof-bundle"
|
||||
review_is_advisory_until_maintainer_or_bifrost_acceptance = true
|
||||
maintainer_readiness_acceptance_required = true
|
||||
bifrost_publication_review_required = true
|
||||
[antecedents]
|
||||
[required_receipts]
|
||||
[readiness_packet]
|
||||
|
|
@ -193,7 +194,8 @@ hands_action_authorized = false
|
|||
service_lifecycle_authority = false
|
||||
cross_body_mutation_authorized = false
|
||||
private_verse_rummaging = false
|
||||
maintainer_or_bifrost_acceptance_authority_required = true
|
||||
maintainer_acceptance_authority_required = true
|
||||
bifrost_accounting_required = true
|
||||
"#;
|
||||
let request = parse_repo_artifact_acceptance_request(text).expect("fixture is typed TOML");
|
||||
assert!(!request.has_authority_seals());
|
||||
|
|
@ -415,7 +417,10 @@ hands_action_authorized = false
|
|||
service_lifecycle_authority = false
|
||||
cross_body_mutation_authorized = false
|
||||
private_verse_rummaging = false
|
||||
bifrost_or_maintainer_authority_required = true
|
||||
maintainer_review_required = true
|
||||
bifrost_publication_gate_required = true
|
||||
hands_execution_required = true
|
||||
github_provider_receipt_required = true
|
||||
"#;
|
||||
let request = parse_repo_pr_request(text).expect("fixture is typed TOML");
|
||||
assert!(!request.has_authority_seals());
|
||||
|
|
|
|||
Reference in a new issue