Closed atagunov closed 3 years ago
I think you made right reasoning. Try hard code your ocamlearlybird path in debug.js and then repackage the extension and try.
I think you made right reasoning. Try hard code your ocamlearlybird path in debug.js and then repackage the extension and try.
Thanks a lot for getting back to me on this.
I have added eval $(opam env)
to my ~/.profile
and rebooted my computer. I can confirm that ocamlearlybird
is now on my $PATH
in a regular terminal.
I have also edited debug.js
, re-run vsce package
, uninstalled hackwaly.ocamlearlybird
extension, closed VSCodium
, deleted ~/.vscode-oss/extensions/hackwaly.ocamlearlybird-1.0.1
folder, started VSCodium
, re-installed extension from the new ocamlearlybird-1.0.1.vsix
, confirmed that ~/.vscode-oss/extensions/hackwaly.ocamlearlybird-1.0.1/debug.js
now looks like this:
const child_process = require('child_process');
child_process.spawn('/home/username/.opam/dev/bin/ocamlearlybird', ['debug'], {
stdio: ['inherit', 'inherit', 'inherit']
});
I am afraid this didn't help.. I'm still seeing the same behaviour: blue progress line runs for 5-10 seconds at top-left of my VSCodium
window and then nothing happens. I still don't see /usr/bin/env CAML_DEBUG_SOCKET=127.0.0.1:... ...
anywhere nor do I see the output from my toy program.
That's wired. I didn't tested it under linux, nor codium. But I tested it in WSL. It runs very well. Could you please upload your toy project onto some place such as github repo?
That's wired. I didn't tested it under linux, nor codium.
I very seriously hoped codium
would behave identically to code
.. OCaml Platform
and Haskell
seem to work
My feeling is that Linux may be a bigger difference between the environments we're trying to make it run in
Could you please upload your toy project onto some place such as github repo?
I've actually uploaded a tiny zip I hope it's as good as a project on github
Sorry, I missed it.
I was hoping some extra logging could be inserted somewhere to make things clearer.. If you ever feel like adding extra logging statements and perhaps committing to a new branch in your github repo I will be happy to give it a go. I guess I will also need advice on which log file to look into/to send to you - there seems to be a lot of them
If you ever feel like adding extra logging statements and perhaps committing to a new branch in your github repo I will be happy to give it a go
Great idea! You are welcome. BTW. There's log mechanics. But only in OCaml side and not densely.
Maybe I had phrased my message badly.. What I wanted to say is:
I suggested that if you didn't want to clog the master
branch you could push the logging onto a new branch in your project on Github. If you do that I will be happy to checkout the new branch, build and try. I will also be happy to report back on the results and send the relevant logs if necessary. I don't know which log to send because there are so many but I think we can work it out.
I wish I could do this myself, however I'm still a total noob in all of OCaml, VSCode and nodejs, and.. well there are so many things to learn :)
Currently I have not enough time to do this because I have no desktop linux environment. And the financial support from ocaml-sf has been suspended for a while. I can't spend much time as I have another jobs to do.
Some users of ocamlearlybird maybe use linux too. Maybe they can help you.
@atagunov I have setted up an Linux environment and did reproduce your problem. This issue is expected to be solved in this week. Before that, you can exec ocamlearlybird serve --verbosity=debug --port=4712
in terminal and add debugServer: 4712
to your launch configuration to use ocamlearlybird to debug your toy project.
I have setted up an Linux environment and did reproduce your problem. This issue is expected to be solved in this week
:+1: happy to test on my machine once done
Before that ...
No big rush learning OCaml is a kind of a side-project for me
I can confirm that latest version from git works for me on Ubuntu. Many thanks for fixing this!
Hi,
hate to bother.. got a tiny toy project (zip) on Ubuntu 20.04, latest compiler (4.11.1), VSCodium 1.53.2 via a snap,
OCaml Platform
version 1.6.0 installed. I didInstalled the resulting
ocamlearlybird-1.0.1.vsix
into VSCodium, madelaunch.js
look like thisWhen I try to launch debugger for this configuration blue progress line runs for 5-10 seconds but nothing happens. In particular I don't see this
/usr/bin/env CAML_DEBUG_SOCKET=127.0.0.1:... ...
printed to myTERMINAL
and there is no output from my app anywhere neither inOUTPUT
nor inTERMINAL
.. At the same time if I open the terminal inVSCodium
these workI have placed breakpoints into source code that doesn't help either.. It seems like the app is not launched at all.. Can't find anything relevant int he
VSCodium
logs either..My
~/.profile
doesn't includeeval $(opam env)
but I tried doingeval $(opam env)
and then launchingcodium
from the same terminal - that didn't help. All relevant libraries are installed indev
opam
switch which I have made my default switch viaopam switch dev
for the purpose of debugging this issue. Normally I expected thedev
switch to be activated byocamllabs.ocaml-platform
extension via this fragment in.vscode/settings.json
in my project:but as I say for now this is my default switch which I can confirm by looking at my
~/.opam/config
.