Skip to content
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

PKG Add msprime and deps including libgsl #2548

Merged
merged 2 commits into from May 17, 2022

Conversation

benjeffery
Copy link
Contributor

@benjeffery benjeffery commented May 11, 2022

Add the msprime package, a wieldy used genetic simulation tool.

  • Add a CHANGELOG entry
  • Add / update tests
  • Add new / update outdated documentation

@benjeffery benjeffery force-pushed the add_msprime branch 2 times, most recently from 3f6597c to e905c29 Compare May 12, 2022 11:27
@benjeffery benjeffery changed the title Add msprime and deps including libgsl PKG Add msprime and deps including libgsl May 12, 2022
@benjeffery benjeffery force-pushed the add_msprime branch 11 times, most recently from d461471 to 72467f8 Compare May 16, 2022 11:05
@benjeffery benjeffery marked this pull request as ready for review May 16, 2022 14:20
@benjeffery
Copy link
Contributor Author

This PR is now ready for review/merge. Thanks again for the great docs and tooling, I was able to get libgsl compiled and added as a package quite easily. Quite a few other libaraies use GSL, so hopefully that saves some work for other people.

Copy link
Member

@rth rth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this work @benjeffery ! A few comments otherwise LGTM.

"tskit",
"demes",
"msprime",
"newick",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Normally you don't need to specify packages that are already dependencies of msprime. It's probably a good idea to omit those to check that dependencies are correctly installed.

sha256: e840bed2ba37ae572b234f0b55af006dc408881593f184304481ee6058ea6f30
build:
script: |
pip install -t $HOSTSITEPACKAGES numpy
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So numpy is a build dependency as far as I understand?

It should already be installed on when building this package. So either it should build without this line altogether, or if it doesn't work you might need to adjust cflags/ldfags to include the right folders see for example

-L$(NUMPY_LIB)/core/lib/

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Due to the way msprime is currently built it's setup.py imports numpy. This is planned to be fixed soon, at which point I will remove this. I've opened tskit-dev/msprime#2055 to track.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, so numpy is a build time dependency -- we have many such packages packaged (e.g. scipy, pandas), it's not an issue as far as Pyodide is concerned. My previous suggestions should still apply.

Also for the future if you could avoid rebasing and add commits instead -- it's easier to see what changed since last review, and we squash commits when merging anyway. Thanks!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shouldn't be necessary in any case because it is already done by building the numpy package. So having it in the run requirements below covers it. Hopefully we will add build requirements and then numpy could be moved there.

@hoodmane
Copy link
Member

This will also need to be fixed for #2551 but maybe we can merge this first and make @ryanking13 deal with it.

@hoodmane hoodmane merged commit 4417005 into pyodide:main May 17, 2022
@hoodmane
Copy link
Member

Thanks @benjeffery!

@benjeffery benjeffery deleted the add_msprime branch May 17, 2022 22:44
@ryanking13
Copy link
Member

This will also need to be fixed for #2551 but maybe we can merge this first and make @ryanking13 deal with it.

Sure, I can deal with it. Thanks @hoodmane and @benjeffery!

@rth rth mentioned this pull request May 18, 2022
3 tasks
@jobovy jobovy mentioned this pull request Jun 8, 2022
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants