Skip to content

Commit e15939f

Browse files
committed
Corrected mistake where logging was turned off instead of contracts
1 parent fb80627 commit e15939f

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

snowplow_tracker/tracker.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ class Tracker:
5858
@contract
5959
def __init__(self, out_queue, _subject=None,
6060
namespace=None, app_id=None, context_vendor=None, encode_base64=DEFAULT_ENCODE_BASE64,
61-
contracts=True):
61+
log=True):
6262
"""
6363
:param out_queue: Consumer to which events will be sent
6464
:type out_queue: consumer
@@ -72,11 +72,11 @@ def __init__(self, out_queue, _subject=None,
7272
:type context_vendor: string_or_none
7373
:param encode_base64: Whether JSONs in the payload should be base-64 encoded
7474
:type encode_base64: bool
75-
:param contracts: Whether to enable contracts
76-
:type contracts: bool
75+
:param log: Whether to enable Python logging
76+
:type log: bool
7777
"""
78-
if not contracts:
79-
disable_all()
78+
if not log:
79+
logger.setLevel(logging.CRITICAL)
8080

8181
if _subject is None:
8282
_subject = subject.Subject()

0 commit comments

Comments
 (0)