|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
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
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Warp <war### [at] tagpovrayorg> wrote:
>
>> I have not yet tried to install the Pyvon package for myself here, but
>>I'm going to try it now.
>
>
> I "installed" the package in the same way as the install.sh script does,
> but to another directory.
> The first problem was that the 'pyvon' script assumes that it has been
> installed in /usr/local/pyvon.
> Fixing that didn't help: When I run it, it opens a small window which
> immediately closes and the program terminates. No error messages, nothing.
> It just immediately terminates and that's it.
> What could be the problem? Perhaps more places which assume that the
> program is installed under /usr/local/pyvon?
>
> (And no, I don't have access to /usr/local nor I can install anything
> there. I'm no root.)
>
I have updated the installation page and made a safer version ( with a
few modifications in the Insert directory).
For those who got stuck, tell me if it's better now.
Fabien
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Warp <war### [at] tagpovrayorg> wrote:
>
>> I have not yet tried to install the Pyvon package for myself here, but
>>I'm going to try it now.
>
>
> I "installed" the package in the same way as the install.sh script does,
> but to another directory.
> The first problem was that the 'pyvon' script assumes that it has been
> installed in /usr/local/pyvon.
> Fixing that didn't help: When I run it, it opens a small window which
> immediately closes and the program terminates. No error messages, nothing.
> It just immediately terminates and that's it.
> What could be the problem? Perhaps more places which assume that the
> program is installed under /usr/local/pyvon?
>
> (And no, I don't have access to /usr/local nor I can install anything
> there. I'm no root.)
>
I guess you untarred the d35.tgz file in you home directory.
I used /usr/local because that's the directory used by POV-RAY when
using the install.sh script contained in the povlinux.tgz archive.
What message do you get when you type python d35.py in the pyvon directory?
Fabien H
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
this quote from HENON fabien of Wednesday 08 Jan 2003 3:10 am:
> 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.
I don't know. I tried rpm -e pyvon when Daniel suggested it for pyvon 1.1.
Also tried it with pyvon 1.2. But no luck.
> Things you might try :
I'll try these out in the morning. (10:30pm so a bit late for me to start
now.)
>
> One more thing near line 2252 :
>
> Replace this
> ----snip----------
> ------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 --------------
Yes, move the menu1= line to above the if statement. I tried that earlier
with 1.1 and recently with 1.2, and it lets pyvon start (and it appears to
function ok). Except the insert pull down menu in pyvon doesn't function
properly - it flashes up and disappears as soon as I let go of the mouse
button. Other menus stay up after one click so you can select a menu item.
(I tried looking through an earlier pyvon for how menus are handled, but it
was too different for me to make sense of it.)
cheers
Peter
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
fabien Henon <fab### [at] caramailcom> wrote:
> What message do you get when you type python d35.py in the pyvon directory?
Oh, it works that way.
The 'pyvon' script seems to start "python res.py" instead, which causes
the problem I described (ie. it just terminates immediately without saying
anything).
--
#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}// - Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote:
>fabien Henon <fab### [at] caramailcom> wrote:
>> What message do you get when you type python d35.py in the pyvon directory?
>
> Oh, it works that way.
>
> The 'pyvon' script seems to start "python res.py" instead, which causes
>the problem I described (ie. it just terminates immediately without saying
>anything).
That's right, pyvon script starts 'python res.py'.
res.py does too things :
1 - calculate the height and width of your screen ( in
order to display an xterm box just below pyvon). All povray streams are
directed to that xterm console.
2 - starts the main pyvon script that is supposed to be in /usr/local/pyvon.
In the file res.py, you have a line that looks like :
[......]d+0+%d -e python /usr/local/pyvon/d35.py" % [.....]
Just replace '/usr/local/d35.py' with '~/pyvon/d35.py' and you should have
both the stream out and the pyvon window.
Fabien H
>
>#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
>N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
>N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}// - Warp -
>
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
HENON fabien <fab### [at] caramailcom> wrote:
> Just replace '/usr/local/d35.py' with '~/pyvon/d35.py' and you should have
> both the stream out and the pyvon window.
It seems to work ok now.
By the way, there doesn't seem to be any way of setting regular text
color, which seems to be fixed to black. Eg. identifiers are colored like this.
As I'm accustomed to using black background, this is a problem.
--
#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}// - Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote:
> HENON fabien <fab### [at] caramailcom> wrote:
>
>>Just replace '/usr/local/d35.py' with '~/pyvon/d35.py' and you should have
>>both the stream out and the pyvon window.
>
Ok I'll see to that and rework the insertions menu, just to check for
remaining bugs (if any).
Fabien H
>
> It seems to work ok now.
>
> By the way, there doesn't seem to be any way of setting regular text
> color, which seems to be fixed to black. Eg. identifiers are colored like this.
> As I'm accustomed to using black background, this is a problem.
>
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
this quote from HENON fabien of Wednesday 08 Jan 2003 3:10 am:
>
> Things you might try :
>
> - Run pyvon as root
su to root
run pyvon from Konsole in KDE
black streams box flashes up, then disappears
pyvon window never appears
(ie same as when run as a user)
> - Check you reading permissions on the Insert directory
All files in the Insert directory have permissions 666, ie
-rw-rw-rw- and are owned by root.
> - Move all your folders and files from the Insert directory to a backup
> directory ( just leave the 'Insert' with nothing in it), run pyvon
pyvon starts ok (nothing in the insert menu, of course)
> - Move all your folders and files from the Insert directory to a backup
> directory except for one folder and all its files, run pyvon
One folder >00 - Scene templates< in Insert directory containing its 7
files, no other folders or files.
Pyvon starts, and has only Scene templates in the insert menu.
> - 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
There are no .pov files installed in the Insert directory, so I copied
lamp.pov across. Test done with no other files or directories in the
Insert directory.
Pyvon won't start, same as before - just flashes the black streams box.
Also, it gives the same result if there is just one .txt file in the Insert
directory and nothing else.
I also tried with all 22 directories (and their contents) in the Insert
directory. Pyvon starts ok.
I hope this helps you debug the programme.
regards
Peter
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
The /usr/local/pyvon/Insert directory on this PC has many .txt files in it,
and these appear to be duplicates of files in the subdirectories of
/Insert.
Maybe these .txt files are from an earlier install of pyvon, and they
weren't removed by either the install script or the rpm -e.
Removing them manually appears to allow Pyvon to start ok.
Peter
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|