Discussion:
[PyQt] Install PyQt5 via setuptools
Tony Arnold
2016-12-07 11:53:08 UTC
Permalink
I have a PyQt5 application which I package using setuptools. I've recently, PyQt5 3.5 or later can be installed using pip3, so I presumed that PyQt5 could be specified in the 'install_required' option in my setup.py file. However, this fails to install PyQt5 when installing my package.

Is it possible to do what I want, and if so how would I go about it?

Regards,
Tony.
--
Tony Arnold MBCS, CITP | Senior IT Security Analyst | Directorate of IT Services | G.110, Kilburn Building | The University of Manchester | Manchester M13 9PL | T: +44 161 275 6093 | M: +44 773 330 0039
Florian Bruhin
2016-12-07 12:13:55 UTC
Permalink
Post by Tony Arnold
I have a PyQt5 application which I package using setuptools. I've
recently, PyQt5 3.5 or later can be installed using pip3, so I
presumed that PyQt5 could be specified in the 'install_required'
option in my setup.py file. However, this fails to install PyQt5
when installing my package.
How does it fail?

Florian
--
http://www.the-compiler.org | ***@the-compiler.org (Mail/XMPP)
GPG: 916E B0C8 FD55 A072 | http://the-compiler.org/pubkey.asc
I love long mails! | http://email.is-not-s.ms/
Tony Arnold
2016-12-07 12:41:13 UTC
Permalink
Florian,
Post by Florian Bruhin
Post by Tony Arnold
I have a PyQt5 application which I package using setuptools. I've
recently, PyQt5 3.5 or later can be installed using pip3, so I
presumed that PyQt5 could be specified in the 'install_required'
option in my setup.py file. However, this fails to install PyQt5
when installing my package.
How does it fail?
It says:

Searching for PyQt5
Reading https://pypi.python.org/simple/PyQt5/
No local packages or working download links found for PyQt5
error: Could not find suitable distribution for
Requirement.parse('PyQt5')


I'm running on Ubuntu 16.10 inside a virtualenv with Python 3.5.

Regards,
Tony.
--
Tony Arnold MBCS, CITP | Senior IT Security Analyst | Directorate of IT Services | G.110, Kilburn Building | The University of Manchester | Manchester M13 9PL | T: +44 161 275 6093 | M: +44 773 330 0039
_______________________________________________
PyQt mailing list ***@riverbankcomputing.com
https://www.riverbankcomputing.com/
Kyle Altendorf
2016-12-07 13:13:27 UTC
Permalink
Post by Tony Arnold
Florian,
Post by Florian Bruhin
Post by Tony Arnold
I have a PyQt5 application which I package using setuptools. I've
recently, PyQt5 3.5 or later can be installed using pip3, so I
presumed that PyQt5 could be specified in the 'install_required'
option in my setup.py file. However, this fails to install PyQt5
when installing my package.
How does it fail?
Searching for PyQt5
Reading https://pypi.python.org/simple/PyQt5/
No local packages or working download links found for PyQt5
error: Could not find suitable distribution for
Requirement.parse('PyQt5')
I'm running on Ubuntu 16.10 inside a virtualenv with Python 3.5.
What command are you running? `python setup.py develop` won't work, you
have to use `pip install -e .` from within the same directory as
`setup.py`. Then pip will search PyPI for dependencies.

Cheers
-kyle
_______________________________________________
PyQt mailing list ***@riverbankcomputing.com
https://www.riverbankcomputing.com/mailman/listinfo/py
Tony Arnold
2016-12-07 13:38:35 UTC
Permalink
Kyle,
Post by Tony Arnold
Florian,
Post by Florian Bruhin
Post by Tony Arnold
I have a PyQt5 application which I package using setuptools. I've
recently, PyQt5 3.5 or later can be installed using pip3, so I
presumed that PyQt5 could be specified in the
'install_required'
option in my setup.py file. However, this fails to install PyQt5
when installing my package.
How does it fail?
Searching for PyQt5
Reading https://pypi.python.org/simple/PyQt5/
No local packages or working download links found for PyQt5
error: Could not find suitable distribution for
Requirement.parse('PyQt5')
I'm running on Ubuntu 16.10 inside a virtualenv with Python 3.5.
What command are you running?  `python setup.py develop` won't work,
you 
have to use `pip install -e .` from within the same directory as 
`setup.py`.  Then pip will search PyPI for dependencies.
I'm running 'python setup.py install' and in my setup.py file, I
have install_requires=['PyQt5', 'pyexiftool', 'keyring']

Note that pyexiftool is not available on PyPI, so I have a
dependency_link defined for that which works just fine, but it means
that your suggestion of 'pip install -e .' fails trying to install
'pyexiftool'. Your suggestion works and installs PyQt5 if I remove
'pyexiftool' from the install_requires line.

Regards,
Tony.
--
Tony Arnold MBCS, CITP | Senior IT Security Analyst | Directorate of IT Services | G.110, Kilburn Building | The University of Manchester | Manchester M13 9PL | T: +44 161 275 6093 | M: +44 773 330 0039
_______________________________________________
PyQt mailing list ***@riverbankcomputing.com
https://www.riverbankcomputing.com/mailm

Loading...