New submission from Andreas Hasenack:
I was trying to use xmlrpclib.ServerProxy() with https and client
certificate validation (I know httplib doesn't do server certificate
validation yet). I found no way to pass on host/uri as a
(host,x509_dict) tuple as the connection methods support, so I
Changes by Andreas Hasenack:
--
nosy: +ahasenack
_
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1114345
_
___
Python-bugs-list mailing list
Unsubscribe:
http
I once made a small app that used threads on IDLE.
There was a strange error when using 'print' threads. When
what I printed filled the entire screen, instead of moving
all the text up, IDLE just hanged. Try running your code from
the shell instead, to see if the problem is in IDLE.
On Dec 5, 6:00 am, Andreas Tawn [EMAIL PROTECTED] wrote:
I'm trying to integrate the timeout function from
herehttp://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/47
3878into a
long running automation script and the following code
causes IDLE after
20 or 30 iterations in countTest
On Dec 5, 6:00 am, Andreas Tawn [EMAIL PROTECTED] wrote:
I'm trying to integrate the timeout function from
herehttp://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/47
3878into a
long running automation script and the following code
causes IDLE after
20 or 30 iterations
I'm trying to integrate the timeout function from here
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/473878 into a
long running automation script and the following code causes IDLE after
20 or 30 iterations in countTest.
This is in 2.5, XP and there's no traceback.
Could someone point
Andreas Eisele added the comment:
How do you run the test? Do you specify a maximum available size?
I naively assumed that running make test from the toplevel would be
clever about finding plausible parameters. However, it runs the bigmem
tests in a minimalistic way, skipping essentially all
Andreas Eisele added the comment:
Tried
@bigmemtest(minsize=_2G*2+2, memuse=3)
but no change; the test is done only once with a small
size (5147). Apparently something does not work as
expected here. I'm trying this with 2.6 (Revision 59231).
__
Tracker
Andreas Eisele added the comment:
Thanks a lot for the patch, which indeed seems to solve the issue.
Alas, the extended test code still does not catch the problem, at
least in my installation. Someone with a better understanding of
how these tests work and with access to a 64bit machine should
Andreas Eisele added the comment:
Then 7G is enough for the test to run.
yes, indeed, thanks for pointing this out.
It runs and detects an ERROR, and after applying your patch it succeeds.
What else needs to be done to make sure your patch finds it's way to the
Python core
New submission from Andreas Eisele:
s.decode(utf-8)
sometimes silently truncates the result if s has more than 2E9 Bytes,
sometimes raises a fairly incomprehensible exception:
Traceback (most recent call last):
File stdin, line 2, in module
File /usr/lib64/python2.5/encodings/utf_8.py
Andreas Eisele added the comment:
For instance:
Python 2.5.1 (r251:54863, Aug 30 2007, 16:15:51)
[GCC 4.1.0 (SUSE Linux)] on linux2
Type help, copyright, credits or license for more information.
__[1] s= *int(5E9)
6.05 sec
__[1] u=s.decode(utf-8)
4.71 sec
__[1] len(u)
705032704
Andreas Eisele added the comment:
An instance of the other problem:
Python 2.5.1 (r251:54863, Aug 30 2007, 16:15:51)
[GCC 4.1.0 (SUSE Linux)] on linux2
Type help, copyright, credits or license for more information.
__[1] s= *int(25E8)
2.99 sec
__[1] u=s.decode(utf-8)
Traceback (most
Tim Golden wrote:
[EMAIL PROTECTED] wrote:
is it possible to parse a pdf file in python? for starters, i would
like to count the number of pages in a pdf file. i see there is a
project called ReportLab, but it seems to be a pdf generator... i
can't tell if i would be able to parse a pdf
New submission from Andreas Kloeckner:
This here basically says it all:
import cmath;[cmath.asinh(i*1e-17).real for i in range(0,20)]
[4.4408920985006257e-16, 4.4408920985006257e-16, 4.4408920985006257e-16,
4.4408920985006257e-16, 4.4408920985006257e-16, 4.4408920985006257e-16
Andreas Kloeckner added the comment:
On Samstag 03 November 2007, Martin v. Löwis wrote:
Martin v. Löwis added the comment:
Can you propose a patch?
Other than point at how boost.math does things, I don't have the time to work
on this right now, sorry.
Andreas
On Oct 19, 1:49 pm, Duncan Booth [EMAIL PROTECTED] wrote:
Andreas Kraemer [EMAIL PROTECTED] wrote:
The only other behaviours I would regard as intuitive for iteration over
a mutating sequence would be to throw an exception either for mutating
the sequence while the iterator exists
may also have added to the confusion since its
similarity to sorted suggests that a copy of the list is returned.
However,
type(reversed([]))
type 'listreverseiterator'
and for comparison
type(iter([]))
type 'listiterator'
reveals what it really is.
-Andreas
--
http://mail.python.org
On Oct 18, 4:39 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Hi,
Does any one know whare I can find some code to phrase a rss feeds?
Thank you,
Ted
Try http://feedparser.org/
--
http://mail.python.org/mailman/listinfo/python-list
StopIteration
else:
return self.seq[self.i]
so it doesn't copy anything, just book-keeping of indexes. I guess one
would call this kind of object a (special) view of the sequence.
Cheers,
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
):
if i == len(myList)-1:
print j*j
else:
print j
Cheers,
Andreas Tawn
Lead Technical Artist
Ubisoft Reflections
--
http://mail.python.org/mailman/listinfo/python-list
[...]In fact, now that I think of it, get_key
is probably a bad name for it, get_other_object_with_this_same_key is
probably more apt :)
Or more precise:
get_key_that_was_used_when_value_was_inserted_into_dictionary :-)
Or even more precisely:
of strings foo bar and some text from
the commandline foo bar some text)?
If not, do you have any other ideas how to handle this problem (increasing
commandline length, xml files might be a way)?
Regards,
Andreas Huesgen
Viel oder wenig? Schnell oder langsam? Unbegrenzt surfen + telefonieren
ohne
', 'some text']
Thanks, that is exactly what i need.
Andreas Huesgen
--
http://mail.python.org/mailman/listinfo/python-list
On Oct 11, 10:17 am, Erik Jones [EMAIL PROTECTED] wrote:
No, duck typing and inheritance are two different things. Duck
typing is when you implement the same operations as another object or
class, whereas with inheritance you get the same implementation as
that of the parent class.
Except
On Oct 11, 1:42 pm, Erik Jones [EMAIL PROTECTED] wrote:
On Oct 11, 2007, at 2:25 PM, Andreas Kraemer wrote:
On Oct 11, 10:17 am, Erik Jones [EMAIL PROTECTED] wrote:
No, duck typing and inheritance are two different things. Duck
typing is when you implement the same operations as another
:
get_key_that_was_used_when_value_was_inserted_into_dictionary :-)
Thanks, for taking the time for this elaborate response!
Cheers,
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
On Oct 9, 9:18 pm, Erik Jones [EMAIL PROTECTED] wrote:
So, do you not keep references to your nodes anywhere but the actual
graph dict? I kind of agree with Chris here in that two dicts will
work. One for the nodes, indexed by their strings.
Yes, I guess that's exactly what I want. To keep
track of their
instances ...
Cheers,
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
syntax like class A(*bases): pass
Is there a better approach? Any comments are appreciated.
I have been seriously using Python for one year know, mostly in the context of
graph algorithms etc., and it has always been a delightful coding experience!
Best regards,
Andreas
--
http
,
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
. get all keys with keys()), but I thought
something similar to a get_key() dictionary method would be the easiest way to
retrieve the actually stored key object, and I was just surprised to discover
that no such method does exist
-Andreas
--
http://mail.python.org/mailman/listinfo
have an exact representation as floating
point.
Interestingly:
0.10001 == 0.1
True
0.30004 == 0.3
False
I guess this means that Python has some concept of close enough, but
I'll have to defer to someone more knowledgeable to explain that.
Cheers,
Andreas Tawn
Lead
and a head-smack, I realise that you're absolutely
right and I just made the same mistake as the OP (doh).
It does demonstrate just how sneaky floating point representations are
though.
Cheers,
Andreas Tawn
Lead Technical Artist
Ubisoft Reflections
--
http://mail.python.org/mailman/listinfo/python
i just want to generate numbers in the form like:
1,2,4,8,16,32.to a maximum of 1024
using a range function
a = [2**x for x in range(11)]
a
[1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024]
Cheers,
Andreas Tawn
Lead Technical Artist
Ubisoft Reflections
--
http://mail.python.org/mailman
--On 28. September 2007 16:36:43 +0100 kamal hamzat
[EMAIL PROTECTED] wrote:
Dear All,
I have this error after i added the if statement
Error Type: TypeError
Error Value: mybrains.__cmp__(x,y) requires y to be a 'mybrains', not a
'int'
for i in context.zCatNewsCurrent():
if i = 5:
Is there something like a osgi implementation in python? I am really
impressed by the bundle system and the possibility to load and unload
bundles without wasting memory. Is it even possible to do something
like that in python? Would be nice to have a very small python
interpreter and just load
)
Maybe http://www.pythonchallenge.com/ ?
Cheers,
Drea
Andreas Tawn
Lead Technical Artist
Ubisoft Reflections
--
http://mail.python.org/mailman/listinfo/python-list
Aloha,
Andreas Lobinger wrote:
Lawrence D'Oliveiro wrote:
In message [EMAIL PROTECTED], Andreas Lobinger wrote:
Anyone any idea where the error is produced?
... to share my findings with you:
def ex(self,context,baseid,n1,n2):
print x,context,n1,n2
return 1
Aloha,
Andreas Lobinger wrote:
Andreas Lobinger wrote:
Lawrence D'Oliveiro wrote:
In message [EMAIL PROTECTED], Andreas Lobinger wrote:
Anyone any idea where the error is produced?
The registered Handler has to return a (integer) value.
Would have been nice if this had been mentioned
New submission from Andreas Kloeckner:
The attached program uncovers a two-fold performance regression in
Python 2.5 with respect to Python 2.4. Below, the element-wise case
goes from 2.5 seconds in 2.4 to about 4 in 2.5. Since that's a pretty
serious increase, I thought I'd point it out
Aloha,
Lawrence D'Oliveiro wrote:
In message [EMAIL PROTECTED], Andreas Lobinger wrote:
Anyone any idea where the error is produced?
Do you want to try adding an EndElementHandler as well, just to get more
information on where the error might be happening?
I want.
Adding an EndElement (left
Aloha,
i'm trying to write an xml filter, that extracts some info about
an .xml document (with external entities), esp. start elements and
external entities. The document is a DOCBOOK xml and afacs
well formed and passes our docbook toolchain (dblatex etc.).
My parser is (very simple):
[115]
Twisted files, because F1 didn't work and there was no help menu, if
such a
Twisted thing ever happened on Windoze).
Ever heard of man pages? and info?
'Andreas
--
Wherever I lay my .emacs, there's my $HOME.
--
http://mail.python.org/mailman/listinfo/python-list
-manipulation
Twisted tool or whatever...you have to save it to a file and load it,
which is
Twisted a pain in the butt and slowly clutters your hard drive with
Twisted temporary files you occasionally forget to delete.
You obviously have no clue about working under Unix either.
'Andreas
and dynamic
Twisted class loading!)
Have a look at Genera, the OS of the Lisp Machines. It offers all
that and much more. Unfortunately it is almost non existent
nowadays.
'Andreas
--
Wherever I lay my .emacs, there's my $HOME.
--
http://mail.python.org/mailman/listinfo/python-list
style? Or would you recommend to
refrain from such complex single-line code??
Thanks!
Andreas
inp = resource(some_file)
# read first entries of all non-empty lines into a set
some_set = frozenset([line.split()[0] for line in \
filter(None, [ln.strip() for ln in inp])])
--
http
://libmsgque.sourceforge.net/tclmsgque.htm
Regards,
Andreas Otto (aotto1968)
--
http://mail.python.org/mailman/listinfo/python-list
in a day).
More than rumor apparently:
http://www.cmu.edu/cmnews/extra/060310_alice.html
Cheers,
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
Hey,
Can someone plz make a function for that takes a array, and then search
in it for duplicates, if it finds 2 or more items thats the same string
then delete all except 1.
Short: it deletes all duplicates in a array
thanks
--
_.____
of the symbols in my module?
Have you already checked the output of LD_DEBUG=all or sth. like that?
cheers,
aa
--
Andreas Ames | Programmer | Comergo GmbH |
Voice: +49 711 13586 7789 | ames AT avaya DOT com
--
http://mail.python.org/mailman/listinfo/python-list
claimes to provide this feature on Windows, but I
haven't tried and it limits your choice of tools (http://edll.sf.net/).
cheers,
aa
--
Andreas Ames | Programmer | Comergo GmbH |
Voice: +49 711 13586 7789 | ames AT avaya DOT com
--
http://mail.python.org/mailman/listinfo/python-list
Is there anything wrong with such design? I am a bit surprised that
Python does not already come with such data type (which is really simple
to implement). Is there something that I am missing here?
Thanks!
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
Hey,
I'm a noob at python so..
I just want to know, is there a function to type text global not in the
program but in other programs(like you where typing it).
For example in a textbox, in a program like cmd.exe or notebook.exe.
I'm using windows xp.
Thanks! :)
/Scripter47
--
Duncan Booth skrev:
Felipe Almeida Lessa [EMAIL PROTECTED] wrote:
On 26 Dec 2006 04:22:38 -0800, placid [EMAIL PROTECTED] wrote:
So do you want to remove or replace them with amp; ? If you
want to replace it try the following;
I think he wants to replace them, but just
? StarKIT?
Best regards
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
the project home page:
http://pyfltk.sourceforge.net
Have fun!
Andreas
http://pyfltk.sourceforge.net
--
http://mail.python.org/mailman/listinfo/python-announce-list
Support the Python Software Foundation:
http://www.python.org/psf/donations.html
inherits (directly or
not) from 'object'. Although new style classes are allowed as
exceptions in 2.5, an additional requirement is, that the exception
must inherit from BaseException (or must not be a new style class
instance at all, as before).
cheers,
aa
--
Andreas Ames | Programmer
Leif K-Brooks [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Frithiof Andreas Jensen wrote:
mumebuhi [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
The simplejson module is really cool and simple to use. This is great!
JUST what I need for some configuration files
mumebuhi [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
The simplejson module is really cool and simple to use. This is great!
JUST what I need for some configuration files!!
Thanks for the link (die, configparse, dieee).
--
http://mail.python.org/mailman/listinfo/python-list
have a
really, really weird problem that also heavily depends on the type of
parameters. Simply stick to the first one, this will be sufficient for
90% of all cases.
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
Hello everybody,
is there a way to receive the name of an object passed to a function
from within the function.
something like
def foo(param):
print theNameOfTheVariablePassedToParam
var1 = hello
var2 = world
foo(var1)
var1
foo(var2)
var2
thanks in advance,
greets
Andreas
Ingo Linkweiler [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Bjoern Schliessmann schrieb:
Ingo Linkweiler wrote:
b) verify an existing mailserver or DNS/MX records
Or? That's two different things.
If you don't know already: Even if you test all this, it is still
something like:
os.popen(wget -r3 http://juicypornpics.com;)
wget understands the peculiarities of web pages so you do have to.
--
http://mail.python.org/mailman/listinfo/python-list
as a try/except. The
finally clause is always executed, whether or not an exception is raised.
Yes, of course it must be the try finally construct and not try/except.
Shame on me ;)
Andreas Huesgen
--
http://mail.python.org/mailman/listinfo/python-list
block around
every peace of code that locks some resources.
Greets,
Andreas Huesgen
--
http://mail.python.org/mailman/listinfo/python-list
++ is so easy. That means
that in spite of its warts (GIL, memory efficiency ...) I don't easily come to
a dead end using python. This fact lets me use python's great strengths (like
programmer efficiency etc.) without tossing and turning sleeplessly in my bed.
cheers,
aa
--
Andreas Ames
Perseo [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hi guys,
we are looking for a python developer for a European project. This
project is multilangual and free it is called EuroCv and it need a
module for exporting data in PDF.
A brute-force approach could be to sidestep PDF
, IMHO. I think the above
code has it right in this case rather than your python version (after all c isA
CountedClass, isn't it?).
cheers,
aa
--
Andreas Ames | Programmer | Comergo GmbH |
Voice: +49 69 7505 3213 | ames AT avaya DOT com
--
http://mail.python.org/mailman/listinfo/python-list
Darren New wrote:
Andreas Rossberg wrote:
Yes, technically you are right. But this makes a pretty weak notion of
mutability. All stateful data structures had to stay within their
lexical scope, and could never be passed to a function.
Not really. The way Hermes handles
by far the worst
incarnation of aliasing issues to the table.
- Andreas
--
Andreas Rossberg, [EMAIL PROTECTED]
--
http://mail.python.org/mailman/listinfo/python-list
holding other mutable objects
(immutable pointer types exist, but are only interesting if you also
have pointer arithmetics - which, however, is largely equivalent to
arrays, i.e. not particularly relevant either).
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
an *aspect* of mutability
in lower-level languages.
Again, I disagree: it is posible to have mutability without
pointers/identity/objects.
OK, if you prefer: it is an aspect of first-class mutability - which is
present in almost all imperative languages I know. :-)
- Andreas
--
Andreas Rossberg
transformation bugs, notwithstanding the relative complexity of
suitable internal type systems.
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Error message cannot find wx
infact I have wxpython in /usr/lib/
I installed it using the rpms given on the wxPython website. Do I
need
to set some path or something.
I vaguely remember that wxWindows changed name to wxWidgets and
file in the
program dir. See examples in the py2exe installation dir.
Andreas
--
http://mail.python.org/mailman/listinfo/python-list
was removed as default because of frequent
user complaints.
Which is why this actually is a very bad example to chose for dynamic
typing advocacy... ;-)
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
of the function before actually running it. Eval itself can easily be
expressed on top of this as a polymorphic function, which does not run
the program if it does not have the desired type:
eval ['a] s = typecase compile s of
f : (()-'a) - f ()
_ - raise TypeError
- Andreas
--
http
.
Anyway, I can't believe that we actually need to argue about the fact
that - for any *useful* and *practical* notion of safety - C is *not* a
safe language. I refrain from continuing the discussion along this line,
because *that* is *really* silly.
- Andreas
--
http://mail.python.org/mailman
, but it clearly also varies.
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
by the types-are-sets metaphor - to
capture something like type abstraction you need to do more. (Even then
it might be arguable if it really describes the same thing.)
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
.
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
Marshall wrote:
Andreas Rossberg wrote:
Chris Uppal wrote:
I have never been very happy with relating type to sets of values (objects,
whatever).
Indeed, this view is much too narrow. In particular, it cannot explain
abstract types, which is *the* central aspect of decent type systems.
What
.
Mh, I'd say typecase is actually a form of reflection, which is yet a
different issue. Moreover, there are statically typed languages with
typecase (e.g. Modula-3, and several more modern ones) or related
constructs (consider instanceof).
- Andreas
--
http://mail.python.org/mailman/listinfo
will always hold numbers.
I'm confused. Are you telling that you just write a+b in your programs
without trying to ensure that a and b are in fact numbers??
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
with a mutable reference-to-union type,
as I suggested? It expresses this perfectly well.
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
comparison function to pass
for individual calls, so that the programmer does not have to bother.)
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
abstract types in a types-as-sets metaphor.
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
typed languages wish to lump these languages together with assembly
language a untyped in an attempt to label them as unsafe.
No, see above. And I would assume that that is how most proponents of
the typed/untyped dichotomy understand it.
- Andreas
--
http://mail.python.org/mailman/listinfo
Don Taylor [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
I find it easy to use sizers in
wxGlade.
Just gave is a spin yesterday: How does on fix the size of layout; I
can only manage to get sizers to distribute space evently amongst the
fields, which is *not* what I want.
--
this is totally different from simple tagging, because it deals
with real types at runtime.
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
to derive) their types too, but that's a separate issue. Most
values are anonymous. Nevertheless their types are known.
Unfortunately it's often necessary to break static type systems.
Your definitely using the wrong static language then. ;-)
- Andreas
--
http://mail.python.org/mailman/listinfo
for that purpose).
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
it isn't *able* to *vary.*
Let's call it a named constant.
The name of a function argument is a variable. Its denotation changes
between calls. Still it cannot be mutated. Likewise, local constants
depending on an argument are not constant.
- Andreas
--
http://mail.python.org/mailman/listinfo
(or another abuse of the
term type).
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
)
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
. And there certainly are more in the OO camp.
But honestly, I do not remember when I last had to actively work with
one of them, including Java... :-)
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
... Pascal does, IIRC.) I guess you just work
with better languages than I do. :-)
OK, I admit that I exaggerated slightly. Although currently I'm indeed
able to mostly work with the more pleasant among languages. :-)
(Btw, Pascal did not have it either, AFAIK)
- Andreas
--
http://mail.python.org
ingredient of a type system,
nor is eliminating tags very relevant to its function.
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
mainstream languages enforce for, but also only allow for, variable
declarations).
- Andreas
--
http://mail.python.org/mailman/listinfo/python-list
801 - 900 of 1064 matches
Mail list logo