xilopaint Posted September 6, 2019 Author Share Posted September 6, 2019 (edited) 6 hours ago, evanfuchs said: Merge Error: "Cannot merge a malformed PDF file" I am suddenly getting this error when I attempt to merge PDF files. (v2.16) Any ideas? Unfortunately, I can't reproduce the issue without the offending PDF files. If you still want me to take a look into it you can send me the files via PM. Edited September 6, 2019 by xilopaint Link to comment
daerias Posted February 22, 2020 Share Posted February 22, 2020 could you update this workflow for the newest Alfred 4 please? It doesn't show up PDF Tools in Alfred if I type "Optimize" etc. Thanks Link to comment
deanishe Posted February 22, 2020 Share Posted February 22, 2020 15 minutes ago, daerias said: could you update this workflow for the newest Alfred 4 please? It doesn't show up PDF Tools in Alfred if I type "Optimize" etc. Thanks The workflow works fine with Alfred 4. If you're having a problem, please follow the instructions on providing a useful report: Link to comment
xilopaint Posted February 22, 2020 Author Share Posted February 22, 2020 4 hours ago, daerias said: could you update this workflow for the newest Alfred 4 please? It doesn't show up PDF Tools in Alfred if I type "Optimize" etc. Thanks Optimize is not a keyword, it's a file action. In the following link you can see how to perform a file action: https://www.alfredapp.com/blog/tips-and-tricks/file-actions-from-alfred-or-finder/ Link to comment
borzov Posted April 14, 2020 Share Posted April 14, 2020 This is a great workflow! Thank you very much for development and support. I have not yet been able to take full advantage of its features due security limitations in macOS. For example, the system won't let you run the "k2pdfopt" script because it is "from an unknown developer". Ughhh... How can I solve this problem? Link to comment
bivalvegruff Posted April 18, 2020 Share Posted April 18, 2020 On 4/14/2020 at 8:38 AM, borzov said: This is a great workflow! Thank you very much for development and support. I have not yet been able to take full advantage of its features due security limitations in macOS. For example, the system won't let you run the "k2pdfopt" script because it is "from an unknown developer". Ughhh... How can I solve this problem? After trying to run the script, go into system settings – integrity (or something like that). There should be a box offering you to run the script anyway. Press that and then try to run the script again. I had to fiddle around a bit with this with some workflows before I got it to work. borzov 1 Link to comment
borzov Posted April 18, 2020 Share Posted April 18, 2020 9 hours ago, bivalvegruff said: After trying to run the script, go into system settings – integrity (or something like that). There should be a box offering you to run the script anyway. Press that and then try to run the script again. I had to fiddle around a bit with this with some workflows before I got it to work. That's great advice, thank you. I did it! Link to comment
RCL Posted October 4, 2021 Share Posted October 4, 2021 (edited) Hi All, Hope all is well. I have been trying to merge PDFs with the merge command on my M1 MBP running the latest best of OS Monterey but keep have the following error. Does anyone know how to fix this? Thank you. -------------------- [01:19:43.338] Alfred PDF Tools[Keyword] Processing complete [01:19:43.341] Alfred PDF Tools[Keyword] Passing output 'test' to Run Script [01:19:43.547] ERROR: Alfred PDF Tools[Run Script] . 01:19:43 workflow.py:2055 DEBUG ---------- Alfred PDF Tools (2.16.0) ---------- 01:19:43 workflow.py:1462 DEBUG reading settings from /Users/r/Library/Application Support/Alfred/Workflow Data/com.xilopaint.alfredapp.pdftools/settings.json 01:19:43 workflow.py:2339 DEBUG update check not due 01:19:43 workflow.py:2074 ERROR 'abs_path' Traceback (most recent call last): File "/Users/r/OneDrive/Alfred.alfredpreferences/workflows/user.workflow.5F1A3B2C-C394-4B63-9DF9-6AE0DF8B5CE4/workflow/workflow.py", line 2067, in run func(self) File "alfred_pdf_tools.py", line 780, in main abs_path = os.environ['abs_path'] File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/UserDict.py", line 40, in __getitem__ raise KeyError(key) KeyError: 'abs_path' 01:19:43 workflow.py:2097 DEBUG ---------- finished in 0.020s ---------- Edited October 18, 2021 by RCL Link to comment
TheThunderChimp Posted February 10, 2022 Share Posted February 10, 2022 On 9/6/2019 at 5:32 PM, xilopaint said: Unfortunately, I can't reproduce the issue without the offending PDF files. If you still want me to take a look into it you can send me the files via PM. I'm having the same issue. I'll send you the offending files by PM and you could look into the issue if you have the time. Thanks for making this workflow, I'm looking forward to using it. Link to comment
AlvinFoo Posted February 13, 2022 Share Posted February 13, 2022 Hi, would you be able to add "Recognise Text" in the scan & OCR capability? Link to comment
xilopaint Posted March 16, 2022 Author Share Posted March 16, 2022 (edited) On 2/10/2022 at 6:22 PM, TheThunderChimp said: I'm having the same issue. I'll send you the offending files by PM and you could look into the issue if you have the time. Thanks for making this workflow, I'm looking forward to using it. Sorry for the late response. I have fully rewritten this workflow using Python 3 and pikepdf (a more modern library than Pypdf). Your files work perfectly in this new unreleased version. The problem is I can't release it until the system Python gets upgraded to 3.10 which can take a long time. I don't know why pikepdf cannot be imported by Python 3.8 and 3.9. If someone gives me some light on what changed on Python 3.10 about imports maybe I can release the new version before the upgrade. Edited March 16, 2022 by xilopaint Link to comment
vitor Posted March 16, 2022 Share Posted March 16, 2022 6 hours ago, xilopaint said: The problem is I can't release it until the system Python gets upgraded to 3.10 There is no system Python. /usr/bin/python3 is a shim which gets you to install the Developer Tools which ship with that older version. Don’t wait for it to be updated, because there’s no clue when or if that will happen. If you really need a higher Python version, recommend installing via Homebrew and set export PATH="/opt/homebrew/bin:/usr/local/bin:${PATH}". Other Python 3 developers do it, and it’s better than not having access to the Workflow. Link to comment
evanfuchs Posted March 16, 2022 Share Posted March 16, 2022 These last two replies are over my head, but I'd sure like to be able to continue to use this workflow Link to comment
xilopaint Posted March 17, 2022 Author Share Posted March 17, 2022 (edited) On 3/16/2022 at 1:29 PM, xilopaint said: The problem is I can't release it until the system Python gets upgraded to 3.10 which can take a long time. I don't know why pikepdf cannot be imported by Python 3.8 and 3.9. If someone gives me some light on what changed on Python 3.10 about imports maybe I can release the new version before the upgrade Maybe @deanishe has a say here? The issue is really weird. If I install pikepdf using pip install pikepdf -t . I get an import error with Python 3.8.9 and Python 3.9.10, although Python 3.10.2 works good. On the other hand I don’t get any error if I don’t use the -t flag at all to install the package. Obviously I’m using the flag because I want to embed the workflow with the package. Edited April 11, 2022 by xilopaint Link to comment
deanishe Posted March 17, 2022 Share Posted March 17, 2022 (edited) @xilopaint You should open an issue on the library's bug tracker. It claims to support 3.7+. Also, like Vítor says, there is no Python 3 on macOS by default, so I wouldn't sweat over using a Homebrew Python instead of an Apple one. The Apple one is slightly preferable, as the devtools are easier to install than Homebrew. Edited March 17, 2022 by deanishe Link to comment
TheThunderChimp Posted March 26, 2022 Share Posted March 26, 2022 On 3/16/2022 at 12:29 PM, xilopaint said: Sorry for the late response. I have fully rewritten this workflow using Python 3 and pikepdf (a more modern library than Pypdf). Your files work perfectly in this new unreleased version. The problem is I can't release it until the system Python gets upgraded to 3.10 which can take a long time. I don't know why pikepdf cannot be imported by Python 3.8 and 3.9. If someone gives me some light on what changed on Python 3.10 about imports maybe I can release the new version before the upgrade. Okay, I'm liking forward to the release! I don't mind using Homebrew. Link to comment
xilopaint Posted March 27, 2022 Author Share Posted March 27, 2022 On 3/16/2022 at 1:29 PM, xilopaint said: Sorry for the late response. I have fully rewritten this workflow using Python 3 and pikepdf (a more modern library than Pypdf). Your files work perfectly in this new unreleased version. The problem is I can't release it until the system Python gets upgraded to 3.10 which can take a long time. I don't know why pikepdf cannot be imported by Python 3.8 and 3.9. If someone gives me some light on what changed on Python 3.10 about imports maybe I can release the new version before the upgrade. I got over this issue and the workflow will work with Developer Tools. I can offer v3 beta builds to some people willing to give me feedback through Telegram. Who's up? @evanfuchs @TheThunderChimp Link to comment
katie Posted April 1, 2022 Share Posted April 1, 2022 @xilopaint I can help with testing - but only as a user with pdfs to manage, not an expert in programming. Link to comment
xilopaint Posted April 2, 2022 Author Share Posted April 2, 2022 15 hours ago, katie said: @xilopaint I can help with testing - but only as a user with pdfs to manage, not an expert in programming. You can send me your Telegram contact by PM. Link to comment
xilopaint Posted April 9, 2022 Author Share Posted April 9, 2022 Update (v3.0) • Python 3 port. • PyPDF4 replaced with pikepdf. Jasondm007 1 Link to comment
xilopaint Posted April 9, 2022 Author Share Posted April 9, 2022 Big changes were made in v3. Unfortunately, because of macOS constraints regarding unsigned binaries, the adoption of pikepdf made the new version around 5 seconds slower. Making the new version faster would require the user either installing pikepdf manually or allowing a large amount of binaries, which I decided to avoid. Any feedback about v3 is appreciated. Thanks to @katiefor testing beta builds before v3 release. Jasondm007 and katie 1 1 Link to comment
2pilvic Posted April 10, 2022 Share Posted April 10, 2022 Thank you very much. I've always loved your workflow xilopaint 1 Link to comment
RYE Posted April 10, 2022 Share Posted April 10, 2022 Dandy! Thanks for the v3 update. xilopaint 1 Link to comment
Jasondm007 Posted April 11, 2022 Share Posted April 11, 2022 Thanks a ton for the update, @xilopaint!! Love this workflow! xilopaint 1 Link to comment
xilopaint Posted April 11, 2022 Author Share Posted April 11, 2022 Thanks guys. All you guys can show your love by giving a star on the workflow's GitHub repo. Btw I would appreciate if anyone with an ARM Mac could tell me if this issue is still present in v3. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now