[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Maposmatic-dev] [PATCH] [ocitysmap] Fix GEOS Intersection error whe
From: |
Jeroen van Rijn |
Subject: |
Re: [Maposmatic-dev] [PATCH] [ocitysmap] Fix GEOS Intersection error when dealing with malformed ways |
Date: |
Thu, 19 Apr 2012 00:49:27 +0200 |
On Thu, Apr 19, 2012 at 00:39, Étienne Loks <address@hidden> wrote:
> + try:
> + cursor.execute(query % {'way':'way'})
> + except psycopg2.InternalError:
> + # This exception generaly occurs when inappropriate ways have
> + # to be cleaned. Using a buffer of 0 generaly helps to clean
> + # them. This operation is not applied by default for
> + # performance.
> + db.rollback()
> + cursor.execute(query % {'way':'st_buffer(way, 0)'})
That's a very quick fix for the GEOS error.
Reading through the patch it looks to be that if psycopg2 fails for
another reason, however unlikely that might seem, you end up with a
runaway process?
Best regards,
Jeroen.
--
↑↑↓↓←→←→BA[Start]