ipykernel-helper 0.0.43__tar.gz → 0.0.45__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.
- {ipykernel_helper-0.0.43/ipykernel_helper.egg-info → ipykernel_helper-0.0.45}/PKG-INFO +1 -1
- ipykernel_helper-0.0.45/ipykernel_helper/__init__.py +2 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper/_modidx.py +1 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper/core.py +6 -2
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45/ipykernel_helper.egg-info}/PKG-INFO +1 -1
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/pyproject.toml +2 -0
- ipykernel_helper-0.0.43/ipykernel_helper/__init__.py +0 -2
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/LICENSE +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/MANIFEST.in +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/README.md +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper.egg-info/SOURCES.txt +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper.egg-info/dependency_links.txt +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper.egg-info/entry_points.txt +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper.egg-info/requires.txt +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper.egg-info/top_level.txt +0 -0
- {ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/setup.cfg +0 -0
|
@@ -49,6 +49,7 @@ d = { 'settings': { 'branch': 'main',
|
|
|
49
49
|
'ipykernel_helper.core._param_idx': ('core.html#_param_idx', 'ipykernel_helper/core.py'),
|
|
50
50
|
'ipykernel_helper.core._rank': ('core.html#_rank', 'ipykernel_helper/core.py'),
|
|
51
51
|
'ipykernel_helper.core._safe_repr': ('core.html#_safe_repr', 'ipykernel_helper/core.py'),
|
|
52
|
+
'ipykernel_helper.core._safe_sig': ('core.html#_safe_sig', 'ipykernel_helper/core.py'),
|
|
52
53
|
'ipykernel_helper.core._signatures': ('core.html#_signatures', 'ipykernel_helper/core.py'),
|
|
53
54
|
'ipykernel_helper.core.fix_editable_priority': ( 'core.html#fix_editable_priority',
|
|
54
55
|
'ipykernel_helper/core.py'),
|
|
@@ -50,6 +50,10 @@ def _safe_repr(obj, max_len=200):
|
|
|
50
50
|
except Exception as e: return f"<repr error: {str(e)}>"
|
|
51
51
|
|
|
52
52
|
# %% ../nbs/00_core.ipynb #1e600ee2
|
|
53
|
+
def _safe_sig(v):
|
|
54
|
+
try: return str(signature(v))
|
|
55
|
+
except Exception: return '(...)'
|
|
56
|
+
|
|
53
57
|
@patch
|
|
54
58
|
def user_items(self:InteractiveShell, max_len=200, xtra_skip=()):
|
|
55
59
|
"Get user-defined vars & funcs from namespace."
|
|
@@ -66,7 +70,7 @@ def user_items(self:InteractiveShell, max_len=200, xtra_skip=()):
|
|
|
66
70
|
if not k in ignore and k not in nsh}
|
|
67
71
|
user_vars = {k:_safe_repr(v, max_len=max_len)
|
|
68
72
|
for k, v in user_items.items() if not k.startswith('_') and not isinstance(v, rm_types)}
|
|
69
|
-
user_fns = {k:
|
|
73
|
+
user_fns = {k:_safe_sig(v) for k, v in user_items.items()
|
|
70
74
|
if isinstance(v, FunctionType) and v.__module__ == '__main__' and not k.startswith('__')}
|
|
71
75
|
return user_vars,user_fns
|
|
72
76
|
|
|
@@ -395,7 +399,7 @@ async def run_cell_magic(self:InteractiveShell, magic_name, line, cell):
|
|
|
395
399
|
return result
|
|
396
400
|
|
|
397
401
|
def _await_cell_magic(lines):
|
|
398
|
-
if lines and 'get_ipython().run_cell_magic(' in lines[0]: lines = ['await ' + lines[0]] + lines[1:]
|
|
402
|
+
if lines and 'get_ipython().run_cell_magic(' in lines[0] and 'await ' not in lines[0]: lines = ['await ' + lines[0]] + lines[1:]
|
|
399
403
|
return lines
|
|
400
404
|
|
|
401
405
|
def load_ipython_extension(ip):
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
{ipykernel_helper-0.0.43 → ipykernel_helper-0.0.45}/ipykernel_helper.egg-info/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|