Giter VIP home page Giter VIP logo

vscode-gmusic's Introduction

Hey! I'm Nick, aka @nickthegroot πŸ‘‹

Commonly Used Languages/Frameworks

Python Typescript Kotlin Swift Pandas PyTorch React Postgres Terraform AWS

vscode-gmusic's People

Contributors

dependabot[bot] avatar hailey123 avatar nickthegroot avatar sedders123 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

vscode-gmusic's Issues

Like/Dislike doesn’t work when listening to a radio

Steps to reproduce:
Launch GPMDP and start a radio station (ex: Feel Good Dance/EDM)
Launch VS Code and like the song.

Expected results:
The song is liked

Additional information
Seems to work when playing from a playlist, just not with a single song/radio station.

Like/Dislike menu action is broken with GPMDP 4.6.0+

I have google-play-music-desktop-player-4.6.0-1.x86_64 installed and the extension's GMusic: Like/Dislike Song action isn't working.

It doesn't print or report any errors but nothing happens on the player side, except that when I check the terminal I launched it from, I saw:

error: WebSocketAPI Error: Invalid message recieved , data={"namespace":"rating","method":"setRating","arguments":5}
Error: Bad arguments
    at WebSocket.<anonymous> (/usr/share/google-play-music-desktop-player/resources/app.asar/build/main/features/core/websocketAPI.js:197:17)
    at emitTwo (events.js:126:13)
    at WebSocket.emit (events.js:214:7)
    at Receiver.ontext (/usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/WebSocket.js:841:10)
    at /usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/Receiver.js:536:18
    at Receiver.applyExtensions (/usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/Receiver.js:371:5)
    at /usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/Receiver.js:508:14
    at Receiver.flush (/usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/Receiver.js:347:3)
    at Receiver.finish (/usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/Receiver.js:541:12)
    at Receiver.expectHandler (/usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/Receiver.js:493:33)
    at Receiver.add (/usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/Receiver.js:103:24)
    at Socket.realHandler (/usr/share/google-play-music-desktop-player/resources/app.asar/node_modules/ws/lib/WebSocket.js:825:20)
    at emitOne (events.js:116:13)
    at Socket.emit (events.js:211:7)
    at addChunk (_stream_readable.js:263:12)
    at readableAddChunk (_stream_readable.js:250:11)
    at Socket.Readable.push (_stream_readable.js:208:10)
    at TCP.onread (net.js:594:20)
error: WebSocketAPI Error: Invalid message recieved , data={"namespace":"rating","method":"setRating","arguments":5}

It appears that the WebSocket API has changed slightly:
https://github.com/MarshallOfSound/Google-Play-Music-Desktop-Player-UNOFFICIAL-/blob/master/docs/PlaybackAPI_WebSocket.md#rating
as I don't see anything about setRating there.

Error when websocket connection fails could be clearer

Hi! Nice extension. Finally got it working after I realised the player had failed to start up the websocket server, even though it was working and capable of playing music otherwise. (I debugged this by attempting to connect to ws://localhost:5672 with https://github.com/lafikl/telsocket)

While the websocket didn't work I was greeted with "Failure to run command" errors for any actions, presenting this nice error dump in one of the Output terminals:

[2018-06-27 18:26:49.705] [exthost1] [error] Error: not opened
    at WebSocket.send (/mnt/users/alan/.vscode/extensions/nbdeg.vscode-gmusic-1.2.0/node_modules/ws/lib/WebSocket.js:344:18)
    at gMusicClass.togglePlay (/mnt/users/alan/.vscode/extensions/nbdeg.vscode-gmusic-1.2.0/out/extension.js:122:17)
    at vscode_1.commands.registerCommand (/mnt/users/alan/.vscode/extensions/nbdeg.vscode-gmusic-1.2.0/out/extension.js:8:16)
    at e._executeContributedCommand (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:674:613)
    at e.$executeContributedCommand (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:675:6)
    at e._doInvokeHandler (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:636:832)
    at e._invokeHandler (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:636:550)
    at e._receiveRequest (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:635:631)
    at e._receiveOneMessage (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:635:400)
    at /usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:634:315
    at /usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:637:395
    at /usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:95:432
    at e.fire (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:96:764)
    at Socket.<anonymous> (/usr/share/code/resources/app/out/vs/workbench/node/extensionHostProcess.js:154:338)
    at emitOne (events.js:96:13)
    at Socket.emit (events.js:191:7)
    at readableAddChunk (_stream_readable.js:178:18)
    at Socket.Readable.push (_stream_readable.js:136:10)
    at Pipe.onread (net.js:560:20) gmusic.playpause

Could be nice to consider presenting a friendly error notification saying something like "Websocket failed to connect. Check the player is running and the JSON API is enabled." or something like that.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.