[Standards] XEP-0084: User Avatar - Invalid example?

Kim Alvefur zash at zash.se
Sun Sep 1 12:51:33 UTC 2019


> On 31.08.19 15:30, Paul Schaub wrote:
> Hello everyone!
> 
> XEP-0084 Example 4 shows a Metadata publication which does contain a
> single info element which has type image/gif. However section §4.2.1
> states in the last paragraph:
> 
>> The <metadata/> root element MAY contain more than one <info/>
> element. Each <info/> element MUST specify metadata for the same avatar
> image but in alternate content-types (e.g., "image/png", "image/gif",
> and "image/jpeg"), and one of the formats MUST be "image/png" to ensure
> interoperability. [...] Support for the "image/png" content type is
> REQUIRED.
> 
> https://xmpp.org/extensions/xep-0084.html#proto-meta
> 
> As I understand this section the example 4 is invalid, as it does not
> contain a info element of type "image/png".

Yeah, my interpretation is that if you publish multiple formats then at
least one of them MUST be PNG. But GIF or JPEG should be sufficiently
well-supported that it doesn't matter that much.

It becomes more problematic if you were to publish only a newer format
with less wide-spread support like WebP.

On Sat Aug 31, 2019 at 3:34 PM Paul Schaub wrote:
> Also, am I right assuming that the last published metadata item always
> contains the whole ensemble of available avatar info elements?

I would think so too, like in
https://xmpp.org/extensions/xep-0084.html#examples

> I.e. if I publish my avatar to PubSub and send a metadata update, I
> have to include the corresponding info elements in the next update
> when I later upload my avatar to a HTTP service, right?

Sounds about right. If you make the same avatar available via another
method then you add that to the same metadata node. Same with
alternative formats or sizes.




More information about the Standards mailing list