fix: send revoke line items signal from order returned task#534
Merged
Conversation
3bebaa6 to
1f18525
Compare
Coverage reportClick to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes revoke-line-items processing for returned orders by introducing a dedicated coordinator signal and dispatching it directly from the “order returned” task after return handling completes.
Changes:
- Added a new
fulfill_order_returned_send_revoke_line_items_signaland wired it inCC_SIGNALSto the existingrevoke_line_itemsreceiver. - Removed
revoke_line_itemsfrom thefulfill_order_returned_signalreceiver list and instead manually dispatched the new signal fromfulfill_order_returned_signal_task. - Updated/expanded unit tests to assert the new signal dispatch behavior from the returned-order task and to validate the signal-to-task wiring.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| commerce_coordinator/settings/base.py | Adds new signal wiring for revoke-line-items and removes the old wiring from fulfill_order_returned_signal. |
| commerce_coordinator/apps/commercetools/signals.py | Defines the new coordinator signal. |
| commerce_coordinator/apps/commercetools/sub_messages/tasks.py | Dispatches the new signal from fulfill_order_returned_signal_task. |
| commerce_coordinator/apps/commercetools/tests/test_signals.py | Updates the signal receiver test to use the new signal. |
| commerce_coordinator/apps/commercetools/tests/sub_messages/test_tasks.py | Adds assertions that the revoke signal is dispatched (or not) in key execution paths. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
colinbrash
approved these changes
Apr 14, 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.
Revoke line items task is not being triggered from
fulfill_order_returned_signal. Create a separate signal for the revoke line items task and manually call it from the order returned task once the return is successful.Internal ticket: https://redventures.atlassian.net/browse/RV2U-473
Merge checklist:
Check off if complete or not applicable:
Post-merge: