Ticket #1572 (closed bug: fixed)

Opened 4 years ago

Last modified 4 years ago

new features will not display before spatial index is recreated/QGIS restarted

Reported by: paull Owned by: mhugent
Priority: critical: causes crash or data corruption Milestone: Version 1.2.0
Component: Vectors Version: Trunk
Keywords: Cc: pcav
Platform Version: Platform: All
Must Fix for Release: Yes Awaiting user input: no

Description

I've imported some shapefile-exports (Geomedia) and added line-features in QGIS. The lines were showing up nicely, until I hit "Toggle editing" and "save". After saving, the features immediately disappeared. I saved everything, restarted QGIS, still not there. (Features were showing up in the table though). I restarted QGIS again, still no sign. I've tried theo whole thing again, drawing new features, and again: as soon as I saved the edits, they would disappear. I hit "create spatial index" and boom: immediately all those features get displayed.

Attachments

shapefiles.zip Download (54.0 KB) - added by paull 4 years ago.
Shapefiles

Change History

Changed 4 years ago by borysiasty

  • component changed from Build/Install to Vectors

I confirm. I observed the same issue several times.

Changed 4 years ago by msieczka

  • priority changed from major: does not work as expected to critical: causes crash or data corruption
  • platform changed from Debian to All
  • must_fix changed from No to Yes
  • milestone set to Version 1.0.2

I noticed a similar thing on Windows couple of versions ago.

Changed 4 years ago by paull

same thing happens again today, after a restart, with the same layers. Newly added features will only show up after (re-)creating the spatial index.

Changed 4 years ago by paull

Shapefiles

Changed 4 years ago by paull

  • priority changed from critical: causes crash or data corruption to major: does not work as expected
  • component changed from Vectors to MapCanvas
  • summary changed from new features will not display before spatial index is created to new features will not display before spatial index is recreated/QGIS restarted

Theres a second funny thing that I think is related to this bug.

- Layer A and Layer B both use the same shape-file to display features of that shape-file (in my case: Points)

- I add points (working with Layer A); The new points are being drawn on the map in Layer A; They disappear as soon as I save the changes to the shapefile and reappear as soon as I rebuild the index (see description above). However: The new points never appear on Layer B throughout the process, even though this layer references the same Shapefile as Layer A.

- It takes a complete Restart of QGIS to have Layer B display the newly added points as well. Zooming, panning, disabling and reenabling all doesn't work; the only way to force Layer B to refresh seems to be a restart of QGIS.

Changed 4 years ago by paull

  • priority changed from major: does not work as expected to critical: causes crash or data corruption

Changed 4 years ago by paull

  • component changed from MapCanvas to Vectors

Changed 4 years ago by lutra

  • cc pcav added
  • version changed from 1.0.0 to HEAD
  • milestone changed from Version 1.0.3 to Version 1.2.0

Confirmed on Qgis 1.2 from trunk on Ubuntu 9.04. Pushing the milestone to 1.2

Changed 4 years ago by pcav

  • owner changed from nobody to mhugent

Changed 4 years ago by mhugent

  • status changed from new to closed
  • resolution set to fixed

Fixed in r11225. The spatial index is now recreated if geometry changes are commited. Note that there is work in progress in the OGR library related to a more efficient update of the spatial index.

Note: See TracTickets for help on using tickets.