stlehmann / pyads

Python wrapper for TwinCAT ADS
MIT License
265 stars 96 forks source link

Updated setuptools with `adslib` in wheel distribution and `pyproject.toml` #426

Open RobertoRoos opened 2 months ago

RobertoRoos commented 2 months ago

I think this is pretty close to what I had in mind. This would resolved #425 .
I based this on top of a developing brach I had to switch over to pyproject.toml, so the diff is quite big.

Check the pipelines running on my fork to see what the distributions would look like.

And this PR will likely conflict with #412 and maybe with #399 .

coveralls commented 2 months ago

Pull Request Test Coverage Report for Build 11027487472

Details


Totals Coverage Status
Change from base Build 10633721828: -1.1%
Covered Lines: 6918
Relevant Lines: 7374

💛 - Coveralls
RobertoRoos commented 2 months ago

Hm, I just realized a pretty bug limitation: when installing in editable mode (pip install -e .) adslib isn't compiled and so the package is not usable. That needs to be fixed.

EDIT: Okay, solved. By moving the compiled adslib.so into src/ it will be available under the PATH even in editable mode.

See a test of the distribution wheels in: https://github.com/RobertoRoos/pyads/actions/runs/11010369726

RobertoRoos commented 2 months ago

Okay, I think I'm happy with this now. Though we should want to change the CI some, currently it's more to show the distribution works, but this is not needed for every build in the future.

chrisbeardy commented 2 months ago

Thanks @RobertoRoos , the idea of moving towards pyproject toml is very good and something that felt daunting to do so I'm glad someone managed it!. I will review these changes when I get back from vacation