06-12-2017, 11:03 PM | #16 |
Guru
Posts: 631
Karma: 7544080
Join Date: Apr 2013
Location: Berlin
Device: PRS 350, Kobo Aura
|
It works for mac, windows and linux. Python and PyQt4 run on all three platforms.
I don't have a mac, but I think it should be even easier than on windows. As far as I know, python is pre-installed on MacOS. You would only need PyQt4 for the gui (the comand line should work without it). |
06-12-2017, 11:40 PM | #17 |
Connoisseur
Posts: 72
Karma: 10
Join Date: Oct 2016
Device: iPad Pro 12.9"
|
Oh, OK, it looks like it will work for Mac. Sorry for the dumb question... but I'm not sure what Python and PyQt4 are.
|
Advert | |
|
06-13-2017, 09:01 AM | #18 |
null operator (he/him)
Posts: 20,575
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Python is a computer language, much of calibre is written in Python. Qt is a set of software libraries (a framework in the modern parlance) that facilitates the development of applications that can run on multiple platforms (e.g. Windows, OSX, Linux etc). PyQt4 is the glue that binds Python to Qt Version 4.
BR |
06-13-2017, 10:29 AM | #19 |
Guru
Posts: 631
Karma: 7544080
Join Date: Apr 2013
Location: Berlin
Device: PRS 350, Kobo Aura
|
You can get python here:
https://www.python.org/downloads/release/python-2713/ Homebrew: https://brew.sh/ is like chocolatey for mac os. With brew install pyqt You can then install pyqt4 |
06-23-2017, 12:50 AM | #20 | |
Connoisseur
Posts: 72
Karma: 10
Join Date: Oct 2016
Device: iPad Pro 12.9"
|
Quote:
So, I understand that the next step is to install something called pyqt4 using Homebrew. So... how do I do that, exactly? |
|
Advert | |
|
06-23-2017, 06:21 AM | #21 | |
Guru
Posts: 631
Karma: 7544080
Join Date: Apr 2013
Location: Berlin
Device: PRS 350, Kobo Aura
|
Quote:
brew install pyqt After that you go to the folder where you unzipped comictagger to and enter in the terminal: pip install -r requirements.txt Now comictagger can be started. You can try to just click on comictagger.py. If this doesn't work, enter the terminal again and type: python comictagger.py You can put that into a batch file, so that you don't have to enter the terminal every time you want to use comictagger. |
|
06-25-2017, 05:44 PM | #22 | |
Connoisseur
Posts: 72
Karma: 10
Join Date: Oct 2016
Device: iPad Pro 12.9"
|
Quote:
I was able to navigate into the directory where I unzipped the comictagger-master folder. It's in my users/Applications directory. There I installed i using the above directions and it looks like worked. I then clicked on "comictagger.py" in that director. Here's where things got a little weird. It opened a program called Xcode. I think I installed that a long time ago and never used it. Anyway, when I reloaded the program, I got a window that says "comictagger.py" and underneath it says: #! python2.7 from comictaggerlib.main import ctmain if __name__ == '__main__': It looks like I can drag and drop a comic into it but nothing else happens... is there a button or command I'm supposed to put in to get it to process the file and find the metadata? |
|
06-25-2017, 06:25 PM | #23 |
Guru
Posts: 631
Karma: 7544080
Join Date: Apr 2013
Location: Berlin
Device: PRS 350, Kobo Aura
|
Xcode seems to be registered as the standard program to open python files on your system. So it just opens the file as a text document. I don't know how to change that on a mac, maybe someone else can help with that (on windows , a right click would give you a context menu, where you coul use "open with" and select python. Maybe that is similar on a mac). For now, just open a terminal in the folder. There enter
python comictagger.py That should work. If not, python is not in your path. If that is the case, you have to type the complete path to your python installation, instead of just python. |
06-25-2017, 07:54 PM | #24 | |
Connoisseur
Posts: 72
Karma: 10
Join Date: Oct 2016
Device: iPad Pro 12.9"
|
Quote:
|
|
06-26-2017, 09:25 AM | #25 |
Guru
Posts: 631
Karma: 7544080
Join Date: Apr 2013
Location: Berlin
Device: PRS 350, Kobo Aura
|
Argh, apparently brew installs only PyQt5.
Try the version of comictagger I attached to this post. It uses PyQt5 instead of PyQt4. Last edited by dickloraine; 06-26-2017 at 09:28 AM. |
06-26-2017, 09:01 PM | #26 | |
Connoisseur
Posts: 72
Karma: 10
Join Date: Oct 2016
Device: iPad Pro 12.9"
|
Quote:
If it helps, I am including the entire terminal window dialogue which occurred after unzipping the ComicTagger to the user/Applications directory. Aside from the occasional typos/wrongly written commands, if I did anything obviously wrong, try not to laugh too hard.... I haven't done command-line type entry since my college days taking courses using Linux systems. I have fond memories of those courses, but a computer programmer I definitely am not. Last login: Sun Jun 25 20:28:59 on console You have mail. ComputerName:~ username$ cd applications ComputerName:applications username$ cd Comictagger ComputerName:Comictagger username$ pip install -r requirements.txt Requirement already satisfied: configparser in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from -r requirements.txt (line 1)) Requirement already satisfied: beautifulsoup4>=4.1 in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from -r requirements.txt (line 2)) ComputerName:Comictagger username$ python comictagger.py PyQt5 is not available. ComicTagger is limited to command-line mode. You must specify at least one filename. Use the -h option for more info ComputerName:Comictagger username$ brew installpyqt Error: Unknown command: installpyqt ComputerName:Comictagger username$ brew install pyqt Updating Homebrew... ==> Auto-updated Homebrew! Updated 1 tap (homebrew/core). ==> New Formulae mruby-cli openfortivpn ==> Updated Formulae angband folly jsoncpp paket weechat camlp5 fwup lapack pegtl zurl fibjs ipv6calc magic-wormhole pqiv flow jenkins mkvtoolnix scalaenv Warning: pyqt 5.8.2 is already installed ComputerName:Comictagger username$ pip install-r requirements.txt ERROR: unknown command "install-r" - maybe you meant "install" ComputerName:Comictagger username$ pip install -r requirements.txt Requirement already satisfied: configparser in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from -r requirements.txt (line 1)) Requirement already satisfied: beautifulsoup4>=4.1 in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from -r requirements.txt (line 2)) ComputerName:Comictagger username$ python comictagger.py PyQt5 is not available. ComicTagger is limited to command-line mode. You must specify at least one filename. Use the -h option for more info ComputerName:Comictagger username$ brew install pyqt5 Warning: pyqt 5.8.2 is already installed ComputerName:Comictagger username$ |
|
06-26-2017, 11:20 PM | #27 |
Guru
Posts: 631
Karma: 7544080
Join Date: Apr 2013
Location: Berlin
Device: PRS 350, Kobo Aura
|
Unfortunately I don't know macs. Brew likely installed it in the wrong place or the wrong python version is in your path. Maybe google can help you finding what to copy where. Another way would be to use https://www.continuum.io/downloads instead of pure python. Anaconda should be more easy to use and has its own package manager with many prebuild packages. Maybe it even ships with pyqt, otherwise
conda install pyqt Will install it. To start comictagger with it, you need to make shure to start it with anacondas python. Maybe it automatically configeres your path, then just python comictagger.py Will suffice. Otherwise replace python with the path to anacondas python executable. |
06-26-2017, 11:27 PM | #28 |
creator of calibre
Posts: 43,860
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Just FYI, you can run python scripts using calibre without needing to install python/pyqt/etc.
/Applications/calibre.app/Contents/calibre-debug.app/Contents/MacOS/calibre-debug file.py |
06-27-2017, 12:39 AM | #29 |
Connoisseur
Posts: 72
Karma: 10
Join Date: Oct 2016
Device: iPad Pro 12.9"
|
Let's just say I did that... what exactly do I do to run the ComicTagger software? Are you saying I should go the above directory (which I was able to find) and run it from there within terminal? In that case, I would move the ComicTagger directory there?
|
06-27-2017, 01:09 AM | #30 | |
Connoisseur
Posts: 72
Karma: 10
Join Date: Oct 2016
Device: iPad Pro 12.9"
|
Quote:
ComputerName:Applications username$ cd Comictagger ComputerName:Comictagger username$ python comictagger.py Traceback (most recent call last): File "comictagger.py", line 2, in <module> from comictaggerlib.main import ctmain File "/Users/username/Applications/Comictagger/comictaggerlib/main.py", line 76 print "Key set" ^ SyntaxError: Missing parentheses in call to 'print' It then occurred to me that I should reinstall pyqt, so I did this: ComputerName:Comictagger username$ conda install pyqt Fetching package metadata ......... Solving package specifications: . Package plan for installation in environment /Users/username/anaconda: The following packages will be UPDATED: anaconda: 4.4.0-np112py36_0 --> custom-py36_0 conda: 4.3.21-py36_0 --> 4.3.22-py36_0 pyqt: 5.6.0-py36_1 --> 5.6.0-py36_2 Proceed ([y]/n)? y anaconda-custo 100% |################################| Time: 0:00:00 2.62 MB/s pyqt-5.6.0-py3 100% |################################| Time: 0:00:00 8.74 MB/s conda-4.3.22-p 100% |################################| Time: 0:00:00 10.21 MB/s Looks like it worked, from what I see, so I next did this: ComputerName:Comictagger username$ python comictagger.py Traceback (most recent call last): File "comictagger.py", line 2, in <module> from comictaggerlib.main import ctmain File "/Users/username/Applications/Comictagger/comictaggerlib/main.py", line 76 print "Key set" ^ SyntaxError: Missing parentheses in call to 'print' ComputerName:Comictagger username$ I'm still getting this syntax error for some reason. I feel like I'm doing something stupid but I'm not sure what it is. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[GUI Plugin] Embed Comic Metadata | dickloraine | Plugins | 113 | 02-22-2024 01:01 PM |
Problems finding a port for Calibre Server | cptnemo | Library Management | 4 | 09-10-2012 02:37 AM |
Comic Book / Graphic Novels: problems | famousboot | Kindle Fire | 7 | 01-08-2012 03:16 AM |
Comic Book Conversion with Calibre | bmwr1200c | Conversion | 4 | 08-11-2011 03:31 PM |
problems with metadata in Calibre | dismukes | Library Management | 8 | 02-16-2011 02:06 PM |