Skip to content

Commit bab2781

Browse files
Fix ruff format issues
Co-Authored-By: AJ Steers <[email protected]>
1 parent c581827 commit bab2781

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

airbyte_cdk/sources/abstract_source.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -198,9 +198,9 @@ def read(
198198
logger.info(timer.report())
199199

200200
if len(stream_name_to_exception) > 0:
201-
error_message = generate_failed_streams_error_message({
202-
key: [value] for key, value in stream_name_to_exception.items()
203-
})
201+
error_message = generate_failed_streams_error_message(
202+
{key: [value] for key, value in stream_name_to_exception.items()}
203+
)
204204
logger.info(error_message)
205205
# We still raise at least one exception when a stream raises an exception because the platform currently relies
206206
# on a non-zero exit code to determine if a sync attempt has failed. We also raise the exception as a config_error

airbyte_cdk/sources/declarative/retrievers/simple_retriever.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -715,7 +715,11 @@ def fetch_one(
715715
)
716716
except Exception as e:
717717
# Check if this is a 404 (record not found) - raise RecordNotFoundException
718-
if "404" in str(e) or (hasattr(e, "response") and hasattr(e.response, "status_code") and e.response.status_code == 404):
718+
if "404" in str(e) or (
719+
hasattr(e, "response")
720+
and hasattr(e.response, "status_code")
721+
and e.response.status_code == 404
722+
):
719723
raise RecordNotFoundException(
720724
f"Record with primary key {pk_value} not found"
721725
) from e

0 commit comments

Comments
 (0)