ChenghaoMou / touchbar-lyric

Show synced lyric in the touch-bar with BetterTouchTool and NetEase APIs
83 stars 28 forks source link

Lyric Website Blocks Connection #28

Open p3n74 opened 6 months ago

p3n74 commented 6 months ago

The code works for one sone but after that, the website blocks any connections.

requests.exceptions.ConnectionError: HTTPSConnectionPool(host='www.megalobiz.com', port=443): Max retries exceeded with url: /search/all?qry=Seafret+Atlantis&display=more (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x102842a50>: Failed to establish a new connection: [Errno 61] Connection refused'))

p3n74 commented 6 months ago

changing to execute script every 3-5 seconds instead of 1 seems to fix this but there is delay

ChenghaoMou commented 6 months ago

Thanks for raising the issue.

I wasn't able to fix the connection issue with the same song. However, I was able to add a few tricks to smooth the experience a little bit. Still, you should expect some delay for any new song (subsequent play will reuse the same lyric info).

Make sure you update the package with

pip install --upgrade touchbar_lyric