Skip to content

Entity matching pipeline hardening, observability, and cleanup#303

Merged
BergsethCognite merged 2 commits into
mainfrom
em_v3
May 29, 2026
Merged

Entity matching pipeline hardening, observability, and cleanup#303
BergsethCognite merged 2 commits into
mainfrom
em_v3

Conversation

@BergsethCognite
Copy link
Copy Markdown
Contributor

  • Fixed runtime bug in read_manual_mappings (early-return shape mismatch crashed pipelines without the manual mapping table) and corrected its return-type annotation
  • Replaced boolean filter checks with is not None to silence the SDK UserWarning and match its documented contract
  • Made the Mixpanel usage tracker truly best-effort (daemon=True + try/except inside the thread body)
  • Dropped redundant patch_existing_pipeline() call from run_locally
  • Lazy-imported RawUploadQueue so pipeline.py is testable without cognite-extractor-utils
  • Wired pipeline_optimizations helpers into production: pre-compiled rule regexes, RobustAPIClient retry around all 9 instances.apply sites, time_operation per major phase, monitor_memory_usage + cleanup_memory at phase boundaries
  • Slimmed pipeline_optimizations.py and test_optimizations.py (~60% smaller) — kept only the 6 helpers actually used in production
  • Fixed pre-existing test_handler.py rot (stale asset_entity_matching patch targets, drifted constants, over-strict assertions): now 11/11 passing instead of 1/11
  • Rewrote the function README's Testing section (run commands, prerequisites, what's covered) and updated the helpers/advanced-usage sections to match reality
  • All 16 tests passing, lint clean, no warnings

@BergsethCognite BergsethCognite requested a review from a team as a code owner May 29, 2026 12:33
@gemini-code-assist
Copy link
Copy Markdown
Contributor

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

@BergsethCognite BergsethCognite merged commit 1dc8dbf into main May 29, 2026
6 checks passed
@BergsethCognite BergsethCognite deleted the em_v3 branch May 29, 2026 14:20
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.

2 participants