[EMAIL PROTECTED] wrote
think), but since I'm new to this thing, I thought I'd do the safe
thing and
try a second time.
I personally didn't see the earlier one so can't say if it got here or
not.
But I'll throw in some comments below.
But first I will say that you seem to be going out of
Bryan Fodness [EMAIL PROTECTED] wrote
I want to get a variable name dependent on another variable.
Thats usually a bad idea, but...
I have tried,
'fs' + str(int(round(unblockedFS))) for fs13
I have no idea what you think this will do.
It gives a syntax error for me, which is what I
Here is the actual snippet of code
calc_depth =8.1 # which is actually d
unblockedFS = 13.4 # which is the indexed fs
for line in file('21Ex6MV_tmr.dat'):
d, fs1, fs2, fs3, fs4, fs5, fs6, fs7, fs8, fs9, fs10, fs11, fs12, fs13,
fs14, fs15, fs16, fs17, fs18, fs19, fs20,
On 10/21/07, Bryan Fodness [EMAIL PROTECTED] wrote:
I want to get a variable name dependent on another variable. I have
tried,
'fs' + str(int(round(unblockedFS))) for fs13
and I get an invalid literal. If I code in the fs13, everything works. Is
it possible to do this?
Eric Brunson wrote:
I'm coming in late to the discussion and thought that someone would
explain it succinctly, but there have been so many correct statements
which I feel fail to nail down the problem that I thought I'd chime in.
Hi Eric,
Thank you for your considerate response. Your
Bryan Fodness wrote:
Here is the actual snippet of code
calc_depth =8.1 # which is actually d
unblockedFS = 13.4 # which is the indexed fs
for line in file('21Ex6MV_tmr.dat'):
d, fs1, fs2, fs3, fs4, fs5, fs6, fs7, fs8, fs9, fs10, fs11, fs12,
fs13, fs14, fs15,
Here is the actual snippet of code
calc_depth =8.1 # which is actually d
unblockedFS = 13.4 # which is the indexed fs
for line in file('21Ex6MV_tmr.dat'):
d, fs1, fs2, fs3, fs4, fs5, fs6, fs7, fs8, fs9, fs10, fs11, fs12,
fs13, fs14, fs15, fs16, fs17, fs18, fs19,
Martin Walsh wrote:
Eric Brunson wrote:
I'm coming in late to the discussion and thought that someone would
explain it succinctly, but there have been so many correct statements
which I feel fail to nail down the problem that I thought I'd chime in.
Hi Eric,
Thank you for your
Thank you. This works well. I am still trying to figure out the pros and
cons of using an array, dictionary or list.
On 10/22/07, Kent Johnson [EMAIL PROTECTED] wrote:
Bryan Fodness wrote:
Here is the actual snippet of code
calc_depth =8.1 # which is actually d
Bryan Fodness wrote:
Thank you. This works well. I am still trying to figure out the pros
and cons of using an array, dictionary or list.
Array is specialized, you probably want list or dict.
Use list when you want a sequence of items indexed by sequential integers.
Lists
- preserve order
-
Hi, this is a module i wrote to catch some data from a csv file:
##
#module csv data reader
# open a csv file and return its data
import csv
import sys
def __init__(self):
rawdata = []
f = open('datalisting_000.csv','r')
try:
reader = csv.reader(f)
for
pierre cutellic wrote:
Hi, this is a module i wrote to catch some data from a csv file:
##
#module csv data reader
# open a csv file and return its data
import csv
import sys
def __init__(self):
Stop right there. You're confusing modules and
classes. A class has a
Hi there.
I have a small system in production with wxPython and PostgreSQL running on
a machine with Centos 5.
At first everytihing was running ok but now a weird bug was discovered:
they can't insert characters like á é í ó ú ä ë ñ (non english characters)
Does anyone knows how can I make
Ismael Farfán Estrada wrote:
Hi there.
I have a small system in production with wxPython and PostgreSQL running on
a machine with Centos 5.
At first everytihing was running ok but now a weird bug was discovered:
they can't insert characters like á é í ó ú ä ë ñ (non english
characters)
Tim Golden wrote:
You really just want to rename __init__ to rawdata
and drop the redundant return rawdata function.
But remember to include the line:
return rawdata
at the end of your function or else nothing will be printed when
print csvdatareader.rawdata()
is called.
Also, I'd
Ismael Farfán Estrada wrote:
Hi there.
I have a small system in production with wxPython and PostgreSQL running on
a machine with Centos 5.
At first everytihing was running ok but now a weird bug was discovered:
they can't insert characters like á é í ó ú ä ë ñ (non english
Kent Johnson wrote:
Ismael Farfán Estrada wrote:
Hi there.
I have a small system in production with wxPython and PostgreSQL running on
a machine with Centos 5.
At first everytihing was running ok but now a weird bug was discovered:
they can't insert characters like á é í ó ú ä ë ñ
Ismael Farfán Estrada wrote:
by the way, does sending the data as a list prevent SQL injection?
Yes.
I haven't worried for that yet.
If you are accepting user input and putting it into the database, you
should worry about it. See
http://xkcd.com/327/
for a humorous take on this ;-)
Kent
Hi,
I'm trying to get this binary converter working, but I can't seem to get the
negatives to work properly. If the integer is too low, the 0's that are
added for the amount of bits gets out of whack. I've tried to solve the
problem by adding another 'count' meter by which I can then tell if there
Why not find the sign, calculate the binary of the absolute value, then
make the result negative (twos complement) if necessary?
Just a thought.
[EMAIL PROTECTED] wrote:
Hi,
I'm trying to get this binary converter working, but I can't seem to get the
negatives to work properly. If the
So far I've gotten five copies of this. It could be mailman doing
something wrong, but if you're resending because you don't see your
reply, please be patient, this list is not always instantaneous.
I think you're missing the gist of what I'm saying. Calculate the
binary of the absolute.
Hi Everybody,
Is there a multi-threaded debugger in Python? I running into some
problems and a debugger would be very helpful here.
Thanks,
Tino
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
Tino Dai wrote:
Hi Everybody,
Is there a multi-threaded debugger in Python? I running into some
problems and a debugger would be very helpful here.
Maybe Winpdb would help:
http://www.digitalpeers.com/pythondebugger/
Kent
___
Tutor maillist
That's not a half-baked idea. ;)
I'm not really sure how I would replace 'yes', though, in this
situation. Thoughts?
.james
On Oct 22, 2007, at 10:33 AM, Eric Brunson wrote:
Just another reason why I would look for a solution that would
avoid the
yes altogether. :-)
No worries. I said it could be mailman, and apparently it was. :-)
[EMAIL PROTECTED] wrote:
Hi,
I also got this email five times, and several rejection emails from the
moderator. I'm very sorry for this, but I swear I only sent the email once.
If this Apology email is also sent multiple
Martin Walsh wrote:
Michael Langford wrote:
This signal is not something you care about. All SIGPIPE means is that
the source of the signal found itself writing to a pipe with no sender.
Your line signal.signal(signal.SIGPIPE, signal.SIG_DFL) means use the
default signal handler for
James [EMAIL PROTECTED] wrote
I'm not really sure how I would replace 'yes', though, in this
situation. Thoughts?
Just read the output of Popen from stdout and respond
with a 'y' to stdin until the process finishes.
See the example in the documentation of Popen
replacing os.popen...
[EMAIL PROTECTED] wrote
I'm trying to get this binary converter working, but I can't seem to
get the
negatives to work properly.
I already sent a reply on this, but:
def conversion(n):
b = ''
while n 0:
This line means you only ever return an empty string for a negative
n...
You know, Alan, I remember you commenting that you had some flakey
behavior from this list a few of weeks ago, then
over the weekend I received about two dozen emails from threads as far
back as August.
Something is definitely wonky (technical term ;-) about this list server.
Alan Gauld
Hello,
I would like to write a program which looks in a web directory for, say
*.gif files. Then processes those files in some manner. What I need is
something like glob which will return a directory listing of all the files
matching the search pattern (or just a simply a certain extension).
Is
John wrote:
Hello,
I would like to write a program which looks in a web directory for, say
*.gif files. Then processes those files in some manner. What I need is
something like glob which will return a directory listing of all the
files matching the search pattern (or just a simply a
Eric Brunson wrote:
Martin Walsh wrote:
Michael Langford wrote:
I don't think this is quite right, but please correct me if I'm
misinformed, or just plain wrong. :)
Using signal.signal(signal.SIGPIPE, signal.SIG_IGN) (kernel 2.6.20,
bash 3.2, python2.5)
I just noticed something, Martin.
32 matches
Mail list logo