-
-
Notifications
You must be signed in to change notification settings - Fork 212
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't connect to new REPL if VSCode was started first #2
Comments
Hello! Very nice to hear from you. I have been dying to get some feedback on how the extension works out there. I am not sure I understand the process described completely, so please bear with me if I seem to answer it with nonsense. =) This is the process I have intended to support:
The reason I've not put effort into starting the real from VS Code is that the project I work most on takes a while to start, and if I need to restart VS Code I don't like the penalty to wait for it to start the REPL again. I think your desired process is almost supported if you use the Reconnect command. And I can certainly make it so that if no This all said. Just a few hours before you filed this issue I updated the plugin so that it automatically starts a REPL in the terminal connected to the REPL started from a terminal somewhere. And I am thinking that maybe you haven't/hadn't seen that update yet? With this version you get some more commands that helps working with the terminal REPL together with the code being edited, such as switching to the edited namespace, and evaluating code being edited in the terminal REPL. Please let me know if you have tried version 1.2 yet and what you think about it, if so. Hoping you will keep finding this extension useful. And will put in work to make it so. 🤠 |
Hi Peter! Thanks for the reply. You're right that I hadn't seen the update before I filed the issue. After updating and coming back to the plugin, the Reconnect command does indeed do what I'm looking for, so I'm a happy camper! I'll close this issue out. I've been considering abandoning VSCode for my Clojure work because it seems to miss some important features that Atom supports, but I don't like Atom nearly as much as an editor. However, the inline evaluation of forms and the "evaluate and send to REPL" functions of your extension help tremendously with my VSCode satisfaction! If I were to choose the one big thing that bothers me about Clojure in VSCode (besides the fact that the parinfer extension is a little buggy and isn't actively supported), it would be auto-indent support that follows the style-guide. Maybe something you could potentially put on your to-do list if you're taking requests 😄 |
Glad your workflow is working again! Still curious about you think of the integrated Terminal REPL support, please feel invited to file more issues or just comment on that in this thread. I haven't noticed the auto-indent thing. Can you tell a way or two it fails? (I mostly use Paredit to get things indented, and haven't studied the style guide very closely.) Didn't know the parinfer extension was abandonware. That is not good and explains some of the pain it deals out, but it still is delivering much more bliss so still using it. Maybe you should make ourself available as the maintainer? 🤠 |
One more thing. I think your way of starting the REPL would benefit from configuring the extension to not autoconnect to the REPL:
(I also think starting the REPL from the internal terminal will get a bit confusing with the internal terminal REPL that the extension starts upon connecting, but anyway. 😀) |
Oh yeah, turning off autoConnect does work for me. Thanks for that tip! For formatting/identing, a good example is using a Consider the following snippet:
As you're typing that out, hitting the But then, hitting I think the parinfer plugin takes care of some of this if you're using the right setting, but I type pretty fast, and parinfer becomes very unpredictable with fast typing because it has slow response time. And personally, I'd rather have to manually format stuff than have to manually undo unpredictable plugin behavior. Being a maintainer is a good suggestion, but I'm already struggling to finish projects I'm already committed to :( |
Thanks. I'll have a look at how these things are determined in VS Code. The responsibilities among the different plugins and core VS Code are unclear to me. But it makes some sense that this plugin should try take care of autoindenting. |
And just to follow-up about the parinfer extension... suddenly it's working a lot better, even though there hasn't been any updates. I wonder if something about VSCode got updated or maybe turning paredit back on somehow makes it interact and work better, though I don't see how. But it's suddenly feeling very usable to me, which is awesome! Honestly, if all this keeps working in conjunction with your plugin, the only Clojure integration that I would really feel like VSCode is missing is the auto-indentation issue. That would be amazing. If you decide to tackle it sometime, I'd be happy to help you test and give suggestions for different indentation cases. (Least I could do, of course, given that you're doing the heavy lifting.) |
I really enjoy using the integrated terminal in VSCode, so I tend to start my repl using
lein repl
from there.I've noticed that clojure4vscode allows you to connect to a new REPL port if it was able to connect to some REPL at startup. But if you start VSCode first, there's no way to connect to a newly started REPL.
This is what I have to do to get it to work, which isn't ideal:
This is what I would like to work:
nrepl - trying to connect
label in the task bar, which pops up the text box that allows you to put in your newly-started REPL addressIf this is supposed to work already and I'm doing something wrong, please let me know!
Really liking what you've done with this plugin so far. Nice work!
The text was updated successfully, but these errors were encountered: