Bug report #13048
WKT Parser seems to be unable to parse polygons with Z values
Status: | Closed | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | - | ||
Category: | - | ||
Affected QGIS version: | 2.8.2 | Regression?: | No |
Operating System: | windows | Easy fix?: | No |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 21121 |
Description
Recently I haven’t been able to insert WKT polygons with Z-values.
I have tried the following in the Python console:
> g = QgsGeometry.fromWkt('Polygon((0 0 0, 0 1 0, 1 1 0, 0 0 0))') > f = QgsFeature() > f.setGeometry(g) > iface.activeLayer().dataProvider().addFeatures([f])
My active layer is a scratch layer configured as Polygon. I get no exceptions and QGIS reports the layer containing 1 feature but nothing is shown. I have altered the above four python lines to only have the X and Y values and this results in a visual result.
Repeating the above using a Point WKT instead works fine with both 2D and 3D data.
History
#1 Updated by Giovanni Manghi over 9 years ago
- Status changed from Open to Feedback
is this a regression?
#2 Updated by Casper Børgesen over 9 years ago
- Status changed from Feedback to Closed
I have closed this issue due to me supplying a wrong affected version. Since I cannot update the affected version, I have created a duplicate issue to ensure that the issue might still be resolved.