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

Multiple fixes to get conda setup working in more environments #741

Merged
merged 8 commits into from
Apr 16, 2020

Conversation

shankari
Copy link
Contributor

My personal laptop had a version of conda even older than the docker container.
So old that it only supported source activate and not conda activate.
So we used source activate in the setup script and checked for the CI
variable before using it in conda activate.

This:

  • supports setup_conda on multiple platforms
  • upgrades all setup scripts to use conda install
  • stops exiting from check_for_conda so it doesn't kill the shell
  • updates the manual install test to also include osx, and to add osx to the
    list of oses that we test against
    • also pass in the platform correctly per OS so that the installation will
      happen correctly

My personal laptop had a version of conda even older than the docker container.
So old that it only supported `source activate` and not `conda activate`.
So we used `source activate` in the setup script and checked for the CI
variable before using it in `conda activate`.

This:
- supports `setup_conda` on multiple platforms
- upgrades all setup scripts to use `conda install`
- stops exiting from `check_for_conda` so it doesn't kill the shell
- updates the manual install test to also include osx, and to add osx to the
  list of oses that we test against
    - also pass in the platform correctly per OS so that the installation will
      happen correctly
So we test install only ubuntu + osx
and go back to linux only for install + tests

This should also catch any inconsistencies between the dev setup and the test
setup scripts (similar to e-mission/e-mission-docs#513 (comment))
Since it inexplicably fails on OSX
+ remove exit 1 since it is confusing in source scripts
- switch to conda on teardown as well
- actually switch to the environment after installing it to ensure that it exists
So that there is more indication of what failed if something fails
@shankari shankari merged commit 6a7a2f7 into e-mission:master Apr 16, 2020
jf87 pushed a commit to jf87/e-mission-server that referenced this pull request Jun 21, 2021
…sion#741)

* Multiple fixes to get conda setup working in more environments

My personal laptop had a version of conda even older than the docker container.
So old that it only supported `source activate` and not `conda activate`.
So we used `source activate` in the setup script and checked for the CI
variable before using it in `conda activate`.

This:
- supports `setup_conda` on multiple platforms
- upgrades all setup scripts to use `conda install`
- stops exiting from `check_for_conda` so it doesn't kill the shell
- updates the manual install test to also include osx, and to add osx to the
  list of oses that we test against
    - also pass in the platform correctly per OS so that the installation will
      happen correctly

* Mongodb install action only works on ubuntu

So we test install only ubuntu + osx
and go back to linux only for install + tests

This should also catch any inconsistencies between the dev setup and the test
setup scripts (similar to e-mission/e-mission-docs#513 (comment))

* Remove miniconda check since osx doesn't have miniconda preinstalled

* Add exit codes so we can see why this is failing

* Checking to see if the error is with which conda

* Check the conda path only on linux

Since it inexplicably fails on OSX
+ remove exit 1 since it is confusing in source scripts

* Final fixes

- switch to conda on teardown as well
- actually switch to the environment after installing it to ensure that it exists

* Some more clarity into what we are doing

So that there is more indication of what failed if something fails
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.

1 participant