Pipx can not build packages when trying to install eth-brownie - error-handling

I got a following error code while trying to install brownie through pipx (by typing "pipx install eth-brownie)
PS C:\Users\J.M\demos\brownie_simple_storage> pipx install eth-brownie
Fatal error from pip prevented installation. Full pip output in file:
C:\Users\J.M\.local\pipx\logs\cmd_2023-01-08_01.26.02_pip_errors.log
pip failed to build packages:
bitarray
cytoolz
lru-dict
multidict
psutil
regex
yarl
Some possibly relevant errors from pip install:
error: subprocess-exited-with-error
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
Error installing eth-brownie.
PS C:\Users\J.M\demos\brownie_simple_storage>
I have all the prerequirements (node.js, recent python version, ganache cli, npm all successfully installed), I really have no idea why it can't build those packages.

Related

Could not import torch_geometric, it says "undefined symbol: _ZN5torch3jit17parseSchemaOrNameERKSs"

I am trying to find a solution to the error:
OSError: /opt/conda/lib/python3.7/site-packages/torch_sparse/_version_cuda.so: undefined symbol: _ZN5torch3jit17parseSchemaOrNameERKSs.
arising from the statement from torch_geometric.data import Data in Kaggle notebook.
There are solutions in github and stackoverflow, but none are working.
-- "nvcc --version" shows
"nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2020 NVIDIA Corporation
Built on Wed_Jul_22_19:09:09_PDT_2020
Cuda compilation tools, release 11.0, V11.0.221
Build cuda_11.0_bu.TC445_37.28845127_0"
I tried to install torch-geometric by
!conda install pyg -c pyg -c conda-forge
!pip install pyg-lib torch-scatter torch-sparse torch-cluster torch-spline-conv torch-geometric -f https://data.pyg.org/whl/torch-1.12.0+cu113.html
from here.
The first statement took more than 1 hour so I moved to the second, which installed it. But the error didn't go.
It is running with out any error in colab.
This issue is mentionned at https://pytorch-geometric.readthedocs.io/en/latest/notes/installation.html :
undefined symbol: make_function_schema: This issue signals (1) a version conflict
between your installed PyTorch version and the ${TORCH} version
specified to install the extension packages, or (2) a version conflict
between the installed CUDA version of PyTorch and the ${CUDA} version
specified to install the extension packages. Please verify that your
PyTorch version and its CUDA version match with your installation
command:
python -c "import torch; print(torch.__version__)"
python -c "import torch; print(torch.version.cuda)"
nvcc --version
For re-installation, ensure that you do not run into any caching issues by
using the pip --force-reinstall --no-cache-dir flags. In addition, the
pip --verbose option may help to track down any issues during
installation. If you still do not find any success in installation,
please try to install the extension packages from source.
So, I would try these commands, and re-install all or part of the packages into a fresh environment.

How to install p4python on Cygwin64

Trying to install p4python on Cygwin fails with
$pip install p4python
[... logs ...]
File "/tmp/pip-install-6mn3hyn3/p4python_9e95a104710b449a90a68bc227a2ee69/setup.py", line 292, in run
raise Exception("Parameter --ssl is needed")
Exception: Parameter --ssl is needed
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> p4python
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
I am using Cygwin64 on Windows 10, specifically:
$ pip --version
pip 22.3 from /usr/local/lib/python3.9/site-packages/pip (python 3.9)
$ python --version
Python 3.9.10
$ which python
/usr/bin/python
I tried using the wheel files from PyPi but there is no compatible platform for Cygwin.
How can I work around this ssl dependency to install the module?
I have included libssl while installing Cygwin.
Try
python -m pip install p4python

Unable to install tensorflow graphics

I am trying to use Levenberg optimizer using the tfg.math.optimizer.levenberg_marquardt.minimize. I am following the installation instructions from https://www.tensorflow.org/graphics/install
On using: pip install --upgrade tensorflow-graphics, I get the following error:
ERROR: Failed building wheel for OpenEXR
Running setup.py clean for OpenEXR
Failed to build OpenEXR
Installing collected packages: OpenEXR, tensorflow-graphics
Running setup.py install for OpenEXR ... error
ERROR: Command errored out with exit status 1:
Could you please help me with this?
Thanks
I'm on Linux and I needed to install libopenexr-dev with apt:
sudo apt install libopenexr-dev
After this pip install tensorflow-graphics run without problems.

Error installing library of Scrapy in PyCharm

I can install other packages, but can't install Scrapy. I get the following errors:
warning: build_py: byte-compiling is disabled, skipping.
running build_ext
building 'lxml.etree' extension
error: Microsoft Visual C++ 10.0 is required (Unable to find vcvarsall.bat).
However, C++ is installed, which I installed numerous of times. I have x86 and 64 bit installations (not sure if it's 10.0) but I have 2013-2017 versions installed.
Please upgrade your pip by following command.
python -m pip install --upgrade pip
Then install Scrapy by following command.
pip install Scrapy
download latest twisted package and install with pip.
https://www.lfd.uci.edu/~gohlke/pythonlibs/#twisted
after that install scrapy
In my case, I found that pywin32 was not installed...
So I did
download the latest Twisted package from https://www.lfd.uci.edu/~gohlke/pythonlibs/#twisted
You want to use the amd64 if you have Windows 64 (regardless if it's an Intel processor or not)
You can use any browser for the download and copy/paste the file into the project folder of your current pycharm project.
Then in pycharm type this:
pip install Twisted-20.3.0-cp39-cp39-win_amd64.whl
(assuming that your package was Twisted-20.3.0-cp39-cp39-win_amd64.whl)
then proceed with:
pip install Scrapy

Win10 scrapy install

I have python install as well as c++ complier. When I run "pip install scrapy" from the command line it starts to install but I get a couple errors surrounding the libxml and libxslt.
error: 'xslt-config' is not recognized...
cannot open libxml/xmlversion.h no such file or directory
compile failed windows C++ for python failed with exit status 2
could not find function xmlCheckVersion
is libxml installed.....
Use this:
set STATICBUILD=true && pip install lxml
Find the documentation here