GNOME Bugzilla – Bug 670523
persona.vala:153:folks_persona_get_individual: assertion failed: (_tmp6_)
Last modified: 2012-04-30 13:46:22 UTC
I got this crash while disconnecting my XMPP accounts. I was using Folks master. folks:ERROR:/home/cassidy/gnome/folks/folks/persona.vala:153:folks_persona_get_individual: assertion failed: (_tmp6_)
+ Trace 229701
Can you reproduce this? If so, it would be good to call folks_debug_emit_print_status(folks_debug_dup()) (from gdb) just before causing the crash. This crash should only happen if a Persona is removed from an Individual it was never in — which should never happen.
Yeah, it happens pretty often when I suspend my laptop while being online. I'll try to reproduce and provide the info.
I just sent you the output of this command once I hit the crash. Not sure how to catch it just before it.
*** Bug 671148 has been marked as a duplicate of this bug. ***
duplicated bug has also the stacktrace i wish that would help https://launchpadlibrarian.net/94067284/Stacktrace.txt
Guillaume, would it be possible for you to reproduce the crash again and get a *correlated* set of debug info? I need: • the logs from FOLKS_DEBUG=all G_MESSAGES_DEBUG=all; • the folks_debug_emit_print_status() stuff in gdb; and • the backtrace from gdb. (Basically, I need the memory addresses to match between them so I can figure out what's going on.) From the two stacktraces so far, I've got a theory that the IndividualAggregator's link map is pointing to Individual A, which contains Persona 1 in its set of personas. However, somehow Individual B has claimed ownership of Persona 1, and also has Persona 1 in its set of personas. Persona 1's individual pointer is pointing at Individual B — so when Individual A iterates over its set of personas, it triggers the assertion when it reaches Persona 1.
Created attachment 208967 [details] [review] core: Don’t modify a HashSet while iterating over it Alternatively, here’s a patch which might fix the problem. (It certainly fixes _a_ bug.) We were iterating over a set, removing elements of the set by calling iter.remove() as we go. This should’ve been fine, but bug #671327 meant it wasn’t, and we were potentially skipping some elements of the set. This patch works around bug #671327. Guillaume, could you please give this a go and see if it fixes your crash? If it doesn’t, I’ll need the debug information listed in comment #6. https://www.gitorious.org/folks/folks/commits/670523-individual-persona-assertion
(In reply to comment #7) > Guillaume, could you please give this a go and see if it fixes your crash? If > it doesn’t, I’ll need the debug information listed in comment #6. Sure, I'm now running it. It uses to happen quiet a lot so if it didn't crash during the next few days I think we'll be good.
Reproduced. I sent you all the info by mail.
*** Bug 671641 has been marked as a duplicate of this bug. ***
with attachment #208967 [details], notify::is-quiescent is never emitted it seems. Patch applied on top of current folks master.
also present in downstream https://bugs.launchpad.net/ubuntu/+source/empathy/+bug/944418
*** Bug 672352 has been marked as a duplicate of this bug. ***
Review of attachment 208967 [details] [review]: ++
Comment on attachment 208967 [details] [review] core: Don’t modify a HashSet while iterating over it commit 46d4506d346199f53039d8d31275b8ce61146528 Author: Philip Withnall <philip@tecnocode.co.uk> Date: Mon Mar 5 00:11:09 2012 +0000 core: Don’t modify a HashSet while iterating over it Even though we were modifying it from the Iterator (which should’ve been OK), we got hit by https://bugzilla.gnome.org/show_bug.cgi?id=671327 which meant that some Personas weren't getting disconnected from Individuals. This is a likely cause of bug #670523. This also includes a related (but irrelevant to the bug itself) tidy-up to Persona._individual. Closes: https://bugzilla.gnome.org/show_bug.cgi?id=670523 NEWS | 2 ++ folks/individual.vala | 11 ++++++----- folks/persona.vala | 4 ++-- 3 files changed, 10 insertions(+), 7 deletions(-)
Guillaume can no longer reproduce the bug with this patch and the one from bug #672381, so let's close this.
*** Bug 673358 has been marked as a duplicate of this bug. ***
*** Bug 675120 has been marked as a duplicate of this bug. ***