Open FrobtheBuilder opened 5 years ago
I've never had this issue (maybe because I compiled the bindings myself?) but @qwerasd205 has worked around this by removing Discord's signature. You should be able to ad-hoc sign the binding though as suggested in the error:
codesign --force -s - node_modules/node-sass/vendor/darwin-x64-69/binding.node
I tried compiling my own bindings with the build_node-sass thing but I'll try that real quick.
Doesn't work, complains about it being signed adhoc.
I found something on this here https://github.com/Valloric/YouCompleteMe/issues/3216. I have Homebrew's python@2 installed and I know node-gyp uses python so I'll try removing it and building again. Let me see if that fixes it.
Still doesn't work. Not sure what's up with this.
I fixed it by running codesign --remove-signature
on /Applications/Discord.app/Contents/MacOS/Discord
.
Phwew, that was annoying. You think there might be a better solution for this?
The unsigning of the executable will be an automated part of the install process on macOS in the installer.
Alright, then at least it's documented in this issue in case anybody else runs into the same problem.
Describe the bug Can't inject into Discord on macOS when building from source. Discord launches with a JS error complaining about the node-sass binary being unsigned.
To Reproduce Run
npm install
,npm run build
,npm run release
, etc, thennpm run inject
and get this stupid error on startup then Discord launches without BetterDiscord being properly injected. Try to fix it withnpm run build_node-sass
and rebuilding but it still doesn't work.Expected behavior I assume it should launch without that error and have BetterDiscord injected into the client, but it doesn't.
Screenshots
System information macOS Mojave, Mainline Discord latest version
Are you willing and able to fix this? I assume it has something to do with signing the node-sass binary so Electron will accept it, but I'm not sure exactly what that entails, so I guess not. Perhaps I could figure it out if given enough time but I assume somebody else is probably more qualified to handle this.