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

dicomtree.py example not working due to tix #379

Closed
massich opened this issue Jul 5, 2017 · 2 comments
Closed

dicomtree.py example not working due to tix #379

massich opened this issue Jul 5, 2017 · 2 comments
Labels

Comments

@massich
Copy link
Member

massich commented Jul 5, 2017

hey all,

I'm going through the examples and I can not run dicomtree.

$ python dicomtree.py ~/Documents/my_dicomdir/

Traceback (most recent call last):
  File "dicomtree.py", line 71, in <module>
    root = tkinter_tix.Tk()
  File "/home/sik/miniconda3/lib/python3.6/tkinter/tix.py", lin
e 218, in __init__                                            
    self.tk.eval('package require Tix')
_tkinter.TclError: can't find package Tix

The main problem is tix, see the following ipython session:

from tkinter import tix
from tkinter.constants import *
root = tix.Tk()
Traceback (most recent call last):
  File "<ipython-input-20-c03089e228b3>", line 3, in <module>
    root = tix.Tk()
  File "/home/sik/miniconda3/lib/python3.6/tkinter/tix.py", line 218, in __init__
    self.tk.eval('package require Tix')
TclError: can't find package Tix

I don't understand the error since the libraries seem to be at the right place according to this thread

$ ldconfig -p | grep Tix
	libTix8.4.3.so.1 (libc6,x86-64) => /usr/lib/libTix8.4.3.so.1
	libTix8.4.3.so (libc6,x86-64) => /usr/lib/libTix8.4.3.so

This is my configuration:

Linux-4.8.0-49-generic-x86_64-with-debian-stretch-sid
Python 3.6.0 |Continuum Analytics, Inc.| (default, Dec 23 2016, 12:22:00) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-1)]
ttk 0.3.1

More over tix is deprecated in fabour of ttk. (see python doc)

Do I have a completely broken python installation? Does anyone have a configuration where this example actually runs? Shall we think about migrating this example to ttk?

@darcymason
Copy link
Member

I have a similar configuration in a Lubuntu virtualbox and it is working for me. Only obvious difference I can see is that ldconfig only returns your first line (exactly the same) but not the second. My linux is 4.10.0-26-generic.

I had python 3.5.3 but also installed python 3.6 and it ran fine with that too. Pydicom was installed with python setup.py develop, but I don't see how that could make a difference.

About ttk, I'm happy to migrate to that to stay ahead of the deprecation. Do you know if there are any issues using it in the python versions supported by pydicom (now dropping 2.6, so python 2.7, 3.4, 3.5, 3.6)?

@glemaitre
Copy link
Contributor

@massich Can you reopen the issue in contrib-pydicom

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants