• Aryan Noshirvnai's avatar
    Route Shazam's HTTP calls through the configured proxy tunnel · f485f7ae
    Aryan Noshirvnai authored
    Shazam identification has been failing on prod (network-level block on
    amp.shazam.com - confirmed DNS-hijacked AND SNI-blocked directly). A
    proxy tunnel (SSH SOCKS5 -> privoxy -> HTTPS_PROXY env var) was already
    built and working for exactly this, but shazamio's own aiohttp client
    builds its session with trust_env left at the default (False), so those
    env vars were silently ignored. Shazam() accepts an injectable
    http_client - subclass it to force proxy= onto every request when one's
    configured; a no-proxy dev machine behaves exactly as before.
    
    This matters more now that short 5-second mic-listen clips are involved:
    AcoustID (the only path that was actually reaching out) matches full
    tracks reliably but frequently returns zero candidates for a bare 5s
    clip, which is exactly what Discovery's mic button sends.
    Co-Authored-By: 's avatarClaude Sonnet 5 <noreply@anthropic.com>
    Claude-Session: https://claude.ai/code/session_019i3NAUkLkHNbsPg5vKfzF9
    f485f7ae
Name
Last commit
Last update
alembic Loading commit data...
deploy Loading commit data...
scripts Loading commit data...
src Loading commit data...
tests Loading commit data...
.env.example Loading commit data...
.gitignore Loading commit data...
.gitlab-ci.yml Loading commit data...
Dockerfile Loading commit data...
README.md Loading commit data...
alembic.ini Loading commit data...
docker-compose.yml Loading commit data...
requirements-remix.txt Loading commit data...
requirements.txt Loading commit data...
setup.sh Loading commit data...