Skip to content

Commit 0e47fd1

Browse files
fix: use search() instead of match() for partial regex matching on schema names
match() does full-string match per RFC 9535, so match(@~, '^source-') requires the entire name to be '^source-'. search() does substring match, so search(@~, '^source-') correctly finds names starting with 'source-'. Co-Authored-By: AJ Steers <aj@airbyte.io>
1 parent 4ac38d8 commit 0e47fd1

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

overlays/python_speakeasy.yaml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,20 +15,21 @@ actions:
1515
$ref: "#/components/schemas/RowFilteringOperationEqual"
1616

1717
# -----------------------------------------------------------------------
18-
# Test: RFC 9535 JSONPath with PropertyNameExtension (@~) to match
19-
# connector schemas by name prefix and mark them deprecated.
18+
# Mark all source-* and destination-* connector schemas as deprecated.
19+
# Uses RFC 9535 JSONPath with Speakeasy's @~ property-name extension.
20+
# search(@~, '^source-') matches schemas whose key starts with "source-".
2021
# -----------------------------------------------------------------------
2122

2223
# Mark all source-* connector schemas as deprecated
23-
- target: "$.components.schemas[?match(@~, '^source-')]"
24+
- target: "$.components.schemas[?search(@~, '^source-')]"
2425
update:
2526
deprecated: true
2627
x-speakeasy-deprecation-message: >-
2728
Typed connector configuration models are deprecated and will be removed in v1.1.0.
2829
Pass configuration as a plain dict with a required 'sourceType' key instead.
2930
3031
# Mark all destination-* connector schemas as deprecated
31-
- target: "$.components.schemas[?match(@~, '^destination-')]"
32+
- target: "$.components.schemas[?search(@~, '^destination-')]"
3233
update:
3334
deprecated: true
3435
x-speakeasy-deprecation-message: >-

0 commit comments

Comments
 (0)