mamba-org / gator

Conda environment and package management extension from within Jupyter
Other
260 stars 31 forks source link

Mamba not recognized on windows #120

Closed fcollonval closed 3 years ago

fcollonval commented 3 years ago

Fixes #119

github-actions[bot] commented 3 years ago

Binder :point_left: Launch a binder notebook on the branch mamba-org/gator/fcollonval/issue119

coveralls commented 3 years ago

Pull Request Test Coverage Report for Build 404135224

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details


Changes Missing Coverage Covered Lines Changed/Added Lines %
mamba_gator/envmanager.py 12 24 50.0%
<!-- Total: 12 24 50.0% -->
Files with Coverage Reduction New Missed Lines %
mamba_gator/envmanager.py 4 84.89%
<!-- Total: 4 -->
Totals Coverage Status
Change from base Build 404093869: -0.2%
Covered Lines: 754
Relevant Lines: 1016

💛 - Coveralls
fcollonval commented 3 years ago

@jtpio could you try that this PR does not break the dependency graph on non-Windows computer?

In WSL, it works. But on binder it seems to hit a bug:

Traceback (most recent call last):\n  File "/srv/conda/envs/notebook/bin/mamba", line 7, in <module>\n    from mamba.mamba import main\n  File "/srv/conda/envs/notebook/lib/python3.7/site-packages/mamba/mamba.py", line 52, in <module>\n    import mamba.mamba_api as api\nImportError: libiconv.so.2: cannot open shared object file: No such file or directory\n
jtpio commented 3 years ago

Thanks @fcollonval, will do.

I remember seeing this error some time before, but that was on CI with Windows.

jtpio commented 3 years ago

I don't seem be hitting this error locally.

However I don't seem to be able to see the graph either, after pulling this branch and setting up the environment with the following:

mamba create -n gator-tmp -c conda-forge jupyterlab=2 nodejs python -y
conda activate gator-tmp
gh pr checkout 120
pip install -e .
jupyter nbextension install mamba_gator --py --sys-prefix --symlink
jupyter nbextension enable mamba_gator --py --sys-prefix
jupyter serverextension enable mamba_gator --py --sys-prefix

yarn install
yarn run build:dev
jupyter labextension link packages/common/ packages/labextension/
jtpio commented 3 years ago

However I don't seem to be able to see the graph either,

This seems to also be the case when opening the current master on Binder:

image

fcollonval commented 3 years ago

Thanks for testing Jeremy.

On the current master on Binder, the problem is the binder issue with mamba:

image

Regarding your local installation, for now the PR from @hbcarlos included the graph feature by clicking on the installed version of a package (no icon in the toolbar, nor graph for not installed package). Could you confirm that even that is not working on your computer? Could you see if mamba --version is raising an error?

jtpio commented 3 years ago

On the current master on Binder, the problem is the binder issue with mamba:

Ah right, I missed that.

Locally:

$ mamba --version
mamba 0.7.1
conda 4.9.2
jtpio commented 3 years ago

Since mamba is already available on Binder, maybe we can remove it from the environment.yml:

https://github.com/mamba-org/gator/blob/60e900a9b86cd8b2de7f1af2839c0808ff3741de/binder/environment.yml#L7

jtpio commented 3 years ago

Locally, clicking on the package seems to tick the checkbox on and off:

graph-local

jtpio commented 3 years ago

Ah I missed that it was on the version number. Seems to be working fine locally!

image

jtpio commented 3 years ago

On the current master on Binder, the problem is the binder issue with mamba:

Should be fixed in https://github.com/mamba-org/gator/pull/121

fcollonval commented 3 years ago

Thanks a lot for correcting Binder and for testing @jtpio.

Once merged, I'll do a release.