You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Profile pictures not loading for most WebID users after commit 2ae197c #29
After commit 2ae197c ("Add inline avatar support for JSON-LD messages"), profile pictures stopped working for most WebID users in regular Solid chats.
User Report
From testpro in Solid Chat Global:
"I am logged in as testpro.solidweb.org, it shows 4 chats at the left including saved messages, I have scanned through all 4 chats, and the only 3 profile pics that show are yours, espenmartine and ewingson/solidcommunity"
"and angelo, all other just single letters"
"to be even more precise: either question mark, or single letter, or capitalized two letters one prename, one surname"
Expected Behavior
All users with foaf:img in their WebID profile should display their avatar.
Actual Behavior
Only ~4 out of many users have working avatars
All others show fallback: ?, single letter initials, or two-letter initials
Affects solid-chat.com with regular Solid chats
Root Cause Analysis
The commit 2ae197c changed the avatar loading logic:
asyncfunctionfetchAvatar(webId,store,$rdf){// First check storeletavatar=store.any(profile,FOAF('img'))?.value// Only fetch if not found AND http URIif(!avatar&&webId.startsWith('http')){awaitstore.fetcher.load(doc, ...)avatar=store.any(profile,FOAF('img'))?.value}}
Potential Issues
rdflib fetcher caching: When store.fetcher.load() is called for a document that was previously loaded (by login flow, solid-ui, or another pane), the fetcher may skip re-fetching. The previous load might not have included avatar data.
In-memory cache persistence: The avatarCache Map persists across SPA navigation. If a profile fetch fails once, the null is cached permanently.
Race condition: If something else partially loads a profile before fetchAvatar runs, the fetcher might think it's already loaded.
Possible Fixes
Add { force: true } option to store.fetcher.load() to bypass fetcher cache
Clear avatar cache on chat load
Revert to always calling store.fetcher.load() for http WebIDs, while still checking store first for non-http URIs (Matrix)
Environment
solid-chat.com
Users on various pod providers (solidweb.org, solidcommunity.net, etc.)
Related
Commit: 2ae197c ("Add inline avatar support for JSON-LD messages")
The change was intended to support Matrix-bridged messages with matrix: URIs
Activity