0

I have python file i want to share it to my friends, but they are saying they cant download the file.

Is there any way that they can run the python file without downloading that file? They cant download .exe files also.

I tried using online compiler for python but as my file has tkinter and many modules, compilers are not able to run my file.Can i run the code which i have mentioned in google colab or jupyter notebook?

Please suggest me how to do this. I just want to demonstrate the app which i created.

2 Answers2

0

Google Colaboratory should be able to solve your problem.

To install external libraries use !pip install <library_name> in any of the cell. And then use go on using colab notebook as one would use a Jupyter Notebook.

It even has option to share your colab notebook, so others would be able to execute the same code as you without having to download any files locally.

sxddhxrthx
  • 587
  • 5
  • 13
  • `TclError: no display name and no $DISPLAY environment variable` this error is coming on google colab – Kushagra Jain Sep 13 '21 at 13:57
  • I would require more context with the code you are running to be able to help you with your error. – sxddhxrthx Sep 13 '21 at 14:01
  • `ERROR: Could not find a version that satisfies the requirement tkinter (from versions: none) ERROR: No matching distribution found for tkinter --------------------------------------------------------------------------- TclError Traceback (most recent call last) in () 24 z=0 25 df='' ---> 26 master = Tk() 27 f1 = 2.5 28 f2 = 2.5 TclError: no display name and no $DISPLAY environment variable` – Kushagra Jain Sep 13 '21 at 14:19
  • I think [this](https://stackoverflow.com/a/61168385/9092023) should help you. – sxddhxrthx Sep 13 '21 at 14:34
-1

Ask to run '.py' extension in a Code Editor (eg. VSCode) Or else just ask to run the '.exe' by downloading it. And then delete if not want to keep it.

Aryan
  • 21
  • 2
  • is there any way they can run the file without downloading it – Kushagra Jain Sep 12 '21 at 14:39
  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-ask). – Community Sep 12 '21 at 16:39