ninia / jep

Embed Python in Java
Other
1.32k stars 150 forks source link

jep 4.0.1 disappeared from conda-forge suddenly #387

Closed SemanticBeeng closed 1 year ago

SemanticBeeng commented 2 years ago

Describe the problem

Creating conda environments with jep 4.0.1 as dependency (not pip). Worked fine and then stopped working. More precisely it fails to resolve (https://anaconda.org/conda-forge/jep used to show 4.0.1 as latest version) and then conda tries a build and that fails.

Noticed the latest is now 4.0.3. How is the deployment to conda-forge supposed to work? Please advise with details on the build and release to better make sense of why this happens.

Environment (please complete the following information):

Logs image

Additional context Add any other context about the problem here.

ndjensen commented 2 years ago

We have nothing to do with conda or conda-forge and don't know how it works.

SemanticBeeng commented 2 years ago

Hmm ... okay. For the record, the build is done with this https://github.com/conda-forge/jep-feedstock. Will post an issue there then.

ndjensen commented 2 years ago

Interesting, looks like it doesn't like the static assert line in jep_platform.h. https://github.com/ninia/jep/blob/v4.0.3/src/main/c/Include/jep_platform.h#L38 I don't understand why.

SemanticBeeng commented 2 years ago

Indeed. Unsure what controls the PY_MAJOR_VERSION variable. Only found two references https://github.com/search?q=org%3Aconda-forge+PY_MAJOR_VERSION&type=issues And found https://stackoverflow.com/a/4352907/4032515 but unsure how this is used in conda-forge builds.

bsteffensmeier commented 2 years ago

Py_MAJOR_VERSION is brought in from patchlevel.h which is the first thing Python.h brings in. I would be surprised if conda-forge is doing anything special with this as it is standard in python builds and we have always had various checks against it.

bsteffensmeier commented 1 year ago

I did some investigation and found the conda_forge environemnt for older versions of python does not define static_assert in assert.h. I've added an extra check in d8cd41bfd1 so we won't use static_assert unless we need to. This will resolve that particular error but I do not have any way to test the conda forge build so if anyone knows how to do that it would be helpful to make sure there aren't other errors.

ndjensen commented 1 year ago

Can someone test the conda-forge build with the Jep 4.1.1 release?

bsteffensmeier commented 1 year ago

Closing because we have no way to test the fix, if there are other issues please open a new issue.