Skip to content

Commit e8d53fe

Browse files
feat: test content-based JSONPath filter for connector schema deprecation
Try filtering schemas by content (existence of sourceType/destinationType properties) instead of by name prefix, since match() is not supported. Co-Authored-By: AJ Steers <aj@airbyte.io>
1 parent acb6928 commit e8d53fe

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

overlays/python_speakeasy.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,21 +14,21 @@ actions:
1414
$ref: "#/components/schemas/RowFilteringOperationEqual"
1515

1616
# -----------------------------------------------------------------------
17-
# Test: wildcard JSONPath to mark all source-* schemas as deprecated.
18-
# Trying several JSONPath filter syntaxes to see which (if any) Speakeasy
19-
# supports for matching schema names by prefix.
17+
# Test: wildcard JSONPath to mark connector schemas as deprecated.
18+
# Strategy: filter by content — source connectors have a sourceType
19+
# property, destination connectors have a destinationType property.
2020
# -----------------------------------------------------------------------
2121

22-
# Attempt 1: RFC 9535 match() on property name via filter
23-
- target: "$.components.schemas[?match(@, '^source-')]"
22+
# Attempt: filter schemas that have a sourceType property
23+
- target: "$.components.schemas[?(@.properties.sourceType)]"
2424
update:
2525
deprecated: true
2626
x-speakeasy-deprecation-message: >-
2727
Typed connector configuration models are deprecated and will be removed in v1.1.0.
2828
Pass configuration as a plain dict with a required 'sourceType' key instead.
2929
30-
# Attempt 2: Same for destination-*
31-
- target: "$.components.schemas[?match(@, '^destination-')]"
30+
# Attempt: filter schemas that have a destinationType property
31+
- target: "$.components.schemas[?(@.properties.destinationType)]"
3232
update:
3333
deprecated: true
3434
x-speakeasy-deprecation-message: >-

0 commit comments

Comments
 (0)