From d424211ed58681ac6f9d6dce678a77914d89c6d3 2021-05-11 21:14:05 From: Matthias Bussonnier Date: 2021-05-11 21:14:05 Subject: [PATCH] Backport PR #12952: Ensure %recall does not show error after argument eval --- diff --git a/IPython/core/magics/history.py b/IPython/core/magics/history.py index 6f2138f..5af09e5 100644 --- a/IPython/core/magics/history.py +++ b/IPython/core/magics/history.py @@ -274,6 +274,7 @@ class HistoryMagics(Magics): return else: self.shell.set_next_input(cmd.rstrip()) + return print("Couldn't evaluate or find in history:", arg) @line_magic