Re: How to "wow" someone new to Python

2015-01-18 Thread alex23
On 17/01/2015 1:03 AM, Chris Angelico wrote: Scenario: You're introducing someone to Python for the first time. S/he may have some previous programming experience, or may be new to the whole idea of giving a computer instructions. You have a couple of minutes to show off how awesome Python is. Wh

Re: Attribute error

2015-01-18 Thread Rustom Mody
On Monday, January 19, 2015 at 5:02:01 AM UTC+5:30, Steven D'Aprano wrote: > Mahendra Prajapati wrote: > > > Hello, > > I'm facing this problem with python class, while practising the python > > programming language.It creates an attribute error. I use windows 7 OS. i > > don't why.I just need to

multiprocessing.Queue & vim python interpreter

2015-01-18 Thread unknown3000
Hi, I am experimenting on a fork of vim-plug for managing vim plugins. I wanted to add parallel update support for python since ruby isn't nearly as common. I've come across a weird bug that only seems to happen when I'm inside vim, I'm wondering if someone could tell me why. This problem can

Re: Attribute error

2015-01-18 Thread Steven D'Aprano
Mahendra Prajapati wrote: > Hello, > I'm facing this problem with python class, while practising the python > programming language.It creates an attribute error. I use windows 7 OS. i > don't why.I just need to know why it gives such an error.please let me > know. Regards An attribute error is a

Re: Attribute error

2015-01-18 Thread Denis McMahon
On Sun, 18 Jan 2015 20:50:49 +, Mahendra Prajapati wrote: > Hello, > I'm facing this problem with python class, while practising the python > programming language.It creates an attribute error. I use windows 7 OS. > i don't why.I just need to know why it gives such an error.please let me > kno

Re: Attribute error

2015-01-18 Thread Chris Angelico
On Mon, Jan 19, 2015 at 7:50 AM, Mahendra Prajapati wrote: > I'm facing this problem with python class, while practising the python > programming language.It creates an attribute error. > I use windows 7 OS. i don't why. > I just need to know why it gives such an error. > please let me know. It'

Re: Hello World

2015-01-18 Thread Marko Rauhamaa
Chris Angelico : > On Sun, Jan 18, 2015 at 9:03 PM, Marko Rauhamaa wrote: >> I believe passwords themselves are the wrong solution. I believe in a >> physical, government-issue object capable of challenge-response. It >> can then be beefed up with extra measures depending on the need. > > I can't

Attribute error

2015-01-18 Thread Mahendra Prajapati
Hello, I'm facing this problem with python class, while practising the python programming language.It creates an attribute error. I use windows 7 OS. i don't why.I just need to know why it gives such an error.please let me know. Regards -- https://mail.python.org/mailman/listinfo/python-list

Re: Hello World

2015-01-18 Thread Michael Ströder
Marko Rauhamaa wrote: > Michael Ströder : > >> Marko Rauhamaa wrote: >>> I believe in a >>> physical, government-issue object >> >> Did you forget the smiley? Or where were you during the last 1,5 years? > > You can juggle the issues all you want. In the end, there's

Re: Formatting string with accented characters for printing

2015-01-18 Thread Peter Otten
Jerry Rocteur wrote: > When I try and format output when there are accented characters the > output does not look right. > > e.g. > > 27 Angie Dickons 67,638 > 28 Anne MÉRESSE 64,825 > > So the strings containing accented characters print one less than > th

Re: Formatting string with accented characters for printing

2015-01-18 Thread Chris Angelico
On Mon, Jan 19, 2015 at 3:04 AM, Jerry Rocteur wrote: > > I've tried both: > > print '{0:2} {1:25} {2} '.format( cnt, nam[num].encode('utf-8'), > steps[ind1]) > print "%3d %-25s %-7s" % ( cnt, nam[num].encode('utf-8'), steps[ind1]) > > I've searched but I can't see a solution.. > > I guess

Re: Trying to parse matchup.io (lxml, SGMLParser, urlparse)

2015-01-18 Thread Peter Otten
Jerry Rocteur wrote: > Hi, > > I'm trying to parse https://matchup.io/players/rocteur/friends > > The body source I'm interested in contains blocks exactly like this > > > > src="https://matchup-io.s3.amazonaws.com/uploads/player/avatar/7651/7651_profile_150_square.jpeg"; > /> > > mizucci0

Formatting string with accented characters for printing

2015-01-18 Thread Jerry Rocteur
Hi, When I try and format output when there are accented characters the output does not look right. e.g. 27 Angie Dickons 67,638 28 Anne MÉRESSE 64,825 So the strings containing accented characters print one less than those that don't. I've tried both:

Re: Hello World

2015-01-18 Thread Chris Angelico
On Mon, Jan 19, 2015 at 2:48 AM, Michael Ströder wrote: >> For instance, someone could join my wifi >> network - all they need is the WPA2 PSK, which is well known around >> the place - and use/abuse our internet connection; but they couldn't >> access my PostgreSQL databases, because the firewall

Re: How to use Pycharm to display the stack and heap python?

2015-01-18 Thread Mark Lawrence
On 18/01/2015 16:45, Jo Barton wrote: I am new to programming. Difficult for me to understand code using http://www.pythontutor.com/visualize.html#. How to use Pycharm to display the stack and heap python? Hello and welcome :) As you are new to programming please abandon all thoughts of loo

How to use Pycharm to display the stack and heap python?

2015-01-18 Thread Jo Barton
I am new to programming. Difficult for me to understand code using http://www.pythontutor.com/visualize.html#. How to use Pycharm to display the stack and heap python? -- https://mail.python.org/mailman/listinfo/python-list

Trying to parse matchup.io (lxml, SGMLParser, urlparse)

2015-01-18 Thread Jerry Rocteur
Hi, I'm trying to parse https://matchup.io/players/rocteur/friends The body source I'm interested in contains blocks exactly like this https://matchup-io.s3.amazonaws.com/uploads/player/avatar/7651/7651_profile_150_square.jpeg"; /> mizucci0 Mizuho 29,646 steps 35,315 steps 818.7 Mil

Re: Hello World

2015-01-18 Thread Chris Angelico
On Sun, Jan 18, 2015 at 9:03 PM, Marko Rauhamaa wrote: > Michael Torrie : > >> Most password policies are the wrong solution. > > I believe passwords themselves are the wrong solution. I believe in a > physical, government-issue object capable of challenge-response. It can > then be beefed up with

Re: Hello World

2015-01-18 Thread Marko Rauhamaa
Michael Ströder : > Marko Rauhamaa wrote: >> I believe in a >> physical, government-issue object > > Did you forget the smiley? Or where were you during the last 1,5 years? You can juggle the issues all you want. In the end, there's no escaping the governments' underw

Re: Hello World

2015-01-18 Thread Michael Ströder
Chris Angelico wrote: > On Mon, Jan 19, 2015 at 12:35 AM, Michael Ströder > wrote: >> Chris Angelico wrote: >>> Want security? >>> Push the encryption and authentication down to a lower layer, and save >>> yourself the trouble. >> >> Yes. And now for the next level: How to prevent unauthorized ma

Re: Hello World

2015-01-18 Thread Chris Angelico
On Mon, Jan 19, 2015 at 12:35 AM, Michael Ströder wrote: > Chris Angelico wrote: >> Want security? >> Push the encryption and authentication down to a lower layer, and save >> yourself the trouble. > > Yes. And now for the next level: How to prevent unauthorized machines to > connect to your netwo

Re: Hello World

2015-01-18 Thread Michael Ströder
Chris Angelico wrote: > Want security? > Push the encryption and authentication down to a lower layer, and save > yourself the trouble. Yes. And now for the next level: How to prevent unauthorized machines to connect to your network… Ciao, Michael. -- https://mail.python.org/mailman/listinfo/py

Re: Hello World

2015-01-18 Thread Michael Ströder
Marko Rauhamaa wrote: > I believe in a > physical, government-issue object Did you forget the smiley? Or where were you during the last 1,5 years? Ciao, Michael. -- https://mail.python.org/mailman/listinfo/python-list

Re: Hello World

2015-01-18 Thread Michael Ströder
Steven D'Aprano wrote: > Mark Lawrence wrote: > >> Bah humbug, this has reminded me of doing secure work whereby each >> individual had two passwords, both of which had to be changed every >> thirty days, and rules were enforced so you couldn't just increment the >> number at the end of a word or

Re: Hello World

2015-01-18 Thread Michael Ströder
Michael Torrie wrote: > Like many of you I use a password manager these days. It's pretty > slick. But really it shows the absurdity of the situation. Instead of > passwords we should all just use private/public keypairs and store the > private keys in a digital wallet. Forget this password gar

Re: Hello World

2015-01-18 Thread Roy Smith
In article <54bb2c5f$0$12977$c3e8da3$54964...@news.astraweb.com>, Steven D'Aprano wrote: > You know that two-factor authentication doesn't offer any real security > against Man In The Middle attacks? The fact that TFA doesn't solve all problems doesn't change the fact that it solves some of th

[Annonce] Une introduction à Python 3 - nouvelle version

2015-01-18 Thread Laurent Pointal
[updated book in french] Bonjour, L'ouvrage d'introduction à la programmation avec Python3 de B.Cordeau et L.Pointal a été mis à jour en version 1.618. Outre des améliorations dans la mise en page, les modifications suivantes ont été réalisées: * Tous les dessins ont été refaits en utilisant l

Re: numpy.allclose()

2015-01-18 Thread Steven D'Aprano
Ian Kelly wrote: > On Sat, Jan 17, 2015 at 8:09 PM, Steven D'Aprano > wrote: >> I'm guessing that can only have come from the mindset of C/C++ >> programmers, where this sort of thing is considered acceptable: > > Maybe. The journal reference in the second link I posted dates the > practice back

Re: Hello World

2015-01-18 Thread Marko Rauhamaa
Michael Torrie : > Most password policies are the wrong solution. I believe passwords themselves are the wrong solution. I believe in a physical, government-issue object capable of challenge-response. It can then be beefed up with extra measures depending on the need. Marko -- https://mail.pyt

Re: Hello World

2015-01-18 Thread Chris Angelico
On Sun, Jan 18, 2015 at 1:13 PM, Michael Torrie wrote: > Like many of you I use a password manager these days. It's pretty > slick. But really it shows the absurdity of the situation. Instead of > passwords we should all just use private/public keypairs and store the > private keys in a digital

Re: Hello World

2015-01-18 Thread Michael Torrie
On 01/17/2015 05:04 PM, Chris Angelico wrote: > Related to that is another reason I've heard: if your password is > figured out by some means other than hash theft [1], there's a maximum > of N days to make use of it. But let's face it, if someone gets hold > of one of your accounts, it won't take

Re: Hello World

2015-01-18 Thread Jason Friedman
> > > Password maximum age is the wrong solution to a few problems, and is > itself a problem. Don't do it. > > Bruce Schneier (mostly) agrees with you: https://www.schneier.com/blog/archives/2010/11/changing_passwo.html. -- https://mail.python.org/mailman/listinfo/python-list

Re: numpy.allclose()

2015-01-18 Thread Ian Kelly
On Sat, Jan 17, 2015 at 8:09 PM, Steven D'Aprano wrote: > I'm guessing that can only have come from the mindset of C/C++ programmers, > where this sort of thing is considered acceptable: Maybe. The journal reference in the second link I posted dates the practice back to at least 1975, a time pred