Python Forum
Python3 No Module Named gi, Tkinter, setuptools and more... On Fedora Linux
Thread Rating:
  • 3 Vote(s) - 3.67 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Python3 No Module Named gi, Tkinter, setuptools and more... On Fedora Linux
#1
hello i am new on python3. i passed to python3 from python2.

while i am using python3 on idle-shell, python3 not giving any import error. but while i am using python3 on terminal, python3 giving too many import error.
i did not understand why is python3 giving import error while i am on terminal.

Thanks.
Reply
#2
Python 3:
Tkinter now tkinter
gi ? http://packages.ubuntu.com/search?keywords=python3-gi
setuptools: https://pypi.python.org/pypi/setuptools/3.3

I would find something better than idle, try PyCharm community or atom
idle does some weird stuff
Reply
#3
You need to show the code. It's not possible to guess.
Please show the code within the IDE and from the terminal.
Reply
#4
I solved, python3 command is not working correctly. i run /usr/bin/python3 command instead of it. that works correctly.

Do you know what are the differences of two commands ?

Thanks for helps.
Reply
#5
There is something wrong in your PATH.

Post the output from both which python3, echo $PATH commands
"As they say in Mexico 'dosvidaniya'. That makes two vidaniyas."
https://freedns.afraid.org
Reply
#6
(Apr-02-2017, 02:08 PM)wavic Wrote: There is something wrong in your PATH.

Post the output from both which python3, echo $PATH commands

/usr/bin/which: no python3, in (/usr/lib64/qt-3.3/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/home/lorderon/.local/bin:/home/lorderon/bin)
/usr/bin/echo
/usr/bin/which: no bin in (/usr/lib64/qt-3.3/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/home/lorderon/.local/bin:/home/lorderon)
Reply
#7
Here is what I've asked for.

Output:
victor@jerry:~$ echo $PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin victor@jerry:~$ which python3 /usr/bin/python3
"As they say in Mexico 'dosvidaniya'. That makes two vidaniyas."
https://freedns.afraid.org
Reply
#8
(Apr-02-2017, 02:47 PM)wavic Wrote: Here is what I've asked for.

Output:
victor@jerry:~$ echo $PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin victor@jerry:~$ which python3 /usr/bin/python3


which python3 command gives "/usr/local/bin/python3" output.
i understand now why does python3 give error because i am using /usr/bin/python3 but python3 command doesn't mean this path. how to change my python3 command path ? Thx.

i solved it with running " export PATH=/usr/bin:$PATH ". it worked. but "/usr/bin" path is duplicated in PATH values so i deleted second same path.


Note:
How can i add the solved tag on topic.
Reply
#9
Quote:i understand now why does python3 give error because i am using /usr/bin/python3 but python3 command doesn't mean this path. how to change my python3 command path ? Thx.

the same problem by me.

i am running python 2.7.6 and python 3.6.1 on linux mint 17.3 simultaneously.
the output of 'which python' is:
Output:
/usr/bin/python
the output of 'which python3' is:
Output:
/usr/local/bin/python3
the output of 'echo $PATH' is:
Output:
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
with the command 'python3' in the linux-terminal i am starting the python 3.6.1 version interactive
mode of the interpreter and ... it works normally ... except that when i import 'tkinter module' with the command 'import tkinter' it gives me error:
Output:
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/local/lib/python3.6/tkinter/__init__.py", line 36, in <module> import _tkinter # If this fails your Python may not be configured for Tk ModuleNotFoundError: No module named '_tkinter'


some ideas how to solve this error?
thanks in advance!
Reply
#10
tkinter is Tkinter (capital 'T') on python 3
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  no module named 'docx' when importing docx MaartenRo 1 712 Dec-31-2023, 11:21 AM
Last Post: deanhystad
  Problem with pymodbus - ModuleNotFoundError: No module named 'pymodbus.client.sync' stsxbel 2 22,947 Nov-02-2023, 08:20 AM
Last Post: South_east
  ModuleNotFoundError: No module named 'requests' Serg 18 2,166 Oct-29-2023, 11:33 PM
Last Post: Serg
  Resolving ImportError: No module named gdb (Python in C++) mandaxyz 3 1,313 Oct-04-2023, 02:43 PM
Last Post: mandaxyz
  ModuleNotFoundError: No module named 'PyPDF2' Benitta2525 1 1,392 Aug-07-2023, 05:32 AM
Last Post: DPaul
  ModuleNotFoundError: No module named 'eyed3' Wimpy_Wellington 2 1,227 Jul-10-2023, 03:37 AM
Last Post: Wimpy_Wellington
  How to fix this error: ModuleNotFoundError: No module named 'notears' yaoyao22 2 964 Jul-09-2023, 11:24 AM
Last Post: yaoyao22
  Help with pyinstaller "No module named" korenron 9 8,209 Jun-15-2023, 12:20 PM
Last Post: snippsat
  Problem with Pyinstaller. No module named '_tkinter' tonynapoli2309 0 934 May-15-2023, 02:38 PM
Last Post: tonynapoli2309
  ModuleNotFoundError: No module named 'omsdk.sdkproto' donvito7 4 1,770 Oct-20-2022, 02:56 PM
Last Post: deanhystad

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020