I'll start off with saying I read this post already and could not find an answer.
I am on Windows 10, and have been trying to install pipenv through powershell.
Only, it returns me the following error:
WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
So I then downloaded ssl-1.16 from this website, but then ran into another error:
ValueError: This extension should not be used with Python 2.6 or later (already built in), and has not been tested with Python 2.3.4 or earlier.
I checked a few forums and still cannot seem to find an answer. So if anyone would know how to come to terms with that, I'd be truly grateful. :)
Thanks
Related
I am embedding python code in my cpp application to provide python-code-runner service. Recently I encountered a problem when I really need to downgrade my python version from 3.8.10 to 3.4.4, so that my application can fit on windows xp.
I used to provided some automatically-installed python 3rd-party packages for my customers to use. Now, as the downgrade of python version, I have to downgrade the 3rd-party packages' version to let my app function fine.
The problem is that I have no idea how to determine whether a 3rd-party package is suitable for python3.4. Is there a way I can test it?
I searched for pypi to get a version suitable for python3.4, but it turns out that this does not work well, as some 3rd-party-libs may rely on other packages with a semanticVersion mark >=.
Take astroid==1.3.8 for an example. I googled and found this version satisfies 3.4.4, so I installed it, and found syntax error when I use import astroid in my python script. The error indicates a syntax error in the lib logilab-common.
File "C:\Python34\lib\site-packages\astroid\__init__.py",line 54, in <module>
from astroid.nodes import *
...... // some traceback
......
File "C:\Python34\lib\site-packages\logilab\common\deprecated.py", line 105
self._proxied: Any = proxied
^
SyntaxError: invalid syntax
It turns out that the package astroid requires logilab-common>=0.63.0, and when I use pip install astroid==1.3.8, it installed the latest logilab-common, which is 1.9.7, and it used a type annotation, which caused this syntax error.
I managed to install logilab-common==0.63.0, and it worked fine when I use import astroid.
Does that mean I can use astroid all fine in python 3.4.4? I am not quite sure whether other functions or apis in this package will raise some syntax error or crash unexpectedly. Is there a way I can test it?
In the case, always installing the minium-satisfied-version of dependency-libs definitely works fine, but that's too much work for me. I want to find a way to test the utility of the libs and their dependency-libs.
Description
When I tried to install package sacrebleu, I got an error like this:
Installation Error
It said "System cannot find the specified file". However I have no idea how to solve it.
I have tried installing package mecab-python3. But it confuses me that it was successfully installed in Anaconda but got an error, "Microsoft Visual C++ 14.0 is required", in original python38 environment.
Whether the package mecab-python3 has been installed or not, I still got the same error and cannot install sacrebleu.
I also tried restarting my machine but it does not work.
Is there anyone could solve it? or I want to know if there is any alternative package I can use to calculate BLEU score.
Thanks Anyway!
My Environment
Windows 10
Python 3.8
pip 20.1.1
Anaconda3 v4.8.2
I'm the mecab-python3 maintainer. Sorry it's giving you trouble.
The README has a link to the C++ runtime pack you have to install on Windows, if you install that it should work.
I have heard reports of the package not working with Anaconda on Windows specifically, though it seems to work sometimes. If you have trouble please open an issue and I'll try to fix it. On the other hand, if you aren't processing Japanese there's no reason to import the module and that may be a bug in sacrebleu.
Ah, actually, I just saw your screenshot - didn't notice it before.
Versions before 1.0 don't support Windows. But to keep using the old dictionary, sacrebleu has to make some changes, so they don't support 1.0+ yet. I think they are working on it, see this issue.
Instead of using a Python distribution, I decided to install Scipy myself and stumbled upon Scipy Superpack (http://fonnesbeck.github.io/ScipySuperpack/). After installing Python 2.7.6 I followed the instructions on the website and everything seemed to work without any problems. However, once the installation was done I received a "fatal error" message as I tried to look through my modules. More specifically, the following error:
>>> help('modules')
Please wait a moment while I gather a list of all available modules...
Fatal Python error: PyThreadState_Get: no current thread
Abort trap: 6
I receive the same error message in the terminal, as well as through IDLE. Despite the error message, I am able to import and use numpy, as well as other modules from the superpack.
I should mention that prior to installing the superpack I installed pip. However, this didn't induce the previously mentioned error.
I am very new to osx, so any advice would be greatly appreciated!
I was also having a lot of problems while trying to install all the python libraries in my mac. I searched on the web for some hours and finally got something that worked out for me.
Scipy is here as well if you want to follow this rules instead:
https://gist.github.com/audy/4012573
New to Python and Scrapy. I need these modules apparently to run scrapy properly. I downloaded Zope interface as suggested and have been attempting to install using easy_install as per instructions on Scrapy. I'm running Windows 7 64 and first downloaded the 64 bit version of Pyton 2.7 and all modules including Zope. That didn't work, so I unistalled everything and downloaded the 32 bit versions, but I'm having the same problem. Clearly, I'm doing something very basic incorrectly. Would appreciate assistance.
This is what happens:
C:>easy_install zope.interface-4.0.3-py2.7-win32.egg
I get a whole bunch of results (which stackoverflow doesn't let me copy/paste even though I'm properly formatting it as code) that says at the end:
No local packages or download links found for zope.interface-4.0.3-py2.7-win32.egg
I know I need zope, because when I try and run srapy, I receive the following error (also other results):
C:>scrapy shell http://www.yahoo.com
raise ImportError(required + ": no module named zope.interface.")
ImportError: Twisted requires zope.interface 3.6.0 or later: no module named zope.interface.
As I said, I'm real new at this and having a tough time with all the modules and packages needed to get going.
easy_install and pip install take package names, not the filename.
so the correct invocation would be
easy_install zope.interface
which will fetch the latest version. If you specifically want that version
easy_install "zope.interface==4.0.3"
You can usually find package names by googling, eg. pypi zope interface
I've spent an absurdly long time trying overcome the zope problems when installing scrapy and just found a solution!
I just followed step 7 here (as Talvalin suggested)
http://steamforge.net/wiki/index.php/How_to_Install_Scrapy_in_64-bit_Windows_7
Then, in my site-packages location I just changed the name of the egg file "zope.interface-3.8.0-py2.7-win-amd64.egg" to "zope". All worked fine after that.
Hope this helps somebody!
I've been trying to run a web server based in Python 2.6 code here at work. The server requires the python LDAP libraries in order to run. Because I'm working on Mac OS X Lion, I needed to run a manual install of python-ldap 2.4.7 in order to get Python to recognize LDAP at all. Python-ldap appeared to intall correctly, but when I try to run the web server I get the following error (I added some line breaks for the sake of clarity):
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/python_ldap-2.4.7-py2.6-macosx-10.7-fat.egg/_ldap.so, 2): Symbol not found: _ber_pvt_opt_on
Referenced from: /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/python_ldap-2.4.7-py2.6-macosx-10.7-fat.egg/_ldap.so
Expected in: flat namespace
in /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/python_ldap-2.4.7-py2.6-macosx-10.7-fat.egg/_ldap.so
I'm using OpenLDAP 2.4.21, and I set the following system variables before running my python-ldap installation:
export ARCHFLAGS="-arch i386"
export CFLAGS="-isysroot /Developer/SDKs/MacOSX10.7.sdk -arch i386"
export MACOSX_DEPLOYMENT_TARGET="10.7"
I should also probably mention that I've had to force everything I've installed to use 32-bit architecture instead of 64-bit in order to work around some issues with Oracle's 64-bit support. Has anyone encountered a similar situation, or do they know the significance of the "_ber_pvt_opt_on" symbol that LDAP was looking for? The number of Google results I was able to come up with was both small and unhelpful. Any light that you could shed on the situation would be greatly appreciated.