mobile icon indicating copy to clipboard operation
mobile copied to clipboard

Input still uses removed column

Open jozef-budac opened this issue 3 years ago • 2 comments

When user removes a column in QGIS and synchronize project, in INPUT, the field is still there in the form, can be edited, but then feature is saved, no new feature is created. This issue was intruduced by autosync feature. It works with older version

Scenario:

  1. create Tree template project and open it in Input and QGIS
  2. in QGIS, remove notes column from surver layer
  3. open the form (with already removed field) update it and hit save
  4. autosync is done.. it passes
  5. from now, you are not ale to store any new feature

https://user-images.githubusercontent.com/83582181/160777819-97793367-5af4-43d7-900c-8ee4326377cb.mp4

jozef-budac avatar Mar 30 '22 07:03 jozef-budac

I think this is related to these two issues:

  • #1797
  • #1798

wonder-sk avatar Mar 30 '22 07:03 wonder-sk

I can reproduce this one on master version as well.

Console logs:

ERROR 1: Invalid index : 1
ERROR 1: sqlite3_exec(DROP TRIGGER "trigger_insert_feature_count_Survey_points") failed: attempt to write a readonly database
ERROR 1: sqlite3_exec(DROP TRIGGER "trigger_delete_feature_count_Survey_points") failed: attempt to write a readonly database
ERROR 1: sqlite3_exec(UPDATE gpkg_ogr_contents SET feature_count = NULL WHERE lower(table_name )= lower('Survey_points')) failed: attempt to write a readonly database
ERROR 1: failed to execute insert : attempt to write a readonly database
"2022-03-30T08:59:15.852Z QGIS : Warning: Commit errors:\n  ERROR: 1 feature(s) not added.\n  \n  Provider errors:\n      OGR error creating feature -10: failed to execute insert : attempt to write a readonly database\n"
"2022-03-30T08:59:15.852Z QGIS Input: Error: Could not save changes. Rolling back.\n"
"2022-03-30T08:59:15.853Z QGIS OGR: Warning: Unbalanced call to leaveUpdateMode() w.r.t. enterUpdateMode()\n"
QFile::remove: Empty or null file name
ERROR 1: Invalid index : 1

In order to reproduce this bug with autosync, one needs to have feature form opened when sync finishes.

tomasMizera avatar Mar 30 '22 09:03 tomasMizera