Skip to content

Commit f841fe5

Browse files
author
alexandr
committed
RPPT-001 | Use 79 char length
1 parent 3cf0275 commit f841fe5

File tree

2 files changed

+15
-7
lines changed

2 files changed

+15
-7
lines changed

pytest_reportportal/rp_logging.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ class RPLogger(logging.getLoggerClass()):
88
def __init__(self, name, level=0):
99
super(RPLogger, self).__init__(name, level=level)
1010

11-
def _log(self, level, msg, args, exc_info=None, extra=None, stack_info=False, attachment=None):
11+
def _log(self, level, msg, args,
12+
exc_info=None, extra=None, stack_info=False, attachment=None):
1213
"""
1314
Low-level logging routine which creates a LogRecord and then calls
1415
all the handlers of this logger to handle the record.
@@ -28,7 +29,9 @@ def _log(self, level, msg, args, exc_info=None, extra=None, stack_info=False, at
2829
if exc_info and not isinstance(exc_info, tuple):
2930
exc_info = sys.exc_info()
3031

31-
record = self.makeRecord(self.name, level, fn, lno, msg, args, exc_info, func, extra, sinfo)
32+
record = self.makeRecord(
33+
self.name, level, fn, lno, msg, args, exc_info, func, extra, sinfo
34+
)
3235
record.attachment = attachment
3336
self.handle(record)
3437

pytest_reportportal/service.py

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ def init_service(self, endpoint, project, uuid, log_batch_size,
4040
self.ignore_errors = ignore_errors
4141
self.ignored_tags = ignored_tags
4242
logging.debug(
43-
msg='ReportPortal - Init service: endpoint={0}, project={1}, uuid={2}'.
43+
msg='ReportPortal - Init service: '
44+
'endpoint={0}, project={1}, uuid={2}'.
4445
format(endpoint, project, uuid))
4546
self.RP = ReportPortalServiceAsync(
4647
endpoint=endpoint,
@@ -85,9 +86,11 @@ def start_launch(
8586
'mode': mode,
8687
'tags': tags
8788
}
88-
logging.debug('ReportPortal - Start launch: request_body=%s', sl_pt)
89+
logging.debug('ReportPortal - Start launch: '
90+
'request_body=%s', sl_pt)
8991
req_data = self.RP.start_launch(**sl_pt)
90-
logging.debug('ReportPortal - Launch started: response_body=%s', req_data)
92+
logging.debug('ReportPortal - Launch started: '
93+
'response_body=%s', req_data)
9194

9295
def start_pytest_item(self, test_item=None):
9396
self._stop_if_necessary()
@@ -102,7 +105,8 @@ def start_pytest_item(self, test_item=None):
102105
'item_type': 'STEP'
103106
}
104107

105-
logging.debug('ReportPortal - Start TestItem: request_body=%s', start_rq)
108+
logging.debug('ReportPortal - Start TestItem: '
109+
'request_body=%s', start_rq)
106110
self.RP.start_test_item(**start_rq)
107111

108112
def _get_tags(self, test_item):
@@ -127,7 +131,8 @@ def finish_pytest_item(self, status, issue=None):
127131
'issue': issue
128132
}
129133

130-
logging.debug('ReportPortal - Finish TestItem: request_body=%s', fta_rq)
134+
logging.debug('ReportPortal - Finish TestItem: '
135+
'request_body=%s', fta_rq)
131136
self.RP.finish_test_item(**fta_rq)
132137

133138
def finish_launch(self, launch=None, status='rp_launch'):

0 commit comments

Comments
 (0)