Repository navigation
fix(registry): Handle null generated metadata and prefer releaseDate for the current version - #1390
Conversation
…for the current version Co-Authored-By: AJ Steers <aj@airbyte.io>
|
I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".
|
👋 Greetings, Airbyte Team Member!Here are some helpful tips and reminders for your convenience. 💡 Show Tips and TricksTesting This PyAirbyte VersionYou can test this version of PyAirbyte using the following: # Run PyAirbyte CLI from this branch:
uvx --from 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1792116890-registry-null-generated' pyairbyte --help
# Install PyAirbyte from this branch for development:
pip install 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1792116890-registry-null-generated'PR Slash CommandsAirbyte Maintainers can execute the following slash commands on your PR:
📚 Show Repo GuidanceHelpful ResourcesCommunity SupportQuestions? Join the #pyairbyte channel in our Slack workspace. |
There was a problem hiding this comment.
🟢 Approval recommended
The narrowly scoped fixes have focused regression coverage and no identified blocking issues.
0 open findings
What changed in this PR
This follow-up to #1382 prevents null commit metadata from breaking registry loading and aligns current-version dates with connector info.
Changes:
- Treat null
generatedandgenerated.gitvalues as missing. - Prefer
releaseDatefor the current version, retaining the commit-date fallback. - Add regression tests for both behaviors.
| File | Description |
|---|---|
| tests/unit_tests/test_mcp_connector_registry.py | Tests null metadata handling and release-date precedence. |
| airbyte/_registry_utils.py | Adds null-safe metadata access and current-version date precedence. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Code coverage overviewLanguages: Python Python / code-coverage/pytest
View coverage of the 10 most impacted files.
Python / code-coverage/pytest-unit
Line coverage data for the release-candidate/v1 branch is not yet available. View coverage of the 10 most covered files.
ℹ️ Calculations represent line coverage. Results may change as calculations are updated. Updated |
2a42e14
into
release-candidate/v1
Overview
👉 TL;DR: If a single connector in the registry had empty commit metadata, loading the connector catalog failed, and every connector lookup failed with it. Version history could also report a different date for the current release than connector info did.
Specifically,
registry_entry_commit_datenow treats a nullgenerated/generated.gitas missing, andfetch_registry_version_datenow prefers the entry'sreleaseDatefor the current version.Follows up on #1382:
release_date#1382Changes
registry_entry_commit_date:(entry.get("generated") or {}).get("git") or {}. Before this,.get(k, {})returnedNoneon a JSON null, and the next lookup raisedAttributeErrorinside_get_registry_cache.fetch_registry_version_date(current-version branch):connector.get("releaseDate") or registry_entry_commit_date(connector), matching_registry_entry_to_connector_metadata. The release-candidate branch is unchanged.generated/ nullgit, metadata conversion withgenerated=None, andreleaseDatewinning over the commit timestamp.Review Spotlight
Reviewers with limited time, please review first:
_registry_utils.py#L86-L119: both fixesTest plan
uv run pytest tests/unit_tests/test_mcp_connector_registry.py: 36 passedLink to Devin session: https://app.devin.ai/sessions/a51d808f26c9402fafc93e7640648187
Open in Devin Desktop: https://app.devin.ai/desktop/session/a51d808f26c9402fafc93e7640648187?variant=devin
Requested by: Aaron ("AJ") Steers (@aaronsteers)