ROOT: new versions with associated dependency constraints#34185
ROOT: new versions with associated dependency constraints#34185sethrj merged 12 commits intospack:developfrom HadrienG2:root-updates
Conversation
|
As commented here (simultaneously to this PR), doesn't it make more sense to have this modeled as closed-ended dependencies rather than open-ended dependencies with conflicts? That would avoid 'automatically' allowing for example new major python versions when they come out even for older ROOT versions. It would 'pin' the dependencies to a known major version until a certain ROOT version that has consciously added support for it. |
|
I'm not sure about full close-ended dependencies because it introduces significant extra maintenance effort where most dependency updates are actually harmless. But I pushed a version that avoids conflicts where possible in favor of version dependency constraints (as far as I know, it's not currently possible to avoid conflicts for OS and compiler constraints). |
|
...and using https://stackoverflow.com/questions/1777344/how-to-detect-mac-os-version-using-python as a template, I added a conflict for macOS 13+ on older ROOT, though again I cannot test it due to lack of suitable hardware. |
|
Spack already knows the macOS version, it's probably easier to just call Also, I'm currently trying to get macOS builds to work for key4hep, I can do some testing on our build machines. |
|
That looks interesting, but in typical Python API documentation fashion, the docs claim that this function returns a "version object" without clarifying how such an object is actually constructed or used... |
|
...oh, well, let's just copy-paste an incantation from another package that uses that API and hope that it's correct 🤷 |
|
Tested that this builds correctly on my system for 6.26.10, with the following variants: ( |
|
Then let's undraft this. |
|
Looks like some pod-related issues with one of the pipeline stacks: @spackbot run pipeline |
|
I've started that pipeline for you! |
|
Same stack failed again (see https://gitlab.spack.io/spack/spack/-/jobs/4803378). |
|
|
||
| # Python | ||
| depends_on("[email protected]:", when="+python", type=("build", "run")) | ||
| depends_on("[email protected]:3.10", when="@:6.26.09 +python", type=("build", "run")) |
There was a problem hiding this comment.
Should this be a conflict indicating an issue with newer pythons on older ROOT? I'm not sure it makes a difference to the concretizer these days, but semantically it might be more appropriate.
There was a problem hiding this comment.
Historically, one difference between this syntax and conflicts has been that in the conflict case, the spack concretizer would not try older dependency versions and just give up stating that there is a conflict. If you are telling me that this is not an issue anymore with newer spack versions, I can turn those back into conflicts.
There was a problem hiding this comment.
The new concretizer is not "greedy" like the old one, so I think it should work. The real expert is @alalazo who could perhaps share some insight into best practices here?
There was a problem hiding this comment.
In general it's better to add "positive" directives like done here. Conflicts add penalties to our minimization and they might trigger more easily weird situations where, to avoid the penalty, Spack turns off some other default.
sethrj
left a comment
There was a problem hiding this comment.
I successfully installed 6.26.10 on macOS 13.
|
There's a conflict to be solved here |
|
The conflict was my bad (#34244) so I've fixed it. |
|
@tldahlgren would you mind checking the box for a second reviewer? Since I added a commit it won't accept my review to qualify for merge. |
|
@spackbot run ci |
|
@spackbot run pipeline |
|
I've started that pipeline for you! |
* Add new root versions and associated dependency constraints * Please style guide * Avoid conflicts where possible * Untested prototype of macOS version detection * Fixes for macOS version prototype * More logical ordering * More correctness and style fixes * Try to use spack's macos_version * Add some forgotten @s * Actually, Spack can't build Python 3.6 anymore, and thus no older PyROOT Co-authored-by: Seth R. Johnson <[email protected]>
@wdconinc Here's my take on the dependency constraints, so that the info on your closed PR don't get lost :)
I couldn't spell out the macOS conflict because I don't have access to a Mac so I can't check how macOS fills uname information.
Feel free to test/approve this once you have the time.