Register Guidelines E-Books Today's Posts Search

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

Notices

Reply
 
Thread Tools Search this Thread
Old 09-16-2023, 08:14 PM   #1
Snowman
Zealot
Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.
 
Posts: 106
Karma: 3566
Join Date: Aug 2008
Location: London UK
Device: iPhone 5, Kindle K3, Kindle Voyage
New error calling edit-book from reader

O/S: Windows 10 64 bit
Calibre version 6.26

I often call edit-book from the calibre reader after highlighting a portion of text. Normally, this will open the book in sigil, and jump to the specified text.

Now at version 6.26, the editor opens to the current chapter, but gives an error pop-up "UnboundLocalError: local variable 'raw' referenced before assignment", and does not position to the requested text string.

I tested this on several different books with the same result.

I regressed to the previous version, and confirmed that the issue is not present at v6.25 version.

The full error traceback is:
Code:
calibre, version 6.26.0
ERROR: Unhandled exception: <b>UnboundLocalError</b>:local variable 'raw' referenced before assignment

calibre 6.26  embedded-python: True
Windows-10-10.0.19045-SP0 Windows ('64bit', 'WindowsPE')
('Windows', '10', '10.0.19045')
Python 3.10.1
Windows: ('10', '10.0.19045', 'SP0', 'Multiprocessor Free')
Interface language: None
Successfully initialized third party plugins: DeDRM (7, 1, 0) && Count Pages (1, 13, 2) && FanFicFare (4, 27, 0)
Traceback (most recent call last):
  File "calibre\gui2\__init__.py", line 721, in dispatch
  File "calibre\gui2\tweak_book\job.py", line 84, in job_done
  File "calibre\gui2\tweak_book\boss.py", line 411, in book_opened
  File "calibre\gui2\tweak_book\boss.py", line 1157, in find_initial_text
  File "calibre\gui2\tweak_book\editor\widget.py", line 322, in find_text
  File "calibre\gui2\tweak_book\editor\text.py", line 519, in find_text
UnboundLocalError: local variable 'raw' referenced before assignment
Snowman is offline   Reply With Quote
Old 09-16-2023, 09:06 PM   #2
Comfy.n
want to learn what I want
Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.Comfy.n ought to be getting tired of karma fortunes by now.
 
Posts: 1,002
Karma: 6422750
Join Date: Sep 2020
Device: Calibre E-book viewer
I've had that same error a couple of times yesterday, when opening the Editor from the Viewer toolbar button.

Now I tried to reproduce, and it wasn't easy, but eventually I remembered what I was trying to do: I wanted to see in the Editor the formatting for the text containing the name of the translator, in order to write an extracting rule for the EPOM plugin.

So I selected this text, and after clicking the "Edit this book" Viewer toolbar button, got the same message again. It's awesome that the Editor opens to the current chapter!
Comfy.n is offline   Reply With Quote
Old 09-16-2023, 09:45 PM   #3
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,860
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
yes this is fixed in the next release.
kovidgoyal is offline   Reply With Quote
Old 09-16-2023, 09:48 PM   #4
Snowman
Zealot
Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.Snowman can teach chickens to fly.
 
Posts: 106
Karma: 3566
Join Date: Aug 2008
Location: London UK
Device: iPhone 5, Kindle K3, Kindle Voyage
Thanks, Kovid
Snowman is offline   Reply With Quote
Old 09-16-2023, 11:14 PM   #5
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,575
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by Snowman View Post
O/S: Windows 10 64 bit
Calibre version 6.26

I often call edit-book from the calibre reader after highlighting a portion of text. Normally, this will open the book in sigil, and jump to the specified text.
In Sigil - how so, does the viewer have an override setting?

BR
BetterRed is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Calibre 3.24 edit book preview error larysa Editor 5 05-26-2018 05:31 PM
Calibre Edit Book - save error mddizon Editor 3 01-17-2018 01:15 PM
Edit Book: ERROR: Unhandled exception chaot Editor 9 01-05-2017 11:17 AM
Edit Book: ParserWorker error macnab69 Library Management 3 11-06-2014 03:31 AM
Calling smarten_punctuation from edit book ShellShock Development 4 01-07-2014 01:47 PM


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


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