Media widget shows Brave logo instead of cover art on first track of a Brave PWA (YouTube Music)

Aperta Adatta ai principianti
#4,412 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
72/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
linux
Ambito
desktop

Direzione di ricerca

Il controllo del segnaposto si trova in Services/TrackArtService.qml, dove _artHashDenylist contiene l'SHA1 del logo di Chrome. Inizia da lì e verifica come viene calcolato l'hash del file artUrl prima che venga accettato. Aggiungi l'hash del segnaposto di Brave alla lista, oppure filtra sull'identità MPRIS "Brave", come suggerisce la issue. È completato quando la prima traccia di una PWA di Brave mostra la copertina reale invece del logo.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug
Description

When I start YouTube Music as an installed Brave web app (PWA), the DankBar media widget
shows the Brave logo as cover art for the first track. As soon as the next track starts,
the correct album cover is displayed and everything works as expected.

It looks like Brave publishes its own logo as a placeholder mpris:artUrl before the real
cover arrives, similar to the Chrome placeholder that is already handled in
Services/TrackArtService.qml:

// sha1s of placeholder art to reject (Chrome's own logo, shown before real cover).
readonly property var _artHashDenylist: ["764a730860c5b8a7bbee690ee5a443672ae37dc8"]

The Brave logo is not on this denylist, so it seems to get committed and stays until the
track changes.

Steps to reproduce
  1. Install YouTube Music as a Brave web app.
  2. Start it: brave --profile-directory=Default --app-id=<app-id>
  3. Play a track. The bar media widget shows the Brave logo.
  4. Skip to the next track. The real cover appears.
Expected behavior

The Brave placeholder logo should be rejected like the Chrome one, and the real cover should
be shown for the first track as well.

Possible fix

Add the SHA1 of Brave's placeholder image to _artHashDenylist (or detect browser
placeholder art in a more generic way, e.g. by MPRIS identity "Brave").

Environment
  • DMS: v2.1.2 (API v40)
  • Hyprland: 0.57.2
  • Brave: 158.1.100.59
  • OS: CachyOS (Linux 7.3.5)
  • MPRIS player: org.mpris.MediaPlayer2.brave.instance*, identity "Brave",
    artUrl is a file:///tmp/.org.chromium.Chromium.* file
Lingua principale
QML
Stelle
8.4k
Fork
549
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di AvengeMedia/DankMaterialShell

Tutte le issue di AvengeMedia/DankMaterialShell

Issue simili

Altre issue su Desktop Dev

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.