bito-code-review[bot] commented on PR #40190: URL: https://github.com/apache/superset/pull/40190#issuecomment-4466501095
<!-- Bito Reply --> The flagged issue is valid. Using `errors='ignore'` in `pd.to_numeric` leaves the column as an object type if any value is non-numeric, which can cause downstream numeric operations to fail. The suggested fix is to use `errors='coerce'` instead, which converts invalid entries to `NaN` and ensures the column becomes numeric. Here's the fix for the specific line in `dataframe_utils.py`: **superset/common/utils/dataframe_utils.py** ``` df[col] = pd.to_numeric(df[col], errors='coerce') ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
