Hello,
Well that confused us for a bit. I tested this and couldn't reproduce it.
And then I remembered that I'm still on Tcl/Tk 8.4 and Python 2.4. After
further investigation we think the problem is because in Tcl/Tk 8.5 (or
perhaps the Python 2.5 Tkinter wrapper around it) they change strings from
being of type "string" to being of type "unicode". So what was being sent
to the API was unicode. And it turns out the API currently does not allow
unicode. (That could well change in future.) As a short-term fix we
forced the text that we get back from both the Entry and Text widgets to
be strings. And this worked for me now with Tcl/Tk 8.5 and Python 2.5.
Wayne
On Tue, 2 Dec 2008, Victoria Higman wrote:
> Hi,
>
> I tried writing something in the Details box in the Spin Systems pop-up
> (V2). Analysis didn't accept what I wrote and gave me the following
> traceback.
> First I thought it was expecting numbers rather than text, but just
> entering a number didn't work either.
>
> Hope you can help,
>
> Vicky
>
>
> Traceback (most recent call last):
> File "/home/wb104/ccpnmr/python2.5/lib/python2.5/lib-tk/Tkinter.py",
> line 1403, in __call__
> return self.func(*args)
> File
> "/home/wb104/ccpnmr/ccpnmr2.0/python/memops/gui/ScrolledMatrix.py", line
> 643, in mouseClick
> File
> "/home/wb104/ccpnmr/ccpnmr2.0/python/memops/gui/ScrolledMatrix.py", line
> 556, in finishEditCell
> File
> "/opt/ccpnmr/ccpnmr2.0/python/ccpnmr/analysis/popups/EditSpinSystem.py",
> line 426, in setDetailsText
> self.spinSystem.setDetails( text )
> File "/home/wb104/ccpnmr/ccpnmr2.0/python/ccp/api/nmr/Nmr.py", line
> 71509, in setDetails
> ApiError: ccp.nmr.Nmr.ResonanceGroup.setDetails:
> memops.Implementation.Text input is not of a valid type: 2NCOCX
> - has to be followed by Thr6.
> Exception in Tkinter callback
> Traceback (most recent call last):
> File "/home/wb104/ccpnmr/python2.5/lib/python2.5/lib-tk/Tkinter.py",
> line 1403, in __call__
> return self.func(*args)
> File
> "/home/wb104/ccpnmr/ccpnmr2.0/python/memops/gui/ScrolledMatrix.py", line
> 643, in mouseClick
> File
> "/home/wb104/ccpnmr/ccpnmr2.0/python/memops/gui/ScrolledMatrix.py", line
> 556, in finishEditCell
> File
> "/opt/ccpnmr/ccpnmr2.0/python/ccpnmr/analysis/popups/EditSpinSystem.py",
> line 426, in setDetailsText
> self.spinSystem.setDetails( text )
> File "/home/wb104/ccpnmr/ccpnmr2.0/python/ccp/api/nmr/Nmr.py", line
> 71509, in setDetails
> ApiError: ccp.nmr.Nmr.ResonanceGroup.setDetails:
> memops.Implementation.Text input is not of a valid type: 100
>
>
>
> *********************************************
> Dr. Victoria Higman
> Leibniz-Institut für Molekulare Pharmakologie
> Robert-Rössle-Str. 10
> 13125 Berlin
> Germany
> +49-30-94793-223
> [log in to unmask]
> http://www.protein-nmr.org.uk
>
|