[19.0[IMP] edi_core_oca: mark process integrity errors as failed - #319
Open
yankinmax wants to merge 1 commit into
Open
[19.0[IMP] edi_core_oca: mark process integrity errors as failed#319yankinmax wants to merge 1 commit into
yankinmax wants to merge 1 commit into
Conversation
Contributor
1 task
wouitmil
approved these changes
Jul 14, 2026
Ricardoalso
reviewed
Jul 15, 2026
simahawk
requested changes
Jul 21, 2026
simahawk
left a comment
Contributor
There was a problem hiding this comment.
I agree w/ @Ricardoalso
yankinmax
force-pushed
the
edi_core_oca-add-exp
branch
from
August 6, 2026 05:59
af09c01 to
4b7cb23
Compare
yankinmax
force-pushed
the
edi_core_oca-add-exp
branch
from
August 6, 2026 06:04
4b7cb23 to
c088ac6
Compare
Ricardoalso
reviewed
Aug 6, 2026
Comment on lines
495
to
+496
| res = f"Error: {error}" | ||
| except (OperationalError, IntegrityError): | ||
| except IntegrityError as err: |
Contributor
There was a problem hiding this comment.
Well with this change we just end up duplicating code
if self.env.context.get("_edi_process_break_on_error"):
raise
traceback = _get_exception_traceback()
error = _get_exception_msg(err)
state = "input_processed_error"
res = f"Error: {error}"
I rechecked the code and with the changes introduced by 8f44487,
I would keep IntegrityError inside _swallable_exceptions because it always runs inside a cr.savepoint(), which rolls back to the savepoint before this is caught, leaving the cursor usable.
Leaving OperationalError handling (res = "__sql_error__") separately as it may indicate a broken connection rather than a "bad statement".
@guewen your input is welcome on this one 🙏
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.
No description provided.