Fixes #669: Log warning when ValidationError occurs during translation.#907
Open
Marvinrose wants to merge 5 commits intowagtail:mainfrom
Open
Fixes #669: Log warning when ValidationError occurs during translation.#907Marvinrose wants to merge 5 commits intowagtail:mainfrom
Marvinrose wants to merge 5 commits intowagtail:mainfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #907 +/- ##
==========================================
+ Coverage 93.02% 93.03% +0.01%
==========================================
Files 47 47
Lines 4243 4251 +8
Branches 551 551
==========================================
+ Hits 3947 3955 +8
Misses 177 177
Partials 119 119 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
zerolab
reviewed
Mar 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previously, when
save_target()raised aValidationErrorduring translation, the error was silently suppressed. This caused a confusingDoesNotExisterror to surface to the user instead of the real cause.Changes
operations.py: replacedcontextlib.suppress(ValidationError)with alogger.warning()so the actual error is visible in logs.views/submit_translations.py: wrappedget_translation()withcontextlib.suppress(DoesNotExist)so the view degrades gracefully whensave_target()fails