pdfsak icon indicating copy to clipboard operation
pdfsak copied to clipboard

getpagecount subprocess error

Open olliwa-git opened this issue 3 years ago • 1 comments

hi, with python 39 or 310 on win10 I got the following issue I dont find my error during installation

MikTex installed

pdfsak.bat -if examples\input\article1.pdf

Traceback (most recent call last): File "c:\Users\Olivier\pdfsak\pdfsak", line 1498, in main(sys.argv[1:]) File "c:\Users\Olivier\pdfsak\pdfsak", line 1493, in main run(args) File "c:\Users\Olivier\pdfsak\pdfsak", line 777, in run page_count = getPageCount(f) File "c:\Users\Olivier\pdfsak\pdfsak", line 103, in getPageCount res = subprocess.run(cmd, capture_output=True, text=True) File "C:\Users\Olivier\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 505, in run with Popen(*popenargs, **kwargs) as process: File "C:\Users\Olivier\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 951, in init self._execute_child(args, executable, preexec_fn, close_fds, File "C:\Users\Olivier\AppData\Local\Programs\Python\Python39\lib\subprocess.py", line 1420, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] Le fichier spécifié est introuvable

Python: 3.9.6 (tags/v3.9.6:db3ff76, Jun 28 2021, 15:26:21) [MSC v.1929 64 bit (AMD64)] PDFsak version: 1.3.0 pdflatex OK ( 4.10 >= 1.40.17): MiKTeX-pdfTeX 4.10 (MiKTeX 22.3) Checking LaTeX package 'grffile' OK: 2019/11/11 v2.1 Checking LaTeX package 'pdfpages' OK: 2022/05/22 v0.5v Checking LaTeX package 'lastpage' OK: 2021/09/03 v1.2n Checking LaTeX package 'fancyhdr' OK: 2022/05/18 v4.0.3 Checking LaTeX package 'geometry' OK: 2020/01/02 v5.9 Checking LaTeX package 'calc' OK: 2017/05/25 v4.3 Checking LaTeX package 'graphicx' OK: 2021/09/16 v1.2d Checking LaTeX package 'transparent' OK: 2019/11/29 v1.4 Checking LaTeX package 'xparse' OK: 2022-06-07 L3 Checking LaTeX package 'letltxmacro' OK: 2019/12/03 v1.6 Checking LaTeX package 'changepage' OK: 2009/10/20 v1.0c Checking LaTeX package 'textpos' OK: 2020/09/26 v1.10 ImageMagick OK: Version: ImageMagick 7.1.0-39 Q16-HDRI x64 21a5642:20220620 Potrace NOT FOUND mkbitmap NOT FOUND Ghostscript OK: 9.56.1

olliwa-git avatar Jun 25 '22 10:06 olliwa-git

Hello,

this is very strange.

It looks like it doesn't find GhostScript in the first case, while it does find it in the second case (see "Ghostscript OK: 9.56.1").

Are you sure those two commands are run from the same exact environment?

What's the output of gswin64c --version from the command line?

raffaem avatar Jul 17 '22 04:07 raffaem

Closing as the requested information has not been provided.

Please re-open it if it still happens.

raffaem avatar Aug 31 '22 08:08 raffaem

Sorry, I did not have time to test your suggestion, Thank you very much for your feedback

olliwa-git avatar Aug 31 '22 09:08 olliwa-git