Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Fail to install Camelot Package for PDF tabular data parsing

stanleychen
6 - Meteoroid

When i tried to run the following scripts, an error was noted as follows. How should i do?

 

#Install Camelot Package for PDF tabular data parsing
Alteryx.installPackages("camelot-py[all]")

 

Collecting camelot-py[all]
  Using cached https://files.pythonhosted.org/packages/fa/72/f51373aa968c3f81823402d04978babe68d2d020c9b3d5c69eae87...
Requirement already satisfied: chardet>=3.0.4 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from camelot-py[all])
Requirement already satisfied: click>=6.7 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from camelot-py[all])
Requirement already satisfied: numpy>=1.13.3 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from camelot-py[all])
Collecting openpyxl>=2.5.8 (from camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/ba/06/b899c8867518df19e242d8cbc82d4ba210f5ffbeebb7704c695e68...
Requirement already satisfied: pandas>=0.23.4 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from camelot-py[all])
Collecting pdfminer.six>=20170720 (from camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/8a/fd/6e8746e6965d1a7ea8e97253e3d79e625da5547e8f376f88de5d02...
Collecting PyPDF2>=1.26.0 (from camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/b4/01/68fcc0d43daf4c6bdbc6b33cc3f77bda531c86b174cac56ef0ffdb...
Collecting opencv-python>=3.4.2.17 (from camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/dc/54/a6b7727c67d4e14194549a9e1a1acd7902ebae2f4a688d84b658ae...
Requirement already satisfied: matplotlib>=2.2.3 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from camelot-py[all])
Collecting jdcal (from openpyxl>=2.5.8->camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/f0/da/572cbc0bc582390480bbd7c4e93d14dc46079778ed915b505dc494...
Collecting et_xmlfile (from openpyxl>=2.5.8->camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/22/28/a99c42aea746e18382ad9fb36f64c1c1f04216f41797f2f0fa567d...
Requirement already satisfied: python-dateutil>=2.5.0 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from pandas>=0.23.4->camelot-py[all])
Requirement already satisfied: pytz>=2011k in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from pandas>=0.23.4->camelot-py[all])
Collecting pycryptodome (from pdfminer.six>=20170720->camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/9a/cb/8e60e63a298ff552874eeebffa6aa0400ce0f0191c15c103020ad1...
Collecting sortedcontainers (from pdfminer.six>=20170720->camelot-py[all])
  Using cached https://files.pythonhosted.org/packages/13/f3/cf85f7c3a2dbd1a515d51e1f1676d971abe41bba6f4ab5443240d9...
Requirement already satisfied: six in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from pdfminer.six>=20170720->camelot-py[all])
Requirement already satisfied: kiwisolver>=1.0.1 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from matplotlib>=2.2.3->camelot-py[all])
Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from matplotlib>=2.2.3->camelot-py[all])
Requirement already satisfied: cycler>=0.10 in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from matplotlib>=2.2.3->camelot-py[all])
Requirement already satisfied: setuptools in c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages (from kiwisolver>=1.0.1->matplotlib>=2.2.3->camelot-py[all])
Installing collected packages: jdcal, et-xmlfile, openpyxl, pycryptodome, sortedcontainers, pdfminer.six, PyPDF2, opencv-python, camelot-py
Exception:
Traceback (most recent call last):
  File "c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\pip\basecommand.py", line 215, in main
    status = self.run(options, args)
  File "c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\pip\commands\install.py", line 342, in run
    prefix=options.prefix_path,
  File "c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\pip\req\req_set.py", line 784, in install
    **kwargs
  File "c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\pip\req\req_install.py", line 851, in install
    self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
  File "c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\pip\req\req_install.py", line 1064, in move_wheel_files
    isolated=self.isolated,
  File "c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\pip\wheel.py", line 345, in move_wheel_files
    clobber(source, lib_dir, True)
  File "c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\pip\wheel.py", line 323, in clobber
    shutil.copyfile(srcfile, destfile)
  File "C:\Program Files\Alteryx\bin\Miniconda3\lib\shutil.py", line 115, in copyfile
    with open(dst, 'wb') as fdst:
PermissionError: [Errno 13] Permission denied: 'c:\\program files\\alteryx\\bin\\miniconda3\\pythontool_venv\\Lib\\site-packages\\jdcal.py'
 
---------------------------------------------------------------------------
CalledProcessError                        Traceback (most recent call last)
<ipython-input-2-69bca24d80e3> in <module>
      1 #Install Camelot Package for PDF tabular data parsing
----> 2 Alteryx.installPackages("camelot-py[all]")

c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\ayx\export.py in installPackage(package, install_type, debug, **kwargs)
    138     This function will install a package or list of packages into the virtual environment used by the Python tool. If using an admin installation of Alteryx, you must run Alteryx as administrator in order to use this function and install packages.
    139     """
--> 140     __installPackages__(package, install_type=install_type, debug=debug, **kwargs)
    141 
    142 

c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\ayx\Package.py in installPackages(package, install_type, debug)
    112     print(pip_install_result['msg'])
    113     if not pip_install_result['success']:
--> 114         raise pip_install_result['err']

c:\program files\alteryx\bin\miniconda3\pythontool_venv\lib\site-packages\ayx\Utils.py in runSubprocess(args_list, debug)
     48 
     49     try:
---> 50         result = subprocess.check_output(args_list, stderr=subprocess.STDOUT)
     51         if debug:
     52             print("[Subprocess success!]")

C:\Program Files\Alteryx\bin\Miniconda3\lib\subprocess.py in check_output(timeout, *popenargs, **kwargs)
    334 
    335     return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
--> 336                **kwargs).stdout    337 
    338 

C:\Program Files\Alteryx\bin\Miniconda3\lib\subprocess.py in run(input, timeout, check, *popenargs, **kwargs)
    416         if check and retcode:
    417             raise CalledProcessError(retcode, process.args,
--> 418                                      output=stdout, stderr=stderr)    419     return CompletedProcess(process.args, retcode, stdout, stderr)
    420 

CalledProcessError: Command '['c:\\program files\\alteryx\\bin\\miniconda3\\pythontool_venv\\scripts\\python.exe', '-m', 'pip', 'install', 'camelot-py[all]']' returned non-zero exit status 2.

 

1 REPLY 1
PaulN
Alteryx Alumni (Retired)

Hi @stanleychen,

 

Thank you for posting!

 

Could you please try to run Alteryx Designer as administrator (right click and "Run as administrator") as Python modules are installed under Alteryx folder.

Please use https://community.alteryx.com/t5/Alteryx-Knowledge-Base/How-To-Use-Alteryx-installPackages-in-Python... for reference.

 

Best,

 

Paul Noirel

Sr Customer Support Engineer, Alteryx

 

Labels