-
-
Notifications
You must be signed in to change notification settings - Fork 546
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
Migrate to scikit-build-core
#4352
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #4352 +/- ##
===========================================
- Coverage 99.42% 95.48% -3.94%
===========================================
Files 299 299
Lines 22691 22715 +24
===========================================
- Hits 22560 21690 -870
- Misses 131 1025 +894 ☔ View full report in Codecov by Sentry. |
2b7db91
to
69309ef
Compare
9a88c5f
to
69309ef
Compare
With this commit, editable + partial rebuilds are available through |
a8f773f
to
e046696
Compare
Updates till now:
|
Problem with Benchmarks:
Because of this, CMake isn't finding the libs and is failing to build them. |
b25357f
to
2f8e252
Compare
…KLU_Sundials.py` script
…stom installation dir
Now that we are done with the v24.9 release, let's plan to merge this in the coming week. |
I've been trying to get to this PR but it has taken me some time to do so. @kratman is attempting the unvendoring of the solver in pybamm-team/pybammsolvers#4, it might be good to migrate this PR there once that is done, @cringeyburger? It would make things a bit easier that were difficult to do here, especially with the troubles that were noticed with the benchmarks and the WSL-specific Dockerfile errors. |
Yes, it would be great if we unvendor the solver and then work on migration. I just wanted to point out that the benchmarks and dockerfile are fixed, along with everything else, atleast before I started the streak of merging commits from main. |
Thanks! Yes, sorry, I, too, meant that the migration would be cleaner with it, not that they were not working right now. Let's wait until that gets merged and we can alter your final report if you'd like to. Do you know why the |
I tried fixing things, here is what I found:
EDIT: The second change is recent one, and it used to work fine before.. |
Thanks for taking a look – I think we should pin As for the macOS wheel builds, I got to notice them in live-action mode just now and I think there is an endless loop somewhere, since the before-all step kicks off another before-all step, and the next one, and the next, and so on until we run out of memory designated by the GHA runner. It's unlikely this is a bug on |
It's because of this line: |
@cringeyburger I think due to the separation of IDAKLU in #4487, we should probably move this work to https://github.com/pybamm-team/pybammsolvers This will make the changes much simpler and easier to manage |
Changes migrated to pybammsolvers, closing for now |
Description
This PR is about migrating to a new build system,
scikit-build-core
fromsetuptools
andwheel
, while incorporating necessary changes in GitHub Workflows, Benchmarks and Documentation.CHANGES IN DISCUSSION:
nox -s pybamm-requires
orinstall_KLU_Sundials.py
script. Adding this feature would change a lot of thingsCHANGES REQUESTED:
.gitignore
sundials_KLU_libs
in.gitignore
CHANGES IN PROGRESS:
COMPLETED, need reviews:
scikit-build-core
in the direction to remove editable-rebuilds, or at least give a warning to the users before using it.pip update
commands fromnox.
set CMAKE_GENERATOR="Visual Studio 17 2022"
andset CMAKE_GENERATOR_PLATFORM=x64
and let CMake set it by itself.CMakeLists.txt
. Use "if set, use that otherwise use default" logic forVCPKG_ROOT
(renameVCPKG_ROOT_DIR
toVCPKG_ROOT
) --- Can not fix using CMake variables, have to set environment variables, hence wrote a batch script to set the env vars permanently for the Windows user. The CI still use pre-defined env vars because this avoids issues related to interactive scripts.find BLAS
script(pybamm.parameter_sets)
can be resolved using an example instead of explicitly setting all the names. --- need to set all namesscikit-build-core
but will keep it as an option in the docs. I will write a warning saying that it is experimental.python/python3
instead ofpython3.X
in TOML kit installation in the guide.# in the PyBaMM/ directory
Install from source
doc.pytest
documentation from Contributors guide in Develop branch..gitignore
*.egg-info
pattern in.gitignore
graphviz
from docs and tests --- had to pin on tests because ofpermission
errors, though it would work fine locally.