Register Guidelines E-Books Search Today's Posts Mark Forums Read

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

Notices

Reply
 
Thread Tools Search this Thread
Old 05-11-2011, 03:29 AM   #1
cybmole
Wizard
cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.
 
Posts: 2,997
Karma: 1285294
Join Date: Sep 2010
Device: Kobo aura HD, Kobo Arc, Kindle Fire HDX 8.9 , Kindle for PC
os error (2) no such file or directory

posting this in devices subforum , as the symptom appears when using send to device.
but I suspect the root cause is not a device issue

had this one time in v7 am seeing it now in v8. - twice in the last few days

I connect my sony & then try to send a book via calibre. ( a book that was edited yesterday). Calibre gives me
OSError: [Errno 2] No such file or directory

log for failure:
Traceback (most recent call last):
File "site-packages\calibre\gui2\device.py", line 890, in dispatch_sync_event
File "site-packages\calibre\gui2\device.py", line 1092, in sync_to_device
File "site-packages\calibre\gui2\library\models.py", line 441, in get_preferred_formats_from_ids
File "site-packages\calibre\ptempfile.py", line 60, in __init__
File "tempfile.py", line 293, in mkstemp
File "tempfile.py", line 228, in _mkstemp_inner
OSError: [Errno 2] No such file or directory

I then get it again ( see below) if I select view in calibre tool bar for that book ( though the book is there & is fine if I go via open path...
log for view failure:
Traceback (most recent call last):
File "site-packages\calibre\gui2\actions\view.py", line 200, in view_book
File "site-packages\calibre\gui2\actions\view.py", line 270, in _view_books
File "site-packages\calibre\gui2\actions\view.py", line 238, in _view_calibre_books
File "site-packages\calibre\gui2\actions\view.py", line 104, in view_format_by_id
File "site-packages\calibre\gui2\actions\view.py", line 134, in _view_file
File "site-packages\calibre\gui2\actions\view.py", line 123, in _launch_viewer
File "site-packages\calibre\gui2\jobs.py", line 227, in launch_gui_app
File "site-packages\calibre\utils\ipc\server.py", line 166, in run_job
File "site-packages\calibre\utils\ipc\server.py", line 121, in launch_worker
File "tempfile.py", line 293, in mkstemp
File "tempfile.py", line 228, in _mkstemp_inner
OSError: [Errno 2] No such file or directory

a complete exit + restart of calibre fixes it, so it's a calibre bug, not a sony bug. after a restart I can send/ view the problem book(s) OK.

so what is happening here. it seems that calibre "forgets" where the book is?

my only other clues : calibre is always left running except for updates, so is the PC, I just use sleep / wake. I have worked on that book in sigil sometime in last couple of days so sigil will have written a revised copy back into calibre library.

this was the case with the v7 error also - work on book in sigil ( from calibre i.e. my workflow is that open with editor option in calibre launches sigil. sigil save puts revised copy back into library. 99.9% of the times there is no issue.



one more clue - maybe between edit/save of book and the attempt to send to device, i have run ccleaner which will wipe temporary files. could be it wipes too aggressively ?

Last edited by cybmole; 05-11-2011 at 03:39 AM.
cybmole is offline   Reply With Quote
Old 05-11-2011, 08:32 AM   #2
user_none
Sigil & calibre developer
user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.
 
user_none's Avatar
 
Posts: 2,473
Karma: 1053245
Join Date: Jan 2009
Location: Florida, USA
Device: Nook STR
Quote:
Originally Posted by cybmole View Post
maybe between edit/save of book and the attempt to send to device, i have run ccleaner which will wipe temporary files. could be it wipes too aggressively ?
Calibre makes extensive use of temporary files. It looks like you've deleted the temporary folder calibre creates when it starts. So subsequent writes to this directory fail because it's not present.
user_none is offline   Reply With Quote
 
Advertisement
Old 05-11-2011, 09:35 AM   #3
cybmole
Wizard
cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.
 
Posts: 2,997
Karma: 1285294
Join Date: Sep 2010
Device: Kobo aura HD, Kobo Arc, Kindle Fire HDX 8.9 , Kindle for PC
i thought it might be something like that. I tried to reproduce it but there's an ageing factor involved. simply trying open in editor save, ccleaner, view works fine. I guess waht has happen is this.

1. calibre runs/sleeps for several days without ever a full shut down.
2. ccleaner runs & applies it's logic to delect "safe-to-delete" + "temporary file" which is probably restricted to files that are > x days old.

so to reproduce it ( without messing with PC system date/time) I'd have to run calibre in tray for a week, then run ccleaner, then try to View something. Connecting an e-reader is probably not relevent if this diagnosis is correct.

if i remember I'll check this out next week.

but a couple of comments.
1. it's a scary & generic error message ( generic because I can google the error text & see it reported for other apps). scary, because 1st thought on seeing it is oh S***T I've accidentally deleted the book!

2. could calibre not trap it, realize it needs a new temp file & simply make one; or if that's not possible then put up a message saying calibre has encountered an error & needs to close, please restart it. { I hate seeing those in games but here, it's what's needed]

3. ccleaner has an exclude function. can I use that to prevent this error , but still have it clean up the calibre .tmp files that get moaned about it other threads ? what is the specific file / folder to exclude ?

Last edited by cybmole; 05-11-2011 at 09:46 AM.
cybmole is offline   Reply With Quote
Old 05-16-2011, 03:59 PM   #4
cybmole
Wizard
cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.
 
Posts: 2,997
Karma: 1285294
Join Date: Sep 2010
Device: Kobo aura HD, Kobo Arc, Kindle Fire HDX 8.9 , Kindle for PC
well I plug in my sony today & get this damn message again, when I try to send a book!

pretty sure I've NOT run ccleaner recently - yet calibre is still losing essential temp files ???

PC /calibre has been runnng without shutdown ( onlt sleep) for a dew days...

how can I diagnose this more ?

Traceback (most recent call last):
File "site-packages\calibre\gui2\actions\view.py", line 203, in view_triggered
File "site-packages\calibre\gui2\actions\view.py", line 270, in _view_books
File "site-packages\calibre\gui2\actions\view.py", line 238, in _view_calibre_books
File "site-packages\calibre\gui2\actions\view.py", line 104, in view_format_by_id
File "site-packages\calibre\gui2\actions\view.py", line 134, in _view_file
File "site-packages\calibre\gui2\actions\view.py", line 123, in _launch_viewer
File "site-packages\calibre\gui2\jobs.py", line 227, in....


File "tempfile.py", line 293, in mkstemp
File "tempfile.py", line 228, in _mkstemp_inner
OSError: [Errno 2] No such file or directory
cybmole is offline   Reply With Quote
Old 05-16-2011, 05:33 PM   #5
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: 26,454
Karma: 5383257
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
That error means that something has deleted the calibre temp directory. calibre itself only does that at shutdown. If you cannot figure out what is doing the deleting, then a workaround is to have calibre periodically restarted.
kovidgoyal is online now   Reply With Quote
Old 05-17-2011, 12:54 AM   #6
cybmole
Wizard
cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.
 
Posts: 2,997
Karma: 1285294
Join Date: Sep 2010
Device: Kobo aura HD, Kobo Arc, Kindle Fire HDX 8.9 , Kindle for PC
ok - can u tell me the name/location of the "no such file or directory ", then I can watch that location while I try to recreate the issue..


PS the culprit software could be auslogic's disc defrag - it has a (ticked) option to remove windows temp files before each defrag; and I ran this program yesterday, I think
cybmole is offline   Reply With Quote
Old 05-17-2011, 01:18 AM   #7
theducks
Grand Sorcerer
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 15,292
Karma: 6022733
Join Date: Aug 2009
Location: (The original) Silicon Valley, USA
Device: Galaxy Tab 2, Astak Pocket Pro, K4NT
Quote:
Originally Posted by cybmole View Post
ok - can u tell me the name/location of the "no such file or directory ", then I can watch that location while I try to recreate the issue..


PS the culprit software could be auslogic's disc defrag - it has a (ticked) option to remove windows temp files before each defrag; and I ran this program yesterday, I think
It is: cal and a random number.tmp
It is in you 'temp' folder
Code:
C:\Documents and Settings\<username>\Local Settings\Temp
on XP
theducks is offline   Reply With Quote
Old 05-17-2011, 05:56 AM   #8
cybmole
Wizard
cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.
 
Posts: 2,997
Karma: 1285294
Join Date: Sep 2010
Device: Kobo aura HD, Kobo Arc, Kindle Fire HDX 8.9 , Kindle for PC
I can live with the explanation & work-arounds - but is there a good reason why calibre could not simply recreate the temp directory as needed, rather than "give up" & report an ( unclear) error.
cybmole is offline   Reply With Quote
Old 05-17-2011, 08:09 AM   #9
user_none
Sigil & calibre developer
user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.
 
user_none's Avatar
 
Posts: 2,473
Karma: 1053245
Join Date: Jan 2009
Location: Florida, USA
Device: Nook STR
Quote:
Originally Posted by cybmole View Post
I can live with the explanation & work-arounds - but is there a good reason why calibre could not simply recreate the temp directory as needed, rather than "give up" & report an ( unclear) error.
Every time a tmpfile needs to be written there would need to be this check. Hundreds if not thousands of places would needed the code over and over again.
user_none is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
error no such file or directory cybmole Calibre 1 04-25-2011 01:52 AM
.Kobo\version directory missing - error communicating bitjockey Devices 4 02-26-2011 10:38 AM
IOError - No such file or directory SkyDream Calibre 7 11-12-2010 03:44 PM
File directory corruption in IR1000S physics@war iRex 3 02-08-2010 09:56 AM
Word to HTML no such file or directory evwool Reading and Management 1 05-11-2009 02:50 AM


All times are GMT -4. The time now is 12:32 AM.


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