Skip to content

Commit

Permalink
misc : added some debugging options
Browse files Browse the repository at this point in the history
Probably will release these sometime
  • Loading branch information
mos9527 committed Dec 10, 2022
1 parent 6cafa0d commit 1a4ea53
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
7 changes: 5 additions & 2 deletions demos/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ def login():

assert_dep("pyncm")
assert_dep("inquirer")
from pyncm import __version__
# Find pyncm from working directories first
import sys
sys.path.insert(0,'.')

print("PyNCM %s" % __version__)
from pyncm import __version__,__file__
print("PyNCM %s" % __version__,__file__)
7 changes: 4 additions & 3 deletions pyncm/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,11 @@
from typing import Text, Union
from time import time
from .utils.crypto import EapiEncrypt, EapiDecrypt, HexCompose
import requests, logging, json
import requests, logging, json, os
logger = logging.getLogger("pyncm.api")

__version__ = "1.6.8.3"
if 'PYNCM_DEBUG' in os.environ:
logging.basicConfig(level='DEBUG', format="[%(levelname).4s] %(name)s %(message)s")
__version__ = "1.6.8.4"

DEVICE_ID_DEFAULT = "pyncm!"
# This sometimes fails with some strings, for no particular reason. Though `pyncm!` seem to work everytime..?
Expand Down

0 comments on commit 1a4ea53

Please sign in to comment.