Skip to content

Commit 92b9dff

Browse files
author
maxime.c
committed
format/lint
1 parent fbf907c commit 92b9dff

File tree

3 files changed

+13
-15
lines changed

3 files changed

+13
-15
lines changed

airbyte_cdk/sources/declarative/parsers/model_to_component_factory.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,9 @@
122122
DEPRECATION_LOGS_TAG,
123123
BaseModelWithDeprecations,
124124
)
125+
from airbyte_cdk.sources.declarative.models.declarative_component_schema import (
126+
Action1 as PaginationResetActionModel,
127+
)
125128
from airbyte_cdk.sources.declarative.models.declarative_component_schema import (
126129
AddedFieldDefinition as AddedFieldDefinitionModel,
127130
)
@@ -362,9 +365,6 @@
362365
from airbyte_cdk.sources.declarative.models.declarative_component_schema import (
363366
PaginationReset as PaginationResetModel,
364367
)
365-
from airbyte_cdk.sources.declarative.models.declarative_component_schema import (
366-
Action1 as PaginationResetActionModel,
367-
)
368368
from airbyte_cdk.sources.declarative.models.declarative_component_schema import (
369369
ParametrizedComponentsResolver as ParametrizedComponentsResolverModel,
370370
)

airbyte_cdk/sources/streams/concurrent/cursor.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -555,7 +555,9 @@ def reduce_slice_range(self, stream_slice: StreamSlice) -> StreamSlice:
555555
]: self._connector_state_converter.output_format(
556556
self._most_recent_cursor_value_per_partition[stream_slice]
557557
),
558-
self._slice_boundary_fields_wrapper[self._END_BOUNDARY]: stream_slice.cursor_slice[
558+
self._slice_boundary_fields_wrapper[
559+
self._END_BOUNDARY
560+
]: stream_slice.cursor_slice[
559561
self._slice_boundary_fields_wrapper[self._END_BOUNDARY]
560562
],
561563
},

unit_tests/sources/declarative/test_concurrent_declarative_source.py

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4947,8 +4947,11 @@ def test_given_pagination_reset_action_is_reset_even_though_stream_is_incrementa
49474947
HttpResponse(
49484948
json.dumps(
49494949
{
4950-
"results": [{"id": 1, "updated_at": "2022-02-01"}, {"id": 2, "updated_at": "2022-03-01"}],
4951-
"next": "https://example.org/test?from=2022-01-01&cursor=toto"
4950+
"results": [
4951+
{"id": 1, "updated_at": "2022-02-01"},
4952+
{"id": 2, "updated_at": "2022-03-01"},
4953+
],
4954+
"next": "https://example.org/test?from=2022-01-01&cursor=toto",
49524955
}
49534956
),
49544957
200,
@@ -4958,15 +4961,8 @@ def test_given_pagination_reset_action_is_reset_even_though_stream_is_incrementa
49584961
HttpRequest("https://example.org/test?from=2022-01-01&cursor=toto"),
49594962
[
49604963
HttpResponse(json.dumps({}), 400),
4961-
HttpResponse(
4962-
json.dumps(
4963-
{
4964-
"results": [{"id": 3, "updated_at": "2022-04-01"}]
4965-
}
4966-
),
4967-
200
4968-
),
4969-
]
4964+
HttpResponse(json.dumps({"results": [{"id": 3, "updated_at": "2022-04-01"}]}), 200),
4965+
],
49704966
)
49714967
messages = list(
49724968
source.read(logger=source.logger, config=input_config, catalog=catalog, state=[])

0 commit comments

Comments
 (0)