pytest-dev / pytest

The pytest framework makes it easy to write small tests, yet scales to support complex functional testing
https://pytest.org
MIT License
11.94k stars 2.66k forks source link

💅 Add a config for the Patchback GitHub App #12475

Closed webknjaz closed 3 months ago

webknjaz commented 3 months ago

This patch prepares the project's backporting process to start being handled by the Patchback GitHub App [1].

Ref #9384 Resolves #9385 Resolves #9553 Resolves #9554 Resolves #9555

nicoddemus commented 3 months ago

Thanks @webknjaz, do we have any documentation on how the patchback works?

I assume we just apply the "backport" label at any moment in the PR lifetime, and once it gets merged, it will open a PR backporting the merged change to the correct branch?

nicoddemus commented 3 months ago

Should we also remove https://github.com/pytest-dev/pytest/blob/main/.github/workflows/backport.yml?

webknjaz commented 3 months ago

Should we also remove main/.github/workflows/backport.yml?

Not yet. Ronny and I agreed to keep it for a while.

webknjaz commented 3 months ago

@nicoddemus

do we have any documentation on how the patchback works?

Not really, but the source code is pretty clear, I think. I posted about how it works in https://github.com/pytest-dev/pytest/issues/9554#issuecomment-1284651068 and never got to writing anything more on the topic. https://github.com/sanitizers/patchback-github-app — there's some feature requests in the issues that I never got to but I think would be useful too.

I assume we just apply the "backport" label at any moment in the PR lifetime, and once it gets merged, it will open a PR backporting the merged change to the correct branch?

Yep, that's it. It should be a drop-in replacement with no change in how it's used (except for having a few more features than the current workflow).

webknjaz commented 3 months ago

For this, install https://github.com/apps/patchback/installations/new/permissions?target_id=8897583&target_type=Organization. You should't need to wait until the PR is merged.

patchback[bot] commented 3 months ago

Backport to 8.2.x: 💚 backport PR created

✅ Backport PR branch: patchback/backports/8.2.x/d7b401063874141fcbcda78eaec3c28148e7dcd8/pr-12475

Backported as https://github.com/pytest-dev/pytest/pull/12480

🤖 @patchback I'm built with octomachinery and my source is open — https://github.com/sanitizers/patchback-github-app.

bluetech commented 3 months ago

Thanks for fixing this, the old setup was quite annoying :)

webknjaz commented 3 months ago

No problem! I would've done this earlier if it was greenlighted..