On 2011-05-22 23:23, Terry Reedy wrote:
On 5/22/2011 2:34 PM, Patrick Sabin wrote:
I wanted to register my project (epdb) in pypi. Unfortunately there
already exists a project with the same name. It is not possible for me
to change the name of the project, because I used it in multiple
writings
I wanted to register my project (epdb) in pypi. Unfortunately there
already exists a project with the same name. It is not possible for me
to change the name of the project, because I used it in multiple
writings. Any ideas how I can deal with the situation? Is it possible to
register a project
Shelve looks like an interesting option, but what might pose an issue
is that I'm reading the data from a disk instead of memory. I didn't
mention this in my original post, but I was hoping that by using a
database it would be more memory efficient in storing data in RAM so I
wouldn't have to r
Have a look at the ctypes module
http://python.net/crew/theller/ctypes/tutorial.html
e.g.:
from ctypes import *
cdll.LoadLibrary("libc.so.6")
libc = CDLL("libc.so.6")
print libc.rand()
print libc.atoi("34")
- Patrick
Patxi Bocos wrote:
Hi!,
I am developing a Python application and I need t
I don't see how this script is able to divide by zero. If a and b
switch places everything works ok.
Have a look at your if-statements. It is possible, that both your if's
are executed in one loop iteration (you can check this using pdb). You
may want to try elif instead.
- Patrick
--
http:/
Peng Yu wrote:
I'm wondering if there is something similar to list comprehension for
dict (please see the example code below).
Do you mean something like this:
>>> {i:i+1 for i in [1,2,3,4]}
{1: 2, 2: 3, 3: 4, 4: 5}
This works in python3, but not in python2
- Patrick
--
http://mail.python.or
kj wrote:
I'm just learning about Google's latest: the GO (Go?) language.
(e.g. http://golang.org or http://www.youtube.com/watch?v=rKnDgT73v8s).
There are some distinctly Pythonoid features to the syntax, such
as "import this_or_that", the absence of parentheses at the top of
flow control const
Carl Banks wrote:
Well, it's hard to argue with not being like C++, but the lack of
inheritance is a doozie.
Well it has the concept of embedding, which seems to be similar to
inheritance.
- Patrick
--
http://mail.python.org/mailman/listinfo/python-list
I use setuptools to create a package. In this package I included some
images and I checked that they are in the egg-file. The problem is how
can I access the images in the package?
I tried pkgutil.get_data, but only got an IOError, because the EGG-INFO
directory doesn't exist.
I tried
pkg_re
Donn wrote:
Have a look at Cairo (python-cairo) in conjunction with librsvg (python-rsvg)
-- that'll fix you up. You can go from an SVG to a PNG/array and thence into
PIL if you need to.
Thanks for the tip. Got it work, although it was a bit tricky, as
resizing doesn't seem to be supported by
I would like to open svg files with PIL, but svg doesn't seem to be
supported. Does anyone know about a svg decoder for the PIL?
- Patrick
--
http://mail.python.org/mailman/listinfo/python-list
My favorite book is "Python Essential Reference" from David M. Beazley.
It is not a beginner book. It is about the python language and not about
a framework or third-party library. It is much more complete than for
instance "Dive into python", but maybe somewhat more difficult.
- Patrick
lal
> You could write a class with a custom __setattr__() method that checks
for valid attribute names for that class (a list of strings given to
it's __init__() method). That way you could form several restricted
"namespaces" for variables simply as different instances of that class.
This can be
Johan Grönqvist schrieb:
Hi All,
I find several places in my code where I would like to have a variable
scope that is smaller than the enclosing function/class/module definition.
One representative example would look like:
--
spam = { ... }
eggs = { ... }
ham = (a[eggs], b[spam])
gentlestone schrieb:
return u"{}".format(self.name)
u"{0}".format(u"blah")
works for me with python-2.6.2
Maybe your format string is wrong.
- Patrick
--
http://mail.python.org/mailman/listinfo/python-list
Now, if the snapshot is a feature of the Python VM, that's another
matter entirely.
I thought of taking a snapshot using fork, which creates a copy of the
process. It may not be the
most performant, but it should be quite portable. Of course there are
some issues with
multithreading/multiproc
Horace Blegg schrieb:
You might consider using a VM with 'save-points'. You run the program
(in a debugger/ida/what have you) to a certain point (logical point
would be if/ifelse/else statements, etc) and save the VM state. Once
you've saved, you continue. If you find the path you've taken isn'
Gabriel Genellina schrieb:
Do you want reverse execution, like an undo function? Undo all changes
made by executing some piece of code?
I am not completly sure, if I really want to make exact undo, i.e.
undoing commands by reversing all their effects, or just restoring the
program state to an ar
Hello,
I am interested if there are any python modules, that supports
reversible debugging aka stepping backwards. Any links or ideas would be
helpful, because I am thinking of implementing something like that.
Thanks in advance,
Patrick
--
http://mail.python.org/mailman/listinfo/python-list
19 matches
Mail list logo