Skip to content

Installable Python package with pyproject.toml#17

Open
uellue wants to merge 4 commits intoBritishGeologicalSurvey:mainfrom
uellue:pyproject
Open

Installable Python package with pyproject.toml#17
uellue wants to merge 4 commits intoBritishGeologicalSurvey:mainfrom
uellue:pyproject

Conversation

@uellue
Copy link

@uellue uellue commented Mar 4, 2026

Via openjournals/joss-reviews#10132 (comment) "installation":

From what I can see, tactool only depends on pyqt5 and numpy. That makes it trivial to set it up as a Python package with a pyproject.toml. All the version pins in the environment files are really not necessary and just make it hard to set up. Anaconda is not available in my organization, meaning I simply can't install these package versions.

Declaring a script in pyproject.toml makes it super simple to run tactool from the command line.

It seems to run just fine on Python 3.14 with current numpy and pyqt5, i.e. no apparent need to pin anything.

Still TODO

Feel free to push into this PR!

  • Keywords and authors in pyproject.toml.

Possible next steps:

  • Review release mechanism to build wheel and add to release assets
  • Publish on PyPI
  • Publish on conda-forge

From what I can see, tactool really only depends on pyqt5 and numpy.
That makes it trivial to set it up as a Python package with a `pyproject.toml`. All the version pins in
the environment files are really not necessary and just make it hard to set up.

Declaring a script in pyproject.toml makes it super simple to run tactool from the command line.

FIXME: Keywords and authors in pyproject.toml.

Possible next steps:

* Review release mechanism to build wheel and add to release assets
* Publish on PyPI
* Publish on conda-forge
@uellue
Copy link
Author

uellue commented Mar 4, 2026

Btw, also runs just fine on Linux -- as to be expected with these simple dependencies!

@leorudczenko
Copy link
Contributor

Hi @uellue, thanks for providing the pyproject.toml to make the dependency installation simpler! This new process works great, I've just pushed some changes to make the existing GitHub Actions workflow install the dependencies from the pyproject.toml.

I have already tested that they work on another branch here: https://github.com/BritishGeologicalSurvey/tactool/tree/pyproject-pipeline-test

I changed the workflow on that branch to push the compiled programs as artifacts instead of release assets. I can confirm that they work for both Windows and MacOS. The artifacts for this run can be found here: https://github.com/BritishGeologicalSurvey/tactool/actions/runs/22901246068/

I still need to review the metadata in the pyproject.toml and update any missing/temporary values.

Thanks for the suggestion for publishing on PyPI and conda-forge, but I don't believe it would be necessary for TACtool. As this is intended to be a standalone and compiled front-end application for end-users, I don't see the value in being able to install it with pip or conda.

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