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

azure-cli: switch to PyPI source #195315

Closed
wants to merge 1 commit into from

Conversation

branchvincent
Copy link
Member

  • Have you followed the guidelines for contributing?
  • Have you ensured that your commits follow the commit style guide?
  • Have you checked that there aren't other open pull requests for the same formula update/change?
  • Have you built your formula locally with HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>, where <formula> is the name of the formula you're submitting?
  • Is your test running fine brew test <formula>, where <formula> is the name of the formula you're submitting?
  • Does your build pass brew audit --strict <formula> (after doing HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>)? If this is a new formula, does it pass brew audit --new <formula>?

The current GitHub tarball doesn't have a pyproject.toml or setup.py at its root, which means it doesn't work with our brew update-python-resources and upstream has to rely on generating accurate resource blocks themselves.

Instead, this switches to the published sdist on PyPI, which we generally prefer anyway.

@branchvincent branchvincent added the maintainer feedback Additional maintainers' opinions may be needed label Oct 23, 2024
@github-actions github-actions bot added python Python use is a significant feature of the PR or issue rust Rust use is a significant feature of the PR or issue labels Oct 23, 2024
@branchvincent branchvincent mentioned this pull request Oct 23, 2024
6 tasks
@branchvincent
Copy link
Member Author

cc @bebound from the azure side

@bebound
Copy link
Contributor

bebound commented Oct 23, 2024

Thank you. brew update-python-resources looks easier than homebrew-pypi-poet.

Here are some concerns about this new methods:

  1. How to deal with pip and setuptools? Can --extra-packages address this?
  2. How can we generate and test the formula before it's released to pypi?
  3. It seems that the whole resources are generated from setup.py. The version is slightly newer than https://github.com/Azure/azure-cli/blob/dev/src/azure-cli/requirements.py3.Darwin.txt. Generally, it should work. However, issues due to dependency upgrades occur every now and then.

cc @jiasli

@p-linnane
Copy link
Member

  1. How to deal with pip and setuptools? Can --extra-packages address this?

We can add pip and setuptools as extra packages in pypi_formula_mappings.json.

@p-linnane
Copy link
Member

One issue with this method is that pymsalruntime does not have an sdist on PyPI or a repository. It'd be great if that was published because it would make the formula dramatically easier to maintain.

@cho-m
Copy link
Member

cho-m commented Nov 1, 2024

One issue with this method is that pymsalruntime does not have an sdist on PyPI or a repository.

Although this will cause update-python-resources to fail on macOS, if run on Linux (which I think is the case for both upstream release CI and Homebrew autobump CI), then it will pass as pymsalruntime is not used there.

Some packages are OS-specific so may want to add those as extra resources, e.g. distro on Linux, since we cannot guarantee a user-opened PR was run on Linux.

@p-linnane
Copy link
Member

There are a couple other packages that are OS-specific so may want to add those as extra resources, e.g. distro on Linux.

I had a complete formula rewrite done locally with those changes, but the test kept failing with missing modules so I abandoned it.

Copy link
Contributor

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@github-actions github-actions bot added the stale No recent activity label Nov 23, 2024
@github-actions github-actions bot closed this Nov 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintainer feedback Additional maintainers' opinions may be needed python Python use is a significant feature of the PR or issue rust Rust use is a significant feature of the PR or issue stale No recent activity switch-to-pypi-source
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants