Chromebook + Linux (Beta) + Thonny 3.2 using PIP installation unable to launch

944 views
Skip to first unread message

JackW

unread,
Aug 18, 2019, 12:48:11 AM8/18/19
to thonny
I have been trying to use Thonny to learn python on my desktop PC
I also want to use it on my chromebook now that Linux apps are supported. 

Tried using the commands below to install v3.0.5
sudo apt install thonny 


So I tried using "pip3 install thonny" to install the latest version. But after successfully installed v3.2, I cannot find where to launch it.  

Can someone help please?

Aivar Annamaa

unread,
Aug 18, 2019, 12:56:36 AM8/18/19
to thonny
Hi!

`thonny` package itself doesn't include any desktop or menu launchers, but you should now have `thonny` command in your Python's bin directory. You could also try `python3 -m thonny`.

Which distro are you using? Note that `tkinter` cannot be expressed as Python package dependency, so it's possible you have one required dependency missing even if `pip3 install thonny` succeeded.

Best regards,
Aivar

JackW

unread,
Aug 18, 2019, 2:28:45 AM8/18/19
to thonny
Thanks 'python3 -m thonny' works. It launches v3.2. However, that means a terminal windows will have to be open too when thonny is being used.  Not a big issue, but is there a way i can build a 'launcher' or shortcut?

As for 'tkinter' I am not 100% certain whether that has been installed during the v3.0.5 installation or not.  As of now, I have both v3.0.5 and v3.2 installed.

I may test on a clear installation by resetting the chromebook to its factory settings

Cheers,
J

Aivar Annamaa

unread,
Aug 18, 2019, 3:08:36 AM8/18/19
to thonny
> As for 'tkinter' I am not 100% certain whether that has been installed

If you got Thonny running, then tkinter is present. Thonny can't work without it.

About launcher -- I'm not familiar with Chrome OS, but you can try this approach: https://support.google.com/pixelbook/thread/708306?hl=en

Best regards,
Aivar

JackW

unread,
Aug 19, 2019, 8:12:58 AM8/19/19
to thonny
Thanks for the link Aivar, 

I had difficulties configuring the .desktop file.

In the example, the answer suggested to use:
[Desktop Entry]
Name=Firefox
Comment=Browse the World Wide Web
GenericName=Web Browser
X-GNOME-FullName=Firefox Web Browser
Exec=/home/username/bin/firefox/firefox %u
Terminal=false
Type=Application
Icon=firefox-esr
Categories=Network;WebBrowser;

Could you provide some advice on how to configure this for Thonny?

I am sort of a novice user of Linux, I follow the suggestion and created a "share/applications" folder in ".local" directory.

For Thonny's execute file path, I am guessing it is ".local/bin/thonny" but I cannot find the full path for ".loacl" folder. 

I tried /home/username/.local, but no joy.

Thanks
J

Aivar Annamaa

unread,
Aug 19, 2019, 8:21:00 AM8/19/19
to thonny
Can you run Thonny by simply executing `thonny` in Terminal? 
If yes, then you can look up its absolute path with `which thonny`.

Alternatively, look up absolute path of your Python interpreter (`which python3`) and use something like this in your desktop file:

Exec=/path/to/python3 -m thonny %F

Best regards,
Aivar

Aivar Annamaa

unread,
Aug 19, 2019, 8:22:50 AM8/19/19
to thonny
BTW, if you have x86 or x64 Chromebook, then you could also try installing Thonny+Python bundle by running this script with bash: https://github.com/thonny/thonny/releases/download/v3.2.0/thonny-3.2.0.bash

A.


On Monday, August 19, 2019 at 3:12:58 PM UTC+3, JackW wrote:

Jack Wong

unread,
Aug 19, 2019, 8:48:33 AM8/19/19
to Aivar Annamaa, thonny
Thanks! Will give them a go. Cheers! J



 

From: tho...@googlegroups.com on behalf of Aivar Annamaa <aivar....@gmail.com>
Sent: Monday, August 19, 2019 1:22 pm
To: thonny
Subject: [Thonny] Re: Chromebook + Linux (Beta) + Thonny 3.2 using PIP installation unable to launch
 
--
You received this message because you are subscribed to the Google Groups "thonny" group.
To unsubscribe from this group and stop receiving emails from it, send an email to thonny+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/thonny/ebbbf9dd-ca09-4856-9f75-41c376cd3051%40googlegroups.com.

Scott Webster

unread,
Aug 19, 2019, 6:09:07 PM8/19/19
to thonny
Try using pythonw instead of python. That is the windowless version for GUI apps.

Nathan Robertson

unread,
Apr 28, 2020, 2:26:47 PM4/28/20
to thonny
I have the same problem, and have read through this thread. When, in IDLE, I just type "thonny", it says "Traceback (most recent call last):
  File "<pyshell#0>", line 1, in <module>
    thonny
NameError: name 'thonny' is not defined"
Then I use "import thonny"
Then when i use thonny, it says, "<module 'thonny' from '/home/ngrob2007/.local/lib/python3.5/site-packages/thonny/__init__.py'>" Im not sure what to do.
Thanks!

Nathan Robertson

unread,
Apr 28, 2020, 2:28:14 PM4/28/20
to thonny
Edit: When I use python3 -m thonny, it says invalid syntax and highlights the word thonny.

Nathan Robertson

unread,
Apr 28, 2020, 2:43:01 PM4/28/20
to thonny
Never mind, 
bash <(curl -s https://thonny.org/installer-for-linux) worked to install it well. Then I typed /home/ngrob2007/apps/thonny/bin/thonny and it ran.

Aivar Annamaa

unread,
Apr 28, 2020, 3:06:37 PM4/28/20
to thonny
Hi!

On Tuesday, April 28, 2020 at 9:43:01 PM UTC+3, Nathan Robertson wrote:
Never mind, 
bash <(curl -s https://thonny.org/installer-for-linux) worked to install it well. Then I typed /home/ngrob2007/apps/thonny/bin/thonny and it ran.



This is the expected way to install Thonny on a Chromebook. BTW. How did you install IDLE?

best regards,
Aivar

Nathan Robertson

unread,
Apr 28, 2020, 5:00:43 PM4/28/20
to thonny
Honestly I can't remember. I think it was just sudo apt-get install python.
Reply all
Reply to author
Forward
0 new messages