View Single Post
Old 10-29-2022, 09:04 AM   #10
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,465
Karma: 8025600
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Well, this was fun.

The problem was introduced in commit 8b270da, 17 Oct, when the ability to call stored python templates added. The python caller class is instantiated by the formatter. Unfortunately the caller class cached a copy of the formatter instance, which was never nulled.

When metadata.book.deepcopy() makes a copy of a book Metadata object it makes a copy of the Metadata's formatter instance. Because of the above commit that instance contains a pointer to itself, so we have infinite recursion. Bang.

Fix submitted.
chaley is offline   Reply With Quote