Opened 16 years ago

Last modified 16 years ago

#10839 closed

Pickling queryset.query doesn't work for gis models — at Initial Version

Reported by: Jani Tiainen Owned by: nobody
Component: GIS Version: dev
Severity: Keywords: oracle gis
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: yes Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

If I pickle queryset.query which is GIS model I get following results (using Oracle as database):
qs = MyModel.objects.filter(id=12345)

before pickling:

qs.query

<django.contrib.gis.db.models.sql.query.GeoQuery object at 0x0199FB90>

qry_str = pickle.dumps(qs.query)
qry = pickle.loads(qry_str)
qry

<django.db.backends.oracle.query.OracleQuery object at 0x019C3F70>

Somehow query object has changed. It works as expected on non GIS models.

Change History (0)

Note: See TracTickets for help on using tickets.
Back to Top