Code review comment for lp:~stolowski/unity-scopes-shell/diff-updates

Revision history for this message
Paweł Stołowski (stolowski) wrote :

> > There seems to be a few issues with aggregator scopes now. It looks like
> while
> > new results are being loaded the first category's results get duplicated.
> Then
> > when the refresh completes, the duplicates disappear.
> >
> > The most noticeable scope I see this with is the Photos scope. All results
> in
> > the My Photos category at the top get duplicated while the refresh is busy,
> > then suddenly disappear when its done.
> >
> > For aggregators that load quickly I think we get away with not revealing
> this
> > issue because the duplicates get removed before the new set is displayed.
> > Perhaps we also get away with duplicating results in a top category that is
> > full as we don't see the extras being appended to the end.
> >
> > Other scope's I've seen this on (although harder to catch) are:
> >
> > * Food (duplicate "Add your fitbit account" item)
> > * Nearby (deplete "Where am I" result)
>
> I debugged this and it turned out it's due to the way these scopes work...
> They create *unique* category ids on every search (an id, plus a timestamp
> each time), e.g. "nominatim-
> how:declared:first_result:incoming_template::surface19.10.2015_14:55:26:265".
>
> Now, this creates a serious issue with the existing implementation of the
> plugin, where we never remove categories, only move them down (and hide) in
> the model when they are empty - effectively a leak of resources. I think we
> could stop shell plugin from caching category objects indefinitely, but I
> would definately leave it for a separate MP if we deem it a good idea.
>
> I talked to Kyle about this problem and he is going to fix the aggregator
> scopes (or ask respective people from their team to do that), which should fix
> the issue you saw. Apparently this MP needs to wait till aggregators are
> updated, otherwise the experience will be suboptimal.

Related bug for Kyle's aggregators: https://bugs.launchpad.net/scope-aggregator/+bug/1507666

« Back to merge proposal