astronomy-python icon indicating copy to clipboard operation
astronomy-python copied to clipboard

gala not installed when Conda-forge is not an available channel

Open abostroem opened this issue 2 years ago • 3 comments

What is the problem?

A number of learners are getting the error:

conda env create -f environment.yml
Collecting package metadata (repodata.json): done
Solving environment: failed

ResolvePackageNotFound: 
  - gala

I believe this is due to gala being on conda-forge and these learners not having Conda-forge as a channel. My solution is to have them remove this line from the environement.yml file and then activate the AstronomicalData environment after they created it and pip install. However, we could also consider adding the Conda-forge channel - I just don't know if this might mess with other installation

Location of problem (optional)

No response

abostroem avatar Jan 03 '24 20:01 abostroem

Alternatively: The main reason for using gala at all is the GD1Koposov model and the reflex correction. GD1Koposov is now natively in astropy, and the reflex-correction is a simple function that only works on astropy SkyCoords and doesn't rely on anything else in gala. Therefore, we could copy this function into the lesson itself (or the catchup part learners can import) and remove the entire dependency on gala, thus getting rid of this installation head-ache.

rkotulla avatar Jan 03 '24 21:01 rkotulla

My concern with this is I think it is poor coding practice as we will not get any updates or bug fixes to the real code. I also encountered an issue with using the astropy GD1 - maybe you know how to fix it. See issue #193

abostroem avatar Jan 03 '24 21:01 abostroem

actually, Conda-forge is a listed channel in the environment file - I'm not sure why this isn't working

abostroem avatar Jan 06 '24 02:01 abostroem