POV-Ray : Newsgroups : povray.unix : Pyvon 1.2 : Re: Pyvon 1.2 Server Time
6 Oct 2024 13:44:50 EDT (-0400)
  Re: Pyvon 1.2  
From: HENON fabien
Date: 7 Jan 2003 09:15:08
Message: <web.3e1addfc84d5eda27ff7c9e30@news.povray.org>
Peter wrote:
>this quote from HENON fabien of Monday 06 Jan 2003 11:04 pm:
>
This is getting interesting...

I downloaded the rpm file from the pyvon web site and installed it after
removing the previous installation with a 'rpm -e pyvon'

And it worked fine.


Things you might try :

- Run pyvon as root

- Check you reading permissions on the Insert directory

- Move all your folders and files from the Insert directory to a backup
directory ( just leave the 'Insert' with nothing in it), run pyvon

- Move all your folders and files from the Insert directory to a backup
directory except for one folder and all its files, run pyvon

- Move all your folders and files from the Insert directory to a backup
directory except for one *.pov file located in the Insert directory, run
pyvon



One more thing near line 2252 :

Replace this
----snip----------
for x in listeobjets :
        longname = os.path.join(InsertDir,x)
        if os.path.isdir(longname) :
            menu1 = Menu(menu_insert_popup,tearoff=0,font=police)
            menu_insert_popup.add_cascade(label=x,menu=menu1)
            importedir(longname,menu1)
        if os.path.isfile(longname) :
            if x[-3:] == 'txt' or  x[-3:] == 'pov' :
                menu1.add_command(label=x.............
------snap --------------

with this :

----snip----------
for x in listeobjets :
        longname = os.path.join(InsertDir,x)
        menu1 = Menu(menu_insert_popup,tearoff=0,font=police)
        if os.path.isdir(longname) :
            menu_insert_popup.add_cascade(label=x,menu=menu1)
            importedir(longname,menu1)
        if os.path.isfile(longname) :
            if x[-3:] == 'txt' or  x[-3:] == 'pov' :
                menu1.add_command(label=x.............
------snap --------------

Please pay attention to the indentation (very important in Python)


Tell me which one works (at least one should) to understand what's going on.


Thanks

Fabien H


>> Could you tell me what you have in the Insert directory (just the first 10
>> items will be enough). It might be because of the way your files are
>> sorted in your directory.
>$ls -l
> total 980
>drwxrwxrwx    2 root     root         4096 Jan  6 16:37 00 - Scene
>templates/
>-rw-rw-rw-    1 root     root           82 Sep 20  2001 10 - background.txt
>-rw-rw-rw-    1 root     root         1156 Aug 16  2001 10 - Basic scene.txt
>-rw-rw-rw-    1 root     root          265 Aug 30  1998 10 - clock.txt
>-rw-rw-rw-    1 root     root          524 Apr 27  2001 10 - Fog
>definition.txt
>drwxrwxrwx    2 root     root         4096 Jan  6 16:37 10 - Headers/
>-rw-rw-rw-    1 root     root           67 Aug 30  1998 10 - rgb.txt
>-rw-rw-rw-    1 root     root          121 Apr 25  2001 10 - Scene File
>Header.txt
>-rw-rw-rw-    1 root     root          477 Apr 27  2001 10 - waveform
>attribute.txt
>-rw-rw-rw-    1 root     root          456 Apr 27  2001 20 - additional
>animation variables.txt
>-rw-rw-rw-    1 root     root           57 Sep 26  2001 20 - Ambient fog.txt
>-rw-rw-rw-    1 root     root          111 Apr 27  2001 20 - frequency
>attribute.txt
>-rw-rw-rw-    1 root     root          106 Sep 20  2001 20 -
>global_settings.txt
>drwxrwxrwx   26 root     root         4096 Jan  6 16:37 20 - Include files/
>-rw-rw-rw-    1 root     root          926 Jul 19  2001 20 - Orthographic
>scene.txt
>
>> Something else : edit the file d35.py, goto line 2252 and replace
>>
>> menu1.add_command(label=x.......
>>
>> with :
>>
>> menu.add_command(label=x.......
>
>ok tried that, but no change.  Just the black streams box comes up for a
>second or so, then all disappears.  When I try running d35 direct with
>python, it gives a similar error to previous ...
>
>$ python /usr/local/pyvon/d35.py
>Traceback (most recent call last):
>  File "/usr/local/pyvon/d35.py", line 2252, in ?
>    menu.add_command(label=x[:-4],command= lambda nom=longname :
>insert_example(nom),font=police)
>NameError: name 'menu' is not defined
>
>
>
>anything else I can try?
>thanks
>
>Peter
>


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.