Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wikiman: support patchUrls for extensions #428

Open
wants to merge 16 commits into
base: main
Choose a base branch
from

Conversation

deer-wmde
Copy link
Contributor

@deer-wmde deer-wmde commented Feb 23, 2024

Currently the wikiman does not respect patchUrls that we manually add to the pacman.yaml (example). This can be quite dangerous as it is easy to miss re-adding them when using wikiman. I think we can circumvent this if we add them to the wikiman.yaml already.

@deer-wmde deer-wmde marked this pull request as ready for review February 23, 2024 17:28
@tarrow
Copy link
Contributor

tarrow commented Apr 24, 2024

I think I made these comments somewhere in the past but perhaps not in text form. I don't have a strong objection to this patch but I don't feel like it resolves the root issue of forgetting to check the patchUrls when updating references. This now inverts the problem.

We may keep patching accidentally when we shouldn't rather than the previous situation where we would forget to patch.

Maybe what we instead need is a checklist for doing patch (or even smaller) updates. I could imagine something along the following lines:

  • Edit wikiman.yaml and do the following things:
    • check mediawiki version is still set to the version we want to target e.g. 1.39
    • check if mediawikiRepoRef is set to a specific value for a reason that still makes sense
    • if not remove it
  • review the existing pacman.yaml and search for patchUrls
    • open each patch and determine if it has now been merged into the updated version you are targeting
      • If so: remove it
      • If not determine if we should:
        • apply it as is
        • edit it so that is correctly applies to the newly updated code
        • remove it since it's no longer needed
  • run wikiman
  • edit pacman.yaml as per your findings from the last but on step
  • run sync
  • git add and commit

@deer-wmde
Copy link
Contributor Author

This PR is a band-aid for sure and doesn't fix the design problems of the update process. Personally I think reviewing each extension patch, as well as each extension update, is unrealistic and there are no checls in place to enforce this. In contrast, it's incredibly easy for missing patchUrls to slip through code review, which would probably break our mediawiki deployments.

A different approach could be to intermediately manually edit the pacman.yaml in such cases but I expect that just would make everything even more unpredictable.

@deer-wmde
Copy link
Contributor Author

note: should be rebased after #439 gets merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants