Skip to content

Compiler is killed when switching between previewed files  #541

@Minnozz

Description

@Minnozz

vscode v1.69.2
rescript-vscode v1.5.11

Reproduce:

  • Open a single file in a project in preview mode (single click in explorer, name is shown in italics in the tab bar)
  • Start a build via the popup
  • Switch to a different file in preview mode
    • This closes the currently previewed file and opens the new file

After starting a build via the popup:

❯ ps aux | grep rescript
bart.sc+  389111  2.5  0.5 21417852 78388 ?      Sl   10:10   0:00 /nix/store/5i1zfmhk46dwl94jfp82lacyi5fk06f5-vscode-1.69.2/lib/vscode/code --ms-enable-electron-run-as-node /home/bart.schuurmans/.vscode/extensions/chenglou92.rescript-vscode/server/out/server.js --node-ipc --clientProcessId=389080
bart.sc+  389337  0.6  0.2 321984 36596 ?        Sl   10:10   0:00 node /home/bart.schuurmans/engineering/lumi/frontend/provisioner/node_modules/.bin/rescript build -w

After switching to a different file in the same project, the compiler is no longer running:

❯ ps aux | grep rescript
bart.sc+  389111  0.5  0.5 21417852 79356 ?      Sl   10:10   0:00 /nix/store/5i1zfmhk46dwl94jfp82lacyi5fk06f5-vscode-1.69.2/lib/vscode/code --ms-enable-electron-run-as-node /home/bart.schuurmans/.vscode/extensions/chenglou92.rescript-vscode/server/out/server.js --node-ipc --clientProcessId=389080

The popup to start a new build is also shown now.

strace of the rescript build -w process during switching:

[pid 389337] --- SIGTERM {si_signo=SIGTERM, si_code=SI_USER, si_pid=389111, si_uid=1000} ---
+++ exited with 0 +++

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions