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

Remove bump-homebrew-formula configuration #3812

Merged
merged 2 commits into from Oct 5, 2023
Merged

Conversation

mislav
Copy link
Contributor

@mislav mislav commented Oct 4, 2023

Moving the conversation from Homebrew/homebrew-core#149334 (comment) /cc @ssbarnea

This updates the download-url input to the bump-homebrew-formula-action to be a URL in the format of https://pypi.org/packages/source/a/ansible-lint/ansible-lint-<VERSION>.tar.gz.

That resource ultimately resolves to https://files.pythonhosted.org/packages/*/*/*/ansible-lint-<VERSION>.tar.gz, which is the URL format currently present in the homebrew-core formula. I find the latter form unwieldy, and I think that the pypi.org-hosted resource looks much nicer and should be the same trustworthiness. I'm not familiar with python-hosted anything, so you should decide which canonical form works best for you (and for the homebrew-core team).

Followup to #2982
Ref. https://docs.github.com/en/webhooks/webhook-events-and-payloads?actionType=published#release
Ref. https://github.com/marketplace/actions/bump-homebrew-formula#action-inputs
Ref. Homebrew/homebrew-core#128963 (comment)

Moving the conversation from Homebrew/homebrew-core#149334 (comment)

This updates the `download-url` input to the `bump-homebrew-formula-action` to be a URL in the format of `https://pypi.org/packages/source/a/ansible-lint/ansible-lint-<VERSION>.tar.gz`.

That resource ultimately resolves to `https://files.pythonhosted.org/packages/*/*/*/ansible-lint-<VERSION>.tar.gz`, which is the URL format currently present in the homebrew-core formula. I find the latter form unwieldy, and I think that the `pypi.org`-hosted resource looks much nicer and should be the same trustworthiness.
@mislav mislav requested review from a team as code owners October 4, 2023 14:45
@mislav mislav temporarily deployed to ack October 4, 2023 14:46 — with GitHub Actions Inactive
.github/workflows/release.yml Outdated Show resolved Hide resolved
.github/workflows/release.yml Show resolved Hide resolved
.github/workflows/release.yml Outdated Show resolved Hide resolved
@mislav
Copy link
Contributor Author

mislav commented Oct 4, 2023

Hmm, I am now learning more about python-based formula in Homebrew-core and it seems like each formula lists its python dependencies as "resources", e.g.

  resource "ansible-compat" do
    url "https://files.pythonhosted.org/packages/36/f9/42b44473cedbf977f8fe41e2b72ea47216f708c59bafc41ad6aa93c09a71/ansible-compat-4.1.10.tar.gz"
    sha256 "2be8c7b510d2e15eed1e9ef443209d67d9aec8f427026b88936d4535ff59863d"
  end

My bump-homebrew-formula action does not have the feature to update these resources. The built-in Homebrew command brew bump does have this feature, which is supported by this non-trivial code: https://github.com/Homebrew/brew/blob/75b18b5afe70ef523b1d78bfcb1e8ee27fe04ef8/Library/Homebrew/utils/pypi.rb#L205.

A better course of action would be to remove the bump-homebrew-formula action from this repository entirely.

The bump-homebrew-formula action is non-viable for this project because it is not able to update the individual `resource` blocks of the Homebrew formula for each python dependency.
@mislav mislav temporarily deployed to ack October 4, 2023 15:22 — with GitHub Actions Inactive
@ssbarnea ssbarnea changed the title Update bump-homebrew-formula configuration Remove bump-homebrew-formula configuration Oct 5, 2023
@ssbarnea
Copy link
Member

ssbarnea commented Oct 5, 2023

@mislav Thanks, I really appreciate your help here.

@ssbarnea ssbarnea added the skip-changelog Can be missed from the changelog. label Oct 5, 2023
@ssbarnea ssbarnea temporarily deployed to ack October 5, 2023 14:28 — with GitHub Actions Inactive
@ssbarnea ssbarnea merged commit 0bcd9f0 into ansible:main Oct 5, 2023
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip-changelog Can be missed from the changelog.
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants