king kikapu wrote:
> Hey Martin,
>
> thanks for the fast reply!
>
> I have already seen that link and i just downloaded the pyodbc module
> but isn't Python already containing a "built-in" odbc module so to
> allow for db communication ??
>
Not that I
, it should
be optional, and it should default to "off".
3. Most importantly: it is difficult to implement, and nobody has
contributed code to make it work.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
you still
holding a pointer to it, and a new interpreter may get allocated
at the same address, making you believe it is the same interpreter.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
his, it seems hard to believe...)
Which lib? "minidom.py"? Well, you are likely importing
"xml.dom.minidom", not "minidom". So adding another minidom.py
to a directory in sys.path won't help.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ributions are welcome!
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
is no AC_UNDEFINE.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
TiNo schrieb:
> # G:\Python25\lib\encodings\aliases.pyc matches
[...]
> File "F:\Python25\lib\encodings\__init__.py", line 32, in
>
> What can I do about this?
Where does F:\Python25 come from?
If you have set any PYTHON* environment variables (e.g. PYTHONPATH),
unset
shared across
interpreters, otherwise, the hierarchical exception matching will break.
The builtin exceptions are all "global" (i.e. shared across
interpreters) (I believe).
In any case, it looks like that the "multiple interpreters" feature of
Python is just broken.
Regards,
Uwe Hoffmann wrote:
> [EMAIL PROTECTED] schrieb:
>> Is there a function/module to find the login name of the user under
>> UNIX environment?
>
>
> http://docs.python.org/lib/os-procinfo.html
>
> http://docs.python.org/lib/module-pwd.html
Speaking of that, is there any reason why there isn't any
ter.
Please submit a patch that does so, then. Make sure you add user
interface to make it an option.
These things are *not* easy, and claiming that they are is
misleading.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
uot;.
Please submit a patch to sf.net/projects/python that does so.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
pass a Unicode string into walk as the directory; then
recursively all results should also be Unicode strings.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
try removing that.
If in doubt, remove all .pyc files.
If one of them is bad, it's either because the stick wasn't ejected
properly at some point, or it suffers from data loss.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
named
"bar"). That you can also use it for a type test is a side-effect.
Some more types are available in the types module. In this case,
you can use types. In this case, types.ClassType would do the trick.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
not only want the directory that contains Python added to
the path, but also /scripts. That's again a new requirement, and I
think it is the first time that somebody requests it.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
already have getopt and optparse).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
t all. I don't even use Windows enough to
> complain about it and I thought I'll voice my agreement on it.
Ok. So I can answer your (implied) question: much of the fuss is about
lack of contributions.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
hat precisely
was the line, and how long did you wait until you thought it hangs?
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
hanges, so that optparse users can
review them to find out whether they are affected.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
; d = minidom.Document()
py> r = d.createElement("root")
py> r.appendChild(d.createTextNode(u"\xf6"))
py> d.appendChild(r)
py> d.toxml()
u'\n\xf6'
py> print d.toxml()
ö
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Paul Watson schrieb:
> Martin v. Löwis wrote:
>> Paul Watson schrieb:
>>> ./configure
>>> make
>>> make test
>>>
>>> The result appears to hang after the test_tkl... line. I had to kill
>>> the 'make test' process which t
ml gives to a byte
string.
So I recommend you pass encoding="utf-8" to the toprettyxml invocation
also.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
s a DLL/shared-object with an init
function.
Other solutions include tools that generate extension modules
automatically (such as SWIG or Pyrex), or using libraries on
top of the C API (such as Boost.Python).
I personally always use the C API directly.
Regards,
Martin
--
http://mail.python.org/ma
lf.older + 1
if now < next: time.sleep(next-now)
# really fetch one item; this may block
result = threading.Queue.get(self)
self.older = self.old
# set the last get time to the time when the get completed,
# not when it started
self.old = time.time()
will be ill-formed.
What you should do instead is
...
encoding_of_csv_file = some_value_that_the_producer_of_the_file_told_you
...
...
mainbox.setAttribute("city", b[10].decode(encoding_of_csv_file))
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
.
> I guess I don't know how to proceed from here. I'm reluctant to start
> adding the code necessary to support even the easily solved issues when
> the issues that I don't know how to solve seem like they could be deal
> breakers.
This asks for a PEP. The views above are mine only, others may feel
differently.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
, one would run the program in a debugger to
analyse it further.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
;t need to compare for
equality:
if type(s) is str
- you can do instance tests with isinstance:
if isinstance(s, str):
- try avoiding instance tests altogether. Instead, just let callers
pass anything, and then let the operations fail if they can't handle
the types.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> I have been trying to find a way to add a directory to Python's sytem
> path on my MS Windows XP computer. I did some searching online, but the
> only solution I found involved editing the MS Windows Registry. That
> seemed a little to hard core. Is there another easier w
or tail of this?
Not yet, although it hints to a bug in Numeric.
It now would help if _numpy.so was compiled with debug information enabled.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
l's process explorer.
Make the program halt (not exit) when the exception occurs (e.g. by
having it sleep(1) in a loop), then view all open handles in the
process explorer (check the menu if it doesn't display them initially).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
not something parsing can recover from. I recommend
that you filter this character out before passing it to the XML parser.
You can use the IncrementalParser interface to do so.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ding.
To filter out these bytes, I recommend to use str.translate.
Make an identity table for the substitution, and put the
bytes you want deleted into the delete table.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
hould I be worried about the stability and security of the python fcgi
> interfaces? Is there something better (more mature / battle tested)?
Certainly: CGI. Performance does not seem to be an issue, so CGI should
work just fine.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
stry()
class pin:
def __init__(self, name):
self.name = name
print registry.aap
HTH,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
should correct it.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] schrieb:
> Does anyone know if there's an actual free implementation of this?
For the dom module in it, xml.dom.minidom should work. Depending on
your processing needs, that might be sufficient.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
uest and return
an error to the client".
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
erit from SVGLocatableElement needs to inherit from
SVGElement needs to inherit from Element.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
y (not a python extension!). Under linux, the following
> works, under windows xp id doesn't (which I guess is obvious, but the
> linux success lead me on).
Not sure it's stupid, but I wonder why you want to use ctypes. What's
wrong with extension modules?
Regards,
Martin
--
he chance for a
well-engineered solution, write a compiled wrapper.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
t kind of thing.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
s in source code
- treats __debug__ statically as being 0
- causes the byte code generator to save .pyo files, not .pyc
HTH,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
sion of Python.
HTH,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
rbt wrote:
> Can someone detail the differences between these two? On Windows which
> is preferred?
They do the same thing: unlink calls DeleteFile. The only difference is
how errors are reported.
For portability, os.unlink is preferred.
Regards,
Martin
--
http://mail.python.org/m
orm. So on the plus side,
this allows for sharing of code across multiple instances of the same
application. On the minus side, each Smalltalk application needs its
own image (even if they share a lot of code).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ther reference nor expose any Python symbols.
Given the different linkers on different systems, this is very tricky
to implement.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
David wrote:
> I don't need to do anything except authenticate and gain the correct
> credentials.
I normally run kinit(1) to determine whether a password is correct.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
scvrt has its own heap, and releasing memory to the wrong
heap might cause memory leaks.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
e often.
For plugins, there is a real problem on Unix, with several
strategies to solve it available. Avoiding naming conflicts
in the first place is the only one that really works,
independently of the plugin host.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
27;t really build COM-based extensions with cygwin,
so if the official compiler would be cygwin, somebody would have to
find out how to build PythonWin (in addition, PythonWin also has
a strong dependency on MSVCRT).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
change between the time of definition and the actual
call. Therefore, the simple function call must go through a
table lookup.
So while it would be possible to apply the same strategy to
Python, it likely wouldn't gain any performance increase over
the interpreter.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
fine to call into Python
in most cases, no? If not, have you tried the CXX package, or
Boost::Python?
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
full Unicode), using the "mbcs" encoding should work fine.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
That might also
be tricky to implement, but could work.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
happens, but one would have to verify the code
to be certain.
The other option is to use GetProcAddress to obtain the address of
fdopen.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
bug ncurses to find out
what precisely happens, and why.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Nir Aides wrote:
> I can not restrict the name to CP_ACP.
> I am interested in the general case of Unicode.
So you should implement a patch, and contribute this
to sf.net/projects/python.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
nyway, I just proposed to have Python 2.5 link against msvcrt.dll
on python-dev, and got mixed responses.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Thomas Dickey wrote:
> no need for debugging - it's a well-known problem. UTF-8 uses more than
> one byte per cell, normal curses uses one byte per cell. To handle UTF-8,
> you need ncursesw.
I tried that, but it didn't improve anything.
Regards,
Martin
--
http://mail
f
> (wchar_t), 77
If that was Python's configure: don't do that. Instead, hack setup.py
to make it change the compiler/linker settings, or even edit the
compiler/linker line manually at first.
Regards.
Martin
--
http://mail.python.org/mailman/listinfo/python-list
le names not in their respective CP_ACP (why
do you need such filenames?), and virtually nobody wants to put such
a file name on Python's sys.path (why do you want to? - just rename
the directory and be done).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
John Pote wrote:
> So my request:
> 1. Are there any python modules 'out there' that might help in securely
> writing such files.
> 2. Can anyone suggest a book or two on this kind of file management. (These
> kind of problems must have been solved in the financial world many times).
>
I can't a
Rene Pijlman wrote:
> dirvine:
>> I would like to create a dictionary based on a variable [...]
>
> And what seems to be the problem?
>
I think that this is his problem:
>>> 'somename'={}
SyntaxError: can't assign to literal
But I'm puzzled why he wants that route, while I'm still pretty new t
a patch.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
support
all possible situations (e.g. curses is ncurses, and ncursesw is
available, curses is ncurses, and ncursesw is not available, curses
is not ncurses), and submit that patch to sf.net/projects/python.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
You can save two bytes with
r=range(2,99)
[x for x in r if sum(x%d==0 for d in r)<2]
--
http://mail.python.org/mailman/listinfo/python-list
th "[socket:", it's a socket. Then search
/proc/net/tcp for the ID. The line containing the ID will have
the information you want.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
l system calls involved (or for library routines that
use the system calls the right way). In case of /proc, this is easy;
if it is a ioctl(2), it might still be doable. If it is something
else, you may have to write a Python wrapper for that other system
call first.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ol, and truly single-binary executables, I recommend
to use freeze itself. It takes a bit more work, but also gives better
results.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
I've been working on PEP 353 for some time now.
Please comment, in particular if you are using 64-bit
systems.
Regards,
Martin
PEP: 353
Title: Using ssize_t as the index type
Version: $Revision: 42333 $
Last-Modified: $Date: 2006-02-12 10:36:52 +0100 (So, 12 Feb 2006) $
Author: Martin v.
Windows, I guess the answer is no (or: everybody
doing that has managed to deal with the build process themselves).
I would probably go for a mingw static build if I had to attempt this.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ems I'm aware of, there is a certain committment to keeping the
proc file system stable for applications (on Solaris more so than
on Linux).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Tony Nelson wrote:
> Minor typo: "too"
Thanks, fixed.
Martin
--
http://mail.python.org/mailman/listinfo/python-list
dirvine wrote:
> Yes I did
>
> I was trying to do something like (pseudo code)
>
> write:
> get files in path
> for each filename get size, type
> create dic called filename assign size:xx,type:y
> pickle to file
>
> read:
> open pickled file
> read dict name and contents (hoping unpickling file
need to recode your data.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
pth ORBit.la pygtk.pyo
setuptools.pth
cairoFormEncode-0.4-py2.4.egg ORBit.so pygtk.py.python2.4-gtk2
cairo.pthgtk-2.0 pygtk.pthpython-support.pth
You mean, on *your* Linux? Give me an SSH account to your machine,
and I find out for you.
Regards,
Mar
Paul Rubin wrote:
> "VSmirk" <[EMAIL PROTECTED]> writes:
>> I am needing to synchronize the file on a remote folder, and my current
>> solution, which simply copies the file if a date comparison or a
>> content comparison, becomes a bit unmanageable for very large files.
>> Some of the files I'm wo
Roy Smith wrote:
> Erik Max Francis <[EMAIL PROTECTED]> wrote:
>> (A 2-tuple is an "ordered pair" in mathematics.) If a 2-tuple is a
>> pair, then it would seem to follow that a 1-tuple is a single.
>
> Yeah, but an *ordered* single :-)
>
> A more interesting question is what do you call ()? A
Sergey wrote:
> (but now I must have two pieces of code, one for linux and one for windows)
> Interesting, why developers of python didn't use here all power of win32 API?
It will in Python 2.5.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
David Hirschfield wrote:
> An xmlrpc client/server app I'm writing used to be super-simple, but now
> threading has gotten into the mix.
>
> On the server side, threads are used to process requests from a queue as
> they come in.
> On the client side, threads are used to wait on the results of r
David Hirschfield wrote:
> My question was whether this is allowed? Can two calls be made via the
> same ServerProxy instance while a request is already underway?
>
> Clearer?
> -Dave
>
Much, and my preliminary answer is, I have no clue :-)
But knowing that python will throw an exceptions whe
D wrote:
> Nope, quite the contrary..I'm looking to write a simple program for a
> client of mine that will, among other things, verify that their
> clients' email servers do not have open relays.
>
I usually test it like this:
[EMAIL PROTECTED]:~> telnet mail.huygenslyceum.nl smtp
Trying 172.16.
m-built libpython.a, will that cause problems? My sense is that it
> will not, but I want to make sure I think things through. Any thoughts?
I don't see a problem with that.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
DannyB wrote:
> I'm just learning Python.
So am I :-)
> I've created a simple coin flipper program -
> here is the code:
>
> [source]
> #Coin flipper
> import random
>
> heads = 0
> tails = 0
> counter = 0
>
> coin = random.randrange(2)
>
> while (counter < 100):
> if (coin ==
[EMAIL PROTECTED] wrote:
> I think I've tried all variations possible but I always get errors.
> Anyone know what I'm doing wrong?
You are passing Unicode strings to Parse. Try byte strings instead.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Hi,
I am using Eclipse 3.0.2 with Pydev 0.9.3 under Mandrake 10.1 and it works
OK.
Is 3.1M3 stable?, I see their latest milestone/stable is 3.1M6 - might want
to upgrade.
Regards,
Philippe
querejeto wrote:
> Folks:
>
> I cannot get a refactoring menu to show up on my Eclipse (3.1M3,
> Wi
Try this:
http://pigseye.kennesaw.edu/~dbraun/csis4650/A&D/UML_tutorial/
[EMAIL PROTECTED] wrote:
> Hey yall,
> I'm new to Python and I love it. Now I can get most of the topics
> covered with the Python tutorials I've read but the one thats just
> stumping me is Object Orientation. I can't get
I might be wrong, but my experience is to keep all tkinter calls in the main
thread and use queues to have other threads tell the main one what to do.
Regards,
Philippe
Nir Aides wrote:
> Hello,
>
> In Tkinter, is it safe to call widget.after(time, callback) from another
> thread (other than
I understand you wish to reroute stdout to some object than can write to a
window - correct ?
If so, this is what I do with tkinter
class SC_Log_Stdout:
#***
def __init__(self, p_log_text):
self.__m_log_text
-ID intends to be a true
low cost security solution for Corporations.
SC-Corporate-ID will soon be followed by a School/University ID as well as
an Health Card ID.
You may find information on SC-Corporate-ID at www.snakecard.com.
Best regards,
Philippe Martin
--
http://mail.python.org/mailman
Hi,
Why don't you catch the exception and print the trace ?
Regards,
Philippe
Maurice LING wrote:
> John Machin wrote:
>> On Sat, 07 May 2005 02:29:48 GMT, [EMAIL PROTECTED] (Bengt Richter) wrote:
>>
>>
>>>On Sat, 07 May 2005 11:08:31 +1000, Maurice LING <[EMAIL PROTECTED]>
>>>wrote:
>>>
>
coding will not be set.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Is it stable ? I tried it a few months ago and it crashed on my code I
do not code that badly ;-)
Regards,
Philippe
[EMAIL PROTECTED] wrote:
> pyobfuscate
>
> http://www.lysator.liu.se/~astrand/projects/pyobfuscate/
--
http://mail.python.org/mailman/listinfo/python-list
This is nice! I just might understand regex eventually.
Xah Lee wrote:
> erratum:
>
> the correct URL is:
> http://xahlee.org/perl-python/python_re-write/lib/module-re.html
>
> Xah
> [EMAIL PROTECTED]
> â http://xahlee.org/
--
http://mail.python.org/mailman/listinfo/python-list
I use http://www.amk.ca/python/code/crypto.html
Regards,
Philippe
Blake T. Garretson wrote:
> I want to save some sensitive data (passwords, PIN numbers, etc.) to
> disk in a secure manner in one of my programs. What is the
> easiest/best way to accomplish strong file encryption in Python?
d make it, as is, somewhere
> in the documentation
But how will that happen? Unless somebody contributes a documentation
patch, the documentation will not change magically!
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
PS: remmember that single DES has been brocken. If you're also interested in
signature, this is an interesting article (a big upsate if true)
http://it.slashdot.org/article.pl?sid=05/02/16/0146218&tid=93
Regards,
Philippe
Philippe C. Martin wrote:
> I use http://www.amk.ca
of this, write
import codecs
fil = codecs.open("testfil.txt", "w", "cp1252")
fil.write(titel)
fil.close()
Instead of cp1252, consider using ISO-8859-1.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
John Machin wrote:
> Martin, I can't guess the reason for this last suggestion; why should
> a Windows system use iso-8859-1 instead of cp1252?
Windows users often think that windows-1252 is the same thing as
iso-8859-1, and then exchange data in windows-1252, but declare them
as iso
2401 - 2500 of 4331 matches
Mail list logo