ksharindam / gospel-pdf-viewer Goto Github PK
View Code? Open in Web Editor NEWPoppler based fast pdf viewer written in PyQt5
License: GNU General Public License v3.0
Poppler based fast pdf viewer written in PyQt5
License: GNU General Public License v3.0
HI there, Thanks for your great work.
I want to run the tool on Windows 10. But while installing dependencies, python3-poppler-qt5 I got in trouble. I have installed using pip with command pip install python-poppler-qt5
but after waiting for a long time, I got an error.
pip install python-poppler-qt5
Collecting python-poppler-qt5pip install python-poppler-qt5
Collecting python-poppler-qt5
Using cached python-poppler-qt5-21.3.0.tar.gz (28 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [30 lines of output]
Querying qmake about your Qt installation...
'pkg-config' is not recognized as an internal or external command,
operable program or batch file.
pyproject.toml: line 5: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
Traceback (most recent call last):
File "c:\users\shahzeb\anaconda3\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
main()
File "c:\users\shahzeb\anaconda3\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "c:\users\shahzeb\anaconda3\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\api.py", line 46, in build_wheel
project = AbstractProject.bootstrap('wheel',
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\abstract_project.py", line 87, in bootstrap
project.setup(pyproject, tool, tool_description)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\project.py", line 587, in setup
self.apply_user_defaults(tool)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\pyqtbuild\project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\project.py", line 240, in apply_user_defaults
bindings.apply_user_defaults(tool)
File "project.py", line 50, in apply_user_defaults
cflags = self.run_pkg_config('--cflags-only-I').split()
File "project.py", line 43, in run_pkg_config
output = subprocess.check_output(
File "c:\users\shahzeb\anaconda3\lib\subprocess.py", line 415, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
File "c:\users\shahzeb\anaconda3\lib\subprocess.py", line 516, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['pkg-config', '--cflags-only-I', 'poppler-qt5']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
Using cached python-poppler-qt5-21.3.0.tar.gz (28 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [30 lines of output]
Querying qmake about your Qt installation...
'pkg-config' is not recognized as an internal or external command,
operable program or batch file.
pyproject.toml: line 5: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
Traceback (most recent call last):
File "c:\users\shahzeb\anaconda3\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
main()
File "c:\users\shahzeb\anaconda3\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "c:\users\shahzeb\anaconda3\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\api.py", line 46, in build_wheel
project = AbstractProject.bootstrap('wheel',
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\abstract_project.py", line 87, in bootstrap
project.setup(pyproject, tool, tool_description)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\project.py", line 587, in setup
self.apply_user_defaults(tool)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\pyqtbuild\project.py", line 70, in apply_user_defaults
super().apply_user_defaults(tool)
File "C:\Users\Shahzeb\AppData\Local\Temp\pip-build-env-0_pbo7np\overlay\Lib\site-packages\sipbuild\project.py", line 240, in apply_user_defaults
bindings.apply_user_defaults(tool)
File "project.py", line 50, in apply_user_defaults
cflags = self.run_pkg_config('--cflags-only-I').split()
File "project.py", line 43, in run_pkg_config
output = subprocess.check_output(
File "c:\users\shahzeb\anaconda3\lib\subprocess.py", line 415, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
File "c:\users\shahzeb\anaconda3\lib\subprocess.py", line 516, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['pkg-config', '--cflags-only-I', 'poppler-qt5']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
I have also tried different other options mentioned in the official repo of python3-poppler-qt5 but no success.
Hi, first, thanks for your great work. I have installed the tool, and it is working fine on my Ubuntu 20.04. I import this tool into my main GUI to view PDFs; however, when I transfer the code to my new system (the same OS, Ubuntu 20.04), the code displays the content list but does not display the pdf. On cmd, I am getting the following message:
Traceback (most recent call last): File "/home/sharoze/WORK/pdfToImage/GUI_Work/newGUI/gospel-pdf-viewer/gospel_pdf/cost_Estimate_Main.py", line 491, in openFile self.loadPDFfile(filename) File "/home/sharoze/WORK/pdfToImage/GUI_Work/newGUI/gospel-pdf-viewer/gospel_pdf/cost_Estimate_Main.py", line 414, in loadPDFfile if collapseUser(self.filename) in self.history_filenames: TypeError: argument of type 'NoneType' is not iterable
Also, one thing more: even though I have selected multiple pdf files, recent history is not showing on my new system. Previous systems show history as well. Any suggestions here?
One more test
On my previous system, the tool was working fine after clearing the recent history by pressing the button. I am getting this error.
sudo gospel-pdf
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
Traceback (most recent call last):
File "/usr/local/bin/gospel-pdf", line 8, in <module>
sys.exit(main())
File "/usr/local/lib/python3.8/dist-packages/gospel_pdf/main.py", line 926, in main
win = Window()
File "/usr/local/lib/python3.8/dist-packages/gospel_pdf/main.py", line 221, in __init__
self.addRecentFiles()
File "/usr/local/lib/python3.8/dist-packages/gospel_pdf/main.py", line 231, in addRecentFiles
for each in self.recent_files:
TypeError: 'NoneType' object is not iterable
QThread: Destroyed while thread is still running
Aborted
Now in both systems, its not working.
I have this error
File "gospel-pdf-viewer/gospel_pdf/main.py", line 238, in __init__
width = int(self.settings.value("WindowWidth"))
TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType'
Hi, I'd love to use your viewer. However, for me it is a deal breaker that I cannot copy the text from the PDF.
Do you have any quick fix for this issue?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.