![]() |
#1 |
Member
![]() Posts: 15
Karma: 10
Join Date: May 2009
Device: kindle
|
using python with windows xp
I have activestate python 2.6 installed on my winxp computer. I've successfully obtained a PID using kindlepid.py but am unable to use the mobidedrm.py script since I keep getting the following error message: No such file or directory: 'python'. I enter the info as following: python mobidedrm.py Name-of-book.format Name-of-book.format PID and it doesn't work. How does this program know where to find the ebook file? Is that the problem? I've tried cutting and pasting the ebook file everywhere .... even in the folder where the mobidedrm.py script is located.... but no luck. What am I doing wrong?
|
![]() |
![]() |
![]() |
#2 |
Bookaholic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 14,391
Karma: 54969924
Join Date: Oct 2007
Location: Minnesota
Device: iPad Mini 4, AuraHD, iPhone XR +
|
Try putting the book in the same folder as the script and not putting 'python' at the beginning of your command string just mobidedrm drmdbook.prc undrmdbook.prc PID (.prc could also be .mobi or .azw). Also make sure you're in the folder where the script is before starting (for example C:\mobi>).
Mods, if this is TMI feel free to delete or edit. ` |
![]() |
![]() |
Advert | |
|
![]() |
#3 | |
Member
![]() Posts: 15
Karma: 10
Join Date: May 2009
Device: kindle
|
different error message now
Quote:
|
|
![]() |
![]() |
![]() |
#4 |
Bookaholic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 14,391
Karma: 54969924
Join Date: Oct 2007
Location: Minnesota
Device: iPad Mini 4, AuraHD, iPhone XR +
|
The 'invalid PID checksum' has come up in other threads
Maybe you can find the solution here... https://www.mobileread.com/forums/showthread.php?t=26093 Otherwise searching for invalid PID checksum brings up a few other threads too. |
![]() |
![]() |
![]() |
#5 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 78,948
Karma: 144284074
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Try uninstalling Active State Python and get Python at http://www.python.org.It is what most people use.
Last edited by JSWolf; 05-05-2009 at 04:58 PM. |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Connoisseur
![]() Posts: 75
Karma: 74
Join Date: Mar 2009
Location: Seattle, WA
Device: Kobo Libra Colour
|
If everything else fails, try the Python from python.org (what most people use), not ActiveState.
|
![]() |
![]() |
![]() |
#7 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 739
Karma: 1018859
Join Date: Jun 2008
Location: Near Seattle
Device: kindle1, K3, K3G (thanks MR), iTouch, Kindle Touch
|
Most likely your problem is either your command line or you have not gotten a valid PID. When you run KindlePID, make sure that all the alphas are input as capital letters, leave out any spaces and 0 are numerics (zero).
Then put your python script in the same folder as your ebook. Open a command prompt window and change directory to that folder. i.e. cd desktop\ebooks When you see confirmation that you are in the correct folder, your input line should be mobidedrm.py ebookname.azw newebookname.prc PID If the ebook name or new ebook name have any spaces in it, enclose the name in " " i.e mobidedrm.py "ebook name.azw" "new ebook name.prc" PID. Let us know if you still have problems. I am using activestate Python for all my python scripts with no issues. cheers Lee |
![]() |
![]() |
![]() |
#8 |
reader
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,977
Karma: 5183568
Join Date: Mar 2006
Location: Mississippi, USA
Device: Kindle 3, Kobo Glo HD
|
Leep's post should be enough to get you going. If not, try argecho.py and pid_checksum.py. Note that if pid_checksum reports a bad PID, it has most likely been typed in wrong (e.g. 0 or O or 1 for I).
|
![]() |
![]() |
![]() |
#9 | |
Member
![]() Posts: 15
Karma: 10
Join Date: May 2009
Device: kindle
|
still no luck
Quote:
|
|
![]() |
![]() |
![]() |
#10 | |
Member
![]() Posts: 15
Karma: 10
Join Date: May 2009
Device: kindle
|
Quote:
I just tried to redownload the mobidedrm.zip file and extract the files again. When I run the kindlepid.py I get the same result but when I run mobidedrm.py I get a new error message: error: invalid encryption type: 0 |
|
![]() |
![]() |
![]() |
#11 | |
Member
![]() Posts: 15
Karma: 10
Join Date: May 2009
Device: kindle
|
Quote:
IT WORKS!!!!!!!!!! THANK YOU SO MUCH!!!!!!! I redownloaded the mobidedrm.zip file and extracted the files and ran everything through the command prompt and it works! I got a different PID when I ran it from with activestate python. |
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
how to use python script with windows xp | tuufbiz1 | Other formats | 12 | 01-08-2011 08:22 AM |
Python error! | didiyy | Calibre | 6 | 09-24-2010 02:05 AM |
Python 261 In Windows Problems | jwsheets | Kindle Formats | 3 | 08-14-2009 09:08 AM |
GUI Frontend for python scripts [windows] - seeking mod input first | sherman | Workshop | 7 | 04-27-2009 01:04 AM |
Python 2.5 or 2.6? | itimpi | Calibre | 5 | 01-19-2009 12:48 PM |