-
Notifications
You must be signed in to change notification settings - Fork 81
Filer - Receiver/Liquidator DRS publishing #4035
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
base: main
Are you sure you want to change the base?
Changes from all commits
8929649
4f3b4e1
685527d
3eb12e9
332008c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -35,6 +35,7 @@ | |
| import copy | ||
|
|
||
| from business_model.models import Business, Filing, PartyRole | ||
| from flask import current_app | ||
|
|
||
| from business_filer.filing_meta import FilingMeta | ||
| from business_filer.filing_processors.filing_components.filings import update_filing_court_order | ||
|
|
@@ -44,6 +45,7 @@ | |
| update_relationship_addresses, | ||
| update_relationship_entity_info, | ||
| ) | ||
| from business_filer.services.publish_event import PublishEvent | ||
|
|
||
|
|
||
| def process(business: Business, filing_rec: Filing, filing_meta: FilingMeta): | ||
|
|
@@ -69,4 +71,11 @@ def process(business: Business, filing_rec: Filing, filing_meta: FilingMeta): | |
| if court_order := filing_json["filing"]["changeOfReceivers"].get("courtOrder"): | ||
| update_filing_court_order(filing_rec, court_order) | ||
|
|
||
| # FUTURE: DRS integration with document id | ||
| try: | ||
| # Create DRS record | ||
| PublishEvent.publish_drs_create_message(current_app, business, filing_rec) | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think its better to move this after commit, that's what we follow in filer for other messages https://github.com/bcgov/lear/blob/main/queue_services/business-filer/src/business_filer/services/filer.py#L277
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yeah that makes sense - will do |
||
|
|
||
| except Exception as err: | ||
| # log error for ops, but don't prevent filing from completing | ||
| current_app.logger.warning(err.with_traceback(None)) | ||
| current_app.logger.warning(f"Failed to create DRS Record for {filing_rec.id}.") | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you move this to dev dependencies