python-printr 3.2__tar.gz → 3.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python-printr-3.2/python_printr.egg-info → python-printr-3.3}/PKG-INFO +1 -1
- {python-printr-3.2 → python-printr-3.3}/printr/__init__.py +4 -3
- {python-printr-3.2 → python-printr-3.3/python_printr.egg-info}/PKG-INFO +1 -1
- {python-printr-3.2 → python-printr-3.3}/setup.py +1 -1
- {python-printr-3.2 → python-printr-3.3}/.gitignore +0 -0
- {python-printr-3.2 → python-printr-3.3}/README.md +0 -0
- {python-printr-3.2 → python-printr-3.3}/python_printr.egg-info/SOURCES.txt +0 -0
- {python-printr-3.2 → python-printr-3.3}/python_printr.egg-info/dependency_links.txt +0 -0
- {python-printr-3.2 → python-printr-3.3}/python_printr.egg-info/requires.txt +0 -0
- {python-printr-3.2 → python-printr-3.3}/python_printr.egg-info/top_level.txt +0 -0
- {python-printr-3.2 → python-printr-3.3}/setup.cfg +0 -0
|
@@ -3,7 +3,7 @@ from pathlib import Path
|
|
|
3
3
|
from datetime import datetime
|
|
4
4
|
|
|
5
5
|
class logger:
|
|
6
|
-
def __init__(self, log_filepath=None, max_lines=100_000, level='info', name=None, log_to_file=
|
|
6
|
+
def __init__(self, log_filepath=None, max_lines=100_000, level='info', name=None, log_to_file=True):
|
|
7
7
|
filename = Path(sys.argv[0]).stem
|
|
8
8
|
self.filename = filename
|
|
9
9
|
if not log_filepath:
|
|
@@ -56,8 +56,6 @@ class logger:
|
|
|
56
56
|
self.logger.error(message)
|
|
57
57
|
elif level == 'debug':
|
|
58
58
|
self.logger.debug(message)
|
|
59
|
-
elif level == 'success':
|
|
60
|
-
self.logger.success(message)
|
|
61
59
|
elif level == 'warning':
|
|
62
60
|
self.logger.warning(message)
|
|
63
61
|
|
|
@@ -156,6 +154,9 @@ class printr:
|
|
|
156
154
|
def __init__(self, *items, same_line=False, current_time=False, check_for_log=True, level='info', beautify=True):
|
|
157
155
|
print(*items, same_line=same_line, current_time=current_time, check_for_log=check_for_log, level=level, beautify=beautify)
|
|
158
156
|
|
|
157
|
+
# from rich.pretty import pretty_repr
|
|
158
|
+
# from rich.text import Text
|
|
159
|
+
|
|
159
160
|
def prettify(items, beautify):
|
|
160
161
|
message = ''
|
|
161
162
|
for item in items:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|