-
Notifications
You must be signed in to change notification settings - Fork 29
Description
Hi,
I have realized that I can't install ismrmrd-python on an apple silicon device (conda platform osx-arm64). While one can pretend to be on x86-64 by creating the env with --platform osx-64, I don't think that this should be required (as ismrmrd-python is a pure python package).
Further, install from conda seems to require conda-forge channels anyway since xsdata is only available from there. Ismrmrd-python could also be distributed via conda-forge to simplify the installation as the currently required custom 'ismrmrd' channel for install is not well documented and I had to dig a bit in the repo to find it.
I would thus propose to publish also to conda-forge. My initial tests with building a noarch python conda package (https://docs.anaconda.com/reference/glossary/?highlight=noarch#noarch-package) for ismrmrd-python were successful, although I could not build directly from the sources released on PyPI, because they don't include all source files (crucially schema/.xsdata.xml is absent, and then the xsdata code generation will default to PascalCase instead of camelCase for classes). Also examples are not present.
The are two options that worked for me for building, including tests:
- Build either from github source release.
- Build from PyPI wheel (which contains the xsd-generated python module): https://docs.conda.io/projects/conda-build/en/3.27.x/user-guide/wheel-files.html.
If building from PyPI wheel, we need to download the PyPI sources still, because LICENSE and tests/ are only contained therein. I have tested this, it works on my apple silicon machine, but it makes the recipe more complicated.
Conda-forge prefers source builds over builds from wheels.
Preferably, sources uploaded to PyPI are identical with those in github releases to avoid confusion. Then it also wouldn't matter anymore where the sources are taken from. It should also be possible for to setup automatic conda-forge packaging regardless of where the sources are from (https://conda-forge.org/docs/maintainer/updating_pkgs.html#how-does-regro-cf-autotick-bot-create-automatic-version-updates), but I have no personal experience with this.
I wanted to ask for the ismrmrd-python maintainers' opinions on this.
I'd be happy to submit a PR to https://github.com/conda-forge/staged-recipes to get the process started.