peek-python 1.4.4__tar.gz → 1.4.5__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.
- {peek_python-1.4.4 → peek_python-1.4.5}/PKG-INFO +1 -1
- {peek_python-1.4.4 → peek_python-1.4.5}/peek/peek.py +18 -5
- {peek_python-1.4.4 → peek_python-1.4.5}/peek_python.egg-info/PKG-INFO +1 -1
- {peek_python-1.4.4 → peek_python-1.4.5}/pyproject.toml +1 -1
- {peek_python-1.4.4 → peek_python-1.4.5}/README.md +0 -0
- {peek_python-1.4.4 → peek_python-1.4.5}/license.txt +0 -0
- {peek_python-1.4.4 → peek_python-1.4.5}/peek/__init__.py +0 -0
- {peek_python-1.4.4 → peek_python-1.4.5}/peek_python.egg-info/SOURCES.txt +0 -0
- {peek_python-1.4.4 → peek_python-1.4.5}/peek_python.egg-info/dependency_links.txt +0 -0
- {peek_python-1.4.4 → peek_python-1.4.5}/peek_python.egg-info/top_level.txt +0 -0
- {peek_python-1.4.4 → peek_python-1.4.5}/setup.cfg +0 -0
- {peek_python-1.4.4 → peek_python-1.4.5}/tests/test_peek.py +0 -0
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
# | .__/ \___| \___||_|\_\
|
|
5
5
|
# |_| like print, but easy.
|
|
6
6
|
|
|
7
|
-
__version__ = "1.4.
|
|
7
|
+
__version__ = "1.4.5"
|
|
8
8
|
|
|
9
9
|
"""
|
|
10
10
|
See https://github.com/salabim/peek for details
|
|
@@ -208,7 +208,7 @@ shortcut_to_name = {
|
|
|
208
208
|
def set_defaults():
|
|
209
209
|
default.prefix = ""
|
|
210
210
|
default.output = "stdout"
|
|
211
|
-
default.serialize = pprint.pformat
|
|
211
|
+
default.serialize = pprint.pformat
|
|
212
212
|
default.show_line_number = False
|
|
213
213
|
default.show_time = False
|
|
214
214
|
default.show_delta = False
|
|
@@ -288,7 +288,7 @@ def return_args(args, return_none):
|
|
|
288
288
|
return args
|
|
289
289
|
|
|
290
290
|
|
|
291
|
-
class _Peek
|
|
291
|
+
class _Peek:
|
|
292
292
|
def __init__(
|
|
293
293
|
self,
|
|
294
294
|
prefix=nv,
|
|
@@ -885,7 +885,7 @@ class _Peek():
|
|
|
885
885
|
if "width" in inspect.signature(self.serialize).parameters:
|
|
886
886
|
kwargs["width"] = width
|
|
887
887
|
|
|
888
|
-
return self.serialize(obj, **kwargs).replace("\\n", "\n")
|
|
888
|
+
return self.serialize(obj, **kwargs).replace("\\n", "\n")
|
|
889
889
|
|
|
890
890
|
|
|
891
891
|
codes = {}
|
|
@@ -894,5 +894,18 @@ set_defaults()
|
|
|
894
894
|
default_pre_json = copy.copy(default)
|
|
895
895
|
apply_json()
|
|
896
896
|
peek = _Peek()
|
|
897
|
-
p=peek.fork()
|
|
897
|
+
p = peek.fork()
|
|
898
898
|
|
|
899
|
+
|
|
900
|
+
class PeekModule(types.ModuleType):
|
|
901
|
+
def __call__(self, *args, **kwargs):
|
|
902
|
+
return peek(*args, **kwargs)
|
|
903
|
+
|
|
904
|
+
def __setattr__(self, item, value):
|
|
905
|
+
setattr(peek, item, value)
|
|
906
|
+
|
|
907
|
+
def __getattr__(self, item):
|
|
908
|
+
return getattr(peek, item)
|
|
909
|
+
|
|
910
|
+
|
|
911
|
+
sys.modules["peek"].__class__ = PeekModule
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|