Add cause
to No_Output_Columns
error to make it clearer what was the _underlying_ cause of the lack of columns and improve the error message
#7635
Milestone
As discussed in another PR, we want to add a
cause
field to theNo_Output_Columns
type. If the lack of output columns (which usually is a hard error) is caused by other problems (which may only be reported at warning level), the hard error is taking precedence - but it is often not stating the true issue that has occurred - the warnings are what is more helpful.So to ensure that the user can more easily know what has happened, we should add a
cause
field toNo_Output_Columns
error and try to fill it in wherever possible.No_Output_Columns.to_display_text
should also include a text representation of thecause
if it is available.We should test it e.g. with
union
, as in the linked discussion. We could also add a test fortable.select_columns ["nonexistent_name"] error_on_missing_columns=False
where theNo_Output_Columns
would holdMissing_Input_Columns
as its cause.The text was updated successfully, but these errors were encountered: