jorgebastida / jorgebastida/awslogs

Issue when time is added to log group

Open
#145 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
5k
Forks
342
PR merge metrics
No merged PRs in 30d

Description

================================================================================
You've found a bug! Please, raise an issue attaching the following traceback
https://github.com/jorgebastida/awslogs/issues/new
--------------------------------------------------------------------------------
Version: 0.10.0
Python: 2.7.10 (default, Feb 7 2017, 00:08:15)
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]
boto3 version: 1.4.5
Platform: Darwin-16.7.0-x86_64-i386-64bit
Config: {'output_timestamp_enabled': False, 'output_group_enabled': True, 'end': '2017-07-10T05:25:24', 'log_group_name': 'service-production', 'log_stream_name': 'ALL', 'aws_region': None, 'watch': False, 'aws_access_key_id': 'SENSITIVE', 'start': '2017-07-10T05:22:24', 'aws_profile': 'SENSITIVE', 'filter_pattern': None, 'aws_secret_access_key': 'SENSITIVE', 'output_ingestion_time_enabled': False, 'query': None, 'func': 'list_logs', 'aws_session_token': 'SENSITIVE', 'color_enabled': True, 'output_stream_enabled': True}
Args: ['/usr/local/bin/awslogs', 'get', 'service-production', '--start=2017-07-10T05:22:24', '--end=2017-07-10T05:25:24']

Traceback (most recent call last):
File "/Library/Python/2.7/site-packages/awslogs/bin.py", line 172, in main
getattr(logs, options.func)()
File "/Library/Python/2.7/site-packages/awslogs/core.py", line 196, in list_logs
consumer()
File "/Library/Python/2.7/site-packages/awslogs/core.py", line 137, in consumer
for event in generator():
File "/Library/Python/2.7/site-packages/awslogs/core.py", line 124, in generator
response = self.client.filter_log_events(**kwargs)
File "/Library/Python/2.7/site-packages/botocore/client.py", line 310, in _api_call
return self._make_api_call(operation_name, kwargs)
File "/Library/Python/2.7/site-packages/botocore/client.py", line 586, in _make_api_call
operation_model, request_dict)
File "/Library/Python/2.7/site-packages/botocore/endpoint.py", line 141, in make_request
return self._send_request(request_dict, operation_model)
File "/Library/Python/2.7/site-packages/botocore/endpoint.py", line 170, in _send_request
success_response, exception):
File "/Library/Python/2.7/site-packages/botocore/endpoint.py", line 249, in _needs_retry
caught_exception=caught_exception, request_dict=request_dict)
File "/Library/Python/2.7/site-packages/botocore/hooks.py", line 227, in emit
return self._emit(event_name, kwargs)
File "/Library/Python/2.7/site-packages/botocore/hooks.py", line 210, in _emit
response = handler(**kwargs)
File "/Library/Python/2.7/site-packages/botocore/retryhandler.py", line 183, in __call__
if self._checker(attempts, response, caught_exception):
File "/Library/Python/2.7/site-packages/botocore/retryhandler.py", line 251, in __call__
caught_exception)
File "/Library/Python/2.7/site-packages/botocore/retryhandler.py", line 269, in _should_retry
return self._checker(attempt_number, response, caught_exception)
File "/Library/Python/2.7/site-packages/botocore/retryhandler.py", line 317, in __call__
caught_exception)
File "/Library/Python/2.7/site-packages/botocore/retryhandler.py", line 223, in __call__
attempt_number, caught_exception)
File "/Library/Python/2.7/site-packages/botocore/retryhandler.py", line 359, in _check_caught_exception
raise caught_exception
error: [Errno 54] Connection reset by peer

Contributor guide

No contributing guide indexed for this repository

Research direction

The traceback points to awslogs/core.py, especially list_logs, consumer, and generator, with failure during filter_log_events for the shown --start/--end command. Reproduce that command and inspect the boto3/botocore request and retry path. Done should mean the cause is understood and the resulting behavior is covered by a regression test.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, python
Domain
cli, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.