Bug 22304

Summary: Avatars interface doesn't implement D-Bus properties
Product: Telepathy Reporter: Felix Kerekes <sttwister>
Component: hazeAssignee: Simon McVittie <smcv>
Status: RESOLVED FIXED QA Contact: Telepathy bugs list <telepathy-bugs>
Severity: enhancement    
Priority: medium CC: will
Version: unspecifiedKeywords: patch
Hardware: Other   
OS: All   
URL: http://git.collabora.co.uk/?p=user/smcv/haze-smcv.git;a=shortlog;h=refs/heads/avatars
Whiteboard: review+
i915 platform: i915 features:

Description Felix Kerekes 2009-06-15 14:16:57 UTC
telepathy-haze still uses the deprecated GetAvatarRequirements spec
Comment 1 Simon McVittie 2010-04-21 11:04:36 UTC
Here, have a patch.

One thing I'm slightly unsure about is that haze_connection_avatars_properties_getter can be called before the Connection is CONNECTED. Is it safe for it to assume that the account's prpl_info will be present already?
Comment 2 Will Thompson 2010-04-21 11:21:23 UTC
Looks fine. Does it work? Is there a simple smoke-test in Gabble we could steal?
Comment 3 Simon McVittie 2010-04-22 05:56:12 UTC
(In reply to comment #2)
> Looks fine. Does it work? Is there a simple smoke-test in Gabble we could
> steal?

Good idea. I stole the one from Gabble and adjusted it to also try before connecting.

(In reply to comment #1)
> One thing I'm slightly unsure about is that
> haze_connection_avatars_properties_getter can be called before the Connection
> is CONNECTED. Is it safe for it to assume that the account's prpl_info will be
> present already?

It turns out this wasn't safe, and crashed Haze. Fixed in my revised branch by returning dummy values before CONNECTED (the spec allows this).
Comment 4 Will Thompson 2010-04-22 06:11:19 UTC
(In reply to comment #3)
> (In reply to comment #2)
> > Looks fine. Does it work? Is there a simple smoke-test in Gabble we could
> > steal?
> 
> Good idea. I stole the one from Gabble and adjusted it to also try before
> connecting.

Could the adjustment be merged back to Gabble too?

> (In reply to comment #1)
> > One thing I'm slightly unsure about is that
> > haze_connection_avatars_properties_getter can be called before the Connection
> > is CONNECTED. Is it safe for it to assume that the account's prpl_info will be
> > present already?
> 
> It turns out this wasn't safe, and crashed Haze. Fixed in my revised branch by
> returning dummy values before CONNECTED (the spec allows this).

Good catch.
Comment 5 Simon McVittie 2010-04-22 06:18:07 UTC
Fixed in git for 0.3.5.

(In reply to comment #4)
> Could the adjustment be merged back to Gabble too?

Yes, in progress.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.