Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 05-17-2017, 01:45 PM   #1
TonyAn
Junior Member
TonyAn began at the beginning.
 
Posts: 5
Karma: 10
Join Date: May 2017
Device: Xiaomi
Python newbie, need help about print statement debug

I've never written python in the past, but have to toughen my scalp in order to fulfill a rigid demand. I've set up the calibre development environment, but can't use the print statement to debug successfully.

I added print(url) in the 224 lines of src/calibre/ebooks/metadata/sources/douban.py, then calibre-debug -g, select a certain ebook, download its douban metadata successfully....but now, the console only shows the debug information as shown in the below, I can't see any print(url)?

don't understand why...which step is mistake?

[Image violates Posting Guidelines for size - MODERATOR]

Last edited by Dr. Drib; 05-17-2017 at 02:10 PM.
TonyAn is offline   Reply With Quote
Old 05-17-2017, 01:55 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,339
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Metadata download happens in a separate process. So it doesn;t output to the console. Instead simply use the view log button in the download metadata notification, it should contain your print statement output
kovidgoyal is offline   Reply With Quote
Advert
Old 05-17-2017, 02:14 PM   #3
Dr. Drib
Grand Sorcerer
Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.
 
Dr. Drib's Avatar
 
Posts: 45,437
Karma: 59592133
Join Date: Jan 2007
Location: Peru
Device: KINDLE: Oasis 3, Scribe (1st), Matcha; KOBO: Libra 2, Libra Colour
Moderator Notice

Please take a few moments to read our Posting Guidelines, in particular the part about the maximum image size allowed (600x600 pixels). Images that violate those guidelines may be deleted.

It is every member's responsibility to read our Posting Guidelines and follow them.

Thanks.
Dr. Drib is offline   Reply With Quote
Old 05-17-2017, 03:46 PM   #4
TonyAn
Junior Member
TonyAn began at the beginning.
 
Posts: 5
Karma: 10
Join Date: May 2017
Device: Xiaomi
Quote:
Originally Posted by kovidgoyal View Post
Metadata download happens in a separate process. So it doesn;t output to the console. Instead simply use the view log button in the download metadata notification, it should contain your print statement output
Ok~ Thanks
TonyAn is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to setup Python debug environment for Calibre Recipes huang5307 Recipes 9 03-03-2016 02:35 PM
win7-debug-python jaapx Calibre 2 10-23-2015 12:11 AM
Ctrl-Shft-R Debug vs calibre-debug -g JimmXinu Development 3 11-20-2014 09:57 AM
Newbie on technology want to print an e-book bassmanwa Introduce Yourself 4 07-02-2011 04:23 AM
Print vs Pixel: retailers experiment with print/ebook bundles DMcCunney General Discussions 42 09-15-2010 11:29 AM


All times are GMT -4. The time now is 06:34 PM.


MobileRead.com is a privately owned, operated and funded community.