Fix: Résoudre tous les conflits d'authentification
All checks were successful
Build and Push Docker Images / Build Frontend Image (push) Successful in 5m31s
Build and Push Docker Images / Build Backend Image (push) Successful in 8m5s

- Nettoyer logs de debug dans auth.py
- Routes /api/audio/* : auth interne au lieu de middleware global
- /stream et /download : token obligatoire en query param (compat <audio>/<a>)
- /waveform : auth standard via header
- Polling scan/status : ajouter Authorization header
- Player : token JWT sur toutes les requêtes (waveform, stream, download)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-12-26 19:26:01 +01:00
parent f05958ed36
commit 34fcbe1223
3 changed files with 29 additions and 8 deletions

View File

@@ -113,8 +113,14 @@ export default function Home() {
// Poll scan status
const pollInterval = setInterval(async () => {
try {
const token = localStorage.getItem('access_token')
const pollHeaders: HeadersInit = {}
if (token) {
pollHeaders['Authorization'] = `Bearer ${token}`
}
const statusResponse = await fetch(`${getApiUrl()}/api/library/scan/status`, {
headers,
headers: pollHeaders,
})
const status = await statusResponse.json()