Skip to content

Commit 77e8abd

Browse files
committed
Add notes deprecating in_ipnb and in_qtconsole
1 parent bfdca6b commit 77e8abd

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

pandas/core/common.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2599,6 +2599,8 @@ def check_main():
25992599
def in_qtconsole():
26002600
"""
26012601
check if we're inside an IPython qtconsole
2602+
2603+
DEPRECATED: This is no longer needed, or working, in IPython 3 and above.
26022604
"""
26032605
try:
26042606
ip = get_ipython()
@@ -2616,6 +2618,9 @@ def in_qtconsole():
26162618
def in_ipnb():
26172619
"""
26182620
check if we're inside an IPython Notebook
2621+
2622+
DEPRECATED: This is no longer used in pandas, and won't work in IPython 3
2623+
and above.
26192624
"""
26202625
try:
26212626
ip = get_ipython()

pandas/core/frame.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -473,6 +473,9 @@ def _repr_html_(self):
473473
# qtconsole doesn't report it's line width, and also
474474
# behaves badly when outputting an HTML table
475475
# that doesn't fit the window, so disable it.
476+
# XXX: In IPython 3.x and above, the Qt console will not attempt to
477+
# display HTML, so this check can be removed when support for IPython 2.x
478+
# is no longer needed.
476479
if com.in_qtconsole():
477480
# 'HTML output is disabled in QtConsole'
478481
return None

0 commit comments

Comments
 (0)