Python plugin

Ivan Van Laningham ivanlan at callware.com
Sat Jan 8 20:36:55 EST 2000


Hi All--

Nemeth Miklos wrote:
> 

[snip]

> Thank you for all suggestions.
> 
> (1) I am completely fed up with Java after two years of permanent
> sucking (I suppose this may be the correct word).

Oh, trust me, it's the perfect word!  I like your phrasing, too, which,
while not usual, adds a distinctive character to a sentiment I share: 
"permanent sucking."  Yes, I like that.

> I am threatened by all languages or tools having the letter "J" anywhere
> in its name.

I finally got the chance to use Python at work for a very small project,
one that should have taken only a day.  A colleague of mine was working
on a web-based application which happens to also communicate with our
voice mail engine using tcp/ip sockets.  We're using the same packets to
log in and count messages, get info about them, and so on.  We wanted to
just build up the packets from scratch, rather than incur the overhead
of using a large, unwieldy and overly complex DLL to communicate with
the engine.  So, we proceeded.

I would have finished my project Friday, except that my friend was using
Java.  He was able to get logged in with the first packet and retrieve a
certain amount of information, but when he actually tried to retrieve
another sort of packet from the engine, it refused to talk to him. 
Eventually (like three hours or so) we discovered that Java was doing
all kinds of icky favors for him behind his back.  He had to build up
his packet using bytes *only*, which happen to be signed bytes.  The
form of casting required meant that to get a 32-bit unsigned integer
(for an opcode for the engine), we finally had to build up the 4 bytes
by assigning each byte separately, with the knowlege that both Java and
the engine use two's complement arithmetic.  For example, to get a
32-bit 0xFFFFFFFF, we had to assign -1 to each individual byte.  Other
opcodes were more complex.

I don't think this is very portable, myself.  Wasn't that a goal of
Java?

After arguing with Java all afternoon, my respect for Jim Huginin's
JPython has increased about a thousand-fold.



> Castanet was also suggested as an alternative - I tried it 1.5 yeras
> ago: never again anything from Marimba.
> 
> (2) No more COM or any Microsoft-only garbage. The only reason I am
> looking for plugin because (apart from simple HTML) this seemed to be
> supported by the browser giants. Everything else (Java applets - a
> nightmare!, COM, DHTML) are browser specific.
> 
> My conclusion after this discussion thread:
> (1) Grail was not mentioned as an alternative. I am a bit sad that this
> project was a failure.

Yah, me too.  But it would take an awful lot of funding to build a real
web browser in Python.  Maybe someday.

> (2) Why on earth do I want to use plugins!? If I want to create a
> sophisticated (ie. non-HTML) client, I do not need any browser, I may do
> it easily with PyGTK (I tried it it seems very fast and simple to use),
> PyQt, etc. communicating via HTTP, XML-RPC, CORBA (all supported by
> Python) with my server. If HTML is acceptable for my application I
> should use Zope with any browser.
> 

I like this distinction, too:  sophisticated != HTML ;-)

Welcome aboard the Python train, Nemeth.  Let's all hope it's not the
hell-bound one;-)

<dare-i-say-it?-oh-sure!-"keep-plugging-away">-ly y'rs,
Ivan
----------------------------------------------
Ivan Van Laningham
Callware Technologies, Inc.
ivanlan at callware.com
ivanlan at home.com
http://www.pauahtun.org
See also: 
http://www.foretec.com/python/workshops/1998-11/proceedings.html
Army Signal Corps:  Cu Chi, Class of '70
Author:  Teach Yourself Python in 24 Hours
----------------------------------------------




More information about the Python-list mailing list