Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Devices

Notices

Reply
 
Thread Tools Search this Thread
Old 01-22-2013, 02:33 PM   #1
Talayero
Member
Talayero began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Apr 2012
Location: Spain
Device: Likebook Mars E Reader
Help with error: TypeError: cannot concatenate 'str' and 'int' objects

Hi:
I would like to be able to solve this communication issue between Calibre and my device without deleting the books.db of my Sony Prs-T1.

I've been using Calibre for a while and I'm happy with it, but I had a couple of problems in the past trying to communicate with the device.
To fix them I always deleted the books.db (the problem was "bad image" or something like that, and the solution Sony suggested was to delete the db)
The thing is that after deleting the books.db you loose all the highlights and annotations and also all the names and the library order or the different collections (I have now 52 collections)

Is there a way to solve this time the issue without deleting the books.db?

This is the communication error with the device:
Traceback (most recent call last):
File "site-packages\calibre\gui2\device.py", line 85, in run
File "site-packages\calibre\gui2\device.py", line 470, in _books
File "site-packages\calibre\devices\prst1\driver.py", line 197, in books
TypeError: cannot concatenate 'str' and 'int' objects

Thank you in advance.
Talayero is offline   Reply With Quote
Old 01-22-2013, 10:05 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: 43,843
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
No, there isn't. That error indicates the db has invalid/corrupted records in it.
kovidgoyal is offline   Reply With Quote
Advert
Old 01-24-2013, 06:02 PM   #3
Talayero
Member
Talayero began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Apr 2012
Location: Spain
Device: Likebook Mars E Reader
Thank you for answering.
Now, after rebuilding the books.db, recreating manually all the collections and adding several books, all seemed OK, but then, suddenly, I got a new error and calibre can't communicate with the device:

Cannot concatenate 'str' and 'NoneType' objects

Traceback (most recent call last):
File "site-packages\calibre\gui2\device.py", line 85, in run
File "site-packages\calibre\gui2\device.py", line 470, in _books
File "site-packages\calibre\devices\prst1\driver.py", line 197, in books
TypeError: cannot concatenate 'str' and 'NoneType' objects

That's a nightmare.
Can I fix that now without deleting again the books.db?

I think I should look for a different way to manage my collections... But that's a pity, because Calibre is the best, if I could fix these weird problems.
Talayero is offline   Reply With Quote
Old 01-24-2013, 10:28 PM   #4
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: 43,843
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
I'll add some code to ignore those invalid db rows, that might workaround your problem, but you really need to figure out why you are getting those invalid entries in your db in the first place.
kovidgoyal is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Error: "can only concatenate list (not "unicode") to list" bmuesse Library Management 2 01-11-2013 03:50 PM
Error calibre OSX: 'int' object has no attribute 'replace' dorjeduck Calibre 3 11-28-2012 10:53 PM
ERROR: Unhandled exception: <b>TypeError</b> mdurham Calibre 3 08-27-2010 11:31 PM
Ubuntu 9.10 error - Unhandled exception - typeerror AdamGott Calibre 6 11-07-2009 07:41 PM
Concatenate mails? Jonas777 Calibre 4 10-21-2009 03:18 PM


All times are GMT -4. The time now is 01:55 PM.


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