Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Similar tracks for own-app users via an external provider (Last.fm first)

Aperta
#714 4 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
rust
Ambito
cli

Direzione di ricerca

Start with src/infra/network/recommend.rs and docs/ai-dj.md to understand the existing out-of-reach detection and external-provider pattern. The issue leaves key storage and whether the fallback replaces the existing action undecided, so confirm those choices before implementation. Done means a configured Last.fm fallback resolves similar tracks to Spotify results in the existing Recommendations screen, while missing keys or provider failures retain the current status message.

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

Descrizione

enhancement

Is your feature request related to a problem? Please describe.

With your own Spotify app (Development Mode), Spotify's /recommendations endpoint answers 403, so "play recommendations for a song" can't work (see #517 and #567, which cover the error handling). ncspot users who move to spotatui lose "songs similar to this one" for good, and Spotify has no replacement endpoint for these apps.

Describe the solution you'd like

Use an external service for the similar tracks and Spotify only as the catalogue and player, the same split the AI DJ already uses (docs/ai-dj.md).

Proposed first step, a Last.fm provider:

  • The user sets a Last.fm API key in the config (the key is free). Nothing is shipped in the binary and nothing changes for users who don't set it.
  • When the recommendations action is used and the Spotify endpoint is out of reach for the key (the case endpoint_is_out_of_reach already detects in src/infra/network/recommend.rs), call Last.fm track.getSimilar with the artist and title of the track.
  • Resolve each result to a Spotify track with search (limited to 10 results in Development Mode), then show them in the existing Recommendations screen / RecommendedTracks table context.
  • If no key is configured or Last.fm fails, keep today's "Recommendation: removed by Spotify..." status message.

Later, behind the same small provider interface, a ListenBrainz provider (no key needed; its similar-recordings dataset returns sensible results, but it needs a MusicBrainz id for the track, so it takes more steps to resolve).

Describe alternatives you've considered

  • ListenBrainz first: no key, but mapping a Spotify track to a canonical MusicBrainz recording takes several calls and one of the lookup endpoints timed out in my tests.
  • The AI DJ: works without Spotify's endpoint but needs an LLM setup, which is more than "songs like this".

Additional context

Questions before I start:

  1. Is a provider-based fallback welcome, or would you rather not depend on third-party services here?
  2. Where should the key live: config.yml under behavior, or an environment variable like the other sources?
  3. Should the fallback replace the existing action (r on a track) or be a separate one?

I'm happy to implement it and open a PR once you confirm the direction.

Lingua principale
Rust
Stelle
1.4k
Fork
238
Merge medio
9h 21m
PR unite (30g)
193

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 LargeModGames/spotatui

Tutte le issue di LargeModGames/spotatui

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.