Invalid Text Buffer Iterator seen with completions

Bug #1214432 reported by Curtis Hovey
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Gedit Developer Plugins
Fix Released
High
Curtis Hovey

Bug Description

When the completions view appears, this error is seen on the command line. The application works. This issue does not happen with the word completion plugin. GDP Completions does set marks. It does not think it is changing the buffer. The error is not caused by continued typing. Control-<space> triggers the error. Selecting a completion causes the error. The word at the cursor is automatically selected when the completion view appears; the bug might be in the hook to choose a completion or be in the completion view itself.

(gedit:7793): Gtk-WARNING **: Invalid text buffer iterator: either the iterator is uninitialized, or the characters/pixbufs/widgets in the buffer have been modified since the iterator was created.
You must use marks, character numbers, or line numbers to preserve a position across buffer modifications.
You can apply tags and insert marks without invalidating your iterators,
but any mutation that affects 'indexable' buffer contents (contents that can be referred to by character offset)
will invalidate all outstanding iterators

(gedit:7793): Gtk-CRITICAL **: gtk_text_view_get_iter_location: assertion 'gtk_text_iter_get_buffer (iter) == get_buffer (text_view)' failed

(gedit:7793): Gtk-WARNING **: Invalid text buffer iterator: either the iterator is uninitialized, or the characters/pixbufs/widgets in the buffer have been modified since the iterator was created.
You must use marks, character numbers, or line numbers to preserve a position across buffer modifications.
You can apply tags and insert marks without invalidating your iterators,
but any mutation that affects 'indexable' buffer contents (contents that can be referred to by character offset)
will invalidate all outstanding iterators

(gedit:7793): Gtk-CRITICAL **: gtk_text_view_get_iter_location: assertion 'gtk_text_iter_get_buffer (iter) == get_buffer (text_view)' failed

Tags: gtk saucy
Revision history for this message
Curtis Hovey (sinzui) wrote :

The appears when a proposal is selected, selecting a proposal generates the error. do_get_start_iter() is called just before the C code takes over, and it calls gtk_text_buffer_get_iter_at_mark() that guarantees a new iter. Maybe the completion was initialized with a stale iter, but since the plugin uses marks to indicate where the cursor and word is in the doc, it seem unlikely that code or user could have changed the document.

Curtis Hovey (sinzui)
Changed in gdp:
status: Triaged → In Progress
Curtis Hovey (sinzui)
Changed in gdp:
status: In Progress → Fix Committed
Revision history for this message
Tom (tom-lorinthe) wrote :

Ubuntu 14.10, same issue for me. Fix is one year old?

Revision history for this message
Curtis Hovey (sinzui) wrote :

The issue is fixed for me using the packages from
    https://launchpad.net/~sinzui/+archive/ubuntu/ppa

Are you using the same?

Curtis Hovey (sinzui)
Changed in gdp:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.