Closed bweisberg closed 4 years ago
Actually there are some errors in the Install Python Dependencies task:
Collecting pip
Downloading pip-20.2-py2.py3-none-any.whl (1.5 MB)
Installing collected packages: pip
Attempting uninstall: pip
Found existing installation: pip 20.1.1
Uninstalling pip-20.1.1:
Successfully uninstalled pip-20.1.1
Successfully installed pip-20.2
Requirement already satisfied: setuptools in /opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages (from -r requirements.txt (line 1)) (47.1.0)
Collecting wheel
Downloading wheel-0.34.2-py2.py3-none-any.whl (26 kB)
Collecting pyspark==2.4.5
Downloading pyspark-2.4.5.tar.gz (217.8 MB)
ERROR: Command errored out with exit status 1:
command: /opt/hostedtoolcache/Python/3.7.8/x64/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-npi3l0t3/pyspark/setup.py'"'"'; __file__='"'"'/tmp/pip-install-npi3l0t3/pyspark/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-amyoot_r
cwd: /tmp/pip-install-npi3l0t3/pyspark/
Complete output (47 lines):
Could not import pypandoc - required to package PySpark
WARNING: The wheel package is not available.
ERROR: Command errored out with exit status 1:
command: /opt/hostedtoolcache/Python/3.7.8/x64/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-wheel-nmiuu3b3/pypandoc/setup.py'"'"'; __file__='"'"'/tmp/pip-wheel-nmiuu3b3/pypandoc/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-awpu9kq3
cwd: /tmp/pip-wheel-nmiuu3b3/pypandoc/
Complete output (8 lines):
no pandoc found, building platform unspecific wheel...
use 'python setup.py download_pandoc' to download pandoc.
usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: setup.py --help [cmd1 cmd2 ...]
or: setup.py --help-commands
or: setup.py cmd --help
error: invalid command 'bdist_wheel'
----------------------------------------
ERROR: Failed building wheel for pypandoc
ERROR: Failed to build one or more wheels
Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/setuptools/installer.py", line 128, in fetch_build_egg
Using a self-hosted agent with Ubuntu 18.04 and Python 3.7 I got further along. I had to add an pip install --ignore-installed
flag, otherwise pyyaml 5.1 was not being installed.
@bweisberg I had a very similar issue, but on Github Actions. I changed how the requirements/dependencies are installed in the workflow file, and it solved the issue. What I changed was:
name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade setuptools
python -m pip install --upgrade pandoc
python -m pip install --upgrade pypandoc
pip install -r requirements.txt
Hope this helps !
@kiranvasudev Thanks! I have updated spark version to 3.0.0 and this has fixed this issue.
how did you resolved this error?
Actually there are some errors in the Install Python Dependencies task:
Collecting pip Downloading pip-20.2-py2.py3-none-any.whl (1.5 MB) Installing collected packages: pip Attempting uninstall: pip Found existing installation: pip 20.1.1 Uninstalling pip-20.1.1: Successfully uninstalled pip-20.1.1 Successfully installed pip-20.2 Requirement already satisfied: setuptools in /opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages (from -r requirements.txt (line 1)) (47.1.0) Collecting wheel Downloading wheel-0.34.2-py2.py3-none-any.whl (26 kB) Collecting pyspark==2.4.5 Downloading pyspark-2.4.5.tar.gz (217.8 MB) ERROR: Command errored out with exit status 1: command: /opt/hostedtoolcache/Python/3.7.8/x64/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-npi3l0t3/pyspark/setup.py'"'"'; __file__='"'"'/tmp/pip-install-npi3l0t3/pyspark/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-amyoot_r cwd: /tmp/pip-install-npi3l0t3/pyspark/ Complete output (47 lines): Could not import pypandoc - required to package PySpark WARNING: The wheel package is not available. ERROR: Command errored out with exit status 1: command: /opt/hostedtoolcache/Python/3.7.8/x64/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-wheel-nmiuu3b3/pypandoc/setup.py'"'"'; __file__='"'"'/tmp/pip-wheel-nmiuu3b3/pypandoc/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-awpu9kq3 cwd: /tmp/pip-wheel-nmiuu3b3/pypandoc/ Complete output (8 lines): no pandoc found, building platform unspecific wheel... use 'python setup.py download_pandoc' to download pandoc. usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: setup.py --help [cmd1 cmd2 ...] or: setup.py --help-commands or: setup.py cmd --help error: invalid command 'bdist_wheel' ---------------------------------------- ERROR: Failed building wheel for pypandoc ERROR: Failed to build one or more wheels Traceback (most recent call last): File "/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/setuptools/installer.py", line 128, in fetch_build_egg
how you resolve this?
I'm running this pipeline in Azure DevOps. The Build Artifact task exits with code '1' and the error details
The earlier task Install Python Dependencies was succesful and appears to have installed wheel.