Env: Windows 10 Pro
I installed python 2.7.9 and using pip installed robotframework and robotframework-selenium2library and it all worked fine with no errors.
Then I was doing some research and found that unless there is a reason for me to use 2.x versions of Python, I should stick with 3.x versions. Since 3.4 support already exists for selenium2library (read somewhere), so I decided to switch to it.
I uninstalled python 2.7.9 and installed python 3.4 version. When I installed robotframerwork, I am getting the following:
C:\Users\username>pip install robotframework
Downloading/unpacking RobotFramework
Running setup.py (path:C:\Users\username\AppData\Local\Temp\pip_build_username\RobotFramework\setup.py) egg_info for package RobotFramework
no previously-included directories found matching 'src\robot\htmldata\testdata'
Installing collected packages: RobotFramework
Running setup.py install for RobotFramework
File "C:\Python34\Lib\site-packages\robot\running\timeouts\ironpython.py", line 57
raise self._error[0], self._error[1], self._error[2]
^
SyntaxError: invalid syntax
File "C:\Python34\Lib\site-packages\robot\running\timeouts\jython.py", line 56
raise self._error[0], self._error[1], self._error[2]
^
SyntaxError: invalid syntax
no previously-included directories found matching 'src\robot\htmldata\testdata'
replacing interpreter in robot.bat and rebot.bat.
Successfully installed RobotFramework
Cleaning up...
When I did pip list I do see robotframework is installed.
C:\Users\username>pip list
pip (1.5.4)
robotframework (3.0)
setuptools (2.1)
Should I be concerned and stick to Python 2.7.9?
If you are using python 3.x then u can install Selenium2Library using this
pip install https://github.com/HelioGuilherme66/robotframework-selenium2library/archive/v1.8.0a1.zip
With python 2.7.9 you can only install robotframework 2.9
With python 3.X you can install robotframework 3.x+ but as Bryan Oakley said, Selenium2Library is not yet supported ;)
Related
I am trying to install python version pypy2.7.1.1 using the following
pyenv install pypy2.7-7.1.1
I get the following error:
Downloading pypy2.7-v7.1.1-osx64.tar.bz2...
-> https://downloads.python.org/pypy/pypy2.7-v7.1.1-osx64.tar.bz2
Installing pypy2.7-v7.1.1-osx64...
Installing pip from https://bootstrap.pypa.io/get-pip.py...
error: failed to install pip via get-pip.py
BUILD FAILED (OS X 11.2.3 using 0000000000)
Inspect or clean up the working tree at /var/folders/zt/q3p12vyx3l990yc32wmybqdr0000gs/T/python-build.20210428193745.1720
Results logged to /var/folders/zt/q3p12vyx3l990yc32wmybqdr0000gs/T/python-build.20210428193745.1720.log
Last 10 log lines:
/var/folders/zt/q3p12vyx3l990yc32wmybqdr0000gs/T/python-build.20210428193745.1720 ~
/var/folders/zt/q3p12vyx3l990yc32wmybqdr0000gs/T/python-build.20210428193745.1720/pypy2.7-v7.1.1-osx64 /var/folders/zt/q3p12vyx3l990yc32wmybqdr0000gs/T/python-build.20210428193745.1720 ~
ERROR: This script does not work on Python 2.7 The minimum supported Python version is 3.6. Please use https://bootstrap.pypa.io/pip/2.7/get-pip.py instead.
since pip was moved for 2.7 how do I install this now? is there a different way to install deprecated versions of python now?
I was having a similar issue on Mac OS 10.15.7 (Catalina).
This is how I was finally able to install Python 2.7 via pyenv
export GET_PIP_URL=https://bootstrap.pypa.io/pip/2.7/get-pip.py
PYTHON_BUILD_HOMEBREW_OPENSSL_FORMULA=openssl#1.0 pyenv install 2.7.5
I realize that you are trying to install pypy and not Python, but hopefully the method above helps you, or others!
I'm working on a Pyramid project that has to be deployed in a Debian 7 server.
The Debian 7 server has the python version 2.7.3 as from the archives repositories.
After creating a virtual environment with virtualenv command the pip version installed in this virtualenv is 1.1.
First thing noted: I can't upgrade pip with pip install --upgrade pip. The version is not updated and remains in 1.1 version.
After installing the OS packages needed to install the project I ran python setup.py install but I get the error:
Searching for zipp==0.5
Reading http://pypi.python.org/simple/zipp/
Couldn't find index page for 'zipp' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading http://pypi.python.org/simple/
No local packages or download links found for zipp==0.5
error: Could not find suitable distribution for Requirement.parse('zipp==0.5')
So, the python setup.py install command could not recognize the zipp package.
I thought that this was related to the older version of pip (1.1). So I could update pip version successfully using the index-url option:
$ pip install --index-url https://pypi.python.org/simple --upgrade pip
That updated pip version from 1.1 to 20.3b1. Then I tried python setup.py install again, but the same error occurred.
What I could see is that, after updating pip version, the zipp==0.5.0 package is installed if I ran pip install zipp==0.5.
I'm new to Pyramid and the package installing using the setup.py module. I'm not understanding why I can install the zipp package with pip and can't with python setup.py install.
I'm not putting the content of setup.py here because I think it's not a problem of the setup.py script. With more recent versions of python and pip in an Ubuntu 18.04 machine the setup.py works like a charm.
Someone could explain how to solve this issue?
When you run python setup.py install directly, you are not using pip, so the version of pip you have installed is irrelevant. This command is antiquated, should not be used, etc, etc. The right answer is to use pip install . as a replacement for python setup.py install and to use pip install -e . as a replacement for python setup.py develop.
With respect to what you're seeing, when you run python setup.py install this using the version of easy_install bundled with setuptools to talk to PyPI and install dependencies. This should be avoided for a lot of reasons but just know that to override urls it uses they go in ~/.pydistutils.cfg and have nothing to do with pip. HTTPS is one problem that you looked at, another is that old versions of Python do not have the right CA trust store, nor support the minimum required TLS 1.2 to handshake with PyPI. So expect lots of problems using old tools - at the very least try to use pip instead of easy_install.
I am using tensorflow in a python module, which is called by a c++ file. I moved to a new computer, where I installed ros again. So it works on one computer, but not on the other. There I got the following error:
UserWarning: h5py is running against HDF5 1.10.0 when it was built against 1.10.4, this may cause problems '{0}.{1}.{2}'.format(*version.hdf5_built_version_tuple)
then I did:
pip2.7 uninstall h5py
pip2.7 install h5py==1.10.4
but then I get the following error:
No handlers could be found for logger "keyring.backend"
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Defaulting to user installation because normal site-packages is not writeable
ERROR: Could not find a version that satisfies the requirement h5py==1.10.4 (from versions: 2.2.1, 2.3.0b1, 2.3.0, 2.3.1, 2.4.0b1, 2.4.0, 2.5.0, 2.6.0, 2.7.0rc2, 2.7.0, 2.7.1, 2.8.0rc1, 2.8.0, 2.9.0rc1, 2.9.0, 2.10.0)
ERROR: No matching distribution found for h5py==1.10.4
It seems like there is no 1.10.4 version. What should I do?
I have to use python2.7. Also if I just let the python2.7 script run, it works. Only in conjunction with ros I get this error. But I think I take the python version from the same folder.
Thank you
I'm trying to install cvxpy on my Mac through pip and through PyCharm and I'm getting the following error: "Command "python setup.py egg_info" failed with error code 1 in /private/tmp/pip-build-azdpOA/CVXcanon/". Would anyone know what's that and how to fix this?
My python is 2.7
My pip is 8.1.2
My PyCharm is 4.5.4
My OSX is 10.8.5
The module CVXcanon is a dependency by the official installation instructions.
We recommend using Anaconda rather than the Python that comes with the Mac and installing pip, nose, NumPy, SciPy, and CVXOPT through Anaconda (i.e., conda install pip nose numpy scipy cvxopt). But it is not necessary to have Anaconda to install CVXPY, and the instructions below assume you do not have Anaconda.
Install the command line tools xcode-select --install and then install the module with all dependencies pip install cvxpy. You can use the Terminal tab in PyCharm.
I have both python 2.7 and 3.2 installed on my computer and I wanted to install django. And when I did it automatically installed django 1.4 on python 3. Is there a way I can install it on python 2.7?
You can mention explicitly the python version while installing.
First download the source from django website.
Now extract it to any location and open the terminal and go to the location into the folder. There must be a file named setup.py that is the installation file.Now type:
For Python 3.2
python3.2 setup.py install
For Python 2.7
python2.7 setup.py install
The real answer here is that you should be using virtual environments, as they both solve this particular problem, and are the industry standard because they solve many problems.
Simple process:
install python-virtualenv :
$>sudo apt-get install python-virtualenv # on Ubuntu
create a virtual-env against the Python you want, and activate it
$> virtualenv -p /usr/bin/pythonX ve
$> source ve/bin/activate
install django into this virtual-env
$> pip install django
...
PROFIT!