- Notifications
You must be signed in to change notification settings - Fork63
fix: Resolve AttributeError in TableWidget and improve initialization#1937
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered byReviewNB |
aee37a7 to303c4afCompareUh oh!
There was an error while loading.Please reload this page.
tswast commentedJul 29, 2025
Please also update the benchmarks to use the |
fc38cf3 tof643cfbCompareshuoweil commentedJul 30, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Let's use a separate PR for this request.#1949 |
e12c8ff tof8ab27bComparef8ab27b todf85824CompareUh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
df85824 to2756968Compare5bc65ce to26eb25eCompare- Reinstated 'Iterator[pd.DataFrame]' inheritance for 'PandasBatches' in 'bigframes/core/blocks.py'.- Removed internal type hint 'bigframes.core.blocks.PandasBatches:' from 'to_pandas_batches' docstring in 'bigframes/dataframe.py' to avoid exposing internal types in public documentation.
This reverts the import path for the benchmark utils to 'benchmark.utils' to address concerns about google3 imports.
42e0580 to76cdec6Compare4c4c9b1 intomainUh oh!
There was an error while loading.Please reload this page.

Uh oh!
There was an error while loading.Please reload this page.
This PR introduces enhancements to the
TableWidgetby improving its initialization and robustness, specifically addressing anAttributeErrorrelated to the_batchesattribute.Key improvements include:
Enhanced Initialization: Ensures the
_batchesattribute is correctly initialized in theTableWidgetconstructor by calling_reset_batches_for_new_page_sizebefore it is accessed, making the widget more reliable from creation.Improved Typing: Added explicit type hints for
_batchesto resolve MyPy errors, contributing to better code clarity and maintainability.Refactored Batch Handling: Changed the
to_pandas_batchescall to the internal_to_pandas_batchesto ensure the correctPandasBatchesobject is returned, satisfying type requirements and streamlining internal data handling.Test Enhancements: Added new tests to verify the widget's row count is immutable after creation and that it gracefully handles cases with invalid total rows, ensuring the stability of the new functionality.