Skip to content

Commit

Permalink
Include http method in SimpleRetriever log message for requests (#1…
Browse files Browse the repository at this point in the history
…9964)

* Add http method to `SimpleRetriever` log message on request

* Update setup.py (bump version to 0.11.2)

* Update CHANGELOG.md
  • Loading branch information
clnoll committed Dec 1, 2022
1 parent 5da3a7c commit 44a1440
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions airbyte-cdk/python/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog

## 0.11.2
Low-code: Include the HTTP method used by the request in logging output of the `airbyte-cdk`

## 0.11.1
Low-code: Fix the component manifest schema to and validate check instead of checker

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ def parse_records_and_emit_request_and_responses(self, request, response, stream

def _create_trace_message_from_request(self, request: requests.PreparedRequest):
# FIXME: this should return some sort of trace message
request_dict = {"url": request.url, "headers": dict(request.headers), "body": request.body}
request_dict = {"url": request.url, "http_method": request.method, "headers": dict(request.headers), "body": request.body}
log_message = filter_secrets(f"request:{json.dumps(request_dict)}")
return AirbyteMessage(type=MessageType.LOG, log=AirbyteLogMessage(level=Level.INFO, message=log_message))

Expand Down
2 changes: 1 addition & 1 deletion airbyte-cdk/python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

setup(
name="airbyte-cdk",
version="0.11.1",
version="0.11.2",
description="A framework for writing Airbyte Connectors.",
long_description=README,
long_description_content_type="text/markdown",
Expand Down

0 comments on commit 44a1440

Please sign in to comment.