Unable to clone github library to python - python-3.x

i trying to clone https://github.com/zhangchiyu10/pyC45 this repo to my python.
i was using
pip install git+https://github.com/zhangchiyu10/pyC45.git
ERROR: Complete output from command python setup.py egg_info:
ERROR: Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\python37\lib\tokenize.py", line 447, in open
buffer = _builtin_open(filename, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\YULIAN~1\\AppData\\Local\\Temp\\pip-req-build-sqgmxgf8\\setup.py'
----------------------------------------
ERROR: Command "python setup.py egg_info" failed with error code 1 in C:\Users\YULIAN~1\AppData\Local\Temp\pip-req-build-sqgmxgf8\
any idea about how to use github library?

that's not really a "package" (i.e. it does not provide tools to install via pip like proper setup.py). just download pyC45.py into your working directory/project

Related

Pyautogui-module is not installing with pip3 on Ubuntu 19.10

I'm developing with python 3 and trying to install the pyautogui Module, and to be able to use it I had to install some packages. But I keep getting errors when installing the packages with pip3.
Collecting pyobjc-framework-Quartz
Using cached https://files.pythonhosted.org/packages/a9/af/fb7a7264d3bf0147bdd1d01eeb4e8b1cac90f0613aca336b178771dcdec7/pyobjc-framework-Quartz-6.2.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-4ukazwoa/pyobjc-framework-Quartz/setup.py", line 67, in <module>
py_limited_api=True,
File "/tmp/pip-install-4ukazwoa/pyobjc-framework-Quartz/pyobjc_setup.py", line 390, in Extension
os_level = get_os_level()
File "/tmp/pip-install-4ukazwoa/pyobjc-framework-Quartz/pyobjc_setup.py", line 200, in get_os_level
with open("/System/Library/CoreServices/SystemVersion.plist", "rb") as fp:
FileNotFoundError: [Errno 2] No such file or directory: '/System/Library/CoreServices/SystemVersion.plist'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-4ukazwoa /pyobjc-framework-Quartz/
Anyone has a idea what the problem is?
Anything related to Objective C, pyobjc and especially pyobjc-framework-Quartz require Mac OS X. You cannot install them at Ubuntu.

Pip install using git+ssh not working for python package

I am trying to install this Python Package:
https://pypi.org/project/SalesforcePy/#install
I am running on python 3.7 on macOS Mojave, I've never experienced an issue downloading a package from github before.
When I tried pip install git+ssh://git#github.com/forcedotcom/SalesforcePy.git
I get this:
Collecting git+ssh://git#github.com/forcedotcom/SalesforcePy.git
Cloning ssh://git#github.com/forcedotcom/SalesforcePy.git to /private/var/folders/xb/_9gc6p552hz8m7vjc5wbgjbm0000gp/T/pip-req-build-ly43g63b
Running command git clone -q ssh://git#github.com/forcedotcom/SalesforcePy.git /private/var/folders/xb/_9gc6p552hz8m7vjc5wbgjbm0000gp/T/pip-req-build-ly43g63b
git#github.com: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
ERROR: Command "git clone -q ssh://git#github.com/forcedotcom/SalesforcePy.git /private/var/folders/xb/_9gc6p552hz8m7vjc5wbgjbm0000gp/T/pip-req-build-ly43g63b" failed with error code 128 in None
I also tried downloading it on my desktop and got this:
pip install Desktop/SalesforcePy-1.1.1
Processing ./Desktop/SalesforcePy-1.1.1
ERROR: Complete output from command python setup.py egg_info:
ERROR: Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/xb/_9gc6p552hz8m7vjc5wbgjbm0000gp/T/pip-req-build-n3xo0za2/setup.py", line 7, in <module>
with open(os.path.join(os.path.dirname(__file__), 'requirements.txt')) as fh:
FileNotFoundError: [Errno 2] No such file or directory: '/private/var/folders/xb/_9gc6p552hz8m7vjc5wbgjbm0000gp/T/pip-req-build-n3xo0za2/requirements.txt'
----------------------------------------
ERROR: Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/xb/_9gc6p552hz8m7vjc5wbgjbm0000gp/T/pip-req-build-n3xo0za2/
The second error message is tracked by forcedotcom/SalesforcePy issue 41 and is still pending.
The first one should work though (it is a public repository), and is the recommended method. The syntax is correct (using '/' everywhere).
It might be a consequence of the second error message: an error from requirement.txt, which might needs a preprocessing, as in this project.

Trouble downloading Pandas, python3 on macOS

I just downloaded python 3.6 after using python 2 for awhile. I need to download my modules for python 3. I started with downloading pandas (unsuccessfully) and I have tried running in my terminal:
$ sudo pip3 install --user pandas
$ pip3 install --user pandas
$ sudo pip3 install pandas
$ pip3 install pandas
I also ran a few more variations trying to play with it. I receive this error at the end of the output for that last attempt:
Collecting pandas
Using cached pandas-0.19.2.tar.gz
Complete output from command python setup.py egg_info:
Download error on https://pypi.python.org/simple/numpy/: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:749) -- Some packages may not be found!
Couldn't find index page for 'numpy' (maybe misspelled?)
Download error on https://pypi.python.org/simple/: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:749) -- Some packages may not be found!
No local packages or working download links found for numpy>=1.7.0
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/68/xjx6zfr570199v_w0dhd9y3c0000gn/T/pip-build-v90_t75r/pandas/setup.py", line 696, in <module>
**setuptools_kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/distutils/core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/setuptools/dist.py", line 315, in __init__
self.fetch_build_eggs(attrs['setup_requires'])
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/setuptools/dist.py", line 361, in fetch_build_eggs
replace_conflicting=True,
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/pkg_resources/__init__.py", line 850, in resolve
dist = best[req.key] = env.best_match(req, ws, installer)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/pkg_resources/__init__.py", line 1122, in best_match
return self.obtain(req, installer)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/pkg_resources/__init__.py", line 1134, in obtain
return installer(requirement)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/setuptools/dist.py", line 429, in fetch_build_egg
return cmd.easy_install(req)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/setuptools/command/easy_install.py", line 659, in easy_install
raise DistutilsError(msg)
distutils.errors.DistutilsError: Could not find suitable distribution for Requirement.parse('numpy>=1.7.0')
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/68/xjx6zfr570199v_w0dhd9y3c0000gn/T/pip-build-v90_t75r/pandas/
I am pretty new to python in general so any help would be greatly appreciated. Thank you

Trying to install pyinstaller, but it shows this meesage:python setup.py egg_info" failed with error code 1

My current verios of linux is 3.19.3 - Arch . I looked up for some answers trying to figure out the problem but I could not get any specific answer for the error I get.
This is the Error
Collecting pyinstaller Using cached PyInstaller-2.1.tar.gz Complete
output from command python setup.py egg_info: Traceback (most recent
call last): File "", line 20, in File
"/tmp/pip-build-wzwxrat3/pyinstaller/setup.py", line 18, in
from PyInstaller import get_version File
"/tmp/pip-build-wzwxrat3/pyinstaller/PyInstaller/init.py", line
32, in from PyInstaller import compat Command "python
setup.py egg_info" failed with error code 1 in
/tmp/pip-build-wzwxrat3/pyinstaller

Does unirest support python3?

Does unirest support python3? I have googled and zero information comes up. Even in the unirest documentation it does not say it is 2.x only which leads me to believe it supports both 3.x and 2.x. However the install fails with 3.4 and succeeds with 2.7. See below.
nkltss:~/dev$ mkvirtualenv mashape -p /usr/bin/python3
Running virtualenv with interpreter /usr/bin/python3
Using base prefix '/usr'
New python executable in mashape/bin/python3
Also creating executable in mashape/bin/python
Installing setuptools, pip...done.
(mashape)nkltss:~/dev$ pip install unirest
Downloading/unpacking unirest
Downloading Unirest-1.1.6.tar.gz
Running setup.py (path:/home/nick/.virtualenvs/mashape/build/unirest/setup.py) egg_info for package unirest
warning: no files found matching '*.txt' under directory 'docs'
Downloading/unpacking poster>=0.8.1 (from unirest)
Downloading poster-0.8.1.tar.gz
Running setup.py (path:/home/nick/.virtualenvs/mashape/build/poster/setup.py) egg_info for package poster
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/home/nick/.virtualenvs/mashape/build/poster/setup.py", line 2, in <module>
import poster
File "/home/nick/.virtualenvs/mashape/build/poster/poster/__init__.py", line 29, in <module>
import poster.streaminghttp
File "/home/nick/.virtualenvs/mashape/build/poster/poster/streaminghttp.py", line 61
print "send:", repr(value)
^
SyntaxError: invalid syntax
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/home/nick/.virtualenvs/mashape/build/poster/setup.py", line 2, in <module>
import poster
File "/home/nick/.virtualenvs/mashape/build/poster/poster/__init__.py", line 29, in <module>
import poster.streaminghttp
File "/home/nick/.virtualenvs/mashape/build/poster/poster/streaminghttp.py", line 61
print "send:", repr(value)
^
SyntaxError: invalid syntax
----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /home/nick/.virtualenvs/mashape/build/poster
Storing debug log for failure in /home/nick/.pip/pip.log
For now I am using 2.7 but I prefer to use 3.x for new projects.
The project is not Python 3 compatible. When the project doesn't explicitly state this (not in the setup.py trove classifiers nor in documentation), you'll have to look at the source code.
There I find:
no use_2to3 use in setup to automatically rewrite code on install
imports for urllib2, a Python 2 only library.
The project depends on the poster library, which is also urllib2 specific.
I'd use the requests library instead. It supports Python 3 out of the box, and apart from asynchronous requests it supports the same feature set (but better as it doesn't have the shortcomings urllib2 brings along). For asynchronous requests, you can add on requests-futures.

Resources