Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WFS-T Broken in QGIS 2.18.* with Geoserver Endpoints #23958

Closed
qgib opened this issue Jan 5, 2017 · 11 comments
Closed

WFS-T Broken in QGIS 2.18.* with Geoserver Endpoints #23958

qgib opened this issue Jan 5, 2017 · 11 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Data Provider Related to specific vector, raster or mesh data providers

Comments

@qgib
Copy link
Contributor

qgib commented Jan 5, 2017

Author Name: Giovanni Manghi (@gioman)
Original Redmine Issue: 16043
Affected QGIS version: master
Redmine category:web_services_clients/wfs
Assignee: Alessandro Pasotti


Works as expected on LTR.

Tested with several datasources, PostGIS included.

@qgib
Copy link
Contributor Author

qgib commented Jan 5, 2017

Author Name: Giovanni Manghi (@gioman)


Works as expected using QGIS Server.

To replicate just fire a Geoserver instance (tested 2.8 and 2.9 here), import a layer, enable wfs-t.

@qgib
Copy link
Contributor Author

qgib commented Jan 13, 2017

Author Name: Alessandro Pasotti (@elpaso)


Confirmed:
2.14 WFS-T works fine with QGIS Server and GeoServer
2.18 WFS-T works fine with QGIS Server and fails with GeoServer
master WFS-T works fine with QGIS Server and fails with GeoServer


  • assigned_to_id was configured as Alessandro Pasotti
  • version was changed from 2.18.2 to master

@qgib
Copy link
Contributor Author

qgib commented Jan 13, 2017

Author Name: Giovanni Manghi (@gioman)


it work if forcing version to 1.0.

@qgib
Copy link
Contributor Author

qgib commented Jan 13, 2017

Author Name: Alessandro Pasotti (@elpaso)


Basically: WFS-T is only implemented for 1.0.0, unfortunately the user does not know that because the developer did not implement any way to warn the user.

What happens is that GeoServer supports 1.0.0, 1.1.0 and 2.0.0, the default "auto" value will fetch the highests.

qgswfscapabilities.cpp line 478 (2.18):

// TODO: remove me when WFS-T 1.1 or 2.0 is done
if ( !mCaps.version.startsWith( "1.0" ) )
return;

Quick fix: change the default value in the WFS dialog from "auto" to 1.0.0 until the implementation is complete.

@qgib
Copy link
Contributor Author

qgib commented Jan 14, 2017

Author Name: Alessandro Pasotti (@elpaso)


There might be another issue in 2.18 and master:
Step to reproduce in GeoServer:

  • enable WFS transactional in GeoServer
  • add a WFS-T GeoServer shapefile layer to QGIS, set version=1.0.0
  • enable editing
  • add a new feature
  • save
  • end editing
  • enable editing
  • add a new feature
  • save
  • end editing
  • zoom in/out to refresh the canvas

Expected result: 2 new features appear in the map
Actual result: only 1 new feature appears in the map (the first added feature).
Note: the second feature was actually inserted in GeoServer, the problem is that QGIS does not notice it

@qgib
Copy link
Contributor Author

qgib commented Jan 14, 2017

Author Name: Alessandro Pasotti (@elpaso)


The reason for the observed behavior is that GeoServer always return new0 as the feature id if the feature store does not support id generation as happen in shapefiles.

@qgib
Copy link
Contributor Author

qgib commented Jan 14, 2017

Author Name: Even Rouault (@rouault)


The reason for the observed behavior is that GeoServer always return new0 as the feature id if the feature store does not support id generation as happen in shapefiles.

Ouch, sounds like an issue of the server. The returned id is supposed to be unique...

@qgib
Copy link
Contributor Author

qgib commented Jan 14, 2017

Author Name: Alessandro Pasotti (@elpaso)


It's unique within a single transaction.

@qgib
Copy link
Contributor Author

qgib commented Jan 14, 2017

Author Name: Anónimo (Anónimo)


Fixed in changeset "93770b1c307fe42c910eb993c7d813931512ba75".


  • status_id was changed from Open to Closed

@qgib
Copy link
Contributor Author

qgib commented Jan 16, 2017

Author Name: Giovanni Manghi (@gioman)


  • status_id was changed from Closed to Reopened

@qgib
Copy link
Contributor Author

qgib commented Jan 16, 2017

Author Name: Giovanni Manghi (@gioman)


  • resolution was changed from to fixed/implemented
  • status_id was changed from Reopened to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Data Provider Related to specific vector, raster or mesh data providers labels May 25, 2019
@qgib qgib closed this as completed May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Data Provider Related to specific vector, raster or mesh data providers
Projects
None yet
Development

No branches or pull requests

1 participant