Skip to content

ci(sync-develop): push main into develop directly (#3102) - #3103

Merged
JarryShaw merged 1 commit into
mainfrom
ci/3102-sync-develop-direct-push
Nov 26, 2026
Merged

JarryShaw merged 1 commit into
mainfrom
ci/3102-sync-develop-direct-push

Conversation

@JarryShaw

Copy link
Copy Markdown
Owner

Please follow the guide below

  • Put an x into every box [ ] that applies to your pull request (like this: [x])

  • Use the Preview tab to see how your pull request will look

  • Searched for similar pull requests

  • Followed the coding style (make pylint, make mypy, make isort)

  • make test passes, and a test case covers the change

  • Described the user-visible change below and left its changelog entry to the maintainer, keeping docs/source/changelog/ and CHANGELOG.md out of the diff, if the change is user-visible: N/A — centralised

What is the purpose of your pull request?

Tick the commit type your subject line carries.

  • fix — corrects a defect

  • feat — adds a feature

  • perf — changes performance, not behaviour

  • refactor — changes neither behaviour nor performance

  • test — tests only

  • docs — documentation only

  • ci — workflows or build tooling

  • release — bumps the version or rolls up a distribution

  • chore — anything else

  • Also tick if it regenerates constant or registry tables, members keeping their numeric values (the const label)


Description of your pull request and other information

Closes #3102. Sync Develop merges main into develop and pushes it itself; only a conflict opens a pull request (options 1A and 2A).

  • sync-develop.yml: new merge job in conda-tag with contents: read. Its steps are "Load maintenance deploy key" (Create Release's pin), main's script, "Check out develop", "Configure git for the deploy key" and "Merge main into develop and push it". pr now needs merge and runs only on conflict == 'true'. "Say why no pull request opens" moves into merge.
  • util/sync_develop.py --merge: git merge --no-ff titled chore: merge main into develop, pushed over ssh. A push refused while develop moved is merged afresh and retried once; any other refusal fails the job. A conflict is aborted and handed to pr. The step summary names the path taken.
  • Docs: workflows.rst (Sync Develop, Deployment environment:), releasing.rst (Release Lines), maintenance.rst (Rebases).
  • Pins: test_sync_develop_2942 gains TestTheMerge (scratch repos: clean push, level, conflict, retry, conflict on retry, two refusals, a refusal while develop stayed put, failed fetch) and pins for the jobs, the key and the guards. test_secret_environments_1968 lists merge. 13 mutations, each fails its pin.

Measured, not changed: PYPCAPKIT_ACTIONS_DEPLOY_KEY, PYPCAPKIT and ANACONDA_TOKEN are repository secrets, and conda-tag holds none, though workflows.rst and test_secret_environments_1968 say it does. merge names conda-tag like every other deploy-key job, so it works either way.

Merge only after the 1.8.0 release freeze ends: Create Release is running on main now.

Tests: tests/project on 3.14, 2480 passed, 88 skipped (-n 4). actionlint 1.7.12 finds nothing.

@JarryShaw JarryShaw added ci Pull requests that change CI or workflow configuration (ci: subject prefix) review: running A cross-review is in flight against the current head - no verdict yet labels Nov 26, 2026
@JarryShaw JarryShaw moved this to In review in PyPCAPKit Nov 26, 2026
@JarryShaw

Copy link
Copy Markdown
Owner Author

NEEDS CHANGES at c82b59f30 (Sonnet cross-review). One gap; the push path, script and job wiring all check out.

  • Pin --no-ff. Swapping it for --ff passes all 34 tests, because the clean-merge test only covers branches that have diverged. Add a case where develop is an ancestor of main and assert a two-parent merge commit. That merge commit is what the docs promise.
  • Verified: ruleset 28079111 bypasses DeployKey (always), and the release App is not a bypass actor. The deploy-key steps match create-release.yml, at the same pin. conda-tag has no approval gate. Every path in --merge raises or cleans up, and 12 mutations each fail their pin.
  • Nit: the header comment grew from 11 to 12 lines; trim it back.
  • Not this PR: on main, workflows.rst and test_secret_environments_1968 already say the deploy key and the PyPI and Anaconda tokens live in environments, but all three are repository secrets. Filing that separately.

@JarryShaw JarryShaw added review: needs-changes Cross-review at the current head says changes are required; see the verdict comment and removed review: running A cross-review is in flight against the current head - no verdict yet labels Nov 26, 2026
Sync Develop opened a pull request from sync/main for every push to main,
each one merged by hand. The owner ruled that main -> develop needs none.

* sync-develop.yml gains a merge job in conda-tag: it loads the maintenance
  deploy key, checks develop out beside main's script, and runs
  util/sync_develop.py --merge. The deploy key bypasses develop's ruleset
  28079111; the release App does not.
* --merge merges main into develop with a merge commit titled as the pull
  request was and pushes it. A push refused while develop moved is merged
  afresh and retried once; any other refusal fails the job.
* A merge that conflicts is aborted and sets conflict=true, and only then
  does pr mirror sync/main and open or update the pull request. The step
  summary names the path taken.
* workflows.rst, releasing.rst and maintenance.rst describe the direct push.
* tests/project runs --merge against scratch repositories and pins the
  jobs, the deploy key and the guards; each fails with its behaviour removed.
@JarryShaw
JarryShaw force-pushed the ci/3102-sync-develop-direct-push branch from c82b59f to 7e13055 Compare November 26, 2026 22:11
@JarryShaw

Copy link
Copy Markdown
Owner Author

GOOD TO GO at 7e13055a5. I checked the round-2 change myself.

@JarryShaw JarryShaw added review: good-to-go Cross-review at the current head says ready; CI state is separate and removed review: needs-changes Cross-review at the current head says changes are required; see the verdict comment labels Nov 26, 2026
@read-the-docs-community

Copy link
Copy Markdown

Documentation build overview

📚 PyPCAPKit | 🛠️ Build #36198666 | 📁 Comparing 7e13055 against latest (81c096e)

  🔍 Preview build  

6 files changed · ± 6 modified

± Modified

@JarryShaw JarryShaw mentioned this pull request Nov 26, 2026
1 of 14 tasks
@github-actions

Copy link
Copy Markdown
Contributor

Coverage: 94.73% (unit tier, Python 3.15, 7e13055a5, Unit Tests run success)

Package Statements Missed Branches Partial Cover
pcapkit (top level) 108 4 20 2 95.31%
pcapkit/const 21668 212 3074 185 98.31%
pcapkit/corekit 3059 83 1004 40 96.73%
pcapkit/dumpkit 423 3 148 5 98.60%
pcapkit/foundation 3755 24 1208 26 98.99%
pcapkit/interface 103 4 34 3 94.89%
pcapkit/protocols 25524 158 6704 128 99.10%
pcapkit/toolkit 963 26 344 8 96.63%
pcapkit/utilities 591 7 162 5 98.41%
pcapkit/vendor 6088 2293 1390 240 59.07%

Per-file detail: the coverage-html artifact of this run.

@JarryShaw

Copy link
Copy Markdown
Owner Author

Ready to merge at 7e13055a5 once the 1.8.0 release finishes. Required checks pass and no KTLO or experimental leg warns; GraalPy, the experimental leg, is still running. Hold it until Create Release's github job is waiting on your approval, because a main push mid-chain makes vendor-update skip.

@JarryShaw JarryShaw added this to the PyPCAPKit v1.8 milestone Nov 26, 2026
@JarryShaw JarryShaw mentioned this pull request Nov 26, 2026
@JarryShaw
JarryShaw merged commit 3719f84 into main Nov 26, 2026
73 checks passed
@github-project-automation github-project-automation Bot moved this from In review to Done in PyPCAPKit Nov 26, 2026
@JarryShaw
JarryShaw deleted the ci/3102-sync-develop-direct-push branch November 26, 2026 23:27
@JarryShaw JarryShaw removed the review: good-to-go Cross-review at the current head says ready; CI state is separate label Nov 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Pull requests that change CI or workflow configuration (ci: subject prefix)

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

ci(sync-develop): push main into develop directly instead of opening a pull request

1 participant