Skip to content

Commit 8ff3540

Browse files
committed
Add package logging initialization
Set default logging handler to avoid "No handler found" warnings.
1 parent 6a3da82 commit 8ff3540

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

ciscosparkapi/__init__.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
from builtins import *
1313
from past.builtins import basestring
1414

15+
import logging
1516
import os
1617

1718
from ciscosparkapi.exceptions import ciscosparkapiException, SparkApiError
@@ -49,6 +50,12 @@
4950
ACCESS_TOKEN_ENVIRONMENT_VARIABLE = 'SPARK_ACCESS_TOKEN'
5051

5152

53+
# Initialize Package Logging
54+
logger = logging.getLogger(__name__)
55+
logger.addHandler(logging.NullHandler())
56+
57+
58+
# Main Package Interface
5259
class CiscoSparkAPI(object):
5360
"""Cisco Spark API wrapper.
5461

0 commit comments

Comments
 (0)