Bug report #17244
New node tool snapping index out of sync for transaction groups (and triggers in the DB)
|Affected QGIS version:||3.4.2||Regression?:||Yes|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||Yes||Copied to github as #:||25142|
This is something that happened in the past I guess.
When playing with new node tool with database updating other features than the currently edited one,
the snapping index is quickly out of sync. It worked correctly in 2.18 (issue was in 2.16 IIRW)
See the video here: [[https://youtu.be/Miex5XarR3g]]
#7 Updated by Hugo Mercier almost 5 years ago
The issue is still present in 3.4.2.
However, when the "data dependencies" are correctly declared on the table "pipe" (the table "pipe" may be modified by the view "vw_pipe"), it works correctly.
But ... this does not fix the other way around: when a modification is made to the table, the view geometry is updated but QGIS does not know it. That would require to declare circular data dependencies between layers, which has been forbidden initially, but should probably be loosen.
#10 Updated by Hugo Mercier over 4 years ago
Nope, the PR only fixed another sync problem of cache found in vertextool ("cachedGeometry").
But that does not resolve the problem here which is: the relation between the table and the view must be known somehow by QGIS to properly maintain caches. Declaring "data dependencies" between them works as a not-very-user-friendly workaround, and only in "one direction", because circular dependencies have been explicitly forbidden. A short term fix would be to allow for such circular dependencies.
IMHO a better fix would be to have an editing mode where no cache is used and get rid of these "data dependencies"