Hi Dear Python programmers,
I want to ask you a question about python scripting.I want to know if I can design web-pages with python or at least write html files with python. and if I write html files with python and some CGI scripts and upload them to the web-page .. does the people who view t
Problems with XMLRPC
I have an xmlrpc server with a method called results() which returns an
XML
message.
I've been able to use this function without problems when I had only
one client talking to one server. I have recently introduced a P2P
aspect to this process and now I have servers calling e
"Fredrik Lundh" <[EMAIL PROTECTED]> writes:
> > You're not making any bloody sense.
>
> oh, I make perfect sense, and I think most people here understand
> why I found your little "lecture" so funny. if you still don't get
> it, maybe some- one can explain it to you.
I would appreciate it if som
Stephen Waterbury wrote:
it's interesting to note that the intent
Steve Holden imputed to it earlier is not explicitly among them:
Steve Holden wrote:
It seems to me the misunderstanding here is that XML was ever intended
to be generated directly by typing in a text editor. It was rather
intended
Paul Rubin said unto the world upon 2005-01-22 20:16:
"Fredrik Lundh" <[EMAIL PROTECTED]> writes:
You're not making any bloody sense.
oh, I make perfect sense, and I think most people here understand
why I found your little "lecture" so funny. if you still don't get
it, maybe some- one can explain
> As for using JPype ... well it depends on what you want to script. if
> you Java code is the main app, I'd eschew CPython completely and use
> Jython to script. If you main app is in Python, and the Java code is
> "simply" libraries you wish to use, then I'f go with CPython + Jpype.
It
> is very
Brian van den Broek <[EMAIL PROTECTED]> writes:
> no Python expert, just a hobbyist. But, I think I can take this one on:
>
> Fredrik's contributed a lot to Python. The Standard Library book,
> several well know tools, and, I'd wager a finger, a fair bit of code
> in the standard lib. I don't thin
Peter Hansen wrote:
If merely thinking about the purpose of XML doesn't make it
clear where Steve got that idea ...
I meant no disparagement of Steve, and it is quite clear
where he got that (correct!) idea ...
It's also clear that the XML user community sees
that as part of *their* purpose in appl
Yun Mao wrote:
>a[ [1,0], [0,1] ] , which should give me
>[[4, 5], [1,2]]
Numeric:
take(take(a,[1,0]),[0,1],1)
fwiw,
Alan Isaac
--
http://mail.python.org/mailman/listinfo/python-list
Sorry - should have given more detail. That's what I get for posting at
1:00AM.
What I want to do us write scripts in CPython that access Windows
ActiveX such as Word and IE. Obviously Jython can't do this (easily at
least). I also have Jython scripts that provide a high level layer on
top of
Bengt Richter wrote:
I thought XML was a good idea, but IMO requiring quotes around
even integer attribute values was an unfortunate decision.
I think it helps guard against incompetent authors who wouldn't
understand when they're required to use quotes and when they're not. I
see HTML pages all
Stephen Waterbury <[EMAIL PROTECTED]> writes:
> I should note that I have to deal with XML a lot, but always
> kicking and screaming (though much less now because of Fredrik's
> Elementtree package ;). Thanks, Fredrik and Peter, for the
> references. ;)
I love this old rant about XML:
http://gr
Doug Holton wrote:
Fredrik Lundh wrote:
and trust me, when things are hard to get right for developers, users
will
suffer too.
That is exactly why YAML can be improved. But XML proves that getting
it "right" for developers has little to do with getting it right for
users (or for saving bandwid
On Sat, 22 Jan 2005 16:22:33 +1000, Nick Coghlan <[EMAIL PROTECTED]> wrote:
>Steven Bethard wrote:
>> I wrote:
>> > If you really want locals that don't contribute to arguments, I'd be
>> > much happier with something like a decorator, e.g.[1]:
>> >
>> > @with_consts(i=1, deftime=time.ctime())
[Tim Peters]
>> But at that time, Python didn't have lexical scoping, and it wasn't
>> clear that it ever would. So what's the bigger wart? Making
>> listcomps exactly equivalent to an easily-explained Python for-loop
>> nest, or introducing a notion of lexical scope unique to listcomps,
>> hard
Bob Smith <[EMAIL PROTECTED]> wrote:
>Are these the same:
>
>1. f_size = os.path.getsize(file_name)
>
>2. fp1 = file(file_name, 'r')
>data = fp1.readlines()
>last_byte = fp1.tell()
>
>I always get the same value when doing 1. or 2. Is there a reason I
>should do both? When reading to the
kishore wrote:
Hi Luigi Ballabio,
Thankyou very much for your reply,
it worked well.
It does work in most cases, but "getattr(self, methodName)" is generally to be
preferred over "vars(self.__class__)[methodName]", as the latter does not use
Python's standard attribute lookup scheme.
The semanti
aurora wrote:
I am think more in the line of string.ljust(). So if we have a
list.ljust(length, filler), we can do something like
name, value = s.split('=',1).ljust(2,'')
Eh?
Py> s.split('=',1).ljust(2,'')
Traceback (most recent call last):
File "", line 1, in ?
AttributeError: 'list' object
Reinhold Birkenfeld wrote:
Why not put these together and put it in itertools, since the requirement seems
to crop up every other week?
>>> line = "A:B:C".split(":")
...
>>> def ipad(N,iterable, default = None):
... return it.islice(it.chain(iterable, it.repeat(default)), N)
...
>>> a,b
While we are on topic, I am having some trouble understanding JPype
classpath. How do I init the JVM with the folder in which the Python
program is located included in the classpath?
I tried
t = JPackage('.').test
That did not work.
My environment variable includes current folder in the classpath
I
Jim Hargrave wrote:
Sorry - should have given more detail. That's what I get for posting at
1:00AM.
What I want to do us write scripts in CPython that access Windows
ActiveX such as Word and IE. Obviously Jython can't do this (easily at
least). I also have Jython scripts that provide a high le
> I am curious to know what makes your Jython code incompatible with
> CPython. If it is only because it uses Java classes, it might
> not be too
> difficult to port them to CPython+Jpype.
CPython+Jpype may indeed be the way to go in the long run - it's only my
ignorance stoping me at this point :
Ali Polatel wrote:
> I want to ask you a question about python scripting.
> I want to know if I can design web-pages with python
Yes.
> or at least write html files with python.
Yes.
> and if I write html files with python and some CGI scripts
> and upload them to the web-page .. does the peopl
Bengt Richter wrote:
(OTOH, deletions of actual local bindings do seem to propagate back into a
previously
bound value of locals on exit, and a new call to locals() seems to return the
same identical
object as before, so I'm not sure I believe the , unless it has a
special slot
and it is automat
Nick Coghlan wrote:
>> I am think more in the line of string.ljust(). So if we have a
>> list.ljust(length, filler), we
>> can do something like
>>
>> name, value = s.split('=',1).ljust(2,'')
>
> Eh?
>
> Py> s.split('=',1).ljust(2,'')
> Traceback (most recent call last):
> File "", line 1,
André wrote:
I have tried this exact example (using Python 2.3 if it makes any
difference) and what I got was:
robot None moved
robot None moved
I checked what I wrote, used cut & paste on your code, removing the
leading "junk", tried it again ... to no avail. :-(
Worked exactly as written for me,
André wrote:
So, students will be able to write:
pete = CreateRobot(2, 3)
pete.move()
learning about objects and methods.
As for things like
for robot in robots:
do stuff
that will be for my use only: drawing robots on the screen, updating
the 'world' when robots pick stuff up, etc. My intention i
Nick Coghlan wrote:
> Reinhold Birkenfeld wrote:
>>>Why not put these together and put it in itertools, since the requirement
>>>seems
>>>to crop up every other week?
>>>
>>> >>> line = "A:B:C".split(":")
>>> ...
>>> >>> def ipad(N,iterable, default = None):
>>> ... return it.islice(it.ch
Peter Hansen wrote:
Good question. The point is that an XML document is sometimes
a file, sometimes a record in a relational database, sometimes an
object delivered by an Object Request Broker, and sometimes a
stream of bytes arriving at a network socket.
These can all be described a
Steve Holden wrote:
Yet again I will interject that XML was only ever intended to be wriiten
by programs. Hence its moronic stupidity and excellent uniformity.
Neither was HTML, neither were URLs, neither were many things used the
way they were intended. YAML, however, is specifically designed t
Daniel Bickett wrote:
In my (brief) experience with YAML, it seemed like there were several
different ways of doing things, and I saw this as one of it's failures
(since we're all comparing it to XML). However I maintain, in spite of
all of that, that it can easily boil down to the fact that, for
s
You might like programming in XML then: http://www.meta-language.net/
Actually, the samples are hard to find, they are here:
http://www.meta-language.net/sample.html
Programming in XML makes Perl and PHP look like the cleanest languages
ever invented.
--
http://mail.python.org/mailman/listinfo/pyt
101 - 132 of 132 matches
Mail list logo