Skip to content

Commit 8325f8d

Browse files
committed
remove dead code
1 parent 9b4b18a commit 8325f8d

File tree

3 files changed

+108
-132
lines changed

3 files changed

+108
-132
lines changed

bigframes/dataframe.py

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -827,30 +827,6 @@ def __repr__(self) -> str:
827827
lines.append(f"[{row_count} rows x {column_count} columns]")
828828
return "\n".join(lines)
829829

830-
def _repr_html_fallback(self) -> str:
831-
"""
832-
Returns an html string primarily for use by notebooks for displaying
833-
a representation of the DataFrame. Displays 20 rows by default since
834-
many notebooks are not configured for large tables.
835-
"""
836-
opts = bigframes.options.display
837-
max_results = opts.max_rows
838-
if opts.repr_mode == "deferred":
839-
return formatter.repr_query_job(self._compute_dry_run())
840-
841-
df, blob_cols = self._get_display_df_and_blob_cols()
842-
843-
pandas_df, row_count, query_job = df._block.retrieve_repr_request_results(
844-
max_results
845-
)
846-
847-
self._set_internal_query_job(query_job)
848-
column_count = len(pandas_df.columns)
849-
850-
return self._create_html_representation(
851-
pandas_df, row_count, column_count, blob_cols
852-
)
853-
854830
def _get_display_df_and_blob_cols(self) -> tuple[DataFrame, list[str]]:
855831
"""Process blob columns for display."""
856832
df = self

bigframes/streaming/dataframe.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -291,13 +291,13 @@ def __repr__(self, *args, **kwargs):
291291

292292
__repr__.__doc__ = _curate_df_doc(inspect.getdoc(dataframe.DataFrame.__repr__))
293293

294-
def _repr_html_fallback(self, *args, **kwargs):
295-
return _return_type_wrapper(self._df._repr_html_fallback, StreamingDataFrame)(
294+
def _repr_mimebundle_(self, *args, **kwargs):
295+
return _return_type_wrapper(self._df._repr_mimebundle_, StreamingDataFrame)(
296296
*args, **kwargs
297297
)
298298

299-
_repr_html_fallback.__doc__ = _curate_df_doc(
300-
inspect.getdoc(dataframe.DataFrame._repr_html_fallback)
299+
_repr_mimebundle_.__doc__ = _curate_df_doc(
300+
inspect.getdoc(dataframe.DataFrame._repr_mimebundle_)
301301
)
302302

303303
@property

0 commit comments

Comments
 (0)