
I had this happen this morning inside Emacs when trying to run Racket and wondered if this could be an issue with macos Big Sur security changes … ? Error running timer: (file-error "make client process failed" "Connection refused" :name "*Racket REPL*" :buffer #<buffer *Racket REPL*> :host "127.0.0.1" :service 55555 :nowait nil :tls-parameters nil :coding nil) [2 times]

That looks like a somewhat old version of Racket Mode, i.e. before c. Feb 2020. It used to connect its Racket back end, via TCP port 55555. But more recently, it just starts the back end and issues command via piped stdin/stdout. It does make TCP connections, one for each REPL if/as/when you start a REPL by e.g. doing a racket-run
. But it doesn’t need to just to start the back end, at all, for things like racket-xp-mode
and the check-syntax support. Startup is much simpler/faster, these days. The back end picks the port number, i.e. it’s a so-called ephemeral port. https://www.greghendershott.com/2020/02/the-big-switcheroo.html

It’s possible that Big Sur if it’s doing anything differently, might handle ephemeral ports differently, and so a later version of Racket Mode might help?

I haven’t attempted to upgrade my older Mac laptop to Big Sur yet. I think it’s probably still on El Capitan or something like that.

(Also, speaking of security, the TCP port is open only to localhost, and more importantly, only accepts connections when given an authentication token given by starting the back end program. So it should be immune to browser hosted attacks. Unless some browser hosted thing can run programs on your PC… but in that case Racket Mode is the least of your worries. :smile:)

The long version of this is at https://github.com/greghendershott/racket-mode/issues/327

That protection isn’t new since Feb 2020, it’s older, so I’m not suggesting upgrading for that.

Just maybe for whatever Big Sur is doing differently. But I don’t know if that will help.

Thank you @greg, I’ll first try updating my racket-mode!

Updating to racket-mode–20201209.1942 fixed all my problems, thanks again!

@jxonas has joined the channel