Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

latest build python3 error when running pykms_Server.py #25

Closed
roadrage999 opened this issue May 15, 2019 · 3 comments
Closed

latest build python3 error when running pykms_Server.py #25

roadrage999 opened this issue May 15, 2019 · 3 comments

Comments

@roadrage999
Copy link

roadrage999 commented May 15, 2019

Module tkinter is being called but is not a default installation option with python:

apt install python3-tk resolved the issue but a default git pull and minimal system build does not contain this module.

same results with python2 running so not isolated to 3 on debian

Error below

py_kms_GuiBase.py line 16 in module import tkinter as tk
ImportError: No module named tkinter

@CirnoT
Copy link

CirnoT commented May 15, 2019

Please do note that this will now not work without DISPLAY when not in TTY. script can be used to go around this: /usr/bin/script -qfc "/usr/bin/python /opt/py-kms/pykms_Server.py -V DEBUG -F /var/log/py-kms_server.log" /dev/null

May 15 11:17:56 mio python[4385]: Traceback (most recent call last):
May 15 11:17:56 mio python[4385]:   File "/opt/py-kms/pykms_Server.py", line 266, in <module>
May 15 11:17:56 mio python[4385]:     srv_main_with_gui()
May 15 11:17:56 mio python[4385]:   File "/opt/py-kms/pykms_Server.py", line 197, in srv_main_with_gui
May 15 11:17:56 mio python[4385]:     root = pykms_GuiBase.KmsGui()
May 15 11:17:56 mio python[4385]:   File "/opt/py-kms/pykms_GuiBase.py", line 77, in __init__
May 15 11:17:56 mio python[4385]:     tk.Tk.__init__(self, *args, **kwargs)
May 15 11:17:56 mio python[4385]:   File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1823, in __init__
May 15 11:17:56 mio python[4385]:     self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
May 15 11:17:56 mio python[4385]: _tkinter.TclError: no display name and no $DISPLAY environment variable

@SystemRage
Copy link
Owner

@roadrage999
try now, bypassed that import.

@roadrage999
Copy link
Author

removed python3-tk package and did a fresh pull, everything working as it did previously on a debian install

edgd1er referenced this issue in edgd1er/py-kms Oct 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants