Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf0e0b32

Browse files
committed
Bumped v0.7.1
Signed-off-by: Vishal Rana <vr@labstack.com>
1 parent463337d commitf0e0b32

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

‎labstack/log.py‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def excepthook(type, value, trace):
2323
sys.__excepthook__(type,value,trace)
2424
sys.excepthook=excepthook
2525

26-
def_dispatch(self,entry):
26+
def_write(self,entry):
2727
r=requests.post(API_URL+self.path,auth=self.interceptor,data=json.dumps(entry))
2828
ifnot200<=r.status_code<300:
2929
data=r.json()
@@ -51,11 +51,15 @@ def _log(self, level, **kwargs):
5151
iflevel<self.level:
5252
return
5353

54+
# Log fields
5455
kwargs['time']=arrow.now().format('YYYY-MM-DDTHH:mm:ss.SSSZ')
5556
kwargs['level']=level.name
57+
fork,vinself.fields.items():
58+
kwargs[k]=v
5659

60+
# Write log
5761
try:
58-
self._dispatch(kwargs)
62+
self._write(kwargs)
5963
exceptLogErroraserr:
6064
print('log error: code={}, message={}'.format(err.code,err.message))
6165

‎setup.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
setup(
44
name='labstack',
5-
version='0.7.0',
5+
version='0.7.1',
66
description='Official Python client library for the LabStack platform',
77
long_description='`<https://github.com/labstack/labstack-python>`_',
88
keywords='labstack cube email log mqtt store',

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp