Closed MilesCranmer closed 1 year ago
Hi! This is the friendly automated conda-forge-linting service.
I just wanted to let you know that I linted all conda-recipes in your PR (recipe
) and found it was in an excellent condition.
Wait with merging this. I found another big issue here.
Wait with merging this. I found another big issue here.
Please remove the two lines mentioned in #86
@conda-forge-admin, please rerender
Are these warnings anything to worry about?
ClobberWarning: This transaction has incompatible packages due to a shared path.
packages: conda-forge/linux-64::numpy-1.24.3-py310ha4c1d20_0, local/linux-64::pysr-0.14.1-py310hfdc917e_1
path: 'lib/python3.10/site-packages/numpy/core/tests/test_dlpack.py'
Apart from that, things seem to be working. Are you happy with this being merged once tests pass?
Are these warnings anything to worry about?
Yeah, this is not a good thing and needs to be fixed. It looks like your installation process is reinstalling numpy, including some of the test sources, and this gets picked up by conda's before/after-snapshotting of the host environment. The answer should be simple: don't reinstall numpy, use the one that's installed in host already.
It's likely this: https://github.com/conda-forge/pysr-feedstock/pull/85/commits/8fac64f0b804e97b77180e6534fd49d5217f47f0 (just pushed)
But, if not, there is a small chance it is from the PyCall.jl build process, which tries to install numpy if not already available: https://github.com/JuliaPy/PyCall.jl/blob/bcaba00d1e2c412b2f61d33343ef5a9ab1b9258a/deps/build.jl#L79.
Numpy is still being spuriously installed.
But, if not, there is a small chance it is from the PyCall.jl build process, which tries to install numpy if not already available:
I haven't been involved with the julia effort in conda-forge, but this must not happen. If it cannot be solved through a build argument, then we have to patch something here. @mkitti - any experience with this issue?
It's interesting that this warning doesn't occur on main: https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=717729&view=logs&jobId=d0d954b5-f111-5dc4-4d76-03b6c9d0cf7e&j=d0d954b5-f111-5dc4-4d76-03b6c9d0cf7e&t=841356e0-85bb-57d8-dbbc-852e683d1642 despite seemingly nothing else in the build process changing.
Are you sure that this warning message is problematic? It seems to only show that warning in the testing stage: https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=717759&view=logs&j=d0d954b5-f111-5dc4-4d76-03b6c9d0cf7e&t=841356e0-85bb-57d8-dbbc-852e683d1642&l=798
Some of these tests involve re-building, and building in temporary environments:
Umm... well numpy is a dependency of pysr, right? The julia-feedstock activate script should tell PyCall.jl and Conda.jl to look at the current conda environment. It should then realize that numpy is already installed, and not install a new one.
What is happening here?
It could be that this line is checking for numpy in the root environment, rather than the environment we are building/testing PySR in?
i.e., here is the add
:
Conda.add("numpy")
and here is a note about the default environment:
The
Conda.jl
package supports environments by allowing you to pass an optionalenv
parameter to functions for package installation, update, and so on. If this parameter is not specified, then the default "root" environment (corresponding to the path inConda.ROOTENV
) is used. The environment name can be specified as aSymbol
, or the full path of the environment (if you want to use an environment in a nonstandard directory) can be passed as a string.For example:
using Conda Conda.add("libnetcdf", :my_env) Conda.add("libnetcdf", "/path/to/directory") Conda.add("libnetcdf", "/path/to/directory"; channel="anaconda")
But I still don't understand how this should affect things, since these warnings are only displayed at the test stage?
It's interesting that this warning doesn't occur on main despite seemingly nothing else in the build process changing.
There's a likely explanation: Before, you were using the newest numpy version (1.24.3) to build, which very likely matched whatever julia was pulling in. Now the build is using 1.21 to build, and so the file delta in $PREFIX
[^1] between numpy 1.21 (the "before" in the snapshot) and numpy 1.24 (the "after" as installed by julia) is what conda now thinks are files installed by pysr
.
[^1]: more precisely, in $PREFIX/lib/python3<x>/site-packages/numpy
, at least as far as the numpy installation is concerned
Some of these tests involve re-building, and building in temporary environments:
The ClobberWarnings happen when the environment is created, which is before these test commands are ever run.
Is there any "band-aid" fix I can apply to the build while I look into this out in the PyCall.jl side? (I don't suppose it would work as-is, would it?) Just something to fix it for users temporarily so they aren't stuck with this libstdc++ bug themselves.
Maybe I can temporarily pin libstdcxx-ng
to the earlier version, finish off this PR, and then unpin it?
You have two choices, both user-unfriendly in some way:
numpy>=1.24.3
at runtime, but the warnings are goneWhatever choice you make to stop the bleeding now (which is fair enough), fixing this properly should be a high priority. Randomly re-installing numpy is baaaaaaaaaaaaaaaaaaaaaaad. Please don't do it.
Thanks, that sounds good to me.
Whatever choice you make to stop the bleeding now (which is fair enough), fixing this properly should be a high priority. Randomly re-installing numpy is baaaaaaaaaaaaaaaaaaaaaaad. Please don't do it.
I agree! That this was even going on was news to me as well. Quite a deeply buried bug in the PyJulia infra. And I guess it makes sense we never saw any signal of this since we were building against the same numpy.
@conda-forge-admin, please rerender
Fixes #83