Error: Cannot find module '#discordjs/opus' on pm2 - visual-studio-code

I am having some issues with discord.js/opus.
So I am having the same error as this guy : Error: Cannot find module '#discordjs/opus' but on pm2. When I run it with the Visual Studio Code Debugger it's work but it's keep disappearing the folder when I reopen the file later so I just copy it from my user folder on my computer. When I run it on pm2 it's say the opus folder is not there.

Related

Mac OS latex workshop does not build pdf, error shown is: Recipe terminated with fatal error: spawn pdflatex ENOENT

I installed latex workshop in VSCODE (on Mac OS), but the pdf does not build. Instead it throws the error:
Recipe terminated with fatal error: spawn pdflatex ENOENT.
Does anyone know the solution as I would have assumed the package would work by simply installing?
I found this issue to occur when launching VSCODE from the anaconda GUI. Launching VSCODE directly in launchpad on MAC OS did not through any errors and simply compiled and built the pdf. Hence, this issue appears to be specific to the anaconda installation and launch.
You need to install MacTex for Latex Workshop to work. After installing MacTex, you'll see TexLive Utility which you will use to install all the packages.
If you have all of it installed, then it throws an error because the environment variable is not set in PATH. You can check this by typing
echo $PATH in your terminal or reading the error message in the log.
To fix this:
Open your Library folder and navigate over to TexShop. Open "Engines" and move latexmk engine from "inactive" back to "Engines" folder.
After doing this, you have to add /usr/local/texlive/2022/bin/universal-darwin to your $PATH.
Open Terminal and type ls -a to view all files.
Type open .zshrc in the terminal and add /usr/local/texlive/2022/bin/universal-darwin: after bin:. Save the text editor and close it.
Now, type source .zshrc in the terminal.
Restart your Visual Studio Code, and it should work. Type echo $PATH in Terminal and you should be able to see the path we just added.

rust-analyzer failed to load workspace: "cargo" "--version" failed: program not found

I have Rust installed using WSL2 Ubuntu I have alredy ran basic commands like hello world in rust so cargo is working. I wanted to download the rust-analyzer in VSCODE but I keep getting that error message from the title: rust-analyzer failed to load workspace: "cargo" "--version" failed: program not found
I tried ensuring all paths are correct, all vesions of extension and vscode and rust are up to date. several uninstall re-installs and rustup updates. Toolchain is using stable version. I have reviewed a lot of the other post about this accross all platforms but it seems I can not find the fix. It would be very helpful to get some guidance. Thank you!st
The solution is to open folder as if in WSL.
To do that you need to install this VS code extension called Remote development
Than go to the green symbol in the bottom right corner and then select open WSL folder and open folder with your rust project or just open new WSL window
The last step is to go to extensions and then search for rust-analyzer and hit install
More info regarding the development on WSL can be found here
another good option is open your wsl, move to the project folder and type $ code . or $ code YOUR_PROJECT, then install rust-analyzer extension
Remove the rustc and cargo provide by system package manager (e.g. apt).
Install them from offical rustup script instead.
[note]
I just encounter the same problem when using flatpak version of Lapce.
rust-analyzer failed to load workspace: "cargo" "--version" failed: No such file or directory (os error 2)

setting up visual studio code for c++, but unable to compile

I have installed visual studio 2019 which works fine for c++ but unable to create folders and sections to store multiple code files. So thought of switching to visual studio code and followed all tutorials available on youtube and documentation. But Visual studio IDE has got nothing showing up when Run Build task is initiated, which is expected to show the c++ extension downloaded. Mingw64 is installed and checked in the terminal too.
no output or terminal opened on Run
compiler installation checked
From the image attached regarding no output in the terminal or terminal opened, it looks like the exe is made because it says 'Build finsihed succesfully'. You'll need to run this executable from the terminal.
For this, if youre in the same directory all you have to do is type the filename. helloworld.exe in the cmd, if its powershell, then ./helloworld.exe. (Also note that for exe files you dont need to explicitly mention .exe at the end of the file name)
The powershell method should work on cmd too.
And if youre not in the same directory as the executable, you can either change directory by typing cd path/to/file and proceed as above, or run directly by typing path/to/file/helloworld.exe. where path/to/file is the directory of your helloworld.exe file

Visual Studio Code only compiles when launched from project folder on Linux

I have Visual Studio Code installed in Ubuntu 20.04. I love how it works. I installed it from the tar ball. Same with the SDK. I just found that those appear to work better than installing from deb packages.
I created a desktop file so I could add Visual Studio Code to the dock and launch it that way, but what I've noticed is that projects won't compile. I get errors stating it can't find the project even though the errors are listing the folder where the items exist.
The only way I can get it to work is to:
Open a terminal.
Navigate to the folder where the project files reside.
Launch code from the command line.
Then it works. Otherwise, I get a pop-up error that says "The preLaunchTask 'build' terminated with exit code -2" and then the terminal window is filled with errors.
Here's the last of the error messages and then I opened up a terminal and it shows that I'm in the folder for the project and the csproj exists there:
This also happens if I install Visual Studio code from a repository. It seems launching it from the Unity desktop breaks something. But if I launch it from the command line in a terminal session from the folder where the project resides, then the problem goes away.
I can also reproduce this error from the command line if I launch Visual Studio Code from a different folder than the project I'm trying to compile.
Is this common? Just curious. I'm wondering if because when I launch it from the Unity desktop, it's launching under a different
I got it working under 20.04. I must have done something wrong so I did a wipe of the .NET Core install and reinstalled it all using the bash shell script and then was able to install Code via Software Installer tool. Not sure why it didn't work before, but it works now.

cannot open file libboost_thread-vc120-mt-1_55.lib

I installed the boost files and everything, but every time I run this program in matlab I get LINK : fatal error LNK1104: cannot open file 'libboost_thread-vc120-mt-1_55.lib'
I was able to link the boost directory in Visual Studio just fine, but it doesn't seem to be taking for the libs folder.