Activity Journal's Right-Click Delete Functionality Broken

Bug #561860 reported by maxx
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
GNOME Activity Journal
Undecided
Siegfried Gevatter
Zeitgeist Framework
Fix Released
High
Unassigned

Bug Description

"
Description of problem:
Activity Journal's right-click delete functionality is broken.

Version-Release number of selected component (if applicable):
0.3.3

How reproducible:
100%

Steps to Reproduce:
1. Launch the Activity Journal.
2. Right-click on an item.
3. From the context menu that appears, choose to delete the item from the
journal.

Actual results:
Nothing happens.

Expected results:
Item's entry should be removed.
"

Reported in Fedora 13 against gnome-activity-journal-0.3.3-1.fc13.noarch.

https://bugzilla.redhat.com/show_bug.cgi?id=579144

Related branches

Revision history for this message
Randal Barlow (email-tehk) wrote :

This works in trunk with zeitgeist trunk installed.

Changed in gnome-activity-journal:
status: New → Fix Committed
Revision history for this message
Mikkel Kamstrup Erlandsen (kamstrup) wrote :

I just tested this in fully up to date trunk of ZG + GAJ and the event stays in the log as reported. I think the bug is in ZGs internal notification system. I see this on stdout from GAJ:

Error from Zeitgeist engine: org.freedesktop.DBus.Python.AttributeError: Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.6/dbus/service.py", line 702, in _message_cb
    retval = candidate_method(self, *args, **keywords)
  File "/usr/share/zeitgeist/_zeitgeist/engine/remote.py", line 297, in DeleteEvents
    TimeRange(timestamps[0], timestamps[1]), event_ids)
  File "/usr/share/zeitgeist/_zeitgeist/engine/notify.py", line 240, in notify_delete
    time_range = mon.time_range.intersect(time_range)
  File "/usr/lib/pymodules/python2.6/zeitgeist/datamodel.py", line 423, in intersect
    if self.begin < time_range.begin:
AttributeError: 'NoneType' object has no attribute 'begin'

Changed in gnome-activity-journal:
status: Fix Committed → Confirmed
Changed in zeitgeist:
status: New → Confirmed
importance: Undecided → High
milestone: none → 0.3.3
Revision history for this message
Randal Barlow (email-tehk) wrote :

Strange as it works find here.

Revision history for this message
Randal Barlow (email-tehk) wrote :

Let me elaborate on my previous message from my cellphone. Deletion works fine here with the latest revisions of both projects.

Revision history for this message
Mikkel Kamstrup Erlandsen (kamstrup) wrote :

OK. Seems I forgot to set PYTHONPATH in my test setup. Sorry.

However, now running against the real trunk ZG I think there are still at least two bugs hidden here...

 1) When I click delete on a configure.ac file in GAJ it gets removed from the view alright, and if I restart GAJ it's still removed. However if I also restart ZG the configure.ac reappears in the journal. This indicates that the delete SQL transaction is never committed.

 2) When I click delete on an Anjuta project file in GAJ nothing happens. No stack trace on stdout.

 3) If I add an external monitor for delete events (in a 3rd process) this monitor never gets notified of the deletion. This is true for both 1) and 2)

Revision history for this message
Mikkel Kamstrup Erlandsen (kamstrup) wrote :

FYI: I reported and committed a fix for bug #566184, which was that we did not commit our sql transaction after a DeleteEvents(). This is not enough to close this bug though. The right click delete option in GAJ is still quite flaky in operation...

Revision history for this message
Mikkel Kamstrup Erlandsen (kamstrup) wrote :

Ok. I have an idea of what's going on now...

Generally (but not always) I have to click delete three times on an item (recently used file) before it's removed from the log. Looking at debug output from ZG I can see that indeed 3 *different* events gets removed as I click. A new one each time. On the third delete the item is removed from the log.

My guess at what's going down is that GAJ has the "same" entry for both a Visit, Modify, and a Create event. This is because of a bug/odd behavior in the way the datahub harvest events from .recently-used.xbel. I see it inserts exactly these three events for each entry in the .recently-used.xbel.

Revision history for this message
Siegfried Gevatter (rainct) wrote :

I think the Zeitgeist side of this has been fixed.

Changed in zeitgeist:
status: Confirmed → Fix Released
Changed in gnome-activity-journal:
assignee: nobody → Siegfried Gevatter (rainct)
status: Confirmed → In Progress
Revision history for this message
Siegfried Gevatter (rainct) wrote :

Fixed, revision 1123.

Changed in zeitgeist:
status: Fix Released → Fix Committed
Seif Lotfy (seif)
Changed in zeitgeist:
milestone: 0.3.3 → 0.6
milestone: 0.6 → 0.3.3
status: Fix Committed → Fix Released
Revision history for this message
Stefano Candori (cando) wrote :

Recently i noticed that i encounter this problem for example with Bzr events: if i commit 2 times on the same branch, i get only one event in GAJ. That is due to the fact that the two commit-event have the same uri...
Imho GAJ should display these 2 events separately for example comparing if the "text" property is different...
If you agree i could assign this bug to me...

Revision history for this message
Siegfried Gevatter (rainct) wrote : Re: [Bug 561860] Re: Activity Journal's Right-Click Delete Functionality Broken

Are you setting the timestamp correctly?

Revision history for this message
Stefano Candori (cando) wrote :

@Siegfried, solved thanks..
Well, also GAJ works flawlessy..i think we can close this bug.

Revision history for this message
Siegfried Gevatter (rainct) wrote :

I'm closing this bug since it has been fixed both in Zeitgeist (by always committing removals) and in GNOME Activity Journal (by removing all events in the same day part).

Stefano, please open a new bug about your issue, against Zeitgeist Data-sources. IMHO the Bazaar plugin should be fixed to give each revision a different URI, possibly including the revision ID.

Changed in gnome-activity-journal:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers