[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.python

Run wxPython app remotely under XWindows

Sean DiZazzo

2/28/2008 11:46:00 PM

Is there something special you have to do to get a wxPython app to run
remotely under xwindows? My Tkinter apps always automatically work
that way, so I was surprised to even be confronted with this problem.

~Sean
8 Answers

Bjoern Schliessmann

2/28/2008 11:51:00 PM

0

Sean DiZazzo wrote:

> Is there something special you have to do to get a wxPython app to
> run remotely under xwindows? My Tkinter apps always automatically
> work that way, so I was surprised to even be confronted with this
> problem.

Could you please provide more detail? My wxPython apps run perfectly
remotely in the X Window System like this:

$ ssh some-other-machine
$ DISPLAY=:0 ./my_app.py

Regards,


Björn

--
BOFH excuse #230:

Lusers learning curve appears to be fractal

Grant Edwards

2/28/2008 11:51:00 PM

0

On 2008-02-28, Sean DiZazzo <half.italian@gmail.com> wrote:

> Is there something special you have to do to get a wxPython
> app to run remotely under xwindows? My Tkinter apps always
> automatically work that way, so I was surprised to even be
> confronted with this problem.

AFAIK, running them remotely works for the sufficiently patient
(I don't actually know abody _that_ patient). The GTK widget
set is a horrible bandwidth hog and in my experience, GTK apps
are unusable over anything slower than a local 100BaseT
Ethernet link.

What sort of failure are you seeing?

--
Grant Edwards grante Yow! Thousands of days of
at civilians... have produced
visi.com a... feeling for the
aesthetic modules --

Sean DiZazzo

2/28/2008 11:59:00 PM

0

On Feb 28, 3:50 pm, Bjoern Schliessmann <usenet-
mail-0306.20.chr0n...@spamgourmet.com> wrote:
> Sean DiZazzo wrote:
> > Is there something special you have to do to get a wxPython app to
> > run remotely under xwindows?  My Tkinter apps always automatically
> > work that way, so I was surprised to even be confronted with this
> > problem.
>
> Could you please provide more detail? My wxPython apps run perfectly
> remotely in the X Window System like this:
>
> $ ssh some-other-machine
> $ DISPLAY=:0 ./my_app.py
>

huh...I am logging into the remote machine with "ssh -X" (actually
with '-Y' in this case because its a mac), then I execute the program
ie. `./test.py' Under Tkinter, this would send the app to display on
the ssh client. Under wxPython it opens it on the ssh server.

Maybe I am missing something obvious, but if I run 'xcalc' from the
same shell, the app opens where I expect it...ssh forwarding seems to
be working.

~Sean

Sean DiZazzo

2/29/2008 1:26:00 AM

0

On Feb 28, 3:50 pm, Bjoern Schliessmann <usenet-
mail-0306.20.chr0n...@spamgourmet.com> wrote:
> Sean DiZazzo wrote:
> > Is there something special you have to do to get a wxPython app to
> > run remotely under xwindows?  My Tkinter apps always automatically
> > work that way, so I was surprised to even be confronted with this
> > problem.
>
> Could you please provide more detail? My wxPython apps run perfectly
> remotely in the X Window System like this:
>
> $ ssh some-other-machine
> $ DISPLAY=:0 ./my_app.py
>

Should wxPython apps work this way? Do you think it's something with
the server?

Sean DiZazzo

2/29/2008 1:49:00 AM

0

On Feb 28, 5:26 pm, Sean DiZazzo <half.ital...@gmail.com> wrote:
> On Feb 28, 3:50 pm, Bjoern Schliessmann <usenet-
>
> mail-0306.20.chr0n...@spamgourmet.com> wrote:
> > Sean DiZazzo wrote:
> > > Is there something special you have to do to get a wxPython app to
> > > run remotely under xwindows?  My Tkinter apps always automatically
> > > work that way, so I was surprised to even be confronted with this
> > > problem.
>
> > Could you please provide more detail? My wxPython apps run perfectly
> > remotely in the X Window System like this:
>
> > $ ssh some-other-machine
> > $ DISPLAY=:0 ./my_app.py
>
> Should wxPython apps work this way?  Do you think it's something with
> the server?

Just to close the loop I think think this is a problem with the ssh
server.

~Sean

Bjoern Schliessmann

2/29/2008 10:24:00 AM

0

Sean DiZazzo wrote:
> On Feb 28, 3:50 pm, Bjoern Schliessmann <usenet-

>> $ ssh some-other-machine
>> $ DISPLAY=:0 ./my_app.py
>
> Should wxPython apps work this way?

I think so; at least it works for me.

> Do you think it's something with the server?

I have no idea.

Regards,


Björn

--
BOFH excuse #325:

Your processor does not develop enough heat.

Mike Driscoll

2/29/2008 4:19:00 PM

0

On Feb 28, 7:49 pm, Sean DiZazzo <half.ital...@gmail.com> wrote:
> On Feb 28, 5:26 pm, Sean DiZazzo <half.ital...@gmail.com> wrote:
>
>
>
> > On Feb 28, 3:50 pm, Bjoern Schliessmann <usenet-
>
> > mail-0306.20.chr0n...@spamgourmet.com> wrote:
> > > Sean DiZazzo wrote:
> > > > Is there something special you have to do to get a wxPython app to
> > > > run remotely under xwindows? My Tkinter apps always automatically
> > > > work that way, so I was surprised to even be confronted with this
> > > > problem.
>
> > > Could you please provide more detail? My wxPython apps run perfectly
> > > remotely in the X Window System like this:
>
> > > $ ssh some-other-machine
> > > $ DISPLAY=:0 ./my_app.py
>
> > Should wxPython apps work this way? Do you think it's something with
> > the server?
>
> Just to close the loop I think think this is a problem with the ssh
> server.
>
> ~Sean

If it's not the server, then please post the issue to the wxPython
list. They can probably help:

http://wxpython.org/ma...

Mike

Sean DiZazzo

3/1/2008 7:17:00 AM

0

On Feb 29, 8:19 am, Mike Driscoll <kyoso...@gmail.com> wrote:
> On Feb 28, 7:49 pm, Sean DiZazzo <half.ital...@gmail.com> wrote:
>
>
>
> > On Feb 28, 5:26 pm, Sean DiZazzo <half.ital...@gmail.com> wrote:
>
> > > On Feb 28, 3:50 pm, Bjoern Schliessmann <usenet-
>
> > > mail-0306.20.chr0n...@spamgourmet.com> wrote:
> > > > Sean DiZazzo wrote:
> > > > > Is there something special you have to do to get a wxPython app to
> > > > > run remotely under xwindows?  My Tkinter apps always automatically
> > > > > work that way, so I was surprised to even be confronted with this
> > > > > problem.
>
> > > > Could you please provide more detail? My wxPython apps run perfectly
> > > > remotely in the X Window System like this:
>
> > > > $ ssh some-other-machine
> > > > $ DISPLAY=:0 ./my_app.py
>
> > > Should wxPython apps work this way?  Do you think it's something with
> > > the server?
>
> > Just to close the loop I think think this is a problem with the ssh
> > server.
>
> > ~Sean
>
> If it's not the server, then please post the issue to the wxPython
> list. They can probably help:
>
> http://wxpython.org/ma...
>
> Mike

To follow up with a solution. I learned that the default install of
wxPython, and Tkinter for that matter is compiled to run under Aqua as
opposed to X11. It won't run remotely, as I first posted, compiled
this way. To get Tkinter to work under X11 you simply need to
configure and install a version of python for the X11 environment.
The default Mac install (Leopard) and the MacPython distro are
configured to run under Aqua. Instead of compiling my own, I found
that the default Fink install is configured to run under X11, so if
you install it, and run that version of Python, you can run Tkinter
apps remotely from a Mac box.

wxPython is a bit more complicated. The idea is the same, but the
process is much more complicated to get it working. You need to
compile wxPython under GTK2, which I found is not well supported for
Mac. I followed the instructions at this site: http://wiki.wxpython.org/wxGTK_...
to get it working. Even with the instructions, I had to finagle a few
things to get it to work properly. But it does work! My first
successful install was on Tiger, but I'm trying an install on Leopard
as we speak.

Thanks to Cody Precord for the instructions. I would have never been
able to do it without. Now my users will have a prettier GUI!

~Sean