hello-stephen opened a new pull request, #70731:
URL: https://github.com/apache/doris/pull/70731

   ### What problem does this PR solve?
   
   Legacy `protected_branches` synchronization repeatedly fails while updating 
GitHub, leaving obsolete required TeamCity checks active even after `.asf.yaml` 
changes. Replace it with eight named branch CI/review rulesets and one shared 
branch safety ruleset, and explicitly clear legacy protections.
   
   - Preserve all 103 configured check contexts, `strict=false`, one approval, 
stale-review dismissal, and branch-specific Code Owner requirements.
   - Keep the classic default repository-admin bypass on CI/reviews only. The 
shared force-push and deletion rules have no bypass.
   - Omit the optional `integration_id` to accept checks from any source and 
avoid raw-payload integer coercion issues.
   - Leave repository metadata, merge buttons, collaborators and notifications 
unchanged.
   
   ### Release note
   
   None
   
   ### Check List (For Author)
   
   - Test: YAML parsing, upstream ruleset normalization with string-valued raw 
input, exact comparison of eight branches and 103 contexts against upstream 
blob `b38cddd733980410dc9ce1503846e91a37491cbd`, patch application check, and 
`git diff --check` passed.
   - Behavior changed: Yes, migrate repository protection to GitHub rulesets.
   - Does this need documentation: No.
   
   Full ASF CLI/schema validation and GitHub server-side reconciliation have 
not been run. Existing live administrator/custom-role exceptions must be 
confirmed before merge.
   
   ### Rollout and verification
   
   Coordinate the merge with Infra: the current public implementation removes 
legacy protection before creating rulesets, so this is not an atomic transition.
   
   1. Verify all nine rulesets are active at 
https://github.com/apache/doris/rules and cover the intended eight branches.
   2. Read effective rules for every branch, including `gh api --paginate 
repos/apache/doris/rules/branches/branch-4.2`. Compare required checks, review 
settings, strictness and bypass actors with the proposed YAML. Confirm the 
shared safety rules have no bypass.
   3. Separately confirm classic branch protection is removed. The effective 
rulesets endpoint alone does not prove old protections are gone. Permission 
failures or an ambiguous 404 are not proof of removal.
   4. Inspect an unmerged PR targeting `branch-4.2`: new TeamCity contexts must 
be required, obsolete contexts must stop gating, and missing/failed required 
checks must block a non-bypass actor from merging. A green or merged PR alone 
is insufficient evidence.
   5. Check ASF synchronization notifications. If reconciliation partially 
fails, ask Infra to restore protection immediately; reverting YAML alone does 
not immediately restore live settings.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to