apple-music-discord-rpc icon indicating copy to clipboard operation
apple-music-discord-rpc copied to clipboard

Timeout and erroring when system is under very high load (0%)

Open MDNich opened this issue 1 year ago • 0 comments

Hey everyone,

First of all wanted to say that this is a great system you have, its amazing and works almost flawlessly :)

Got the following error when computer was under very high load (i.e. 0.0% CPU free), I think its because he did not wait long enough as the system was busy and couldn't give him the resources he wanted.

here is the full error output:

Error: AppleEvent timed out.
    at handleError (https://raw.githubusercontent.com/NextFire/jxa/64b6de1748ea063c01271edbe9846e37a584e1ab/run/mod.ts:180:9)
    at runInOsascript (https://raw.githubusercontent.com/NextFire/jxa/64b6de1748ea063c01271edbe9846e37a584e1ab/run/mod.ts:152:21)
    at async setActivity (file:///opt/homebrew/bin/music-rpc.ts:164:16)
    at async file:///opt/homebrew/bin/music-rpc.ts:74:9
Error: AppleEvent timed out.
    at handleError (https://raw.githubusercontent.com/NextFire/jxa/64b6de1748ea063c01271edbe9846e37a584e1ab/run/mod.ts:180:9)
    at runInOsascript (https://raw.githubusercontent.com/NextFire/jxa/64b6de1748ea063c01271edbe9846e37a584e1ab/run/mod.ts:152:21)
    at async setActivity (file:///opt/homebrew/bin/music-rpc.ts:164:16)
    at async file:///opt/homebrew/bin/music-rpc.ts:74:9
error: Uncaught (in promise) BadResource: Bad resource ID
    this.#ipcHandle.close();
                    ^
    at opSync (deno:core/01_core.js:170:12)
    at Conn.close (deno:ext/net/01_net.js:136:12)
    at DiscordIPC.close (https://raw.githubusercontent.com/harmonyland/discord_rpc/ba127c20816af15e2c3cd2c17d81248b097e9bd2/src/conn.ts:143:21)
    at Client.close (https://raw.githubusercontent.com/harmonyland/discord_rpc/ba127c20816af15e2c3cd2c17d81248b097e9bd2/src/client.ts:317:15)
    at file:///opt/homebrew/bin/music-rpc.ts:78:13
Error: AppleEvent timed out.
    at handleError (https://raw.githubusercontent.com/NextFire/jxa/64b6de1748ea063c01271edbe9846e37a584e1ab/run/mod.ts:180:9)
    at runInOsascript (https://raw.githubusercontent.com/NextFire/jxa/64b6de1748ea063c01271edbe9846e37a584e1ab/run/mod.ts:152:21)
    at async setActivity (file:///opt/homebrew/bin/music-rpc.ts:164:16)
    at async file:///opt/homebrew/bin/music-rpc.ts:74:9
error: Uncaught (in promise) BadResource: Bad resource ID
    this.#ipcHandle.close();
                    ^
    at opSync (deno:core/01_core.js:170:12)
    at Conn.close (deno:ext/net/01_net.js:136:12)
    at DiscordIPC.close (https://raw.githubusercontent.com/harmonyland/discord_rpc/ba127c20816af15e2c3cd2c17d81248b097e9bd2/src/conn.ts:143:21)
    at Client.close (https://raw.githubusercontent.com/harmonyland/discord_rpc/ba127c20816af15e2c3cd2c17d81248b097e9bd2/src/client.ts:317:15)
    at file:///opt/homebrew/bin/music-rpc.ts:78:13

[1]-  Exit 1                  music-rpc.ts
[2]+  Exit 1                  music-rpc.ts

I had it running in background. Specs:

Apple M1 Max on 14" MacBook Pro 64GB Mem 10 Cores CPU 32 Cores GPU 3 total displays 0% CPU free at time of crash

P.S. Just to be clear, the 0% CPU Free was not due to this, I was running 25 instances of Python :) so not the fault of this program.

Thanks everyone!

MDNich avatar Aug 04 '22 21:08 MDNich