Skip to content

32920 - Update Filer to Process Directors Based on ID Instead of Name for LEAR Filings#4256

Merged
meawong merged 7 commits intobcgov:mainfrom
meawong:32920-Identify-Distinct-Director-Records
Apr 16, 2026
Merged

32920 - Update Filer to Process Directors Based on ID Instead of Name for LEAR Filings#4256
meawong merged 7 commits intobcgov:mainfrom
meawong:32920-Identify-Distinct-Director-Records

Conversation

@meawong
Copy link
Copy Markdown
Collaborator

@meawong meawong commented Apr 13, 2026

Issue #: /bcgov/entity#32920

Description of changes:

  • Update filer to use id-based matching instead of name-based matching for director updates for LEAR-native filings
  • Maintain the name-based matching for COLIN-native filings as we don't have a way to use id-based matching (to confirm)

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of the lear license (Apache 2.0).

@meawong meawong changed the title 32920 - Update filer to match based on party id instead of director name 32920 - Update Filer to Process Directors Based on ID Instead of Name for LEAR Filings Apr 13, 2026
@bcgov bcgov deleted a comment from sonarqubecloud Bot Apr 14, 2026
for director in new_directors:
# add new diretor party role to the business
party = create_party(business_id=business.id, party_info=director)
party = create_party(business_id=business.id, party_info=director, create=False)
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

create=False is used to bypass checking for an existing matching party, this is used in flows where we are creating new directors (i.e. IA, Amalg, Registration) and should be the same for COD when we are appointing a new director

@meawong meawong self-assigned this Apr 15, 2026
@meawong meawong requested a review from ketaki-deodhar April 15, 2026 18:05
director["officer"].get("prevLastName"))
if filing_rec.colin_event_ids:
# Colin path: retain name-based matching for now.
_update_director_using_name(director=director, business_id=business.id)
Copy link
Copy Markdown
Collaborator Author

@meawong meawong Apr 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't maintain the director id from lear in colin and vice versa so keeping the existing logic for colin path (matching based on name) since there is no cross-reference for the id.

update_director(director=current_director, new_info=director)
break
# Lear path: match by party ID instead of name
_update_director_using_party_id(director=director, business_id=business.id)
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For lear-native filings, we can match by party ID instead of name.

@meawong meawong requested a review from argush3 April 16, 2026 15:23
Copy link
Copy Markdown
Collaborator

@argush3 argush3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good. just the one comment.

@sonarqubecloud
Copy link
Copy Markdown

@meawong meawong merged commit fcafbb9 into bcgov:main Apr 16, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants