freeCodeCamp / CodeAlly-CodeRoad-freeCodeCamp

10 stars 5 forks source link

Add a restart whole tutorial button #16

Closed moT01 closed 7 months ago

moT01 commented 3 years ago

https://github.com/coderoad/coderoad-vscode/issues/476

Duplicating here for myself

moT01 commented 3 years ago

Should be resolved with https://github.com/coderoad/coderoad-vscode/pull/513

ShMcK commented 3 years ago

@moT01 safe to close this one?

moT01 commented 3 years ago

Well, it doesn't seem to be working quite right. I tried on one of my tutorials, it reset me to the second step - after I passed it, it did not load the next commit - it did take me to the next instructions. Resetting your Learn NPM tutorial, took me to the first step, but it also did not load next commit after I passed it. Both times - a file I had created was still there and did not get deleted after reset.

Not quite sure what the process of this reset button is. But here's a thought on how it maybe could work: remove everything from the workspace folder, re-clone the tutorial, and re-run the set-up commands? I suppose there must be something in there to tell it to go to the first instructions.

moT01 commented 2 years ago

update: still not working in CodeAlly with CodeRoad 0.18.4 - no worries, low priority. Just an update as I'm testing.

ShMcK commented 2 years ago

I can see this is not working properly in a lot of cases. I've added extra command line logs to help debug. https://github.com/coderoad/coderoad-vscode/pull/563

AdamZaczek commented 2 years ago

An update that might help @ShMcK prioritize - we are 80% done with adding our own way to reset the entire tutorial. It's as Quincy said - once something goes badly, it goes very very badly. We want to give users a way to reset to a clean state.

moT01 commented 2 years ago

Nice @AdamZaczek - I was unaware that was in the works. It will make it easier. Probably something CodeRoad wants to have on their side as well in case the extension is running somewhere else. Although, it's not necessary for either of them to work right away. With the CodeAlly dashboard, users can start over by deleting their container there, which I will have to explain in some sort of FAQ or something.

ShMcK commented 2 years ago

In that case, would we hide the "reset" button in the tutorial?

moT01 commented 2 years ago

You can hide it if you want @ShMcK. Probably not a bad idea since it doesn't seem to be working quite right at the moment - last I tried anyway.

ShMcK commented 2 years ago

To remove the reset button, add the following env:

CODEROAD_DISPLAY_RUN_TEST_BUTTON=false