Skip to content

Fix critical and important review findings#1

Merged
nicosuave merged 1 commit intomainfrom
fix-review-findings
Feb 16, 2026
Merged

Fix critical and important review findings#1
nicosuave merged 1 commit intomainfrom
fix-review-findings

Conversation

@nicosuave
Copy link
Member

Summary

  • Fix API key transport (critical): OpenLineageClient(options={"api_key": ...}) passed a plain dict where OpenLineageClientOptions dataclass is expected, crashing any authenticated deployment. Now uses OpenLineageClientOptions(api_key=api_key).
  • Wrap all emit calls in try/except (critical): OL endpoint failures no longer propagate into SQLMesh scheduler. All emit paths in both emitter.py and console.py are protected with warning-level logging.
  • Thread-safe install: install() now uses threading.Lock to prevent double-installation under concurrent calls.
  • Fix env var fallthrough: namespace or os.environ.get(...) replaced with namespace if namespace is not None else ... so passing explicit empty string doesn't silently fall through to env vars.
  • Fix custom facet schemaURL: Points to project repo instead of nonexistent openlineage.io path.
  • Remove unused import: from sqlmesh.core.model import Model in datasets.py (ruff F401).
  • 3 new tests: API key uses ClientOptions, emit failure resilience on start and complete (27 total).

- Fix API key transport: use OpenLineageClientOptions instead of plain
  dict, which crashed any authenticated deployment
- Wrap all emit calls in try/except so OL failures never crash SQLMesh
  plan execution
- Thread-safe install() with threading.Lock
- Fix namespace/url env var fallthrough using is-not-None checks
- Fix custom facet schemaURL to point to project repo
- Remove unused Model import (ruff F401)
- Add tests for API key handling and emit resilience (27 total)
@nicosuave nicosuave merged commit 28e29a7 into main Feb 16, 2026
2 checks passed
@nicosuave nicosuave deleted the fix-review-findings branch February 16, 2026 15:01
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.

1 participant

Comments