Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

CalledProcessError while installing a Package: Returned non-zero exit status 1.

harshal98
8 - Asteroid

Hi Team,

Had tried the commands below to reset the Python Tool.

But my python/packages are not working from that moment.

Getting kernel error first and then the CalledProcessError while executing python packages in a Macro.

Exact Error:

 

CalledProcessError: Command '['c:\\program files\\alteryx\\bin\\miniconda3\\envs\\designerbasetools_venv\\python.exe', '-I', '-m', 'pip', 'install', 'google-cloud-bigquery']' returned non-zero exit status 1.

 

Please help me how do i get to my previous environment again to execute python in macros properly.

Have given the commands below and below that the Entire Logs to the Error i am receiving now.

 

Link:

https://community.alteryx.com/t5/Alteryx-Designer-Knowledge-Base/How-to-reset-the-Python-tool-to-its...

REM Remove existing folder
rmdir /S /Q "%ALTERYXDIR%\bin\Miniconda3\envs\JupyterTool_vEnv"

REM Go to Alteryx Miniconda3 folder
cd "%ALTERYXDIR%\bin\Miniconda3"

REM Activate base environment
call condabin\activate.bat

REM Create Python environment (without dependencies)
conda create -y -n JupyterTool_vEnv python=3.6.8 --offline --no-deps

REM Activate Python environment
conda activate JupyterTool_vEnv

REM Install pip and wheel in
conda install -y -n JupyterTool_vEnv pip wheel --offline

REM Install all packages
pip.exe install --verbose --no-index --no-deps --no-cache-dir --force-reinstall --find-links="%ALTERYXDIR%\bin\Miniconda3\Common_Config\wheels" -r "%ALTERYXDIR%\bin\PythonConda\requirements-jupyter-tool.txt"

REM Leave Python environments (x 2)
conda deactivate
conda deactivate

 

 

Requirement already satisfied: google-cloud-bigquery in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (2.17.0)
Requirement already satisfied: google-cloud-core<2.0dev,>=1.4.1 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-cloud-bigquery) (1.6.0)
Collecting proto-plus>=1.10.0
  Using cached proto_plus-1.18.1-py3-none-any.whl (42 kB)
Requirement already satisfied: google-resumable-media<2.0dev,>=0.6.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-cloud-bigquery) (1.3.0)
Requirement already satisfied: packaging>=14.3 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-cloud-bigquery) (20.9)
Requirement already satisfied: requests<3.0.0dev,>=2.18.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-cloud-bigquery) (2.22.0)
Collecting protobuf>=3.12.0
  Using cached protobuf-3.17.1-py2.py3-none-any.whl (173 kB)
Requirement already satisfied: google-api-core[grpc]<2.0.0dev,>=1.23.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-cloud-bigquery) (1.28.0)
Requirement already satisfied: six>=1.12.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-cloud-core<2.0dev,>=1.4.1->google-cloud-bigquery) (1.12.0)
Requirement already satisfied: google-auth<2.0dev,>=1.24.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-cloud-core<2.0dev,>=1.4.1->google-cloud-bigquery) (1.30.1)
Requirement already satisfied: google-crc32c<2.0dev,>=1.0; python_version >= "3.5" in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-resumable-media<2.0dev,>=0.6.0->google-cloud-bigquery) (1.1.2)
Requirement already satisfied: pyparsing>=2.0.2 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from packaging>=14.3->google-cloud-bigquery) (2.4.0)
Requirement already satisfied: certifi>=2017.4.17 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-cloud-bigquery) (2020.12.5)
Requirement already satisfied: chardet<3.1.0,>=3.0.2 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-cloud-bigquery) (3.0.4)
Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-cloud-bigquery) (1.25.10)
Requirement already satisfied: idna<2.9,>=2.5 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-cloud-bigquery) (2.8)
Requirement already satisfied: setuptools>=40.3.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.23.0->google-cloud-bigquery) (49.6.0.post20210108)
Requirement already satisfied: pytz in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.23.0->google-cloud-bigquery) (2019.1)
Requirement already satisfied: googleapis-common-protos<2.0dev,>=1.6.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.23.0->google-cloud-bigquery) (1.53.0)
Requirement already satisfied: grpcio<2.0dev,>=1.29.0; extra == "grpc" in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.23.0->google-cloud-bigquery) (1.38.0)
Collecting pyasn1-modules>=0.2.1
  Using cached pyasn1_modules-0.2.8-py2.py3-none-any.whl (155 kB)
Collecting cachetools<5.0,>=2.0.0
  Using cached cachetools-4.2.2-py3-none-any.whl (11 kB)
Collecting rsa<5,>=3.1.4; python_version >= "3.6"
  Using cached rsa-4.7.2-py3-none-any.whl (34 kB)
Requirement already satisfied: cffi>=1.0.0 in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from google-crc32c<2.0dev,>=1.0; python_version >= "3.5"->google-resumable-media<2.0dev,>=0.6.0->google-cloud-bigquery) (1.14.1)
Collecting pyasn1<0.5.0,>=0.4.6
  Using cached pyasn1-0.4.8-py2.py3-none-any.whl (77 kB)
Requirement already satisfied: pycparser in c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages (from cffi>=1.0.0->google-crc32c<2.0dev,>=1.0; python_version >= "3.5"->google-resumable-media<2.0dev,>=0.6.0->google-cloud-bigquery) (2.20)
Installing collected packages: protobuf, proto-plus, pyasn1, pyasn1-modules, cachetools, rsa
ERROR: Could not install packages due to an EnvironmentError: [Errno 13] Permission denied: 'c:\\program files\\alteryx\\bin\\miniconda3\\envs\\designerbasetools_venv\\Lib\\site-packages\\protobuf-3.17.1-nspkg.pth'
Consider using the `--user` option or check the permissions.
 
 
ERROR I AM RECIEVING NOW:
---------------------------------------------------------------------------
CalledProcessError                        Traceback (most recent call last)
<ipython-input-5-5b633b475d1b> in <module>
----> 1 Package.installPackages("google-cloud-bigquery")

c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages\ayx\Package.py in installPackages(package, install_type, debug)
    200     print(pip_install_result["msg"])
    201     if not pip_install_result["success"]:
--> 202         raise pip_install_result["err"]

c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\site-packages\ayx\Utils.py in runSubprocess(args_list, debug)
    118 
    119     try:
--> 120         result = subprocess.check_output(args_list, stderr=subprocess.STDOUT)
    121         if debug:
    122             print("[Subprocess success!]")

c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\subprocess.py in check_output(timeout, *popenargs, **kwargs)
    409         kwargs['input'] = '' if kwargs.get('universal_newlines', False) else b''
    410 
--> 411     return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,    412                **kwargs).stdout
    413 

c:\program files\alteryx\bin\miniconda3\envs\designerbasetools_venv\lib\subprocess.py in run(input, capture_output, timeout, check, *popenargs, **kwargs)
    510         retcode = process.poll()
    511         if check and retcode:
--> 512             raise CalledProcessError(retcode, process.args,    513                                      output=stdout, stderr=stderr)
    514     return CompletedProcess(process.args, retcode, stdout, stderr)

CalledProcessError: Command '['c:\\program files\\alteryx\\bin\\miniconda3\\envs\\designerbasetools_venv\\python.exe', '-I', '-m', 'pip', 'install', 'google-cloud-bigquery']' returned non-zero exit status 1.
1 REPLY 1
shreyanshrathod
11 - Bolide

Hi @harshal98 ,

 

the second error is with regards to Administrator permission.

Please run the Alteryx Designer with "Run as administrator" option and then try running your macro.

 

Regards,

Shreyansh Rathod

Labels
Top Solution Authors