SEPURI-SAI-KRISHNA commented on PR #44953:
URL: https://github.com/apache/superset/pull/44953#issuecomment-6040174139

   Right on both counts, and it is now fixed rather than documented as out of 
scope.
   
   `SemanticView.get_query_result` and `SqlaTable.get_query_result` each 
carried an `except (TypeError, pd.errors.DataError)` next to the 
`InvalidPostProcessingError` handler, added by #44502 and #44463. With the 
wrapping moved into `exec_post_processing`'s loop those two no longer serve 
built-in operations, and keeping them left a custom operation's `TypeError` as 
a 400 while its `ValueError` and `AttributeError` became 500. Both handlers are 
removed, so a custom operation's fault is consistently a server error.
   
   I had expected this to need #44502's and #44463's tests edited, which is why 
the previous body deferred it. It does not. Both drive a real built-in 
operation, `resample` on an object-dtype column, and assert only that 
`QueryObjectValidationError` is raised, which still holds via the 
`InvalidPostProcessingError` path. 883 pass across 
`tests/unit_tests/{queries,models,semantic_layers,pandas_postprocessing,charts}`
 with no existing test touched.
   
   One test is added at each call site for the behaviour that did change: a 
custom operation registered through `EXTRA_PANDAS_POSTPROCESSING_OPS` raising 
`TypeError` propagates rather than being converted. Putting either handler back 
fails both, so the removal stays removed.
   
   `semantic_layers/models.py` loses its `import pandas as pd` along with the 
handler, since nothing else in the file used it.
   


-- 
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]

Reply via email to