You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The reason will be displayed to describe this comment to others. Learn more.
Hmm. Does this work in general?
$ python --version
Python 3.7.9
$ pip install PyQt
ERROR: Could not find a version that satisfies the requirement PyQt (from versions: none)
ERROR: No matching distribution found for PyQt
$ pip install PyQt5
Requirement already satisfied: PyQt5 in /.../apps/conda/lib/python3.7/site-packages (5.12.3)
The reason will be displayed to describe this comment to others. Learn more.
Hmm. Looks like there are differences in how pip and conda solve the dependency requirements. I see the same thing you do with pip, but when I tried conda this happened:
(with PyQt5 in requirements.txt)
(pyani_dev) ! conda config --add channels anaconda
(pyani_dev) ! make setup_env
Collecting package metadata (current_repodata.json): done
Solving environment: done## Package Plan ##
environment location: /Users/baileythegreen/Software/miniconda3/envs/pyani_dev
added / updated specs:
- bandit
- black
- blacken-docs
- codecov
- coverage
- doc8
- flake8
- jinja2
- mypy
- pydocstyle
- pylint
- pytest
- pytest-cov
- rstcheck
- sphinx
The following packages will be downloaded:
package | build
---------------------------|-----------------
appdirs-1.4.4 | py_0 13 KB anaconda
black-19.10b0 | py_0 84 KB anaconda
ca-certificates-2020.10.14 | 0 127 KB anaconda
certifi-2020.6.20 | py38_0 159 KB anaconda
codecov-2.1.10 | py_0 20 KB anaconda
coverage-5.3 | py38haf1e3a3_0 256 KB anaconda
jinja2-2.11.2 | py_0 97 KB anaconda
pydocstyle-5.1.1 | py_0 37 KB anaconda
pytest-cov-2.10.1 | py_0 20 KB anaconda
regex-2020.10.15 | py38haf1e3a3_0 349 KB anaconda
sphinx-3.2.1 | py_0 1.4 MB anaconda
------------------------------------------------------------
Total: 2.6 MB
The following NEW packages will be INSTALLED:
appdirs anaconda/noarch::appdirs-1.4.4-py_0
regex anaconda/osx-64::regex-2020.10.15-py38haf1e3a3_0
The following packages will be SUPERSEDED by a higher-priority channel:
black conda-forge::black-21.12b0-pyhd8ed1ab~ --> anaconda::black-19.10b0-py_0
ca-certificates conda-forge::ca-certificates-2021.10.~ --> anaconda::ca-certificates-2020.10.14-0
certifi conda-forge::certifi-2021.10.8-py38h5~ --> anaconda::certifi-2020.6.20-py38_0
codecov conda-forge::codecov-2.1.11-pyhd3deb0~ --> anaconda::codecov-2.1.10-py_0
coverage conda-forge::coverage-6.2-py38h96a096~ --> anaconda::coverage-5.3-py38haf1e3a3_0
jinja2 conda-forge::jinja2-3.0.3-pyhd8ed1ab_0 --> anaconda::jinja2-2.11.2-py_0
pydocstyle conda-forge::pydocstyle-6.1.1-pyhd8ed~ --> anaconda::pydocstyle-5.1.1-py_0
pytest-cov conda-forge::pytest-cov-3.0.0-pyhd8ed~ --> anaconda::pytest-cov-2.10.1-py_0
sphinx conda-forge::sphinx-4.3.2-pyh6c4a22f_0 --> anaconda::sphinx-3.2.1-py_0
Downloading and Extracting Packages
pydocstyle-5.1.1 | 37 KB |######################################################################### | 100%
ca-certificates-2020 | 127 KB |######################################################################### | 100%
regex-2020.10.15 | 349 KB |######################################################################### | 100%
pytest-cov-2.10.1 | 20 KB |######################################################################### | 100%
coverage-5.3 | 256 KB |######################################################################### | 100%
codecov-2.1.10 | 20 KB |######################################################################### | 100%
appdirs-1.4.4 | 13 KB |######################################################################### | 100%
sphinx-3.2.1 | 1.4 MB |######################################################################### | 100%
jinja2-2.11.2 | 97 KB |######################################################################### | 100%
black-19.10b0 | 84 KB |######################################################################### | 100%
certifi-2020.6.20 | 159 KB |######################################################################### | 100%
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
PackagesNotFoundError: The following packages are not available from current channels:
- pyqt5
Current channels:
- https://conda.anaconda.org/anaconda/osx-64
- https://conda.anaconda.org/anaconda/noarch
- https://conda.anaconda.org/conda-forge/osx-64
- https://conda.anaconda.org/conda-forge/noarch
- https://conda.anaconda.org/bioconda/osx-64
- https://conda.anaconda.org/bioconda/noarch
- https://repo.anaconda.com/pkgs/main/osx-64
- https://repo.anaconda.com/pkgs/main/noarch
- https://repo.anaconda.com/pkgs/r/osx-64
- https://repo.anaconda.com/pkgs/r/noarch
To search for alternate channels that may provide the conda package you'relooking for, navigate to https://anaconda.organd use the search bar at the top of the page.make: *** [setup_env] Error 1
The reason will be displayed to describe this comment to others. Learn more.
The fundamental issue is that we're using CircleCI and pip exclusively to install packages, but pyqt/PyQt5 has different names in pip/conda, so we must choose one. pyqt installs OK with conda - but our CircleCI builds fail with that.
If we choose conda we either need to use miniconda/conda in our CircleCI config, or move to another CI (e.g. GitHub Actions) or similar.
The path of least resistance - while we still need to install via bothconda and pip (which we do because some packages are in pip and not conda) - is the one chosen here, and that's perfectly fine.
We should try to keep this in mind though, should all the packages become available in conda and/or we swap to another CI, as we might want to revisit this, then.
0949a46
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm. Does this work in general?
0949a46
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm. Looks like there are differences in how
pip
andconda
solve the dependency requirements. I see the same thing you do withpip
, but when I triedconda
this happened:(with PyQt5 in
requirements.txt
)(with PyQt in
requirements.txt
)I will need to look into the best way to handle these not playing well together.
0949a46
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh dear, that's be painful - I've been lucky to date, and not run into one of these namespaces clashes between pip and conda.
0949a46
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fundamental issue is that we're using CircleCI and
pip
exclusively to install packages, butpyqt
/PyQt5
has different names inpip
/conda
, so we must choose one.pyqt
installs OK withconda
- but our CircleCI builds fail with that.If we choose
conda
we either need to useminiconda
/conda
in our CircleCI config, or move to another CI (e.g. GitHub Actions) or similar.The path of least resistance - while we still need to install via both
conda
andpip
(which we do because some packages are inpip
and notconda
) - is the one chosen here, and that's perfectly fine.We should try to keep this in mind though, should all the packages become available in
conda
and/or we swap to another CI, as we might want to revisit this, then.0949a46
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest making it clear in the requirements.txt which system is being used (if sadly it cannot be both) with a human readable comment,
e.g. https://github.com/peterjc/thapbi-pict/blob/v0.11.2/requirements.txt