Originally Posted by kovidgoyal
The way the download system works is as follows:
Thank you. I've been poking through the code and had figured some of that out, but your explanation helps a lot.
I've also figured out that calibre.ebooks.metadata.__init__.py defines smart_update and there's a convenient spot there at line 252 to block the title and author changes that occur during multiple ebook metadata downloads. That lets me handle the two important cases I need - single and multiple metadata downloads.
I still need to work on understanding the plugin customization code and I'm not totally certain whether blocking parts of smart_update might block other required functionality. (Right now I haven't tested enough, and I'm just blocking the changes when I want to do a global update for multiple books.)
I'd like to get to the point where I could propose some code that would be close to correct. That's hard to do before you understand the basic structure of the code. There's really no better way to learn this stuff than to have a project and try to figure out what you need to know to complete it.