Skip to content

Handle polygon index size errors

Erwan Rouchet requested to merge large-polygon-error into master

Closes #721 (closed)

This removes the memory size constraint, but keeps a maximum size on serializers set to 300 points.

This catches the index size errors in any SQL query made by Django from Zone.objects.create, Zone.objects.update, Zone.objects.bulk_create, Zone.objects.bulk_update, Zone().save(), etc. by overriding the Zone queryset, similarly to how we overrode the Element queryset to add trash.

This uses an unrealistic polygon; out of 18000 Transkribus polygons, none could be simplified down to 300 points and crash properly, so I could not use any for the unit tests.

Edited by Erwan Rouchet

Merge request reports

Loading