fix(ep_approval): Fix error handling, add test for single record flow - #917
Open
sakshamarora1 wants to merge 1 commit into
Open
fix(ep_approval): Fix error handling, add test for single record flow#917sakshamarora1 wants to merge 1 commit into
sakshamarora1 wants to merge 1 commit into
Conversation
sakshamarora1
force-pushed
the
fix/ep_approval
branch
from
August 13, 2026 08:41
70da679 to
8f82c43
Compare
zzacharo
reviewed
Aug 19, 2026
| if incoming_apprn != stored_apprn: | ||
| error_msg = _( | ||
| "The 'apprn' identifier is system-managed and cannot be " | ||
| "The EP approval report number is system-managed and cannot be " |
Contributor
There was a problem hiding this comment.
here we cannot hardcode the EP label as we would like to have this configurable. Maybe we added a label fro this in the config.
zzacharo
reviewed
Aug 19, 2026
Comment on lines
+208
to
+211
| if approved_internal == source_internal: | ||
| return record["id"] == source_internal | ||
| # Public copy: source points back to a different (internal) record, always sync | ||
| return True |
| return False | ||
| # Migrated case: both flags point at the same version, so only the current version carries apprn | ||
| if approved_internal == source_internal: | ||
| return record["id"] == source_internal |
Contributor
There was a problem hiding this comment.
If I understand correctly, that wil regenerate the apprn only for the accepted version. The truth is that all the newer versions should have the apprn number
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.
Fixes: #912
Also makes the code ready for the migration script: https://gitlab.cern.ch/cds-team/production_scripts/-/merge_requests/59
Related: #908