From: "Stefan Behnel"
Beliavsky, 20.05.2011 18:39:
I thought this essay on why one startup chose Python was interesting.
Since everyone seems to be hot flaming at their pet languages in this
thread, let me quickly say this:
Thanks for sharing the link.
Maybe I have missed a message, but
On Tue, May 24, 2011 at 6:10 PM, Octavian Rasnita wrote:
> From: "Stefan Behnel"
>>
>> Beliavsky, 20.05.2011 18:39:
>>>
>>> I thought this essay on why one startup chose Python was interesting.
>>
>> Since everyone seems to be hot flaming at their pet languages in this
>> thread, let me quickly s
dear mentor,
I need help with my code:
1) my program won't display file contents upon opening
2) my program is not writing to file
3) my program is not closing when user presses enter- gow do I do this with
a while loop?
please see my attempt below and help:
#1) open file and display current fil
On 24/05/2011 09:31, Cathy James wrote:
dear mentor,
I need help with my code:
1) my program won't display file contents upon opening
#1) open file and display current file contents:
f = open ('c:/testing.txt'', 'r')
f.readlines()
If you're running this in an interactive interpreter, I would
On Tue, May 24, 2011 at 6:31 PM, Cathy James wrote:
> s = input ('enter name: ').strip()
Are you using Python 2 or Python 3? If it's Python 2, this should be
raw_input().
> f = open ('c:/testing.txt', 'a')
> ...
> f = open ('c:/testing.txt', 'r')
You may be having trouble here a
Varuna Seneviratna wrote:
Now How shall I uninstalled
python 3.2?
Now, how shall I remove Python 3.2 ?
... very carefully.
It might be nice if there were a label in the Makefile so this would work:
sudo make removeall
... but alas,why do you want to un-install Python3.2 ?
-
On Tue, May 24, 2011 at 5:00 PM, Octavian Rasnita wrote:
> And you are telling that in Perl should be used an even more complicated and
> ugly syntax just for beeing the same as in Python just for showing that I am
> wrong, but I was comparing just the shortness and cleraness of the code.
>
> So,
On Tue, May 24, 2011 at 1:31 AM, Cathy James wrote:
> dear mentor,
>
> I need help with my code:
In addition to what others have already said...
> please see my attempt below and help:
>
> #1) open file and display current file contents:
> f = open ('c:/testing.txt'', 'r')
> f.readlines()
> #2)
On Tue, May 24, 2011 at 7:03 PM, Larry Simons
wrote:
> On Tue 24/05/2011 04:11, Libby Moyer wrote:
>>
>> And the rhymes in Mikado!
>
> Are you referring to ablutioner, diminutioner and “you shun her” all rhymed
> with executioner?
>
Can't deny that they're grin-worthy!
(Or groan-worthy, I always
Varuna Seneviratna wrote:
Now How shall I uninstalled
python 3.2?
What --prefix did you use? default?
--
http://mail.python.org/mailman/listinfo/python-list
Cathy James wrote:
f = open ('c:/testing.txt'', 'r')
replace the double quote by a single quote.
JM
--
http://mail.python.org/mailman/listinfo/python-list
On Tue, 24 May 2011 09:00:14 +0300
"Octavian Rasnita" wrote:
> So, again, in Perl is just:
>
> %d = @l;
>
> Please tell me if Python has a syntax which is more clear than this for
> doing this thing.
How is that clear? "Shorter" != "clearer." A Python programmer
looking at that sees line noi
On Tue, 24 May 2011 00:17:55 -0500
John Bokma wrote:
> > $d = @a;
>
> That will give you the number of elements in @a. What you (probably)
> mean is %hash = @array;
If I was even considering using Perl, this one exchange would send me
screaming in the opposite direction.
--
D'Arcy J.M. Cain
Hello,
I have a program that uses pyside for an QT interface and a thread that
downloads a lot of files. The thread is created with QThread object. But
my problem I don't think it's QT related.
The thread retrieves with pycurl a file that contains a list of files
and start to downloads them.
TheSaint writes:
> self.handle= \
> xmlrpclib.ServerProxy('http://localhost:%s/rpc' %int(self.numport))
Couldn't you just try to call something via this handle, like
self.handle.aria2.getVersion()? If there's an error, then start aria2
as a daemon and try again.
--
http://mail.
Hello all. I have Python 2.71 installed on my Windows 7 laptop and it
runs fine. I was having a problem with Python 3.2, 32bit, not starting
with an error message saying this application has quit abnormally.
That was fixed when I took the PYTHONPATH statement out of my
environment variables. Howeve
On 24/05/2011 11:01, Claudiu Nicolaie CISMARU wrote:
The problem appears when I close the called program (in our case
calc.exe). The (1) part (the call of os.rename) raise an exception:
(32, 'The process cannot access the file because it is being used by
another process')
[Error 32] The process
* 2011-05-24T06:05:35-04:00 * D'Arcy J. M. Cain wrote:
> On Tue, 24 May 2011 09:00:14 +0300
> "Octavian Rasnita" wrote:
>> %d = @l;
>>
>> Please tell me if Python has a syntax which is more clear than this
>> for doing this thing.
>
> How is that clear? "Shorter" != "clearer." A Python programme
Anssi Saari wrote:
> Couldn't you just try to call something via this handle, like
> self.handle.aria2.getVersion()? If there's an error, then start aria2
> as a daemon and try again.
>
Very good, you're right. Furthermore I should avoid to call that function
several times. I think to join it w
On 5/22/11 3:44 AM, Octavian Rasnita wrote:
Somebody told that C# and Objective C are good languages. They might be good,
but they are proprietary, and not only that they are proprietary, but they need
to be ran under platforms that cannot be used freely, so from the freedom point
of view, Per
On 20/05/2011 12:26, Ayaskanta Swain wrote:
> Thanks for the reply and suggestions. I followed the patch provided by
> you in issue 2528, but the code looks very tricky to me.
OK, first a summary of the discussion on the python-dev thread.
Essentially it was felt that os.access was sufficiently s
On Wed, May 25, 2011 at 12:09 AM, Kevin Walzer wrote:
> Proprietary?
>
> Licensing options for C# in its Mono (Free Platform) implementation:
>
> http://www.mono-project.com/Licensing
>
> Licensing options for Objective-C in its GNUStep (Free Platform)
> implementaiton
>
> http://www.gnustep.org/i
On 5/24/11 2:23 AM, Stefan Behnel wrote:
Beliavsky, 20.05.2011 18:39:
I thought this essay on why one startup chose Python was interesting.
Since everyone seems to be hot flaming at their pet languages in this
thread, let me quickly say this:
Thanks for sharing the link.
Stefan
I kind of
Hi:
I am learning Python on my own using a " Guide to Programming with Python"
book. Author of the book is Micheal Dawson and I am using version 2.3.5 of
python. When I try to run the code I do not get required results. The picture
could not be loaded. I get trackback message regarding undefi
On Wed, May 25, 2011 at 1:17 AM, SKHUMBUZO ZIKHALI
wrote:
> The example from the book is as follows:
>
> from liveswires import games
I think this might be meant to say "livewires". Presumably you did
install this package? If not, it won't work (but even if you have, it
won't work as "liveswires"
s = "C:\AciiCsv\Gravity_Test_data\A.csv"
f = open(s,"r")
How do I obtain the full pathname given the File, f? (which should
equal "C:\AciiCsv\Gravity_Test_data"). I've tried all sorts of stuff
and am just not finding it. Any help greatly appreciated !
--
http://mail.python.org/mailman/listinfo/py
* SKHUMBUZO ZIKHALI [110524 07:26]:
> Hi:
>
> I am learning Python on my own using a " Guide to Programming with Python"
> book. Author of the book is Micheal Dawson and I am using version 2.3.5 of
> python. When I try to run the code I do not get required results. The
> picture
> could not
On 24/05/2011 16:36, RVince wrote:
s = "C:\AciiCsv\Gravity_Test_data\A.csv"
f = open(s,"r")
How do I obtain the full pathname given the File, f? (which should
equal "C:\AciiCsv\Gravity_Test_data"). I've tried all sorts of stuff
and am just not finding it. Any help greatly appreciated !
You're
Ha! You;re right -- but is there a way to get it without the filename
appended at the end?
On May 24, 11:52 am, Tim Golden wrote:
> On 24/05/2011 16:36, RVince wrote:
>
> > s = "C:\AciiCsv\Gravity_Test_data\A.csv"
> > f = open(s,"r")
>
> > How do I obtain the full pathname given the File, f? (whi
Tim Golden wrote:
> On 24/05/2011 16:36, RVince wrote:
>> s = "C:\AciiCsv\Gravity_Test_data\A.csv"
>> f = open(s,"r")
>>
>> How do I obtain the full pathname given the File, f? (which should
>> equal "C:\AciiCsv\Gravity_Test_data"). I've tried all sorts of stuff
>> and am just not finding it. Any
On Wed, May 25, 2011 at 2:04 AM, RVince wrote:
> Ha! You;re right -- but is there a way to get it without the filename
> appended at the end?
Parse the file name with the os.path functions:
http://docs.python.org/library/os.path.html
Chris Angelico
--
http://mail.python.org/mailman/listinfo/py
On 24/05/2011 17:04, RVince wrote:
Ha! You;re right -- but is there a way to get it without the filename
appended at the end?
Well, just use the functions in os.path, specifically os.path.dirname...
TJG
--
http://mail.python.org/mailman/listinfo/python-list
RVince wrote:
Ha! You;re right -- but is there a way to get it without the filename
appended at the end?
On May 24, 11:52 am, Tim Golden wrote:
On 24/05/2011 16:36, RVince wrote:
s = "C:\AciiCsv\Gravity_Test_data\A.csv"
f = open(s,"r")
How do I obtain the full pathname given t
From: "D'Arcy J.M. Cain"
> On Tue, 24 May 2011 09:00:14 +0300
> "Octavian Rasnita" wrote:
>> So, again, in Perl is just:
>>
>> %d = @l;
>>
>> Please tell me if Python has a syntax which is more clear than this for
>> doing this thing.
>
> How is that clear? "Shorter" != "clearer." A Python
From: "D'Arcy J.M. Cain"
> On Tue, 24 May 2011 00:17:55 -0500
> John Bokma wrote:
>> > $d = @a;
>>
>> That will give you the number of elements in @a. What you (probably)
>> mean is %hash = @array;
>
> If I was even considering using Perl, this one exchange would send me
> screaming in the opp
From: "Daniel Kluev"
> On Tue, May 24, 2011 at 5:00 PM, Octavian Rasnita wrote:
>> And you are telling that in Perl should be used an even more complicated and
>> ugly syntax just for beeing the same as in Python just for showing that I am
>> wrong, but I was comparing just the shortness and cler
From: "Kevin Walzer"
> On 5/22/11 3:44 AM, Octavian Rasnita wrote:
>> Somebody told that C# and Objective C are good languages. They might be
>> good, but they are proprietary, and not only that they are proprietary, but
>> they need to be ran under platforms that cannot be used freely, so from
Subject: Re: Why did Quora choose Python for its development?
> I've been programming for about seven years, and am basically
> self-taught. I got my first taste of writing code when trying do to some
> basic hacking on my (then) shiny new G3 iBook. (Even though it was a
> Mac, I was enthralled
On 5/24/2011 8:01 AM, markrri...@aol.com wrote:
Hello all. I have Python 2.71 installed on my Windows 7 laptop and it
runs fine. I was having a problem with Python 3.2, 32bit, not starting
with an error message saying this application has quit abnormally.
That was fixed when I took the PYTHONPATH
Teemu Likonen writes:
> * 2011-05-24T06:05:35-04:00 * D'Arcy J. M. Cain wrote:
>
>> On Tue, 24 May 2011 09:00:14 +0300
>> "Octavian Rasnita" wrote:
>>> %d = @l;
>>>
>>> Please tell me if Python has a syntax which is more clear than this
>>> for doing this thing.
>>
>> How is that clear? "Shorte
"D'Arcy J.M. Cain" writes:
> On Tue, 24 May 2011 00:17:55 -0500
> John Bokma wrote:
>> > $d = @a;
>>
>> That will give you the number of elements in @a. What you (probably)
>> mean is %hash = @array;
>
> If I was even considering using Perl, this one exchange would send me
> screaming in the op
I'm quoting a message that I received on personal address and wasn't
sent to list:
>
> try adding argument close_fds=True to subprocess.Popen
>
> harish
>
And Tim's message:
> It's not quite clear from your description above whether you
> can be sure that the called subprocess has closed all
On Tue, 24 May 2011 19:10:56 +0300
"Octavian Rasnita" wrote:
> > If I was even considering using Perl, this one exchange would send me
> > screaming in the opposite direction.
>
> If you didn't consider to change the language you prefer it means
> that you are closed minded and use to fell in lov
On Wed, May 25, 2011 at 2:50 AM, John Bokma wrote:
> Wise words. And I agree. To me Python vs. Perl has nothing to do with
> being a fanboy (unlike many other posters here). I like both languages,
> I have invested a lot of time in learning Python and I am really not
> dense. Yet, even though I ca
On Tue, 24 May 2011 11:52:39 -0500
John Bokma wrote:
> >> > $d = @a;
> >>
> >> That will give you the number of elements in @a. What you (probably)
> >> mean is %hash = @array;
> >
> > If I was even considering using Perl, this one exchange would send me
> > screaming in the opposite direction.
>
On May 23, 9:28 pm, Chris Angelico wrote:
> On Tue, May 24, 2011 at 2:20 PM, Xah Lee wrote:
> > why don't you file a bug report? In GNU Emacs 23.2, it's under the
> > Help menu. I suppose it's the same in other emacs distro.
>
> Because I do not consider its behaviour to be errant. And I suspect
Chris Angelico writes:
> On Wed, May 25, 2011 at 2:50 AM, John Bokma wrote:
>> Wise words. And I agree. To me Python vs. Perl has nothing to do with
>> being a fanboy (unlike many other posters here). I like both languages,
>> I have invested a lot of time in learning Python and I am really not
"D'Arcy J.M. Cain" writes:
> On Tue, 24 May 2011 11:52:39 -0500
> John Bokma wrote:
>> >> > $d = @a;
>> >>
>> >> That will give you the number of elements in @a. What you (probably)
>> >> mean is %hash = @array;
>> >
>> > If I was even considering using Perl, this one exchange would send me
>>
TJG- that solved the printing issue!! Many thanks:)
Thanks to Chris and Jean Michel for your hints.
On Tue, May 24, 2011 at 4:07 AM, wrote:
> Send Python-list mailing list submissions to
>python-list@python.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>http:
--
http://mail.python.org/mailman/listinfo/python-list
If a filename does not contain a path component, os.path.abspath will prepend
the current directory path onto it.
--
http://mail.python.org/mailman/listinfo/python-list
From: "John Bokma"
"Octavian Rasnita" writes:
From: "Daniel Kluev"
a = [1,2]
dict([a])
Yes, but
d = dict([a])
is not so nice as
$d = @a;
That will give you the number of elements in @a. What you (probably)
mean is %hash = @array;
Of course. Thank you for correction.
Octavian
--
h
Hello all,
Please review the code pasted below. I am wondering what other ways
there are of performing the same tasks. This was typed using version
3.2. The script is designed to clean up a directory (FTP, Logs, etc.)
Basically you pass two arguments. The first argument is an number of
days old to
On Tue, 24 May 2011 12:50:47 -0400, Terry Reedy
wrote:
>On 5/24/2011 8:01 AM, markrri...@aol.com wrote:
>> Hello all. I have Python 2.71 installed on my Windows 7 laptop and it
>> runs fine. I was having a problem with Python 3.2, 32bit, not starting
>> with an error message saying this applicati
> Seems that close_fds did the trick. Anyway, I read that description on
> the documentation last night but I think I was so tired that I
> understood that in Windows has no effect... :)
Now. There is one more issue. Seems that on faster computers and/or
Windows 7 (the Win32 thing I have tested
Ok, another time I'd like to thank you for your help. I gave up, I'm going to
get used to IDLE GUI... at least this one works!
--
http://mail.python.org/mailman/listinfo/python-list
On May 24, 12:27 am, Deeyana wrote:
>
> Classic unsubstantiated and erroneous claim. Scheme does not come OOTB
> with any suitable libraries for host interop and though it can make calls
> to C libraries, doing so is awkward and involves difficulties with the
> impedance mismatch between Scheme's
On Wed, May 25, 2011 at 3:56 AM, John Bokma wrote:
> Chris Angelico writes:
>> To me, a language is a tool.
>
> To me, and to a lot of Perl programmers it's not different.
>
>> The more tools you have competence with, the easier it will be to
>> select the right one for any job. There are very fe
On 5/24/2011 4:12 PM, markrri...@aol.com wrote:
On Tue, 24 May 2011 12:50:47 -0400, Terry Reedy
How do you try to start it?
From start|programs|python and clicking on the idle icon.
OK. Works fine for me on winxp desktop and win7 laptop.
3.2.1 will be out soon. Whether or not you find a fix
On Wed, May 25, 2011 at 3:39 AM, D'Arcy J.M. Cain wrote:
> My point was that even proponents of the language can make a
> significant error based on the way the variable is named. It's like
> the old Fortran IV that I first learned where the name of the variable
> determined whether it was an int
On 5/24/2011 4:18 PM, Claudiu Nicolaie CISMARU wrote:
Seems that close_fds did the trick. Anyway, I read that description on
the documentation last night but I think I was so tired that I
understood that in Windows has no effect... :)
Now. There is one more issue. Seems that on faster computers
Chris Angelico writes:
> On Wed, May 25, 2011 at 3:56 AM, John Bokma wrote:
>> Chris Angelico writes:
>>> To me, a language is a tool.
>>
>> To me, and to a lot of Perl programmers it's not different.
>>
>>> The more tools you have competence with, the easier it will be to
>>> select the right
On Tue, 24 May 2011 17:53:53 -0400, Terry Reedy
wrote:
>On 5/24/2011 4:12 PM, markrri...@aol.com wrote:
>> On Tue, 24 May 2011 12:50:47 -0400, Terry Reedy
>>> How do you try to start it?
>>
>>> From start|programs|python and clicking on the idle icon.
>
>OK. Works fine for me on winxp desktop and
On Wed, May 25, 2011 at 3:40 AM, Xah Lee wrote:
> On May 23, 9:28 pm, Chris Angelico wrote:
>> Because I do not consider its behaviour to be errant. And I suspect
>> its main developers won't either. That's why I suggested you grab the
>> sources and make The Perfect Emacs.
>
> why don't you try
Here's my background:
I'm a Windows based Visual FoxPro developer, and I want to start programming
in Python. I'll be sticking to Windows (XP & 7) and my immediate needs are
to manage & display large groups of jpg's, tiff's etc... so I need form
based & graphics capable libraries (in addition to b
On Tue, May 24, 2011 at 8:27 AM, Deeyana wrote:
> Classic unsubstantiated and erroneous claim. Scheme does not come OOTB
> with any suitable libraries for host interop and though it can make calls
> to C libraries, doing so is awkward and involves difficulties with the
> impedance mismatch between
Chris Angelico writes:
> On Wed, May 25, 2011 at 3:39 AM, D'Arcy J.M. Cain wrote:
>> My point was that even proponents of the language can make a
>> significant error based on the way the variable is named. It's like
>> the old Fortran IV that I first learned where the name of the variable
>> d
On Wed, May 25, 2011 at 9:16 AM, John Bokma wrote:
> Chris Angelico writes:
>
>> Yes, I believe that was Perl. And an amusing quote. But most of the
>> point of it comes from the fact that Perl uses punctuation for most of
>> its keywords,
>
> For example?
>
>> whereas (say) Python uses English w
On May 17, 8:50 am, RJB wrote:
> I noticed some discussion of recursion. the trick is to find a
> formula where the arguments are divided, not decremented.
> I've had a "divide-and-conquer" recursion for the Fibonacci numbers
> for a couple of years in C++ but just for fun rewrote it
> in Pyth
On 2011-05-24, Steven D'Aprano wrote:
>>> I think that is a patronizing remark that under-estimates the
>>> intelligence of lay people and over-estimates the difficulty of
>>> understanding recursion.
>>
>> Why would you presume this to be related to intelligence? The point was
>> not about being
On Tue, 24 May 2011 13:39:15 -0700, asandroq wrote:
> On May 24, 12:27 am, Deeyana wrote:
>>
>> Classic unsubstantiated and erroneous claim. Scheme does not come OOTB
>> with any suitable libraries for host interop and though it can make
>> calls to C libraries, doing so is awkward and involves d
I'm starting to feel incredibly stupid here. Hopefully someone can
point out a really obvious thing that I've missed, thus enabling me to
move forward!
Up until now, I've been embedding Python 2.6.6 in my C++ program, by
compiling with "-I/usr/include/python2.6 -lpython2.6", and all has
been well.
What is mrjob?
-
mrjob is a Python package that helps you write and run Hadoop Streaming jobs.
mrjob fully supports Amazon's Elastic MapReduce (EMR) service, which
allows you to buy time on a Hadoop cluster on an hourly basis. It also
works with your own Hadoop cluster.
Some impor
On 05/24/2011 03:17 PM, Lew Schwartz wrote:
Here's my background:
I'm a Windows based Visual FoxPro developer, and I want to start
programming in Python. I'll be sticking to Windows (XP & 7) and my
immediate needs are to manage & display large groups of jpg's, tiff's
etc... so I need form based
On Wed, May 25, 2011 at 8:06 AM, Rikishi42 wrote:
> On 2011-05-24, Steven D'Aprano wrote:
> Why not use 'delete a directory'. It's obvious the content gets binned, too.
Which is why I raised the issue with regard to other operations.
Manipulating files matching a glob can be done recursively or
Chris Angelico writes:
> On Wed, May 25, 2011 at 9:16 AM, John Bokma wrote:
>> Chris Angelico writes:
>>
>>> Yes, I believe that was Perl. And an amusing quote. But most of the
>>> point of it comes from the fact that Perl uses punctuation for most of
>>> its keywords,
>>
>> For example?
>>
>>>
John Lee writes:
> In this thread, I'm asking about the views of Python programmers on
> languages other than Python.
I sympathize with what you're looking for but I don't think there's
a really good answer at this time. Things IMO are converging in the
direction of functional languages like H
On May 24, 3:06 pm, Rikishi42 wrote:
> On 2011-05-24, Steven D'Aprano wrote:
>
> >>> I think that is a patronizing remark that under-estimates the
> >>> intelligence of lay people and over-estimates the difficulty of
> >>> understanding recursion.
>
> >> Why would you presume this to be related t
So, if I read between the lines correctly, you recommend Python 3? Does the
windows version install with a development environment?
--
http://mail.python.org/mailman/listinfo/python-list
79 matches
Mail list logo