You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Our plotting API requires some functions to be available in the database; for example, we use the percentile_disc function to calculate percentiles. Unfortunately, some databases do not have these functions, so when users run them, they'll sometimes see unclear errors.
We have two options here: either raise an error when a user runs one of these functions and is using a database that does not have support for it (e.g., MySQL and percentile_disc) or capture the errors and hint the user that the problem might be that the function isn't available.
The problem with the first approach is that we'd have to check the documentation for each major database and map all the unavailable functions; this gets tricky since those functions might be available via external packages. So the second alternative sounds better.
We could catch errors when executing our plotting functions and add a message at the end of the original message displayed by the database to hint to the user.
Example:
[Error from the database]
Ensure that the [some function] is available on [driver name]
If you need help [slack link]
The text was updated successfully, but these errors were encountered:
We have two options here: either raise an error when a user runs one of these functions and is using a database that does not have support for it (e.g., MySQL and percentile_disc) or capture the errors and hint the user that the problem might be that the function isn't available.
@edublancas I guess it kind of falls under the first option, but what about doing something as we did with pydts, essentially handing the missing functionality to them with another query?
@neelasha23 looks good, I'd probably also add 6. documenting those in case it's not documented already.
Our plotting API requires some functions to be available in the database; for example, we use the
percentile_disc
function to calculate percentiles. Unfortunately, some databases do not have these functions, so when users run them, they'll sometimes see unclear errors.We have two options here: either raise an error when a user runs one of these functions and is using a database that does not have support for it (e.g., MySQL and percentile_disc) or capture the errors and hint the user that the problem might be that the function isn't available.
The problem with the first approach is that we'd have to check the documentation for each major database and map all the unavailable functions; this gets tricky since those functions might be available via external packages. So the second alternative sounds better.
We could catch errors when executing our plotting functions and add a message at the end of the original message displayed by the database to hint to the user.
Example:
The text was updated successfully, but these errors were encountered: