Open weiji14 opened 1 week ago
I'm unsure if "uv" is a good solution here, since it installs packages from PyPI only, but GMT is only available on conda-forge. It means we will mix packages from conda-forge and PyPI, which is usually not recommended.
BTW, the "Install package" step has errors but the step still passes.
I'm unsure if "uv" is a good solution here, since it installs packages from PyPI only, but GMT is only available on conda-forge. It means we will mix packages from conda-forge and PyPI, which is usually not recommended.
We have a similar situation in ci_tests_dev.yaml
where we install some packages from conda, compile GMT manually, and install Python dependencies from PyPI. But yeah, definitely not recommended (which is why I'm running this on ci_tests_legacy.yaml
instead of ci_tests.yaml
). This PR is more of a proof of concept right now, and will at least allow us to check what lower bound pins might be needed.
BTW, the "Install package" step has errors but the step still passes.
Yes, I noticed that. Struggling to see if there's an upstream issue on this at https://github.com/astral-sh/uv/issues. Need to find a way to make it return a non-zero exit code.
Description of proposed changes
Test lowest versions of all direct dependencies of PyGMT listed in the pyproject.toml file (both required and optional dependencies).
This implements the idea at https://github.com/GenericMappingTools/pygmt/issues/3615#issuecomment-2472660976 on
.github/workflows/ci_tests_legacy.yaml
(instead ofci_tests.yaml
) by using theuv
package manager's--resolution lowest-direct
strategy (https://docs.astral.sh/uv/concepts/resolution/#resolution-strategy).Related to optional dependency policy at https://github.com/GenericMappingTools/pygmt/issues/3456, and complements #3615 by testing lowest versions of transitive dependencies more thoroughly. The following version pins have been set:
xyzservices
as requirement, https://github.com/GenericMappingTools/pygmt/pull/3639#discussion_r1853062032Testing locally
If it helps, this is how I'm testing locally using
nektos/act
:ci_tests_legacy.yaml
first:os: [ubuntu-20.04, macos-13, windows-2019]
to justos: [ubuntu-20.04]
(or whatever OS you want to test on)act schedule --workflows '.github/workflows/ci_tests_legacy.yaml'
Reminders
make format
andmake check
to make sure the code follows the style guide.doc/api/index.rst
.Slash Commands
You can write slash commands (
/command
) in the first line of a comment to perform specific operations. Supported slash command is:/format
: automatically format and lint the code