zim-wiki team mailing list archive
-
zim-wiki team
-
Mailing list archive
-
Message #00335
Re: [Fwd: Re: Pyzim alpha 2 released]
Forgive me as I'm not a programmer. I don't know what else I can do
to debug this issue.
If you guys have any tips, just let me know what else I can try.
I tried using pdb, and here's the output:
ln-liquidnets-macbook-pro-3:~ jliu$ ./pyzim
> /Users/jliu/pyzim(19)<module>()
-> zim.main(sys.argv)
(Pdb) n
AttributeError: "'NoneType' object has no attribute 'path'"
> /Users/jliu/pyzim(19)<module>()
-> zim.main(sys.argv)
(Pdb) l
14 sys.exit(1)
15
16
17 try:
18 pdb.set_trace()
19 -> zim.main(sys.argv)
20 except zim.GetoptError, err:
21 print >>sys.stderr, sys.argv[0]+':', err
22 sys.exit(1)
23 except zim.UsageError, err:
24 print >>sys.stderr, zim.usagehelp.replace('zim', sys.argv[0])
(Pdb) q
Traceback (most recent call last):
File "./pyzim", line 19, in <module>
zim.main(sys.argv)
File "/Users/jliu/gtk/inst/lib/python2.5/bdb.py", line 54, in trace_dispatch
return self.dispatch_exception(frame, arg)
File "/Users/jliu/gtk/inst/lib/python2.5/bdb.py", line 92, in
dispatch_exception
if self.quitting: raise BdbQuit
bdb.BdbQuit
ln-liquidnets-macbook-pro-3:~ jliu$ gtk/inst/bin/zim
Traceback (most recent call last):
File "gtk/inst/bin/zim", line 17, in <module>
zim.main(sys.argv)
File "/Users/jliu/gtk/inst/lib/python2.5/site-packages/zim/__init__.py",
line 192, in main
handler = zim.gui.GtkInterface(*args, **optsdict)
File "/Users/jliu/gtk/inst/lib/python2.5/site-packages/zim/gui/__init__.py",
line 189, in __init__
icon = data_file('zim.png').path
AttributeError: 'NoneType' object has no attribute 'path'
On Sat, Jul 18, 2009 at 11:38 AM, Jeffrey Liu<jliu@xxxxxxxxxxx> wrote:
> FYI - running from the source worked.
> (python zim.py)
>
>
>
> On Sat, Jul 18, 2009 at 11:08 AM, Jeffrey Liu<jliu@xxxxxxxxxxx> wrote:
>> I ran from the zim install (after python setup.py install).
>> I tried setting the XDG_DATA_DIRS environment variable and re-running,
>> but I'm still getting the same error. (With the gtk-osx build from
>> source, the zim.png and other files are located at
>> ~/gtk/inst/share/zim)
>>
>>
>> ls gtk/inst/share/zim
>> applications globe_banner_small.png pixmaps
>> templates
>> globe.svg manual preferences.conf zim.png
>> globe_banner.svg menubar.xml style.conf zim.svg
>>
>>
>> There are wiki pages at gtk-osx talking about how to package your
>> program for Mac OS X, and I can give that a try.
>>
>> Thanks,
>> Jeff
>>
>>
>>
>> On Sat, Jul 18, 2009 at 4:08 AM, Jaap
>> Karssenberg<jaap.karssenberg@xxxxxxxxx> wrote:
>>> ... forgot to CC the mailing list
>>>
>>> Jeffrey Liu wrote:
>>>>
>>>> However, I ran into two things when running pyzim.
>>>> 1. The version check fails even though I'm running python 2.5.2.
>>>>
>>>
>>> Oops, typo on my side - code 2.6 in that version check instead of 2.5 as
>>> intended.
>>>
>>>> 2. After removing the version check, pyzim would attempt to run, but
>>>> I see the following error:
>>>> Traceback (most recent call last):
>>>> File "/Users/jliu/gtk/inst/bin/zim-test", line 8, in <module>
>>>> zim.main(sys.argv)
>>>> File "/Users/jliu/gtk/inst/lib/python2.5/site-packages/zim/__init__.py",
>>>> line 192, in main
>>>> handler = zim.gui.GtkInterface(*args, **optsdict)
>>>> File
>>>> "/Users/jliu/gtk/inst/lib/python2.5/site-packages/zim/gui/__init__.py",
>>>> line 189, in __init__
>>>> icon = data_file('zim.png').path
>>>> AttributeError: 'NoneType' object has no attribute 'path'
>>>>
>>>
>>> This means it can not find the data files. Will add a check for that.
>>> Are you running from the source directory or did you install already?
>>> In this later case you need to check where the data files were installed
>>> (e.g. /usr/local/share/zim) and set the XDG_DATA_DIRS environment
>>> variable to point to that location.
>>>
>>>> Sorry, I wish I knew more python to help debug these two issues.
>>>>
>>>
>>> No problem. I'm really interested to hear your results trying to run on OS
>>> X. Ideally would like to have some procedure how to compile a binary package
>>> for OS X.
>>>
>>> Cheers!
>>>
>>> Jaap
>>>
>>>
>>>
>>
>
Follow ups
References