I have been trying to figure out how to use pdb to correct simple errors in a
file and then continue with program execution. Perhaps someone can tell me why
this is not working for me.
Here is my file test.py:
#--
import pdb
pdb.set_trace()
print """
this is a test file
"""
x =
Steven D'Aprano writes:
> Save yourself a lot of time and just killfile him now. You'll thank me
> for it later.
You never thanked *me* for it, after you eventually realised that was
the right decision :-)
--
\ “Time's fun when you're having flies.” —Kermit the Frog |
`\
Thanks for the responses, all! In its strictest sense,
itertools.count() seems to be what I'm after, but may not be what I
need.
On Fri, Apr 15, 2011 at 12:33 PM, Steven D'Aprano
wrote:
> No. But you can use an itertools.count([start=0]) object, and then catch
> the KeyError when you pass the end
In article <4da7abad$0$29986$c3e8da3$54964...@news.astraweb.com>,
Steven D'Aprano wrote:
> What they give is ubiquity, which is a point in their favour. But just
> because something is common doesn't make it useful: for the most part
> both are used for style over substance, of sizzle without
On Fri, 2011-04-15 at 12:34 +1000, Ryan Kelly wrote:
> On Fri, 2011-04-15 at 12:10 +1000, Chris Angelico wrote:
> >
> >
> > My first draft looks something like this. The input dictionary is
> > called dct, the output list is lst.
> >
> > lst=[]
> > for i in xrange(1,1000): # arbitrary top, do
In article <4da7a8f5$0$29986$c3e8da3$54964...@news.astraweb.com>,
Steven D'Aprano wrote:
> On Thu, 14 Apr 2011 13:50:24 -0700, Westley MartÃnez wrote:
>
> > Also, why aren't Opera and Google criticized for their proprietary
> > browsers (Chrome is essentially a proprietary front-end)? Is it be
If I understand your question correctly, what you want is probably
something like:
i = 0
lst=[]
while True:
try:
lst.append(parse_kwdlist(dct["Keyword%d"%i]))
i += 1
except KeyError:
break
--jac
On Thu, Apr 14, 2011 at 9:10 PM, Chris Angelico wrote:
> Apologies for interrupting the
On Fri, 15 Apr 2011 12:10:52 +1000, Chris Angelico wrote:
> Apologies for interrupting the vital off-topic discussion, but I have a
> real Python question to ask.
Sorry, you'll in the wrong forum for that.
*wink*
[...]
> My first draft looks something like this. The input dictionary is called
>
On Fri, 15 Apr 2011 12:10:52 +1000, Chris Angelico wrote:
> One, is there a way to make an xrange object and leave the top off?
itertools.count()
> And two, can the entire thing be turned into a list comprehension or
> something? Generally any construct with a for loop that appends to a
> list i
On Fri, 2011-04-15 at 12:10 +1000, Chris Angelico wrote:
> Apologies for interrupting the vital off-topic discussion, but I have
> a real Python question to ask.
>
> I'm doing something that needs to scan a dictionary for elements that
> have a particular beginning and a numeric tail, and turn the
On Fri, Apr 15, 2011 at 12:09 PM, Steven D'Aprano
wrote:
> Personally, I think it is *good* that there is a plurality of browsers in
> the market. In my perfect world, no single browser should capture more
> than 20% share of users.
In *MY* perfect world, choice of browser should be completely up
On Thu, 14 Apr 2011 12:15:59 -0500, Jeffrey Gaynor wrote:
[...]
> Don't know much about this topic, but boy is my BS detector going off...
Just search the archives for "rantingrick". He's been around a few years
now, and my estimate is that 99% of his posts are haranguing others for
refusing to
On Thu, 14 Apr 2011 13:46:46 -0700, Westley Martínez wrote:
>> Now, if only we could convince web users that having your browser
>> execute untrusted code downloaded from the Internet is not such a good
>> idea, supposed sandbox or not. What the world needs is a virus that
>> silently removes Java
On Thu, 14 Apr 2011 13:50:24 -0700, Westley Martínez wrote:
> Also, why aren't Opera and Google criticized for their proprietary
> browsers (Chrome is essentially a proprietary front-end)? Is it because
> their browsers follow web standards, or is it because we have demonized
> Microsoft?
A littl
Apologies for interrupting the vital off-topic discussion, but I have
a real Python question to ask.
I'm doing something that needs to scan a dictionary for elements that
have a particular beginning and a numeric tail, and turn them into a
single list with some processing. I have a function parse_
On Fri, Apr 15, 2011 at 11:14 AM, Stephen.Wu <54wut...@gmail.com> wrote:
> It works. Seems the DNS server will exchange localhost and 127.0.0.1,
> taking nearly 15 seconds. Anyway, I got to know the exactly reason let
> the initialized procedures down, which is the most important thing.
Generally
On Fri, 15 Apr 2011 06:25:34 +0530, लेवीस quoted:
>> I'v mad a text chat sytem in python using xmpp.
>>can anyone help me to implement video chat in it, heard python-farsight
>>is used for audio/video conferencing. Can anyone help me how to use
>>it in my code, I'm a python beginer so can't im
On Fri, 15 Apr 2011 08:01:42 +1000, Chris Angelico wrote:
> On Fri, Apr 15, 2011 at 7:36 AM, Martin Gregorie
> wrote:
>> I think the only real evil is to set out to make a non-standards-
>> compliant server and then design client software that seeks to lock in
>> people to your server. FWIW I'm n
On Apr 14, 9:39 pm, Chris Angelico wrote:
> On Thu, Apr 14, 2011 at 11:30 PM, Stephen.Wu <54wut...@gmail.com> wrote:
> > Thanks Chris.
> > I recheck the logic line by line and I find it is this sentence drag
> > speed down : hello_client = Client('http://localhost:7789/?wsdl').
> > To initialize
> I'v mad a text chat sytem in python using xmpp.
>can anyone help me to implement video chat in it, heard python-farsight is
>used for audio/video conferencing. Can anyone help me how to use it in my
>code, I'm a python beginer so can't imlement much in python. I found this
>python-farsight
On Thu, 14 Apr 2011 15:23:01 -0700, Westley Martínez wrote:
> On Fri, 2011-04-15 at 08:01 +1000, Chris Angelico wrote:
>> On Fri, Apr 15, 2011 at 7:36 AM, Martin Gregorie
>> wrote:
>> > I think the only real evil is to set out to make a non-standards-
>> > compliant server and then design client
On Fri, 2011-04-15 at 08:01 +1000, Chris Angelico wrote:
> On Fri, Apr 15, 2011 at 7:36 AM, Martin Gregorie
> wrote:
> > I think the only real evil is to set out to make a non-standards-
> > compliant server and then design client software that seeks to lock in
> > people to your server. FWIW I'm
On Fri, 15 Apr 2011 08:01:42 +1000, Chris Angelico wrote:
> On Fri, Apr 15, 2011 at 7:36 AM, Martin Gregorie
> wrote:
>> I think the only real evil is to set out to make a non-standards-
>> compliant server and then design client software that seeks to lock in
>> people to your server. FWIW I'm n
On Fri, Apr 15, 2011 at 7:36 AM, Martin Gregorie
wrote:
> I think the only real evil is to set out to make a non-standards-
> compliant server and then design client software that seeks to lock in
> people to your server. FWIW I'm not certain that is anything that MS
> deliberately set out to do.
On Thu, 14 Apr 2011 13:50:24 -0700, Westley Martínez wrote:
> Also, why aren't Opera and Google criticized for their proprietary
> browsers (Chrome is essentially a proprietary front-end)? Is it because
> their browsers follow web standards, or is it because we have demonized
> Microsoft?
>
Person
Reading the PEPs is a great way to get a look at how Python has developed
and at some of its subtle nuances. It's a great way to compare your great
new idea to what the community has seriously considered before. Most of
them have information that you won't find consolidated anywhere else.
Quite
I'm not a python expert, but you might trying running 'print sys.path' inside
your script and run that from TextWrangler to see where it's looking for
modules.
- Ernest
On Apr 14, 2011, at 5:01 PM, Jon Clements wrote:
> On Apr 14, 9:52 pm, Fabio wrote:
>> Hi to all,
>> I have troubles with T
Westley Martínez wrote:
Also, why aren't Opera and Google criticized for their proprietary
browsers (Chrome is essentially a proprietary front-end)? Is it because
their browsers follow web standards, or is it because we have demonized
Microsoft?
My biggest gripe with Microsoft as that they *don
On Apr 14, 9:52 pm, Fabio wrote:
> Hi to all,
> I have troubles with TextWrangler "run" command in the "shebang" (#!)
> menu.
> I am on MacOSX 10.6.7.
> I have the "built-in" Python2.5 which comes installed by "mother Apple".
> Then I installed Python2.6, and left 2.5 untouched (I was suggested to
Hi to all,
I have troubles with TextWrangler "run" command in the "shebang" (#!)
menu.
I am on MacOSX 10.6.7.
I have the "built-in" Python2.5 which comes installed by "mother Apple".
Then I installed Python2.6, and left 2.5 untouched (I was suggested to
leave it on the system, since "something mi
On Thu, 2011-04-14 at 14:02 +, Steven D'Aprano wrote:
> On Thu, 14 Apr 2011 19:15:05 +1000, Chris Angelico wrote:
>
> > 4) Assumes people aren't deliberately fiddling the figures. Yeah, that
> > would be correct. We're in the realm of conspiracy theories here... does
> > anyone seriously think
On Thu, 2011-04-14 at 14:02 +, Steven D'Aprano wrote:
> On Thu, 14 Apr 2011 19:15:05 +1000, Chris Angelico wrote:
>
> > 4) Assumes people aren't deliberately fiddling the figures. Yeah, that
> > would be correct. We're in the realm of conspiracy theories here... does
> > anyone seriously think
In article
<0d6d1306-6395-4c29-a3c1-b2748bda4...@i39g2000prd.googlegroups.com>,
Robert wrote:
> Can I install Python 2.7 and 3.2 (from python.org) side by side on OSX
> without them stepping all over each other?
I have troubles with textwrangler, and I have the feeling it is related
to the fa
On 2011-04-14, rantingrick wrote:
> [the usual bait]
One has to congratulate RR on how many fish he catches. I guess we
should just be glad that in this electronic ocean overfishing doesn't
cause a population crash.
--
Grant Edwards grant.b.edwardsYow! Everybody gets fre
Lemme see now...
>i laid out grandiose plans for a new beginning only to have my words
>fall on deaf ears. Have we become so self absorbed as to care only for
>our status and ego and not for the community at whole?
So you proposed a grandiose plane that is a heck of a lot of work for the
peo
In article ,
Daniel Fetchinson wrote:
>>> what is the character limit on a one liner :P.
>>
>> For PEP 8 compliance, 80 characters. :-)
>
>Yeah, but we don't live in the 80's or 90's anymore and our screens
>can support xterms (or let alone IDE widows) much wider than 80
>characters. I'm using 14
On 4/14/2011 12:55 PM, Peter Otten wrote:
I don't expect that it matters much, but you don't need to sort your data if
you use a dictionary anyway:
Which means that one can build the dict line by line, as each is read,
instead of reading the entire file into memory. So it does matter for
int
christian wrote:
> Hello,
>
> i'm not very experienced in python. Is there a way doing below more
> memory efficient and maybe faster.
> I import a 2-column file and then concat for every unique value in
> the first column ( key) the value from the second
> columns.
>
> So The ouptut is someth
On Thu, Apr 14, 2011 at 12:22 AM, harrismh777 wrote:
> geremy condra wrote:
>>
>> Having said that, I have a greater respect for mathematics than I do
>> for my own economic views, and I don't like seeing it become a
>> political football. If you can prove something,*prove it*. If you
>> cannot- n
On Thu, Apr 14, 2011 at 12:04 AM, harrismh777 wrote:
> How mamy times have you altered the identity of your web browser so that
> the web site would 'work'? You know, stupid messages from the server that
> say, "We only support IE 6+, upgrade your browser...", so you tell it
> you're using IE
On Apr 14, 1:50 am, harrismh777 wrote:
> Westley Martínez wrote:
> I don't even know one person who has Win7 installed, running, and
> likes it...
> > >> not even one.
>
> >>> > > Hi, m harris, nice to meet you. Now you do.
>
> >>> > > To the online community: Is there a
Hello,
i'm not very experienced in python. Is there a way doing below more
memory efficient and maybe faster.
I import a 2-column file and then concat for every unique value in
the first column ( key) the value from the second
columns.
So The ouptut is something like that.
A,1,2,3
B,3,4
C,9,10,
geremy condra wrote:
On Wed, Apr 13, 2011 at 10:50 PM, harrismh777 wrote:
>>
My major professor once told me, "You know you've won the argument when they
start calling you names!"
I think your professor should have said "you know you've won the
argument when you can prove it".
If you can
HI Steven D'Aprano...
> Now, if only we could convince web users that having your browser execute
> untrusted code downloaded from the Internet is not such a good idea, supposed
> sandbox or not.
No need, we have an abundance of half wits - erm I mean, surfers - out there
willing click on anyth
On Fri, Apr 15, 2011 at 12:02 AM, Steven D'Aprano
wrote:
> Now, if only we could convince web users that having your browser execute
> untrusted code downloaded from the Internet is not such a good idea,
> supposed sandbox or not. What the world needs is a virus that silently
> removes Javascript
On Thu, 14 Apr 2011 19:15:05 +1000, Chris Angelico wrote:
> 4) Assumes people aren't deliberately fiddling the figures. Yeah, that
> would be correct. We're in the realm of conspiracy theories here... does
> anyone seriously think that browser stats are THAT important that they'd
> go to multiple
On Wed, 2011-04-13 at 20:26 -0700, rantingrick wrote:
> On Apr 13, 10:01 pm, Ryan Kelly wrote:
> > On Wed, 2011-04-13 at 19:10 -0700, rantingrick wrote:
> > > On Apr 13, 8:29 pm, Ryan Kelly wrote:
> > > > On Wed, 2011-04-13 at 17:39 -0700, rantingrick wrote:
> [...]
>
> > Funny you should bring
On Thu, Apr 14, 2011 at 11:30 PM, Stephen.Wu <54wut...@gmail.com> wrote:
> Thanks Chris.
> I recheck the logic line by line and I find it is this sentence drag
> speed down : hello_client = Client('http://localhost:7789/?wsdl').
> To initialize a suds.client.Client instance need that long lasting
On Apr 14, 5:18 pm, Chris Angelico wrote:
> On Thu, Apr 14, 2011 at 6:43 PM, Stephen.Wu <54wut...@gmail.com> wrote:
> > I just follow the instructions below
> > -http://soaplib.github.com/soaplib/2_0/pages/helloworld.html
> > to establish a soap server. After starting the server, everytime I run
Nitish Sharma wrote:
> Hi PyPpl,
> For my current project I have a kernel device driver and a user-space
> application. This user-space application is already provided to me, and
> written in python. I have to extend this application with some addition
> features, which involves communicating with
Hi PyPpl,
For my current project I have a kernel device driver and a user-space
application. This user-space application is already provided to me, and
written in python. I have to extend this application with some addition
features, which involves communicating with kernel device driver through
io
On 14 avr, 08:59,
> Fortunately, if you're using a recent Linux or a Mac with MacPorts,
> installing wxPython should never be more than one command line (or half a
> dozen clicks) away. Windows users aren't quite so lucky, but still, it's
> not like installing it is a major hassle.
>
Probably, t
James Mills writes:
> Does anyone know of a tool that will help with
> reformatting badly written code to be pep8 compliant ?
>
> a 2to3 for pep8 ?
>
What I daily and with great happiness use is flymake-mode in emacs.
Combined with pylint, pep8 and pychecker I can see while I'm programming
all t
On Thu, Apr 14, 2011 at 6:43 PM, Stephen.Wu <54wut...@gmail.com> wrote:
> I just follow the instructions below -
> http://soaplib.github.com/soaplib/2_0/pages/helloworld.html
> to establish a soap server. After starting the server, everytime I run
> the client script, I fetch the response nearly 2
On Thu, Apr 14, 2011 at 4:04 PM, harrismh777 wrote:
>
> How many web crawlers have you built? Are there any web programmers out
> there who need a web bot to hit multiple sites zillions of times a month
> from different places on earth to 'up' the number of hits for economic
> reasons? I've see
I just follow the instructions below -
http://soaplib.github.com/soaplib/2_0/pages/helloworld.html
to establish a soap server. After starting the server, everytime I run
the client script, I fetch the response nearly 20 seconds afterward.
Why this happen?
I just want the server send response asap
On Thu, Apr 14, 2011 at 12:03 PM, Ryan Kelly wrote:
> On Thu, 2011-04-14 at 11:46 +1000, Chris Angelico wrote:
>> Wait... so where do the Python experts hang out?
>
> Don't panic, there are plenty of experts here :-)
>
> It's an oft-cited troll complaint that many python big-wigs (Guido,
> Raymond
> There's a postmortem on the failure of Unladen Swallow by one of the
> developers at:
>
> http://qinsb.blogspot.com/2011/03/unladen-swallow-retrospective.html
This outcome of things is really a testament to the hard work of the pypy folks.
They, a volunteer bunch, beat google!
And that's somethi
geremy condra wrote:
> But on a serious note, I did wonder who would be the first jouster to offer
> the argumentum ad hominem? ... ah, sticks and stones...
> My major professor once told me, "You know you've won the argument when they
> start calling you names!"
I think your professor
geremy condra wrote:
Having said that, I have a greater respect for mathematics than I do
for my own economic views, and I don't like seeing it become a
political football. If you can prove something,*prove it*. If you
cannot- no matter how close you might feel you are- don't claim that
math says
On Wed, 13 Apr 2011 22:08:17 -0700, John Ladasky wrote:
> I may regret wading into a flame-war, but...
>
> I got started with Python in 2002. I took one look at TKinter, said
> "yuck!", and went searching for something else. Now, wxPython is a bit
> clunky for a Python programmer because of its
61 matches
Mail list logo