﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
31366	GEOSGeometry fails on instance with GEOJson and srid not 4326.	Walter Lorenzetti	nobody	"On creating a GEOSGeometry intance by a GEOJson string with a srid not 4326, I obtain this error:
coord = '{""type"": ""Point"", ""coordinates"": [10000, 10000]}'

{{{
g = GEOSGeometry(coord, srid=3857)
Traceback (most recent call last):
  File ""<input>"", line 1, in <module>
  File ""/home/envs/g3w_suite_dj22/lib/python3.6/site-packages/django/contrib/gis/geos/geometry.py"", line 732, in __init__
    raise ValueError('Input geometry already has SRID: %d.' % input_srid)
ValueError: Input geometry already has SRID: 4326.
}}}

So to fix it I use this not beautyfull solution:

{{{
g = GEOSGeometry(GEOSGeometry(coord).wkt, srid=3857)
}}}

Thanks in advance.
W"	Bug	closed	GIS	dev	Normal	invalid	Geodjango		Unreviewed	0	0	0	0	0	0
