abhishekkrthakur / colabcode

Run VSCode (codeserver) on Google Colab or Kaggle Notebooks

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Google Colab has started banning colabcode

ar8372 opened this issue · comments

colabcode is really an awesome tool, especially for someone who has very low local compute. But recently after the policy update of Google Colab (https://research.google.com/colaboratory/faq.html) , it has started banning use of tunneling.

colabcode

Now Google Colab gets timeout after 10-15 minutes. Is there any solution to this @abhishekkrthakur ? any other alternative library,

thanks.

This is really unfortunate. Why would they do this? I think the same thing is happening with Kaggle now. Very sad. Ive been using this for so long I actually don't know what to do now. I cant import my code into cells this is so terrible. Importing files into Kaggle is a nightmare.

This is really unfortunate. Why would they do this? I think the same thing is happening with Kaggle now. Very sad. Ive been using this for so long I actually don't know what to do now. I cant import my code into cells this is so terrible. Importing files into Kaggle is a nightmare.

Yes , kaggle editor is terrible. Is there any other ways to connect to kaggle jupyter server remotely?

I dont know, I tried looking into this method briefly.

https://towardsdatascience.com/how-to-kaggle-the-engineer-way-act-1-vs-code-containers-b3279970c029

https://code.visualstudio.com/docs/remote/containers

I dont know a lot about containers so im going to have to try and learn this method.

I definitely want to avoid using kaggle cells. Kaggle cells are an absurd way to code.

Hi @kuro7766 , @JapinderSandhu ,
I found a workaround for this, not the best but the closest I could get to vs code like env on google-Colab.
First mount the drive where your code is available and then run below code. [Make sure you disable the add blocker if you are using brave]

!pip install colab-xterm
%load_ext colabxterm
%xterm

It will open a terminal for you.
You can edit all your .py files or any other file by just double clicking on it and a tab will open for it.
terminal

Another option is using GitHub Codespaces . GitHub provides with vs code env to write your code on fly.
To open a project in vs-code just open the project on GitHub and press . key on your keyboard.

@ar8372 thanks for the response. I see that colab-xterm however this does not work with Kaggle. I will have to swtich to google colab then which is still better than nothing.

Thank you so much for this help ! I had some issues installing anaconda on the google colab env but I figured it out. Hoping for smooth sailing from here.

I dont understand why Kaggle and Google Colab are doing this and banning ngrok tunnels. It is a way more effective method of programming with VS CODE and actual files, rather than coding in cells.

Dont know why they are making our lives harder.

@ar8372 This is really terrible, the runtime on google colab disconnects randomly after 45 minutes. Google colab seems very unreliable compared to kaggle.

this is not good

colabcode is really an awesome tool, especially for someone who has very low local compute. But recently after the policy update of Google Colab (https://research.google.com/colaboratory/faq.html) , it has started banning use of tunneling.

colabcode

Now Google Colab gets timeout after 10-15 minutes. Is there any solution to this @abhishekkrthakur ? any other alternative library,

thanks.

UPDATE: S
After some digging and guidance this stackoverflow :
https://stackoverflow.com/questions/48350226/methods-for-using-git-with-google-colab

showed me a better method of using github and cloning my repository in the kaggle runtime using the !git clone command. I was unaware you could clone a github repository and run a python file in this method. I was even able to create an anaconda environment and run everything smoothly. So everything is running smoothly again :D <3 <3 :D

The method shared in this article seems to work quite well for creating a publicly accessible FastAPI endpoint from Colab. I'm only doing it for very brief periods to test the endpoints, so don't anticipate any issues from Colab with it...

https://medium.datadriveninvestor.com/flask-on-colab-825d2099d9d8

Similar info here:

https://stackoverflow.com/questions/63833593/how-to-run-fastapi-uvicorn-in-google-colab