Don't wrap exceptions in DriftRemoteException
if not necessary
#2879
Labels
breaking
A breaking change that would require a major version jump
enhancement
New feature or request
package-drift
Affects the core drift package
For exceptions happening on an other isolate or other server through the remote protocol, we wrap the exception in a
DriftRemoteException
.At the time drift first gained support for isolates, we couldn't reliably send arbitrary Dart objects across send ports, and so we had to transport exceptions by calling
toString()
on them, without giving users better details about what happened. This is no longer a concern in recent Dart versions, and so we should drop this exception wrapper and just surface a copy of the exception object we got from the other isolate.The text was updated successfully, but these errors were encountered: