-
Couldn't load subscription status.
- Fork 30
feat: Add metadata models package with dynamic schema download #807
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
Open
aaronsteers
wants to merge
21
commits into
main
Choose a base branch
from
devin/1760999875-add-metadata-models
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+2,234
−63
Open
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
ff01ea0
feat: Add metadata models package with dynamic schema download
devin-ai-integration[bot] 63930c6
refactor: Move metadata models to airbyte_cdk.test.models.connector_m…
devin-ai-integration[bot] 62902f6
refactor: Move models to generated subdirectory and add convenience i…
devin-ai-integration[bot] 3de3af0
refactor: Generate metadata models as single file with JSON schema ou…
devin-ai-integration[bot] 933d478
style: Apply ruff formatting to build script
devin-ai-integration[bot] c89faab
docs: Move metadata models documentation to CONTRIBUTING.md
devin-ai-integration[bot] 6980060
Merge branch 'main' into devin/1760999875-add-metadata-models
aaronsteers a56208b
chore: revert unrelated format changes on other generated file
aaronsteers 0f48425
Delete airbyte_cdk/test/models/connector_metadata/README.md
aaronsteers 07d7014
docs: clean up docstring (merged content from `README.md`)
aaronsteers c63223a
feat: Replace HTTP downloads with sparse git clone for metadata schemas
devin-ai-integration[bot] da4371f
Revert accidental formatting of generated file declarative_component_…
devin-ai-integration[bot] 5373480
Add exclusions for auto-generated files in ruff and pre-commit configs
devin-ai-integration[bot] 7e4e3f4
Fix JSON schema consolidation to properly resolve references
devin-ai-integration[bot] 015a60e
Remove $schema and $id from definitions to fix IDE validation
devin-ai-integration[bot] fe4b9cc
Refactor: Extract metadata generation into separate script
devin-ai-integration[bot] 66d4eeb
Move metadata generation to poe tasks instead of shell script
devin-ai-integration[bot] 23837eb
Replace Dagger with uvx in metadata generation script
devin-ai-integration[bot] c686574
Simplify metadata generation: generate Python from JSON schema
devin-ai-integration[bot] ba912fe
Fix schema consolidation per CodeRabbit feedback
devin-ai-integration[bot] 3c2a4f8
Add type annotations and fix formatting
devin-ai-integration[bot] File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
146 changes: 86 additions & 60 deletions
146
airbyte_cdk/sources/declarative/models/declarative_component_schema.py
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,10 +1,16 @@ | ||
| # Copyright (c) 2025 Airbyte, Inc., all rights reserved. | ||
| """Models used for standard tests.""" | ||
|
|
||
| from airbyte_cdk.test.models.connector_metadata import ( | ||
| ConnectorMetadataDefinitionV0, | ||
| ConnectorTestSuiteOptions, | ||
| ) | ||
| from airbyte_cdk.test.models.outcome import ExpectedOutcome | ||
| from airbyte_cdk.test.models.scenario import ConnectorTestScenario | ||
|
|
||
| __all__ = [ | ||
| "ConnectorMetadataDefinitionV0", | ||
| "ConnectorTestScenario", | ||
| "ConnectorTestSuiteOptions", | ||
| "ExpectedOutcome", | ||
| ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| """Pydantic and JSON Schema models for `metadata.yaml` validation and testing. | ||
| ## Usage | ||
| ```python | ||
| from airbyte_cdk.test.models import ConnectorMetadataDefinitionV0 | ||
| import yaml | ||
| metadata = ConnectorMetadataDefinitionV0(**yaml.safe_load(metadata_yaml)) | ||
| ``` | ||
| ## Regenerating Models | ||
| These models are auto-generated from JSON schemas in the airbytehq/airbyte repository. | ||
| For information on regenerating these models, see the Contributing Guide: | ||
| https://github.com/airbytehq/airbyte-python-cdk/blob/main/docs/CONTRIBUTING.md#regenerating-connector-metadata-models | ||
| """ | ||
|
|
||
| from .generated.models import ConnectorMetadataDefinitionV0, ConnectorTestSuiteOptions | ||
|
|
||
| __all__ = [ | ||
| "ConnectorMetadataDefinitionV0", | ||
| "ConnectorTestSuiteOptions", | ||
| ] | ||
Empty file.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.