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

Implement error handling for MediaWiki warnings on existing files #327

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

marcfrederick
Copy link
Member

Fixes #211 by raising an error when ignore=False and the MediaWiki response contains the upload.warnings.exists key. Previously, this warning was logged, but the call to Site.upload succeeded. This could be easily missed by users, especially when they haven't configured the log level.

@coveralls
Copy link
Collaborator

coveralls commented Feb 17, 2024

Coverage Status

coverage: 75.022% (+0.2%) from 74.805%
when pulling 6aada3a on feature/handle-upload-exists
into 390fd4d on master.

@marcfrederick marcfrederick changed the title #211: Implement error handling for MediaWiki warnings on existing files Implement error handling for MediaWiki warnings on existing files Feb 17, 2024
Raises an error when ignore=False and the MediaWiki response contains
the `upload.warnings.exists` key. Previously, this warning was logged,
but the call to `Site.upload` succeeded. This could be easily missed by
users, especially when they haven't configured the log level.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

site.upload() should raise exception for warnings
2 participants