) * fix: Support Pandas future.infer_string=True in report generation Previously, report generation encountered issues when `future.infer_string=True` was set. This resulted in multiple warnings ("FutureWarning: Dtype inference on a pandas object is deprecated") and failures when string columns contained only empty strings ("AttributeError: 'StringDtype' object has no attribute 'pyarrow_dtype'"). This change resolves the issue by explicitly setting the dtype to "object" for the relevant operations. * refactor: Refactor pandas option usage for backward compatibility - Introduce the `optional_option_context` helper to replace the direct use of `pd.option_context("future.no_silent_downcasting", True)`, ensuring compatibility with older pandas versions that lack this option. - Update the `future.infer_string` test to run only on pandas >= 2.1, where it is applicable. * Add type annotations for optional_option_context * Make the silent downcasting explicit
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4