Skip to content

Commit

Permalink
Do not swallow return_value (#44)
Browse files Browse the repository at this point in the history
* Do not swallow return_value

* Add this PR to CHANGELOG
  • Loading branch information
nelz9999 authored and haotianw465 committed Mar 21, 2018
1 parent 9ff8539 commit 4f91e5f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ unreleased
* bugfix: SQLAlcemy plugin would cause warning messages with some db connection strings that contained invalid characters for a segment/subsegment name.
* bugfix: Aiohttp middleware serialized URL values incorrectly. `PR37 <https://github.com/aws/aws-xray-sdk-python/pull/37>`_
* bugfix: Don't overwrite plugins list on each `.configure` call. `PR38 <https://github.com/aws/aws-xray-sdk-python/pull/38>`_
* bugfix: Do not swallow `return_value`. `PR44 <https://github.com/aws/aws-xray-sdk-python/pull/44>`_

0.96
====
Expand Down
2 changes: 1 addition & 1 deletion aws_xray_sdk/core/recorder.py
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ def record_subsegment(self, wrapped, instance, args, kwargs, name,
finally:
# No-op if subsegment is `None` due to `LOG_ERROR`.
if subsegment is None:
return
return return_value

end_time = time.time()
if callable(meta_processor):
Expand Down
3 changes: 2 additions & 1 deletion tests/ext/botocore/test_botocore.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ def test_pass_through_on_context_missing():

with Stubber(ddb) as stubber:
stubber.add_response('describe_table', response, {'TableName': 'mytable'})
ddb.describe_table(TableName='mytable')
result = ddb.describe_table(TableName='mytable')
assert result is not None

xray_recorder.configure(context_missing='RUNTIME_ERROR')

0 comments on commit 4f91e5f

Please sign in to comment.