{{{
import mock
import sys
with mock.patch('django.utils.six.moves.html_parser'):
import django
from django.test import TestCase
from django.contrib.gis.geos import Point
from test_app.models import City
def side_effect(*args, **kwargs):
sys.exit(1)
django.setup()
with mock.patch('django.contrib.gis.db.models.fields.Geometry.__init__',
side_effect=side_effect):
City.objects.first()
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/28341>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* owner: nobody => Sergey Fedoseev
* status: new => assigned
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:1>
Old description:
> Bisected to e9103402c0fa873aea58a6a11dba510cd308cb84 on test project with
> this script:
>
> {{{
> import mock
> import sys
>
> with mock.patch('django.utils.six.moves.html_parser'):
> import django
> from django.test import TestCase
> from django.contrib.gis.geos import Point
>
> from test_app.models import City
>
> def side_effect(*args, **kwargs):
> sys.exit(1)
>
> django.setup()
>
> with mock.patch('django.contrib.gis.db.models.fields.Geometry.__init__',
> side_effect=side_effect):
> City.objects.first()
> }}}
New description:
Bisected to e9103402c0fa873aea58a6a11dba510cd308cb84 on test project with
this script:
{{{
import mock
import sys
with mock.patch('django.utils.six.moves.html_parser'):
import django
from django.test import TestCase
from django.contrib.gis.geos import Point
from test_app.models import City
def side_effect(*args, **kwargs):
sys.exit(1)
django.setup()
with mock.patch('django.contrib.gis.db.models.fields.Geometry.__init__',
side_effect=side_effect):
City.objects.first()
}}}
This laziness is declared in
[https://docs.djangoproject.com/en/dev/ref/contrib/gis/tutorial/#lazy-
geometries GeoDjango Tutorial].
--
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:2>
* stage: Unreviewed => Accepted
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:3>
* owner: Sergey Fedoseev => Srinivas Reddy Thatiparthy
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:4>
* owner: (none) => Srinivas Reddy Thatiparthy
* status: new => assigned
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:6>
* status: assigned => new
* owner: Srinivas Reddy Thatiparthy => (none)
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:5>
Comment (by Srinivas Reddy Thatiparthy):
Apologies for spam - Are you working on this ? @SergeyFedoseev
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:7>
Comment (by Sergey Fedoseev):
Feel free to work on it.
--
Ticket URL: <https://code.djangoproject.com/ticket/28341#comment:8>