mrholtsr schrieb:
I am absolutely new to python and barely past beginner in programming.
Also I am not a mathematician. Can some one give me pointers for
finding the 1000th. prime for a course I am taking over the internet
on Introduction to Computer Science and Programming. Thanks, Ray
Do you
Peng Yu schrieb:
There had been some discussion on IDE. But I'm not sure what pros and
cons of each choice. Current, I'm using vim and ctags.
Could somebody give some advices on choosing the best IDE for me?
http://groups.google.com/group/comp.lang.python/browse_thread/thread/4b3300d10285ae2b/e
Peng Yu schrieb:
On Nov 15, 11:15 am, "Diez B. Roggisch" wrote:
Peng Yu schrieb:
There had been some discussion on IDE. But I'm not sure what pros and
cons of each choice. Current, I'm using vim and ctags.
Could somebody give some advices on choosing the b
[email protected] schrieb:
Hi
I need to link against Python, is there a way to get the path to the
directory containing Python's C library (e.g., /libs on
Windows)?
Most probably from the registry somehow. In general, try & locate a
python-executable, and make it execute
python -c "im
[email protected] schrieb:
On 15 Nov, 20:05, "Diez B. Roggisch" wrote:
[email protected] schrieb:
Hi
I need to link against Python, is there a way to get the path to the
directory containing Python's C library (e.g., /libs on
Windows)?
Most probably from the regis
[email protected] schrieb:
On 15 Nov, 21:24, "Diez B. Roggisch" wrote:
[email protected] schrieb:
On 15 Nov, 20:05, "Diez B. Roggisch" wrote:
[email protected] schrieb:
Hi
I need to link against Python, is there a way to get the path to the
directory
[email protected] schrieb:
On 15 Nov, 22:11, "Diez B. Roggisch" wrote:
[email protected] schrieb:
On 15 Nov, 21:24, "Diez B. Roggisch" wrote:
[email protected] schrieb:
On 15 Nov, 20:05, "Diez B. Roggisch" wrote:
[email protected]
mrholtsr wrote:
> Is there a Python newsgroup for those who are strictly beginners at
> programming and python?
Yes, the tutor-list.
http://mail.python.org/mailman/listinfo/tutor
Diez
--
http://mail.python.org/mailman/listinfo/python-list
hong zhang schrieb:
List,
I try to assign value to force_mcs sitting in a wildcard subdirectory
/sys/kernel/debug/ieee80211/phy*, but python does not work for that such as:
os.system("echo %i > /sys/kernel/debug/ieee80211/phy*/iwlagn/data/force_mcs" %
mcs)
Any right way to do it?
Don't use
King schrieb:
"eval" can solve this problem right away but I am concerned about
security issues. If not "eval" could you suggest something more
efficient way. It won't be a big deal to change the format as
application is still at development stage?
If you don't want to use eval (which is a good
Glenn Maynard schrieb:
I want to do something fairly simple: read files from one ZIP and add
them to another, so I can remove and replace files. This led me to a
couple things that seem to be missing from the API.
The simple approach would be to open each file in the source ZIP, and
hand it off
Eden Kirin wrote:
> Hi there,
>
> I'm playing with SCGIServer
> (http://vmlinux.org/cgi-bin/dwww/usr/share/doc/python-scgi/guide.html),
> everything works just fine, but one thing bothers me. All prints after
> try-except block are executed twice after the Ctrl+C is pressed!
>
> test.py:
> #
Stefan Behnel wrote:
> Robert P. J. Day, 15.11.2009 15:44:
>> On Sun, 15 Nov 2009, mrholtsr wrote:
>>
>>> I am absolutely new to python and barely past beginner in programming.
>>> Also I am not a mathematician. Can some one give me pointers for
>>> finding the 1000th. prime for a course I am tak
Eden Kirin wrote:
> Diez B. Roggisch wrote:
>
>>> Is there some reasonable explanation for this behaviour? Thanks in
>>> advance.
>>
>> I can only guess that SCGIServer does something to stdout. Your code
>> isn't executed twice, so the doubling s
Lie Ryan schrieb:
hong zhang wrote:
--- On Tue, 11/17/09, Tim Chase wrote:
From: Tim Chase
Subject: Re: IOError: [Errno 28] No space left on device
To: "Lie Ryan"
Cc: [email protected]
Date: Tuesday, November 17, 2009, 7:47 PM
for i in
glob.glob('/sys/kernel/debug/ieee80211/phy*/iwl
Keith Hughitt wrote:
> Hi all,
>
> I ran into a problem recently when trying to add support for earlier
> versions of Python (2.4 and 2.5) to some database related code which
> uses MySQLdb, and was wondering if anyone has any suggestions.
>
> With later versions of Python (2.6), inserting Unico
hong zhang wrote:
>
>
> --- On Wed, 11/18/09, Grant Edwards wrote:
>
>> From: Grant Edwards
>> Subject: Re: IOError: [Errno 28] No space left on device
>> To: [email protected]
>> Date: Wednesday, November 18, 2009, 9:22 AM
>> On 2009-11-18, hong zhang
>> wrote:
>>
>> >> Apparently the
Daniel Dalton schrieb:
Hi,
Here is my situation:
I'm using the command line, as in, I'm not starting gnome or kde (I'm on
linux.)
I have a string of text attached to a variable,. So I need to use one of
the browsers on linux, that run under the command line, eg. lynx,
elinks, links, links2 and d
Peng Yu schrieb:
On Wed, Nov 18, 2009 at 9:12 PM, Tim Chase
wrote:
There are many special characters listed on
http://docs.python.org/library/re.html
I'm wondering if there is a convenient function that can readily
convert a string with the special characters to its corresponding
regex. For ex
hong zhang schrieb:
List,
I want to input hex number instead of int number. in type="int" in following,
parser.add_option("-F", "--forcemcs", dest="force_mcs", type="int", default=0,
help="index of 11n mcs table. Default: 0.")
How can I do it?
You can't. You can get a string, and convert th
DreiJane schrieb:
NB: I wondered about about dict(one=1, two=2) - why not d = {one:1,
two:2} ? Since you do not write L=list((1, 2)) either. These composed
because it's not working.
>>> {one : 1}
Traceback (most recent call last):
File "", line 1, in
NameError: name 'one' is not defined
Y
Esmail schrieb:
Could someone help confirm/clarify the semantics of the [:] operator
in Python?
a = range(51,55)
# 1 ##
b = a[:] # b receives a copy of a, but they are independent
>
# The following two are equivalent
# 2 ##
c = [
eric.frederich schrieb:
I have a class which holds a connection to a server and a bunch of
services.
In this class I have methods that need to work with that connection
and services.
Right now there are about 50 methods some of which can be quite long.
From an organizational standpoint, I'd like
King schrieb:
class A(object):
def __init__(self, value=0.):
self.value = value
class B(A):
def __init__(self, value=None):
A.__init__(self)
self.value = value
obj = B()
When "B" initializes, it overwrite "value" variable of "A&quo
Esmail schrieb:
Diez B. Roggisch wrote:
Esmail schrieb:
Could someone help confirm/clarify the semantics of the [:] operator
in Python?
a = range(51,55)
# 1 ##
b = a[:] # b receives a copy of a, but they are independent
>
# The following two are equival
Steve Howell schrieb:
On Nov 21, 4:07 pm, MRAB wrote:
I don't see the point of EvalNode and PrettyPrintNode. Why don't you
just give Integer, Sum and Product 'eval' and 'pprint' methods?
That's a good question, and it's the crux of my design dilemma. If
ALL I ever wanted to to with Integer/S
randint(0, 50))]
Better use .append here, looks nicer and should also be a bit faster.
b = a[:]
c = a[:]
print 'Sorting...'
t = time()
b.sort(cmp=v_cmp)
print time() - t
t = time()
c.sort()
print time() - t
print b == c
= RESTART ==
Daniel Fetchinson schrieb:
Has anyone every tried wrapping the CPython lib into a daemon with an
RPC mechanism in order to move the GIL out of the process? I have
multiple audio threads, each of which use the python interpreter but
don't have to interact with each other and can might as well use
Marc Leconte schrieb:
Dear all,
I have a problem with the following code (ubuntu 8.04, Python 2.5.2):
class Toto(object):
def __init__(self, number, mylist=[]):
self.number=number
self.mylist=mylist
pass
pass
listA=Toto(number=1)
Andy dixon wrote:
> Hi,
>
> Does anyone have a link to, or can provide an example script for using
> python-pgsql (http://pypi.python.org/pypi/python-pgsql/) or if someone can
> recommend an alternative, that would be fantastic.
I'd recommend psycopg2.
This is an introduction:
http://www.dev
Krishnakant wrote:
> On Mon, 2009-11-23 at 11:22 +0100, Diez B. Roggisch wrote:
>> Andy dixon wrote:
>>
>> > Hi,
>> >
>> > Does anyone have a link to, or can provide an example script for using
>> > python-pgsql (http://pypi.python.org/pypi
Anjanesh Lekshminarayanan wrote:
> Python 3.1.1
>
> sql = "INSERT INTO `tbl` VALUES (NULL, '%s', '%s', '%s', '%s', '%s');"
> for row in fp:
> print (sql, (row[0],row[1],row[2],row[3],row[4]))
> .
> INSERT INTO `tbl` VALUES (NULL, '%s', '%s', '%s', '%s', '%s'); ('142',
> 'abc', '2006-04-09 02:
Anjanesh Lekshminarayanan wrote:
>> Depending on your DB-adapter, you are out of luck here. Either connect to
>> a db even if you don't need it, or try & see if you can locate the
>> implementation in the module somehow.
>
> ImportError: No module named MySQLdb
> MySQLdb only available in Python2
Anjanesh Lekshminarayanan wrote:
>> Maybe it would help if you explained what you are actually trying to
>> accomplish.
>
> import csv
> f = csv.reader(open('data.txt'), delimiter='\t') # 2GB text file
> sql = "INSERT INTO `data` VALUES (NULL,%s,%s,%s,%s,%s);"
> for row in f:
> print (sql, (r
Sérgio Monteiro Basto wrote:
> Hi,
> I am in x86_64 arch , but I need
> compile things on 32 bits with
> python setup.py build
>
> Can't change the fact that distutils creates x86_64
> directories:
> build/temp.linux-x86_64-2.3/
>
> Also if I try with a python compile in 32bits and installed
> i
x27;
> 103 for label, name in zip(labels, names):
The zip-function takes n iterables, and produces a list with n-tuples out of
it. Type this into the python-prompt:
>>> zip([1, 2, 3], ["a", "b", "c"])
The other thing here is tuple-unpacking. If you kn
Patrick Stinson schrieb:
On Mon, Nov 23, 2009 at 1:01 AM, Carl Banks wrote:
On Nov 22, 10:58 pm, Patrick Stinson
wrote:
On Sun, Nov 22, 2009 at 3:15 PM, Diez B. Roggisch wrote:
icating) the multiprocessing module would be ideal.
The problem is that the OP has a embedded application
Sérgio Monteiro Basto schrieb:
Diez B. Roggisch wrote:
Hi, Thanks,
Sérgio Monteiro Basto wrote:
Hi,
I am in x86_64 arch , but I need
compile things on 32 bits with
python setup.py build
Can't change the fact that distutils creates x86_64
directories:
build/temp.linux-x86_64-2.3/
Also
Jankins schrieb:
I am trying to use sys.stdout to print out "process-bar" like:
-->1%
Here is my program ‘test.py’:
from sys import stdout
for v in range(10):
stdout.write('-->%d' % v)
stdout.flush()
else:
stdout.write('done!')
#end for
Then, I use 'python -u test.py' to run this s
NMarcu wrote:
> Hello all,
> I need some help to understand a getattr syntax. The syntax is:
>
> try:
> getattr(self, command)(cursor, row)
> except Exception, e:
> print "Action failed : '%s'" % command
> raise e
>
> I don't understand why is not like this: a = getattr(), and wh
Sandy schrieb:
Hi all,
I am a little bit confused about os.fork().
Say I have the following code.
import os
a = ['a','b','c','d','e']
for i in xrange(len(a)):
pid = os.fork()
if not pid:
print a[i]
os._exit(0)
From mo
Am 31.01.10 16:38, schrieb kj:
It gets tedious to have to append .encode('utf-8') to all my unicode
strings when I print them, as in:
print foobar.encode('utf-8')
I want to tell python to apply this encoding automatically to
anything argument passed to print.
How can I do this?
TIA!
K
Am 31.01.10 16:52, schrieb kj:
I want to pass Chinese characters as command-line arguments to a
Python script. My terminal has no problem displaying these
characters, and passing them to the script, but I can't get Python
to understand them properly.
E.g. if I pass one such character to the sim
So.I'm wondering if there is any interest in an apply() built-in
function that would work like map() does in 2.x (calls the function
with each value returned by the iterator) but return nothing. Maybe
"apply" isn't the best name; it's just the first one that occurred to
me.
Or is this just s
m with the values, and submit that
- of course you need javascript for this.
But this doesn't increase security a bit. Using an extension to FF such
as HTTP live headers, it's easy enough to figure out what parameters are
passed, and simply forge a request.
b) without the user bein
Am 03.02.10 22:46, schrieb soltys:
Hi Everybody,
I've been doing some test on pythons' virtualenv and recently I've
decided to run PyChecker. But I'm having some difficulties with importing
modules available only on virtualenv by pychecker. As if it was
trying to use systemwide python.
I've googl
Am 03.02.10 23:35, schrieb Paul Rubin:
"Diez B. Roggisch" writes:
If somebody happens to have access to a proxy& it's logs, he can as
well log the request body.
I'm not talking about a malicious server operator. In this situation, I
was the server operator and I did
Am 04.02.10 01:52, schrieb Steve Holden:
Diez B. Roggisch wrote:
Am 03.02.10 22:46, schrieb soltys:
Hi Everybody,
I've been doing some test on pythons' virtualenv and recently I've
decided to run PyChecker. But I'm having some difficulties with importing
modules available o
ime: data sent over the wire can be recorded.
From the user's POV, your nitpicking of who's the actual culprit - the
IT-guys, or the programmers - is fruitless. You have a nice anecdote
where switching from GET to POST allowed you to trick whoever wasn't
acting to your wishes.
Am 03.02.10 19:11, schrieb John Bokma:
Alan Harris-Reid writes:
I have a web-page where each row in a grid has edit/delete buttons to
enable the user to maintain a selected record on another page. The
buttons are in the form of a link with href='/item_edit?id=123', but
this string appears in
Am 03.02.10 23:09, schrieb Paul Rubin:
"Diez B. Roggisch" writes:
Also, your claim of it being more risky is simply nonsense. GET is a
tiny bit more prone to tinkering by the average user. But calling this
less risky is promoting security by obscurity, at most.
GET parameters al
Am 04.02.10 00:39, schrieb Paul Rubin:
"Diez B. Roggisch" writes:
Of course only information not gathered is really safe
information. But every operation that has side-effects is reproducable
anyway, and if e.g. your chat-app has a history, you can as well log
the parameters.
Am 04.02.10 03:52, schrieb Nobody:
On Wed, 03 Feb 2010 14:09:07 -0800, Paul Rubin wrote:
Also, your claim of it being more risky is simply nonsense. GET is a
tiny bit more prone to tinkering by the average user. But calling this
less risky is promoting security by obscurity, at most.
GET para
Am 04.02.10 18:22, schrieb John Bokma:
"Diez B. Roggisch" writes:
Am 04.02.10 01:42, schrieb John Bokma:
[..]
Maybe you should think about what happens if someone posts:
http://example.com/item_delete?id=123";> to a popular forum...
And the difference to posting
f
Am 04.02.10 01:42, schrieb John Bokma:
"Diez B. Roggisch" writes:
Am 03.02.10 19:11, schrieb John Bokma:
Alan Harris-Reid writes:
I have a web-page where each row in a grid has edit/delete buttons to
enable the user to maintain a selected record on another page. The
buttons
Am 08.02.10 02:51, schrieb Alf P. Steinbach:
* Chris Rebert:
On Sun, Feb 7, 2010 at 5:05 PM, T wrote:
Ok, just looking for a sanity check here, or maybe something I'm
missing. I have a class Test, for example:
class Test:
def __init__(self, param1, param2, param3):
self.param1 = param1
self.p
Am 06.02.10 12:48, schrieb Steven D'Aprano:
It seems that doctest doesn't discover or execute doctests in methods
which have been decorated.
Here is my test file:
# ==
class MyStaticMethod(object):
"""Emulate built-in staticmethod descriptor."""
def __init__(self, f):
se
Am 09.02.10 07:00, schrieb OdarR:
On 9 fév, 02:50, Jean-Michel Pichavant wrote:
Aahz wrote:
In article<0efe23a6-b16d-4f92-8bc0-12d056bf5...@z26g2000yqm.googlegroups.com>,
OdarR wrote:
and with eval(), did you try ?
WARNING: eval() is almost always the wrong answer to any question
Some
Am 13.02.10 11:50, schrieb hjebbers:
On Feb 13, 10:25 am, Dennis Lee Bieber wrote:
On Fri, 12 Feb 2010 09:21:07 -0800 (PST), hjebbers
declaimed the following in gmane.comp.python.general:
What strikes me is:
1. the crash on windows, but linux works OK (same test sets)
2. the linux box has 750
Am 13.02.10 13:51, schrieb Ernest Adrogué:
Hello everybody,
I'm designing a container class that supports slicing.
The problem is that I don't really know how to do it.
class MyClass(object):
def __init__(self, input_data):
self._data = transform_input(input_data)
Am 13.02.10 20:46, schrieb Gnarlodious:
Hello, searched all over but no success. I want to have a script
output HTML if run in a browser and plain text if run in a Terminal.
In Python 2, I just said this:
if len(sys.argv)==True:
and it seemed to work. Py3 must have broken that by sending a list
Am 13.02.10 17:18, schrieb Anssi Saari:
Nobody writes:
A single process can't use much more than 2GiB of RAM without a 64-bit CPU
and OS.
That's not really true. Even Windows XP has the /3GB boot option to
allow 3 GiB per process. On PCs, free operating systems and server
Windows can use PAE
Am 14.02.10 13:05, schrieb Florian Ludwig:
On Sun, 2010-02-14 at 10:16 +0100, Paul Kölle wrote:
Am 13.02.2010 10:50, schrieb Florian Ludwig:
Hi,
I'm looking for a module/plugin/intra-process-communication/hook system
for python. Maybe someone here could point me to some project I missed
or mig
Am 14.02.10 12:28, schrieb Laszlo Nagy:
2010.02.13. 17:40 keltezéssel, Diez B. Roggisch írta:
Am 13.02.10 17:18, schrieb Anssi Saari:
Nobody writes:
A single process can't use much more than 2GiB of RAM without a
64-bit CPU
and OS.
That's not really true. Even Windows XP has the
Am 15.02.10 23:12, schrieb Florian Ludwig:
On Sun, 2010-02-14 at 18:47 +0100, Diez B. Roggisch wrote:
Here there problem with the trac (and other plugin systems I've
seen)
approach:
You need to define something like:
|
| class IAuthPlugin(Interface): [...]
|
in your blog software.
Why
IMHO the ones using interfaces usually immediatly implement them for some
cases - so you actually get the interface for you authentication
framework, and also implement an OpenID plugin for it. And this forms
one package. Then you can add new packages that implement other things.
So if I want to
Am 19.02.10 16:08, schrieb Yasser Almeida Hernández:
Hi all.
I have a class with the attribute 'log_file', opened out of the class:
class ProteinCluster:
def __init__(self,cluster_name,log_file):
...
self.log_file = log_file
...
Then i have a private method which write in the log_file:
def _read
Am 20.02.10 17:12, schrieb lallous:
Hello
How can I do something similar to pure virtual functions in C++ ?
Let us consider this:
class C1:
# Pure virtual
def cb(self, param1, param2):
"""
This is a callback
@param param1: ...
@param param2: ...
Sorry, I totally mis-read the OP, too tired. You are right of course.
Diez
--
http://mail.python.org/mailman/listinfo/python-list
Am 22.02.10 22:29, schrieb Bryan:
On Feb 22, 10:57 am, "Alf P. Steinbach" wrote:
* Bryan:
I am looping through a list and creating a regular dictionary. From
that dict, I create an ordered dict. I can't think of a way to build
the ordered dict while going through the original loop. Is th
Am 22.02.10 23:48, schrieb Bryan:
On Feb 22, 2:16 pm, "Diez B. Roggisch" wrote:
Am 22.02.10 22:29, schrieb Bryan:
On Feb 22, 10:57 am, "Alf P. Steinbach"wrote:
* Bryan:
I am looping through a list and creating a regular dictionary. From
that dict, I create
Am 24.02.10 18:07, schrieb Sebastian Bassi:
c.execute("SELECT bin FROM bins WHERE qtl LIKE '%:keys%'",{'keys':keywords})
This query returns empty. When it is executed, keywords = 'harvest'.
To check it, I do it on the command line and it works as expected:
sqlite> SELECT bin FROM bins WHERE qt
Am 24.02.10 00:08, schrieb monkeys paw:
On 2/23/2010 3:17 PM, Tim Chase wrote:
monkeys paw wrote:
I used the following code to download a PDF file, but the
file was invalid after running the code, is there problem
with the write operation?
import urllib2
url = 'http://www.whirlpoolwaterheaters
Am 24.02.10 03:00, schrieb Mag Gam:
I am trying to compile python with Tk bindings. Do I need to do
anything special for python to detect and enable Tk?
What OS? What does the configure/build process say?
Diez
--
http://mail.python.org/mailman/listinfo/python-list
Am 24.02.10 23:35, schrieb kj:
Is there some standard module for getting info about the process's
memory usage, in a Linux/Unix system?
(I want to avoid hacks that involve, e.g., scraping ps's output.)
http://code.google.com/p/pympler/
Diez
--
http://mail.python.org/mailman/listinfo/python-li
Am 24.02.10 12:42, schrieb Michael Rudolf:
First: Thanks for all the replies so far, they really helped me.
Am 24.02.2010 11:28, schrieb Jean-Michel Pichavant:
>>> def a(x=None):
if x is None:
pass
else:
pass
This is the way to do it python, and it has its advantages: 1 docstring,
1 way do do
Am 25.02.10 08:54, schrieb john maclean:
python version is 2.6.2 does any one else have this issue? Seen a few
closed tickets for various Linux Distros but it is obvoiusly still my
problem.
help> modules
Please wait a moment while I gather a list of all available modules...
dm.c: 1640: not r
Am 25.02.10 18:08, schrieb Robert:
After (intended/controlled) reload or similar action on a module/class
the pickle/cPickle.dump raises errors like
pickle.PicklingError: Can't pickle : it's
not the same object as somemodule.SomeClass
Cause in pickle.py (and cPickle) is a line
"if klass is not
Am 25.02.10 20:27, schrieb Luca:
Chris Rebert wrote:
On Thu, Feb 25, 2010 at 7:26 AM, Luca wrote:
Hello, i am trying to develop an application to teach programming to
young
kids in a similar way as Logo did in the past. I would like to use an
embedded Python as underlying language but this rai
Am 25.02.10 01:55, schrieb Mag Gam:
sorry for the vague answer.
Its Linux.
The configure build does not say anything actually. This is for SAGE.
I managed to have it pick it up by compiling/installing tcl and tk and
then recompile python
Then most probably installing the tk-dev packages would
And also I don't think that your concerns are valid in general.
Keywords are like brandnames or other things - the stand for a
concept, and people immediatly accept them when they want them.
Maybe you are right, but being italian myself i can remember when i was
a middle schooler (no computer be
On a related note, did you investigate SUGAR of the OLPC? I'd say these
guys certainly tried to create something that appealed to children, and
AFAIK it comes with a Python interpreter. I'm don't know anything about
that, nor if it comes with learning material. Might be worth checking out.
Die
That better way turned out to asynchronous update transactions. All we
did was keep feeding updates to the remote site and forget about ACKS.
We then had a second process which handled ACKS and tracked which
packets had been properly transferred. The system had IDs on each
update and retries hap
Am 26.02.10 09:55, schrieb Joan Miller:
When a package is imported, it gets the dosctring to store it in
*__doc__*.
Does that funcion is built in python? because I would want use it to
get the docstring without import a package
You'd need to write your own parser for that. All standard tools s
Am 26.02.10 06:07, schrieb darnzen:
Having an odd problem that I solved, but wondering if its the best
solution (seems like a bit of a hack).
First off, I'm using an external DLL that requires static callbacks,
but because of this, I'm losing instance info. It could be import
related? It will ma
Am 26.02.10 05:01, schrieb D'Arcy J.M. Cain:
On Fri, 26 Feb 2010 01:12:00 +0100
"Diez B. Roggisch" wrote:
That better way turned out to asynchronous update transactions. All we
did was keep feeding updates to the remote site and forget about ACKS.
We then had a second proces
at that point of comparison the module is already identical ("klass =
getattr(mod, name)")
Ah, didn't know that context.
even more corner-cases. Python's import-mechanism can sometimes be
rather foot-shoot-prone.
still don't see a real reason against the mere module+name comparison.
same iss
Am 26.02.10 16:32, schrieb darnzen:
On Feb 26, 3:15 am, "Diez B. Roggisch" wrote:
Am 26.02.10 06:07, schrieb darnzen:
Having an odd problem that I solved, but wondering if its the best
solution (seems like a bit of a hack).
First off, I'm using an external DLL that
Am 26.02.10 16:57, schrieb darnzen:
On Feb 26, 9:41 am, "Diez B. Roggisch" wrote:
Am 26.02.10 16:32, schrieb darnzen:
On Feb 26, 3:15 am, "Diez B. Roggisch"wrote:
Am 26.02.10 06:07, schrieb darnzen:
Having an odd problem that I solved, but wondering if i
Am 26.02.10 17:08, schrieb Diez B. Roggisch:
Am 26.02.10 16:57, schrieb darnzen:
On Feb 26, 9:41 am, "Diez B. Roggisch" wrote:
Am 26.02.10 16:32, schrieb darnzen:
On Feb 26, 3:15 am, "Diez B. Roggisch" wrote:
Am 26.02.10 06:07, schrieb darnzen:
Having an odd p
Am 02.03.10 21:41, schrieb mk:
Jerry Hill wrote:
Just import subprocess at the top of your module. If subprocess
hasn't been imported yet, it will be imported when your module is
loaded. If it's already been imported, your module will use the
cached version that's already been imported.
In othe
Am 04.03.10 06:23, schrieb yamamoto:
Hi,
I tried to make a simple script with SUD library for caching torrent
files. it doenst work!
[versions]
suds: 0.4, python: 2.6.4
[code]
from suds.client import Client
import base64
path = 'sample.torrent'
doc = open(path, 'rb').read()
encoded_doc = base6
Am 08.03.10 01:18, schrieb Paweł Banyś:
Hello,
I have already read about Python and multiprocessing which allows using
many processors. The idea is to split a program into separate tasks and
run each of them on a separate processor. However I want to run a Python
program doing a single simple ta
kj wrote:
>
>
>
>
>
>
> I need to create a class solely for the purpose of encapsulating
> a large number of disparate data items. At the moment I have no
> plans for any methods for this class other than the bazillion
> accessors required to access these various instance variables.
> (In c
Artur Siekielski writes:
> Hi.
> I'm using CPython 2.7 and Linux. In order to make parallel
> computations on a large list of objects I want to use multiple
> processes (by using multiprocessing module). In the first step I fill
> the list with objects and then I fork() my worker processes that d
Artur Siekielski writes:
> On Nov 15, 1:03 am, [email protected] (Diez B. Roggisch) wrote:
>> You don't say what data you share, and if all of it is needed for each
>> child. So it's hard to suggest optimizations.
>
> Here is an example of such a problem I'm de
Martin Caum writes:
> I am attempting to open a window on mouse activity which works, but
> the window fails to stay open.
> I set it to terminate when the escape key is pressed even when the
> program is not currently selected. This works fine. Originally I had
> it create the window only with a
Grigory Petrov writes:
> Hello.
>
> I have a DLL that allocates memory and returns it. Function in DLL is like
> this:
>
> void Foo( unsigned char** ppMem, int* pSize )
> {
> * pSize = 4;
> * ppMem = malloc( * pSize );
> for( int i = 0; i < * pSize; i ++ ) (* pMem)[ i ] = i;
> }
>
> Also,
Eric Frederich writes:
> I have a proprietary software PropSoft that I need to extend.
> They support extensions written in C that can link against PropLib to
> interact with the system.
>
> I have a Python C module that wraps a couple PropLib functions that I
> call PyProp.
>>From an interactive
Adrian Casey writes:
> I have a PyQt4 multi-threaded application which accesses many hosts
> concurrently via ssh. I would like each thread to have access to a
> database so that it can look up details about the particular system it
> is connected to.
>
> The easy way is to have each thread crea
4001 - 4100 of 4481 matches
Mail list logo