psf / psf/black

Request: new releases triggering `black-pre-commit-mirror`'s `mirror` action

Open
#3,972 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

C: maintenance T: enhancement
Dominant language
Python
Stars
41.8k
Forks
2.9k
Avg merge
5d 6h
Merged PRs (30d)
9

Description

Is your feature request related to a problem? Please describe.

Looks like https://github.com/psf/black-pre-commit-mirror/blob/91867dbada8a528dcc51a369d95a9d11a81a26a8/.github/workflows/mirror.yml#L7 runs at 5:43 am UTC. An aside, is it's too bad seconds aren't supported by cron otherwise we could have 5:43:21 😆

black==23.10.1 was just released an hour ago, but it won't propagate to black-pre-commit-mirror for about 9 hrs. I am wondering, is it possible to tighten up this timing?

Describe the solution you'd like

Having black's release pipeline trigger the mirror job in black-pre-commit-mirror. I think this is possible with GitHub actions.

It would also save GitHub CI resources 🌲 from avoiding unnecessary daily cron jobs in https://github.com/psf/black-pre-commit-mirror.

Describe alternatives you've considered

N/a

Additional context

N/a

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading .github/workflows/mirror.yml in black-pre-commit-mirror, especially the cron entry at line 7, and inspect how Black's release pipeline could trigger it. Confirm the GitHub Actions cross-repository trigger mechanism and ensure new Black releases update the mirror without the daily cron job; done means the mirror is triggered by releases and the scheduled polling is no longer needed.

Written by the indexing model from the issue text.

Assessment

Tech stack
github-actions, python
Domain
ci-cd, release
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.