Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merging keywords for error log output. #575

Closed
nel997 opened this issue Jan 12, 2020 · 0 comments
Closed

Merging keywords for error log output. #575

nel997 opened this issue Jan 12, 2020 · 0 comments

Comments

@nel997
Copy link

nel997 commented Jan 12, 2020

Good day.

I would like to ask if it's possible to merge keywords for error log messages, since the keyword I desire to show up is different in each extractor. For example, in Mangadex it would be "manga" but on Exhentai it would be "title". According to configuration.rst, the logger can access extractor atributes, so it should be possible to get an output like:

[2020/01/12, 10:54:02][download][Manga Name/Exhentai Gallery][error] Failed to download Filename.extension

Thanks.

Edit: Accidentally tabbed and posted before finishing, sorry.

mikf added a commit that referenced this issue May 18, 2020
Wrap all loggers used by job, extractor, downloader, and postprocessor
objects into a (custom) LoggerAdapter that provides access to the
underlying job, extractor, pathfmt, and kwdict objects and their
properties.

__init__() signatures for all downloader and postprocessor classes have
been changed to take the current Job object as their first argument,
instead of the current extractor or pathfmt.

(#574, #575)
@mikf mikf closed this as completed Dec 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants