summaryrefslogtreecommitdiffstats
path: root/contrib/python/ipython/py3/IPython/core/magics
diff options
context:
space:
mode:
authorrobot-piglet <[email protected]>2024-04-15 10:18:44 +0300
committerrobot-piglet <[email protected]>2024-04-15 10:26:35 +0300
commit7930380b354abe9969174901a4e8a730ab1d0906 (patch)
tree43c5e5107bc0cf0ac7c74f82874451a7a83aa173 /contrib/python/ipython/py3/IPython/core/magics
parent969a7065950f3f4c76d45c7bb813a3e27df8a466 (diff)
Intermediate changes
Diffstat (limited to 'contrib/python/ipython/py3/IPython/core/magics')
-rw-r--r--contrib/python/ipython/py3/IPython/core/magics/basic.py3
-rw-r--r--contrib/python/ipython/py3/IPython/core/magics/execution.py2
2 files changed, 4 insertions, 1 deletions
diff --git a/contrib/python/ipython/py3/IPython/core/magics/basic.py b/contrib/python/ipython/py3/IPython/core/magics/basic.py
index 3ac4049614e..3e3eb2d3f83 100644
--- a/contrib/python/ipython/py3/IPython/core/magics/basic.py
+++ b/contrib/python/ipython/py3/IPython/core/magics/basic.py
@@ -40,6 +40,9 @@ class MagicsDisplay(object):
def _repr_pretty_(self, p, cycle):
p.text(self._lsmagic())
+ def __repr__(self):
+ return self.__str__()
+
def __str__(self):
return self._lsmagic()
diff --git a/contrib/python/ipython/py3/IPython/core/magics/execution.py b/contrib/python/ipython/py3/IPython/core/magics/execution.py
index 4147dac9637..f3688f4eb08 100644
--- a/contrib/python/ipython/py3/IPython/core/magics/execution.py
+++ b/contrib/python/ipython/py3/IPython/core/magics/execution.py
@@ -1506,7 +1506,7 @@ class ExecutionMagics(Magics):
@line_cell_magic
def code_wrap(self, line, cell=None):
"""
- Simple magic to quickly define a code transformer for all IPython's future imput.
+ Simple magic to quickly define a code transformer for all IPython's future input.
``__code__`` and ``__ret__`` are special variable that represent the code to run
and the value of the last expression of ``__code__`` respectively.