[Django] #31015: loss of precision of geometry coordinates on Oracle 18

16 views
Skip to first unread message

Django

unread,
Nov 21, 2019, 5:46:35 AM11/21/19
to django-...@googlegroups.com
#31015: loss of precision of geometry coordinates on Oracle 18
-------------------------------------------+------------------------
Reporter: Sergey Fedoseev | Owner: nobody
Type: Bug | Status: new
Component: GIS | Version: 2.2
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------------+------------------------
This test fails on Oracle 18, but works on Oracle 12 and other backends:

{{{
def test_round_trip(self):
g = City.objects.values_list(models.Value(Point(-87.650175,
41.850385), models.PointField()), flat=True)[0]
self.assertEqual(g.wkt, 'POINT (-87.650175 41.850385)')
}}}

{{{
Traceback (most recent call last):
File "/home/jenkins/workspace/pull-requests-
oracle/database/oragis18/label/bionic-
pr/python/python3.8/tests/gis_tests/geoapp/tests.py", line 228, in
test_round_trip
self.assertEqual(g.wkt, 'POINT (-87.650175 41.850385)')
AssertionError: 'POINT (-87.65017499999999 41.850385)' != 'POINT
(-87.650175 41.850385)'
- POINT (-87.65017499999999 41.850385)
? ^^^^^^^^^
+ POINT (-87.650175 41.850385)
? ^
}}}

I'm not sure if we should fix it, since it might be treated like Oracle
bug, but it looks like it can be fixed by using WKB instead of WKT in
queries on Oracle.

--
Ticket URL: <https://code.djangoproject.com/ticket/31015>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Dec 18, 2019, 2:49:04 AM12/18/19
to django-...@googlegroups.com
#31015: loss of precision of geometry coordinates on Oracle 18
---------------------------------+--------------------------------------

Reporter: Sergey Fedoseev | Owner: nobody
Type: Bug | Status: closed
Component: GIS | Version: 2.2
Severity: Normal | Resolution: needsinfo

Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
---------------------------------+--------------------------------------
Changes (by felixxm):

* status: new => closed
* resolution: => needsinfo


Comment:

Thanks for this report. I would like to check how it looks like on Oracle
19 (but I have some issues with this db), so let's close it for now as
"needsinfo".

--
Ticket URL: <https://code.djangoproject.com/ticket/31015#comment:1>

Django

unread,
Feb 10, 2021, 5:48:10 AM2/10/21
to django-...@googlegroups.com
#31015: loss of precision of geometry coordinates on Oracle 18
---------------------------------+--------------------------------------

Reporter: Sergey Fedoseev | Owner: nobody
Type: Bug | Status: closed
Component: GIS | Version: 2.2
Severity: Normal | Resolution: invalid

Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
---------------------------------+--------------------------------------
Changes (by Mariusz Felisiak):

* resolution: needsinfo => invalid


Comment:

I confirmed the same behavior on Oracle 19c, however I think it's a bug in
Oracle. Closing as invalid unless someone can prove it's Django's fault or
there is anything we can improve in Django itself.

--
Ticket URL: <https://code.djangoproject.com/ticket/31015#comment:2>

Reply all
Reply to author
Forward
0 new messages