Skip to content

Commit 76fcdb7

Browse files
committed
Remove approach of checking environment which could not differentiate between jupyter console and notebook
1 parent 72bc9ad commit 76fcdb7

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

python/datafusion/dataframe.py

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -149,17 +149,6 @@ def __repr__(self) -> str:
149149
Returns:
150150
String representation of the DataFrame.
151151
"""
152-
# Check if we're in a Jupyter notebook. If so, we will only use
153-
# the _repr_html_ output to avoid calling collect() twice.
154-
try:
155-
from IPython import get_ipython
156-
157-
shell = get_ipython().__class__.__name__
158-
if shell == "ZMQInteractiveShell":
159-
return "" # Return empty string to effectively disable
160-
except (ImportError, NameError):
161-
pass
162-
163152
return self.df.__repr__()
164153

165154
def _repr_html_(self) -> str:

0 commit comments

Comments
 (0)