Open afonsoduarte opened 2 years ago
It seems macOS is preventing Sublime Text.app to create TCP connections on your machine. I don't know macOS very much but it does work on mine. You may goto > System Preferences > Security & Privacy > … to see if Sublime Text was blocked by some reason.
If for some reason the deamon process was killed, then any further requests will result in Connection Refused
error. This is rarely seen (I haven't seen any) but it is still possible. So I just fixed that in c276cfa to try respawn server on any TCP error. You can update your plugin (basically uninstall and install it again) to see if it works.
I checked Security & Privacy
but no trace of Sublime there. I also tried installing prettierd
in a brand new Sublime, in a different laptop, and the result was the same.
With this new patch, it gets stuck trying to connect and failing, in a loop.
If I launch the node server manually with node prettierd.mjs 9870
, the plugin works as expected. So it seems like the node server is going down as soon as it's spun by the plugin.
Sorry but I cannot reproduce this problem on my macOS (same version as yours) / Windows (10, latest). The node server seems to be launched successfully on its first run since it outputs {"ok":9870}
in your console log above. Here's the corresponding python code that spawns it: https://github.com/hyrious/prettierd/blob/5ddb6b30957649fa6c04cc8371cfc71cdc296d84/prettierd.py#L70-L76
I will mark this as unactionable
unless you/me/someone else could figure out how it happens.
I'm running Sublime 4, build 4126 on macOS 12.5, and Prettierd isn't running. As soon as I open Sublime, I see the following in the console:
Once I try to save the file, I see 2 more errors in the console:
I have
prettier
installed globally, and no otherprettier
plugins installed on Sublime.Let me know if there's anything else I should post to help track down this issue.