Hello everyone, I’ve had an issue with discord on Arch Linux for a long time, but only now had the time to document the error (had to photograph it with phone and transcribe it).

Its a weird one, buckle up.

At random times, discord crashes which causes my polybar to crash, as well as my sxhkd, which obviously means my computer is practically useless until I hard shutdown using the power button on my case. Whats weird is that sometimes it will go weeks without crashing, and other times it will crash frequently in a short time span (e.g. it crashed a couple times yesterday, and once today).

Here is the error as I photographed it:

And here it is after I manually copied it into a text editor (keep in mind I might have missed a character here or there because of this).

A JavaScript Error occurred in the main process

Uncaught exception:
Error: EROFS: read-only file system, write
	at writeSync (node:fs:923:3)
	at SyncWriteStream._write (node:internal/fs/sync._write_stream:275)
	at writeOrBuffer (node:internal/streams/writable:572:12)
	at _write (node:internal/streams/writable:501:10)
	at Writeable.write (node:internal/streams/writable:510:10)
	at console.value (node:internal/console/constructor:298:16)
	at console.warn (node:internal/console/constructor:405:26)
	at transport.writeFn (/opt/discord/resources/app.asar/node_modules/electron-log/src/node/transports/console.js:45:7)
	at transport (/opt/discord/resources/app.asar/node_modules/electron-log/src/node/transports/console.js:51:15)
	at Logger.processMessage (/opt/discord/resources/app.asar/node_modules/electron-log/src/core/Logger.js:175:11)

Anyone have any idea how I can troubleshoot this?

I also tried checking the following directory but it doesn’t exist on my PC:

/opt/discord/resources/app.asar/node_modules/electron-log/src/core/

I only have the file /opt/discord/resources/app.asar So obviously something is going on there that shouldn’t be happening.

I’ve got no idea how to troubleshoot node apps, so would appreciate any help from those of you who have those skills.

Thanks in advance! Please let me know if you need more info or need me to run commands and show you the output, and Ill do so.

  • chrash0@lemmy.world
    link
    fedilink
    arrow-up
    1
    ·
    46 minutes ago

    weird. i’d probably good around for drive checks personally, any test should be pretty definitive. how did you install Discord? the AUR? maybe a reinstall is in order.

    i don’t think this is Node specific. if i were writing logs, i’d want to be pretty sure they get written, either by creating the directories necessary, putting them in a place i was pretty dang sure existed, and/or crashing as early as possible if the location didn’t exist, which makes me think it’s a weird Discord config error.

    • promitheas@programming.devOP
      link
      fedilink
      arrow-up
      1
      ·
      10 minutes ago

      It seems Ive installed it through the official repositories:

      $ pacman -Qm | grep "discord\|Discord"
      // EMPTY OUTPUT
      

      Ill get back to you about the drive checks, either tomorrow evening or the day after. Ive got a technical assessment for a job position tomorrow so I’ll have to look into that issue after that. :)