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

MNT: switch to pyproject.toml, PEP-518 build system and improve CI #498

Merged
merged 13 commits into from
Dec 31, 2023

Conversation

theOehrly
Copy link
Owner

@theOehrly theOehrly commented Dec 28, 2023

This pull request

  • fully removes setup.py and setup.cfg in favour of the new pyproject.toml configuration file
  • migrates to the new Python packaging system according to PEP-518 (using the hatchling build backend)
  • introduces automatic semantic versioning from vcs using setuptools_scm
  • changes how FastF1 internally gets its current version
  • adds a minimum versions CI test
  • migrates from flake8 to ruff for linting

TBD:

  • Upgrade contributor docs to reflect changes
  • clean up changes to workflows once the changes to the packaging system are final

@theOehrly
Copy link
Owner Author

@daylinmorgan if I remember correctly, the conda-forge package relies on the source distribution. Can you verify that the changes here don't cause any issues? I have uploaded a developement release to the PyPI test index (https://test.pypi.org/project/fastf1/3.2.0.dev35/) using the new automated release process. Can you use that for testing? Else, what do you need?

@pbulsink @SCasanova I don't know how the R wrapper interacts with FastF1. Is there any potential for issues here? There are no API changes. How FastF1 internally provides the fastf1.__version__ property has changed, but that should not have external consequences.

In case anyone wants to install the development release, use the following commands to install using pip:

pip install --upgrade fastf1  # ensures up to date dependencies from the main index
pip install -i https://test.pypi.org/simple/ fastf1==3.2.0.dev35 --no-deps

Alternatively, you can download the wheel build or a source distribution from the PyPI test index (see link above).

@pbulsink
Copy link

We do have a version check that I think uses fastf1.__version__, I'll have a look and report back (hopefully <48h). It should be an easy change to use any other syntax as a backup if __version__ doesn't work.

@theOehrly
Copy link
Owner Author

We do have a version check that I think uses fastf1.__version__, I'll have a look and report back (hopefully <48h). It should be an easy change to use any other syntax as a backup if __version__ doesn't work.

If it doesn't work, that would likely be an issue on my side. But please have a look at it so we could figure out any issues already.

@daylinmorgan
Copy link
Contributor

Great work! These changes should have no effect on the conda-forge packaging.

@pbulsink
Copy link

No change in how things worked for f1dataR on dev:

> get_fastf1_version()
$major
[1] 3

$minor
[1] 2

@theOehrly
Copy link
Owner Author

Great, thank you both for checking!

@theOehrly theOehrly merged commit 92aa85f into master Dec 31, 2023
18 checks passed
@theOehrly theOehrly deleted the mnt-buildsystem branch January 1, 2024 18:16
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.

3 participants