Decorator question (how to test if decorated function is in a class)

2009-06-19 Thread Martin P. Hellwig
Hi all, I have been trying out to wrap my mind around the advantages of decorators and thought I found a use in one of my experiments. (see code after my sig). Although it works, I think it should be able to do it better. My particular problem is that I want to remove an argument (say always

Re: Status of Python threading support (GIL removal)?

2009-06-19 Thread Martin von Loewis
round the issue aside from forking new processes or using something else? If you know that your (C) code is thread safe on its own, you can release the GIL around long-running algorithms, thus using as many CPUs as you have available, in a single process. Regards, Martin -- http://mail.pyt

Re: Status of Python threading support (GIL removal)?

2009-06-19 Thread Martin von Loewis
round the issue aside from forking new processes or using something else? If you know that your (C) code is thread safe on its own, you can release the GIL around long-running algorithms, thus using as many CPUs as you have available, in a single process. Regards, Martin -- http://mail.pyt

Re: Decorator question (how to test if decorated function is in a class)

2009-06-20 Thread Martin P. Hellwig
Bruno Desthuilliers wrote: Short answer: this makes no sense. Absolutely right, took me a while to figure that out though :-) Lesson learned (again): If it really seems impossible to do something in Python, it is likely the proposed solution is flawed. -- MPH http://blog.dcuktec.com 'If con

Re: IMPORTANT: I NEED TO HELP WITH ONE OF THE CORE DEVELOPERS

2009-06-25 Thread Martin P. Hellwig
Chris Rebert wrote: In the future, also NOTE THAT SHOUTING TYPICALLY DOES NOT EARN ONE SYMPATHY. Cheers, Chris Let me demonstrate: Chris, I have no sympathy for you :-) -- MPH http://blog.dcuktec.com 'If consumed, best digested with added seasoning to own preference.' -- http://mail.python.

Re: Barbara Liskov wins Turing Award

2009-06-25 Thread Martin v. Löwis
probably best described as coming from LISP (in the sense of caller and callee sharing references). FWIW, Simula has also inheritance, but that specific notion of inheritance did not transfer to any other language, except for Beta. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Tkinter - non-ASCII characters in text widgets problem

2009-06-25 Thread Martin v. Löwis
s "one big garbage"? > I'm out of ideas: my script is UTF-8 in 101%; Mac and Windows both > support UTF-8, Python also supports it - so where is the problem? Most likely, Tk does not work correctly on your system. See whether you can get correct results with wish. Regards, Ma

Re: print u'\u2013' error on console/terminal

2009-06-25 Thread Martin v. Löwis
> is there a switch to suppress those encoding errors for standard print's > on the console No, there is no such switch. > or a new filter file class necessary? You can wrap sys.stdout with a codecs.StreamWriter, passing "replace" as the error handler.

Re: Tkinter - non-ASCII characters in text widgets problem

2009-06-25 Thread Martin v. Löwis
try installing Tk separately. > (isn't Tk build-in Python?). Depends on where exactly you got your Python from, and what exactly is your OSX version. Recent releases of OSX include a copy of Tcl/Tk, and some sets of Python binaries link against the Apple Tk. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Tkinter - non-ASCII characters in text widgets problem

2009-06-26 Thread Martin v. Löwis
rowser that works. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: What does Guido want in a GUI toolkit for Python?

2009-06-27 Thread Martin v. Löwis
t what is in the toolkit, but what isn't. It must not require lots of lines of code to produce a simple GUI, it must not require specification of absolute coordinates, ... - you should be able to continue the list yourself. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: [RELEASED] Python 3.1 final

2009-06-28 Thread Martin v. Löwis
rogates). See PEP 383. > However, sys.std{in,out,err} are still created as text streams, and AFAICT > there's nothing you can do about this from within your code. That's intentional, and not going to change. You can access the underlying byte streams if you want to, as you could

Re: encoding problem

2009-06-28 Thread Martin v. Löwis
erals. In that sense, the encoding declaration only "matters" for Unicode literals (of course, it also matters for source editors, and in a few other places). Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: [RELEASED] Python 3.1 final

2009-06-28 Thread Martin v. Löwis
> 2. How do you do this for non-invertible encodings (e.g. ISO-2022)? ISO-2022 cannot be used as a system encoding. Please do read the responses I write, and please do identify yourself. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: [RELEASED] Python 3.1 final

2009-06-28 Thread Martin v. Löwis
t was his first release of a large open source software package. Knowing that you have worked so long on a single project, to see the project then finally completed, is exciting - just try it out for yourself. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: urllib with x509 certs

2009-07-04 Thread Martin v. Löwis
s impossible to specify pass phrase while > constructing URLopener. > So what should I do? You can remove the passphrase on the private key, e.g. with the openssl rsa utility. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: urllib with x509 certs

2009-07-04 Thread Martin v. Löwis
> Thanks for the reply. I want my key to be as secure as possible. So I > will remove pass phrase if only there is no other possibility to go > through authentication. And you put the passphrase into the source code instead? How does it make that more secure? Regards, Martin

Re: Code that ought to run fast, but can't due to Python limitations.

2009-07-05 Thread Martin v. Löwis
utines. I don't think this has anything to do with the case statement. Regards, Martin diff -r 30ba63d28b1b python/src/html5lib/filters/validator.py --- a/python/src/html5lib/filters/validator.py Fri Jul 03 17:47:34 2009 +0300 +++ b/python/src/html5lib/filters/validator.py Sun Jul 05 21:10:06

Re: 2.4 VS 3.1 for simple print

2009-07-10 Thread Martin v. Löwis
> Why does > print "GarbageCollector: collected %d objects." % (gc.collect()) > > work in 2.4 but not in 3.1? Because print is a function in 3.1, so you have to follow it with a parenthesis. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Python code for testing well parenthesized expression

2009-07-14 Thread Martin P. Hellwig
candide wrote: To add to your implementations; a readable version: +++file parantheses.py+++ """Parentheses Module Test""" def parentheses_are_paired(input_string): "Check if 'input_string' contains paired parentheses, if so return True." parenthesis_count = 0 parenthesis_open = '(

Re: Python code for testing well parenthesized expression

2009-07-14 Thread Martin P. Hellwig
Martin P. Hellwig wrote: candide wrote: To add to your implementations; a readable version: +++file parantheses.py+++ """Parentheses Module Test""" def parentheses_are_paired(input_string): "Check if 'input_string' contains paired parentheses

Re: why did you choose the programming language(s)you currently use?

2009-07-14 Thread Martin P. Hellwig
Aahz wrote: In article <4a5ccdd6$0$32679$9b4e6...@newsspool2.arcor-online.net>, Stefan Behnel wrote: Deep_Feelings wrote: So you have chosen programming language "x" so shall you tell us why you did so , and what negatives or positives it has ? *duck* Where do you get the duck programming

Re: Managing non-ascii filenames in python

2009-07-19 Thread Martin v. Löwis
ary > for write (I expect so) but then what encoding should I write in? You need to tell us how precisely you tried to do this. My guess is: if you now try again, with the filenames being Unicode strings, it will work fairly well. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Compilation problem with Python < 2.6 and db >= 4.7

2009-07-20 Thread Martin v. Löwis
_bsddb.c to the newer db versions. BSDDB is in the tradition of both breaking the data format and the API frequently, so we (python-dev) have given up on it. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Running a Python Service under the LocalService or NetworkService Account

2009-07-21 Thread Martin P. Hellwig
sightseer wrote: Error Installing Service: Access is Denied. (5) Are you trying to do this on windows vista? -- MPH http://blog.dcuktec.com 'If consumed, best digested with added seasoning to own preference.' -- http://mail.python.org/mailman/listinfo/python-list

Re: Running a Python Service under the LocalService or NetworkService Account

2009-07-21 Thread Martin P. Hellwig
David Adamo Jr. wrote: On Jul 21, 10:40 am, "Martin P. Hellwig" wrote: sightseer wrote: Error Installing Service: Access is Denied. (5) Are you trying to do this on windows vista? -- MPHhttp://blog.dcuktec.com 'If consumed, best digested with added seasoning to own pref

Re: challenging problem for changing to a dedicated non-privileged user within a script.

2009-07-22 Thread Martin P. Hellwig
Krishnakant wrote: I've seen a method before in a MS cmd script (MakeMeAdmin.cmd) for the purpose of temporarily elevating your rights but remaining the same user. There was a need trick in that the script checks itself on what credentials it runs, if it is not the appropriate one it will ca

Re: Ideas for problem with chat server application!

2009-07-23 Thread Martin P. Hellwig
David Adamo Jr. wrote: My attempt was to create a windows service that start automatically and runs this batch file using a Network Service account on the server system. Although, I'm having a hard time with this (temporarily), I would love to ask if there are any alternatives to using a windows

Re: installing 2.6 on vista64

2009-07-24 Thread Martin v. Löwis
;msiexec /i /l*v python.log", and search the log file for 1602. This should give a clue. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: uniicode and executing a process with subprocess.call, or os.system

2009-07-25 Thread Martin v. Löwis
> I am very confused about unicode. Can someone point me in the right > direction? Try Python 3.1. This should accept Unicode strings directly for sp.call, so you wouldn't need to encode first. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: C-API, tp_dictoffset vs tp_members

2009-07-26 Thread Martin v. Löwis
y wants to set the attributes, and never read them. It's easier to maintain: if you want to add a field with tp_members, you have to change multiple places, and you have to consider garbage collection (assuming you have embedded objects). With tp_dictoffset, adding another attribute is easy.

Re: C-API, tp_dictoffset vs tp_members

2009-07-26 Thread Martin v. Löwis
ers list: static PyMemberDef example_members[] = { {"__dict__", T_OBJECT, offsetof(Example, dict), READONLY}, {0} }; Perhaps dir() should know about tp_dictoffset, but alas, it doesn't. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: C-API, tp_dictoffset vs tp_members

2009-07-26 Thread Martin v. Löwis
the >> field in the class. > > So is that intentional or is it dir() that could be improved there? It's probably both. > Should I file a bugreport? Only if you can provide a patch also. My guess is that when you have the patch completed, you might realize that it is not an improve

Re: M2Crypto hangs on this URL

2009-07-27 Thread Martin P. Hellwig
John Nagle wrote: John Nagle wrote: John Nagle wrote: There's something strange about this URL: "https://sagar310.pontins.com/sraep/"; It hangs Firefox 2; there's no short timeout, the web page just gets stuck in initial load for about ten minutes. Then "The connection to sagar310.pontins.co

Re: M2Crypto hangs on this URL

2009-07-28 Thread Martin P. Hellwig
John Nagle wrote: Martin P. Hellwig wrote: John Nagle wrote: John Nagle wrote: John Nagle wrote: There's something strange about this URL: "https://sagar310.pontins.com/sraep/"; ... It looks to me like the SSL handshake is not done properly from the server side. Compar

Re: simple splash screen?

2009-07-29 Thread Martin P. Hellwig
NighterNet wrote: I am trying to make a simple splash screen from python 3.1.Not sure where to start looking for it. Can any one help? Sure, almost the same as with Python 2 :-) But to be a bit more specific: """Only works if you got Python 3 installed with tkinter""" import tkinter IMAGE

Re: 64-bit issues with dictionaries in Python 2.6

2009-07-29 Thread Martin v. Löwis
> Are there any known issues with dictionaries in Python 2.6 (not 2.6.2) > when running on a 64-bit platform? No, none. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: simple splash screen?

2009-07-29 Thread Martin P. Hellwig
NighterNet wrote: Thanks it help. Sorry about that, I was just wander what kind of answer and if there are other methods to learn it. Is there a way to position image to the center screen? Yes there is, just start reading from here: http://effbot.org/tkinterbook/ Though because Python 3 has

Re: Does python have the capability for driver development ?

2009-07-29 Thread Martin P. Hellwig
MalC0de wrote: hello there, I've a question : I want to know does python have any capability for using Ring0 and kernel functions for driver and device development stuff . if there's such a feature it is very good, and if there something for this kind that you know please refer me to some referen

Re: Does python have the capability for driver development ?

2009-07-29 Thread Martin P. Hellwig
Rodrigo S Wanderley wrote: What about user level device drivers? Think the Python VM could communicate with the driver through the user space API. Is there a Python module for that? Sure why not? Look for example to libusb, which provides a userspace environment and pyusb which uses that

Re: Does python have the capability for driver development ?

2009-07-30 Thread Martin P. Hellwig
Marcus Wanner wrote: Look for example to libusb, which provides a userspace environment and pyusb which uses that and provides an interface to Python. iicr pyusb uses a c interface to libusb, not python... According to them they use ctypes indeed. Sorry if I was misleading in my explanati

Re: Does python have the capability for driver development ?

2009-07-30 Thread Martin P. Hellwig
Michel Claveau - MVP wrote: Hi! Python is interpreted No. Python is compiled (--> .pyc) But the term "to compile" is not always unambiguous... And the notion of "compiler" is not attached to Python (the language), but is attached to the implementation. @+ MCI Well the pyc, which I though

Re: Does python have the capability for driver development ?

2009-07-30 Thread Martin P. Hellwig
Dave Angel wrote: Ah yes, we thread on the territory of word definition and difference in interpretation. Any argument is doomed to fail if not agreed or at least taken in perspective of the terminology used by users. I could be (well it is quite likely) wrong in my interpretation of the ter

Re: Does python have the capability for driver development ?

2009-07-30 Thread Martin P. Hellwig
Ben Finney wrote: "Martin P. Hellwig" writes: Machine Code: Whatever the machine executes, it could be that the CPU uses an abstraction of microcode to do this but from the perspective of the user, this is all done in the same 'black box' This requires, of course,

Re: No PyPI search for 3.x compatible packages

2009-07-30 Thread Martin v. Löwis
is written in. For a Python library, it surely would make most sense to specify the Python version it supports - notice, however, that this is *also* the Python version the library is written in. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Python docs disappointing

2009-07-31 Thread Martin P. Hellwig
kj wrote: Well to a level I agree with you. If you are totally new to programming _and_ you won't/can't invest in educational material _and_ have an adversity for looking up resources using a web browser _and_ don't have the patience for trial and error *then* getting proficient with the langua

Parsing Binary Structures; Is there a better way / What is your way?

2009-08-05 Thread Martin P. Hellwig
Hi List, On several occasions I have needed (and build) a parser that reads a binary piece of data with custom structure. For example (bogus one): BE +-+-+-+-+--++ | Version | Command | Instruction | Data Length | Data | Filler | +-+-

Re: Parsing Binary Structures; Is there a better way / What is your way?

2009-08-05 Thread Martin P. Hellwig
Jon Clements wrote: IIRC (and I have my doubts) the BitVector module may be of use, but it's been about 3 years since I had to look at it. I think it used the C equiv. of short ints to do its work. Otherwise, maybe the array module, the struct module or even possibly ctypes. Not much use, but m

Re: Parsing Binary Structures; Is there a better way / What is your way?

2009-08-05 Thread Martin P. Hellwig
Paul Rubin wrote: "Martin P. Hellwig" writes: what I usually do is read the packet in binary mode, convert the output to a concatenated 'binary string'(i.e. '0101011000110') and Something wrong with reading the data words as an integer and using old fashioned

Re: Parsing Binary Structures; Is there a better way / What is your way?

2009-08-05 Thread Martin P. Hellwig
Paul Rubin wrote: "Martin P. Hellwig" writes: Is there an advantage using shifts and masks over my kitchen type solution? Weren't you complaining about the 8-to-1 expansion from turning each bit to an ascii char? Yes you are (of course) right, my 'dream' solution

Re: Google sitemap generator in python gone?

2009-08-05 Thread Martin P. Hellwig
Jon Clements wrote: Now please piddle off... I am guessing west-midlands? :-) -- MPH http://blog.dcuktec.com 'If consumed, best digested with added seasoning to own preference.' -- http://mail.python.org/mailman/listinfo/python-list

Re: String to valid Python identifier

2009-08-06 Thread Martin v. Löwis
mkident(s): return "foo" It returns a valid Python identifier for any random string. If you now complain that this gives too many collisions, I propose def mkident(s): return "foo%d" % (hash(s) & 0x7fff) Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: How to comment on a Python PEP?

2009-08-06 Thread Martin v. Löwis
> Is there a mechanism for submitting comments on a Python PEP? You post to python-dev or comp.lang.python, and you CC the author. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Parsing Binary Structures; Is there a better way / What is your way?

2009-08-06 Thread Martin P. Hellwig
Thanks all for your insights and suggestions. It seems to me that there are a couple of ways to this bit manipulation and a couple of foreign modules to assist you with that. Would it be worth the while to do a PEP on this? Personally I think that it would be nice to have a standard module in

Re: Character encoding & the copyright symbol

2009-08-06 Thread Martin v. Löwis
", "credits" or "license" for more information. py> file Traceback (most recent call last): File "", line 1, in NameError: name 'file' is not defined Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: www.python.org website is down?

2009-08-08 Thread Martin v. Löwis
l haven't given up on the original disks: they are (probably) fine; it's just the RAID controller that has failed (and we can't buy a replacement before Monday). Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: .h files?

2009-08-08 Thread Martin v. Löwis
now don't make this distinction; there is only a single set of header files that you can choose to install. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: coding for multiple versions of python

2009-08-13 Thread Martin v. Löwis
Python packages for multiple versions on a single system. Specifically, put the source code into /net/source/python/foo/*.py. Then, on each system, put symlinks to all .py files into lib/site-packages/foo. Then Python will place the .pyc files next to the symlinks, not next to the actual .py

Re: coding for multiple versions of python

2009-08-14 Thread Martin v. Löwis
he need two sets of .py files? As Dave explains: So that the Python 2.4 installation on HP can write its own .pyc files on disk next to the source files, and Python 2.6 can write its .pyc files next to the sources on Linux. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: coding for multiple versions of python

2009-08-14 Thread Martin v. Löwis
Python on different systems - I also assume that he has an NFS server that both can mount (or that one machine can NFS mount the other). Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: A Exhibition Of Tech Geekers Incompetence: Emacs whitespace-mode

2009-08-15 Thread Martin P. Hellwig
Sounds like a bad case of STRIS http://blog.dcuktec.com/2009/08/stris.html -- http://mail.python.org/mailman/listinfo/python-list

Re: Python 2.6 still not giving memory back to the OS...

2009-08-16 Thread Martin v. Löwis
malloc will not return anything from the brk heap to the system. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: zip codes

2009-08-17 Thread Martin P. Hellwig
Shailen wrote: Is there any Python module that helps with US and foreign zip-code lookups? I'm thinking of something that provides basic mappings of zip to cities, city to zips, etc. Since this kind of information is so often used for basic user-registration, I'm assuming functionality of this so

Mercurial migration: help needed

2009-08-18 Thread Martin v. Löwis
ry: a short-term one, that operates as a hook and has limitations, and a long-term one, that improves the hook system of Mercurial to implement the proper functionality (which then might get shipped with Mercurial in a cross-platform manner). Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Parallelization in Python 2.6

2009-08-19 Thread Martin P. Hellwig
sturlamolden wrote: The human brain is bad at detecting computational bottlenecks though. So it almost always pays off to write everything in Python first, and use the profiler to locate the worst offenders. +1 QOTW -- MPH http://blog.dcuktec.com 'If consumed, best digested with added seasoni

Re: thread and win32com.client problem

2009-08-20 Thread Martin P. Hellwig
Christian Heimes wrote: Ray wrote: I already find the way to fix it. :-) I consider it good style when people describe their solution to a problem, too. Other Python users may run into the same issue someday. :) Christian He probably used: pythoncom.CoInitialize() -- MPH http://blog.dcu

Re: pypi category

2009-08-21 Thread Martin v. Löwis
python.org, along with a list of packages that are already on PyPI that could use that classifier. Having a classifier that classifies zero or one package is pointless. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: 2.6 windows install

2009-08-21 Thread Martin v. Löwis
d. In principle, Python doesn't need any registry settings or environment variables in order to run. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: 2.6 windows install

2009-08-21 Thread Martin v. Löwis
allation won't. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: can python make web applications?

2009-08-24 Thread Martin P. Hellwig
Deep_Feelings wrote: can python make powerfull database web applications that can replace desktop database applications? e.g: entrprise accounting programs,enterprise human resource management programs ...etc As the other replies already mentioned that these already exists, I would like to add t

Re: print() and unicode strings (python 3.1)

2009-08-24 Thread Martin v. Löwis
> I don't understand why I'm getting an encode error in python 3.1. The default encoding is not relevant here at all. Look at sys.stdout.encoding. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Python memory management <-> virtualized server environments

2009-08-24 Thread Martin P. Hellwig
gravityzoo-dmo wrote: Hello everyone, I was wondering if anyone here has had any experience in running Python in a virtualized server environment? The reason I'm asking is the recent thing I noticed when running my server application (written in Python + Twisted); The memory of the server applic

Re: print() and unicode strings (python 3.1)

2009-08-24 Thread Martin v. Löwis
> I can't figure out a way to programatically set the encoding for > sys.stdout. So where does that leave me? You should be setting the terminal encoding administratively, not programmatically. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Python memory management <-> virtualized server environments

2009-08-25 Thread Martin P. Hellwig
gravityzoo-dmo wrote: On 24 aug, 20:35, "Martin P. Hellwig" wrote: gravityzoo-dmo wrote: Hello everyone, I was wondering if anyone here has had any experience in running Python in a virtualized server environment? The reason I'm asking is the recent thing I noticed when ru

Re: Need help with Python scoping rules

2009-08-25 Thread Martin P. Hellwig
kj wrote: Here's a toy example illustrating what I mean. It's a simplification of a real-life coding situation, in which I need to initialize a "private" class variable by using a recursive helper function. eh? class Demo(object): def fact(n): if n < 2: return 1

Re: Need help with Python scoping rules

2009-08-26 Thread Martin P. Hellwig
kj wrote: First, one of the goals of OO is encapsulation, not only at the level of instances, but also at the level of classes. Who says? Anyway, you could be right (I am not capable to judge it) and Python should change on this issue but from what I gathered, Pythons OO is inspired by the fo

Re: break unichr instead of fix ord?

2009-08-26 Thread Martin v. Löwis
line 1, in unichr(65600) ValueError: unichr() arg not in range(0x1) (narrow Python build) This is Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 bit (Intel)] on win32 Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Processor

2009-08-26 Thread Martin P. Hellwig
John Nagle wrote: CPython's performance problems come from excessive dictionary lookups, not from instruction decode. John Nagle Could you please suggest some background information/links to this? I tried to Google for it but unsurprisingly any combination with 'cpython' and

Re: break unichr instead of fix ord?

2009-08-26 Thread Martin v. Löwis
upports? See PEP 261, http://www.python.org/dev/peps/pep-0261/ It specifies all this. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: break unichr instead of fix ord?

2009-08-28 Thread Martin v. Löwis
wer is "because the PEP says so". Only *then* the question is "what is the rationale for the PEP specifying things the way it does". The PEP is relevant so that we can both agree that Python behaves correctly (in the sense of behaving as specified). Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: why python got less developers ?

2009-08-28 Thread Martin P. Hellwig
Esam Qanadeely wrote: who cares if a language is compiled or interpreted as long as it runs and perform the function. second thing is : even if java is faster than python , unless you are making performance critical operations : who cares? computers are getting faster all the time and languages

Re: break unichr instead of fix ord?

2009-08-29 Thread Martin v. Löwis
on-dev/2001-July/016153.html http://mail.python.org/pipermail/python-dev/2001-July/016155.html http://mail.python.org/pipermail/python-dev/2001-July/016186.html Eventually, in r28142, MAL changed it to give it its current state. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Python community buildbot page still 503

2009-09-01 Thread Martin v. Löwis
o a new code base, and nobody upgraded the buildbot configuration file. So I have now removed it from the web server configuration, and put a notice on the web site. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Python community buildbot page still 503

2009-09-01 Thread Martin v. Löwis
g if I'm in charge of it, I'm now lead to believe that > no one contacted Grig. Is this the case? In case it is, I'm cc'ing him > on this email. I sent a message to Grig right after I sent the other one, and he already responded. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: [OT] evolution [was Re: An assessment of the Unicode standard]

2009-09-02 Thread Martin P. Hellwig
Steven D'Aprano wrote: I'd like to add the following: It is an intriguing human trade to attribute emotions and reasons to things that have none. Intriguing because I haven't observed yet that it provides an advantage, but it happens so often that I can't exclude it either. I find that evol

Re: python daemon - compress data and load data into MySQL by pyodbc

2009-09-03 Thread Martin P. Hellwig
MacRules wrote: What I am looking for is this. Oracle DB in data center 1 (LA, west coast) MSSQL DB in data center 2 (DC, east coast) So network bandwidth is an issue, I prefer to have gzip fist and deliver the data. If bandwidth is really an issue, you should send compressed delta's. I n

Re: How to access ODBC databases ?

2009-09-04 Thread Martin P. Hellwig
Timothy Madden wrote: >>> conn = pyodbc.connect('DRIVER={PostgreSQL Unicode};Servername=127.0.0.1;UID=pikantBlue;Database=pikantBlue') Traceback (most recent call last): File "", line 1, in pyodbc.Error: ('0', '[0] [nxDC (202) (SQLDriverConnectW)') Not sure (i.e. wild guess) but that l

Re: Support for Windows 7 ?

2009-09-04 Thread Martin v. Löwis
hould also work on W7 just fine. If there is a specific problem, we would need a specific test case, to be reported to bugs.python.org. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: Support for Windows 7 ?

2009-09-04 Thread Martin v. Löwis
> Given that the problem is with reading the file system, it is likely to > be w/ sth else > > than Windows 7, maybe some weird HD partition combination? Without having seen any details, I refuse to guess. Most likely, it is a user mistake. Regards, Martin -- http://mail.python

Re: How to access ODBC databases ?

2009-09-04 Thread Martin P. Hellwig
Timothy Madden wrote: Martin P. Hellwig wrote: Timothy Madden wrote: >>> conn = pyodbc.connect('DRIVER={PostgreSQL Unicode};Servername=127.0.0.1;UID=pikantBlue;Database=pikantBlue') Traceback (most recent call last): File "", line 1, in pyodbc

Re: Support for Windows 7 ?

2009-09-04 Thread Martin P. Hellwig
Michel Claveau - MVP wrote: Du coup, j'ai envie de déduire : - Que certains étudiants d'écoles de commerce françaises préfèrent travailler avec "l'étranger" plutôt qu'avec "le français". - Il faudra dire à d'autres étudiants d'écoles de commerce françaises que le fait de ne pas arriver/sav

Re: How to access ODBC databases ?

2009-09-06 Thread Martin P. Hellwig
Timothy Madden wrote: Thank you. The precompiled psqlodbca.so driver from apt-get worked on one of the Ubuntu machines that I tried. I would still like o use the Unicode driver if possible. Do you know what the problem could be ? Or where ? pyodbc/unixODBC/psqlodbcw.so ? Thank you, Timot

Re: difficulty in understanding rsplit(None,1)[1]

2009-09-22 Thread Martin P. Hellwig
hrishy wrote: Hi What does rsplit(None,1)[1] accomplish. Can somebody please decompose that to me. regards Sure: >>> test = 'This is a test' >>> help(test.rsplit) Help on built-in function rsplit: rsplit(...) S.rsplit([sep [,maxsplit]]) -> list of strings Return a list of the word

Re: difficulty in understanding rsplit(None,1)[1]

2009-09-22 Thread Martin P. Hellwig
John Machin wrote: On Sep 22, 7:10 pm, hrishy wrote: Hi Martin Many thanks And by the way great way to explain that thing great way to find out for yourself faster than waiting for a response from the internet ;-) I have been called many things in the past but being labeled 'the int

Re: custom data warehouse in python vs. out-of-the-box ETL tool

2009-09-23 Thread Martin P. Hellwig
snfctech wrote: Does anyone have experience building a data warehouse in python? Any thoughts on custom vs using an out-of-the-box product like Talend or Informatica? I have an integrated system Dashboard project that I was going to build using cross-vendor joins on existing DBs, but I keep hea

Re: custom data warehouse in python vs. out-of-the-box ETL tool

2009-09-23 Thread Martin P. Hellwig
snfctech wrote: Thanks for your replies, Sean and Martin. I agree that the ETL tools are complex in themselves, and I may as well spend that learning curve on a lower-level tool-set that has the added value of greater flexibility. Can you suggest a good book or tutorial to help me build a data

Re: custom data warehouse in python vs. out-of-the-box ETL tool

2009-09-23 Thread Martin P. Hellwig
snfctech wrote: @Martin: I originally thought that there was nothing "magical" about building a data warehouse, but then I did a little research and received all sorts of feedback about how data warehouse projects have notorious failure rates, that data warehouse design IS different t

Re: custom data warehouse in python vs. out-of-the-box ETL tool

2009-09-23 Thread Martin P. Hellwig
Tony Schmidt wrote: So do you think it would be very beneficial for me to start with an Inman or Kimball book? Or do you think it would be just leisure reading and not very practical at best - fill my head with needless jargon and inflexible dogmas, at worst? You have an unique opportunity he

Re: Installation problem: Python 2.6.6 (32-Bit) on Windows 7 (32-Bit)

2010-09-04 Thread Martin v. Loewis
sk that it tries to compile and it won't, because of a syntax error. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

Re: what is this kind of string: b'string' ?

2010-09-04 Thread Martin v. Loewis
Am 01.09.2010 23:32, schrieb Stef Mientki: > in winpdb I see strings like this: > >>>> a = b'string' >>>> a > 'string' >>>> type(a) > > > what's the "b" doing in front of the string ? It's redundant. Regards, Martin -- http://mail.python.org/mailman/listinfo/python-list

<    38   39   40   41   42   43   44   >