@@ -254,7 +254,7 @@ def texture_coordinates() -> flask.Response:
254254 params = schemas .TextureCoordinates .from_dict (json_data )
255255 geode_object = geode_functions .load_geode_object (params .id )
256256 if not isinstance (geode_object , GeodeSurfaceMesh2D | GeodeSurfaceMesh3D ):
257- flask .abort (500 , f"{ params .id } is not a GeodeSurfaceMesh" )
257+ flask .abort (400 , f"{ params .id } is not a GeodeSurfaceMesh" )
258258 texture_coordinates = geode_object .texture_manager ().texture_names ()
259259 return flask .make_response ({"texture_coordinates" : texture_coordinates }, 200 )
260260
@@ -270,7 +270,7 @@ def vertex_attribute_names() -> flask.Response:
270270 params = schemas .VertexAttributeNames .from_dict (json_data )
271271 geode_object = geode_functions .load_geode_object (params .id )
272272 if not isinstance (geode_object , GeodeMesh ):
273- flask .abort (500 , f"{ params .id } is not a GeodeMesh" )
273+ flask .abort (400 , f"{ params .id } is not a GeodeMesh" )
274274 vertex_attribute_names = geode_object .vertex_attribute_manager ().attribute_names ()
275275 return flask .make_response (
276276 {
@@ -290,7 +290,7 @@ def cell_attribute_names() -> flask.Response:
290290 params = schemas .PolygonAttributeNames .from_dict (json_data )
291291 geode_object = geode_functions .load_geode_object (params .id )
292292 if not isinstance (geode_object , GeodeGrid2D | GeodeGrid3D ):
293- flask .abort (500 , f"{ params .id } is not a GeodeGrid" )
293+ flask .abort (400 , f"{ params .id } is not a GeodeGrid" )
294294 cell_attribute_names = geode_object .cell_attribute_manager ().attribute_names ()
295295 return flask .make_response (
296296 {
@@ -310,7 +310,7 @@ def polygon_attribute_names() -> flask.Response:
310310 params = schemas .PolygonAttributeNames .from_dict (json_data )
311311 geode_object = geode_functions .load_geode_object (params .id )
312312 if not isinstance (geode_object , GeodeSurfaceMesh2D | GeodeSurfaceMesh3D ):
313- flask .abort (500 , f"{ params .id } is not a GeodeSurfaceMesh" )
313+ flask .abort (400 , f"{ params .id } is not a GeodeSurfaceMesh" )
314314 polygon_attribute_names = geode_object .polygon_attribute_manager ().attribute_names ()
315315 return flask .make_response (
316316 {
@@ -331,7 +331,7 @@ def polyhedron_attribute_names() -> flask.Response:
331331 params = schemas .PolyhedronAttributeNames .from_dict (json_data )
332332 geode_object = geode_functions .load_geode_object (params .id )
333333 if not isinstance (geode_object , GeodeSolidMesh3D ):
334- flask .abort (500 , f"{ params .id } is not a GeodeSolidMesh" )
334+ flask .abort (400 , f"{ params .id } is not a GeodeSolidMesh" )
335335 polyhedron_attribute_names = (
336336 geode_object .polyhedron_attribute_manager ().attribute_names ()
337337 )
0 commit comments