Skip to content

Commit d181da3

Browse files
committed
Fix typo
1 parent f3896b4 commit d181da3

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-6
lines changed

airbyte_cdk/sources/declarative/declarative_component_schema.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1807,7 +1807,7 @@ definitions:
18071807
type: object
18081808
required:
18091809
- property_name
1810-
- property_type_pinter
1810+
- property_type_pointer
18111811
- type_mapping
18121812
properties:
18131813
property_name:
@@ -1825,7 +1825,7 @@ definitions:
18251825
description: (This component is experimental. Use at your own risk.) Represents a mapping between a current type and its corresponding target type for property.
18261826
type: object
18271827
required:
1828-
- items_type_pinter
1828+
- items_type_pointer
18291829
- type_mapping
18301830
properties:
18311831
property_name:

airbyte_cdk/sources/declarative/parsers/model_to_component_factory.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1930,7 +1930,7 @@ def create_types_map(self, model: TypesMapModel, config: Config, **kwargs: Any)
19301930
items_type = (
19311931
self._create_component_from_model(model=model.items_type, config=config)
19321932
if model.items_type
1933-
else model.items_type
1933+
else None
19341934
)
19351935

19361936
properties_types = []

airbyte_cdk/sources/declarative/schema/dynamic_schema_loader.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ def _replace_type_if_not_valid(
251251
"""
252252
Replaces a field type if it matches a type mapping in `types_map`.
253253
"""
254-
additional_types = []
254+
additional_types: List[str] = []
255255
if self.schema_type_identifier.types_mapping:
256256
for types_map in self.schema_type_identifier.types_mapping:
257257
# conditional is optional param, setting to true if not provided
@@ -288,7 +288,6 @@ def _get_airbyte_type(
288288
"""
289289
Maps a field type to its corresponding Airbyte type definition.
290290
"""
291-
print(additional_types)
292291
if additional_types is None:
293292
additional_types = []
294293

@@ -300,6 +299,11 @@ def _get_airbyte_type(
300299
if field_type == "array" and additional_types:
301300
airbyte_type["items"] = deepcopy(AIRBYTE_DATA_TYPES[additional_types[0]])
302301

302+
# elif field_type == "object" and additional_types:
303+
# for additional_type in additional_types:
304+
#
305+
# airbyte_type["properties"] =
306+
303307
return airbyte_type
304308

305309
def _extract_data(

unit_tests/sources/declarative/schema/test_dynamic_schema_loader.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -417,5 +417,4 @@ def test_dynamic_schema_loader_with_type_conditions():
417417
actual_catalog = source.discover(logger=source.logger, config=_CONFIG)
418418

419419
assert len(actual_catalog.streams) == 1
420-
breakpoint()
421420
assert actual_catalog.streams[0].json_schema == expected_schema

0 commit comments

Comments
 (0)