rage / tmc-vscode

TestMyCode extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=moocfi.test-my-code
MIT License
24 stars 6 forks source link

TMC Extensions failing #700

Open fr0ggie00 opened 11 months ago

fr0ggie00 commented 11 months ago

So the TMC extension is not working at all. It say when opening it/trying to download it that the extension tests are failing.

To Reproduce Steps to reproduce the behavior:

  1. Go to visual studio code and go to extensions and open TMC
  2. if you try to open test my code menu it says: There is no data provider registered that can provide view data.

Screenshots

Screenshot 2023-10-10 124933 Screenshot 2023-10-10 130100

Desktop (please complete the following information):

TMC Extension logs

[2023-10-10 09:55:44:477] [DEBUG] Backend at https://tmc.mooc.fi [2023-10-10 09:55:44:477] [DEBUG] Config dir at undefined [2023-10-10 09:55:44:479] [ERROR] Error during initialization: Error: spawn EBUSY

Heliozoa commented 11 months ago

Hi, The "Extension tests" badge is just referring to the "Extension tests" Github workflow that is currently passing and is unrelated to the issue: https://github.com/rage/tmc-vscode/actions/workflows/test.yml

The error in the logs indicates that the CLI file is currently being accessed by something else, possibly by something like an antivirus program. Depending on your operating system, there are various ways of figuring out what's accessing it. The log message before the ones you posted should display the path of the CLI that the extension is trying to use.

If it is caused by an antivirus, the issue may be temporary while it's scanning the file and restarting VSCode will solve the issue. If not, more information like your operating system and whether this issue also occurs on older versions like 2.2.3 would be needed.

fr0ggie00 commented 11 months ago

Here is what it says now when trying to use TMC. I uninstalled the whole studio code app and also tmc and tried to use older versions of tmc but it did not help at all.

[2023-10-10 16:17:21:336] [DEBUG] Backend at https://tmc.mooc.fi [2023-10-10 16:17:21:336] [DEBUG] Config dir at undefined [2023-10-10 16:17:37:124] [ERROR] Failed to check if authenticated: Process didn't seem to finish or was taking a really long time. [2023-10-10 16:17:37:124] [ERROR] Error during initialization: Runtime Error: Process didn't seem to finish or was taking a really long time.

fr0ggie00 commented 11 months ago

I use a windows computer and had no previous issues with the extension.

Heliozoa commented 11 months ago

Can you check the CLI executable manually? The path should be in the logs before the "Backend at..." message. If you check its properties, try to run it manually by double clicking it, or run the command it's trying to execute (the one in the "Running..." log message) directly from a terminal, it might give some hint as to why it's timing out like that. I'm not sure what could cause issues like this, except maybe an antivirus, sorry.

JoshGrab commented 9 months ago

I had the same problem and was able to make it work. For reference, I had been trying to install the extension immediately upon opening VS Code for the first time. After clicking Install on the TMC extension and getting the same failure as noted in OP, I tried saving the generic "Untitled-1" tab as a .py file and saving it to a Workspace. I'm a totally new VS Code user, so I'm still figuring out how workspaces work, but basically as soon as it seemed I had a workspace open, a "Welcome to TMC 2.2.4" tab popped open and within that tab, it was simple to follow instructions to get to point where you "Add new course" and search for your course. It still says "Extension Tests failing" in the Extension tab, but it's clearly working and I was able to log into the course I'd already started online (not in VS Code) and see and download the course exercises.

Good luck!

To be clear, this was the error message I had been getting, which matches OP above: [DEBUG] Config dir at undefined [ERROR] Error during initialization: Error: spawn EBUSY