Bug report #16753

off-line editing synchronization cripples the original datasource if this is a WFS-T Layer

Added by Giovanni Manghi almost 3 years ago. Updated over 2 years ago.

Status:Closed
Priority:High
Assignee:Alessandro Pasotti
Category:C++ plugins/Offline editing
Affected QGIS version:2.18.9 Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:wontfix
Crashes QGIS or corrupts data:Yes Copied to github as #:24652

Description

The functionality seems ok is the original layer is a PostGIS one, for example.

If it is a WFS-T and the edits made off-line are simple (like just adding a polygon) then the synchronization back seems also ok.

On the other end if edit in the off-line layer are more complex (like moving 1 feature + adding 1 feature + removing 1 feature + 1 editing one feature geometry) then the synchronization seems to produce very bad effects, like data loss (the edited features disappear) and also features duplication (the feature being moved).

The attached video probably is more clear > https://www.dropbox.com/s/ch2zyqefjrzlb2c/Recording%20%231.mp4?dl=0

This was seen on 2.18.9/10 as well 2.14.15/16 using a Geoserver endpoint.

Associated revisions

Revision 68ddf3b9
Added by Alessandro Pasotti over 2 years ago

[offline-editing] Add a warning icon and tooltip to WFS sources

Fixes #16753 off-line editing synchronization cripples
the original datasource if this is a WFS-T Layer

Revision 7f5128bf
Added by Alessandro Pasotti over 2 years ago

[bugfix] Add a warning icon and tooltip to WFS sources

Fixes #16753 off-line editing synchronization cripples
the original datasource if this is a WFS-T Layer

Backported from master commit 68ddf3b9916a1148b3f

History

#1 Updated by Giovanni Manghi almost 3 years ago

If the above edits operation are done one at a time (then synchronize back, then placing again off-line the datasource) it seems it all goes as expected.

#2 Updated by Giovanni Manghi almost 3 years ago

one more note: this does not seems to happen in the endpoint is qgis server, but I have been able to test only with lines, as if the wfs-t/qgis server layer is a polygon when placing this off-line I always gets messages like:

Offline Editing Plugin: ERROR: 246 feature(s) not added - geometry type is not compatible with the current layer.

#3 Updated by Giovanni Manghi over 2 years ago

  • Resolution set to wontfix

Giovanni Manghi wrote:

If the above edits operation are done one at a time (then synchronize back, then placing again off-line the datasource) it seems it all goes as expected.

this has proven to happen only if the underlying datasource has no primary key (i.e. is not a real database). Apparently there is no way to fix this, so a warning has been added.

#4 Updated by Giovanni Manghi over 2 years ago

Giovanni Manghi wrote:

one more note: this does not seems to happen in the endpoint is qgis server, but I have been able to test only with lines, as if the wfs-t/qgis server layer is a polygon when placing this off-line I always gets messages like:

Offline Editing Plugin: ERROR: 246 feature(s) not added - geometry type is not compatible with the current layer.

this is a completely separated issue and a new ticket has been filed.

#5 Updated by Anonymous over 2 years ago

  • % Done changed from 0 to 100
  • Status changed from Open to Closed

Also available in: Atom PDF