mcneel / compute.rhino3d

REST geometry server based on RhinoCommon and headless Rhino
Other
296 stars 185 forks source link

Standardise error response and raise as exceptions in client libraries #205

Open pearswj opened 3 years ago

pearswj commented 3 years ago

It would be very useful to be able to see server errors in clients, rather than having to check the server logs to see exactly what went wrong. Since #157 the /grasshopper endpoint includes errors and warnings in the response, so they can be displayed by Hops. Having a standardised structure for error responses from all endpoints and exposing these errors as exceptions in the JS, python and C# client libraries would make for a better development experience!

mcneel-build commented 3 years ago

Linked with COMPUTE-175

pearswj commented 3 years ago

Another situation where a more appropriate error code and a descriptive error would be useful... https://discourse.mcneel.com/t/one-failure-in-a-batched-call-kills-entire-call/122024

seanmerrifield commented 1 year ago

Are there any updates on this issue? I'm running into the same problem as well, it would be helpful to be able to see the error in the response, rather than investigating the server logs (since typically the clients won't have access to them).