Re: I'm getting a spamassassin party here

2018-06-25 Thread Cameron Simpson
On 24Jun2018 17:03, Gene Heskett wrote: Greetings list; Generally spamassassin only gets picky about this occasionally, but for the past several hours its working overtime on python list messages, with the major problem being the servers time stamp, a day or more in the past. Anyboy ever hear o

Re: Proper way to download stylesheets and templates

2018-06-25 Thread T Berger
On Monday, June 25, 2018 at 12:12:26 PM UTC-4, T Berger wrote: > I’m creating a webapp and trying to download a stylesheet and templates from > my manual’s support site. I must be doing something wrong, because when I try > to run my app, I get a 404 error message. I downloaded the files by dragg

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Steven D'Aprano
On Mon, 25 Jun 2018 18:22:56 +, Grant Edwards wrote: > On 2018-06-24, Steven D'Aprano wrote: > >> Building functions is cheap. Cheap is not free. >> >> Inner functions that aren't exposed to the outside cannot be tested in >> isolation, you can't access them through help() interactively. Giv

Re: syntax difference

2018-06-25 Thread boB Stepp
On Mon, Jun 25, 2018 at 2:37 AM Mark Lawrence wrote: > > On 24/06/18 00:44, boB Stepp wrote: > > I imagine that the > > transition from version 2 to 3 was not undertaken halfheartedly, but > > only after much thought and discussion since it did break backwards > > compatibility. > > > > So much so

Re: syntax difference

2018-06-25 Thread Chris Angelico
On Tue, Jun 26, 2018 at 6:04 AM, Grant Edwards wrote: > On 2018-06-24, Steven D'Aprano wrote: > >> That's nothing, there are languages where the standard way to write >> a for loop is to call an external program that generates a stream of >> numeric strings separated by spaces in a subprocess, an

Re: syntax difference

2018-06-25 Thread Grant Edwards
On 2018-06-24, Steven D'Aprano wrote: > That's nothing, there are languages where the standard way to write > a for loop is to call an external program that generates a stream of > numeric strings separated by spaces in a subprocess, and read the > strings from standard input as text. What langu

Re: range

2018-06-25 Thread Schachner, Joseph
Re: "I know I'm going to get flak for bringing this up this old issue, but remember when you used to write a for-loop and it involved creating an actual list of N integers from 0 to N-1 in order to iterate through them? Crazy. But that has long been fixed - or so I thought. When I wrote, today:

Re: Accessing the Python list

2018-06-25 Thread Abdur-Rahmaan Janhangeer
i would prefer everyone using the mailing list (misses many spams) but of course that is a crazy idea (no need to reply with brain-damaged by facebook, aol, gmail etc expressions) Abdur-Rahmaan Janhangeer https://github.com/Abdur-rahmaanJ > -- https://mail.python.org/mailman/listinfo/python-li

Re: Where's the junk coming from?

2018-06-25 Thread Mark Lawrence
On 24/06/18 21:39, Mark Lawrence wrote: Hi folks, In the last hour or so I've seen via thunderbird and gmane around 15 emails from various people where the from field is name@1261/38.remove-r7u-this.  The part after the @ symbol never changes.  I've seen the contents previously, apart from on

wily+python=NNTPclient ?

2018-06-25 Thread qhsgrant
Gary Capell who designed wily [in the 90s] mentioned that it could interface with python to make a NNTP client. As a daily user of wily, I seek info on connecting with python to get NNTP service. == TIA. -- https://mail.python.org/mailman/listinfo/python-list

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Marko Rauhamaa
Grant Edwards : > IOW, you use a local function instead of a global one for the exact > same reasons you use local "variables" instead of global ones. > > In Python, functions are first class objects. Binding a name to a > function is no different than binding it to an integer, list, string, > or

Re: Package directory question

2018-06-25 Thread Robert Latest via Python-list
Ben Finney wrote: > Robert Latest via Python-list writes: > >> Because the main.py script needs to import the tables.py module from >> backend, I put this at the top if main.py: >> >>sys.path.append('../..') >>import jobwatch.backend.tables as tables >> >> My question is: Is this the way i

Re: Where's the junk coming from?

2018-06-25 Thread José María Mateos
On Sun, Jun 24, 2018 at 09:39:33PM +0100, Mark Lawrence wrote: > Hi folks, > > In the last hour or so I've seen via thunderbird and gmane around 15 > emails from various people where the from field is > name@1261/38.remove-r7u-this. The part after the @ symbol never > changes. I've seen the cont

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Grant Edwards
On 2018-06-24, Steven D'Aprano wrote: > Building functions is cheap. Cheap is not free. > > Inner functions that aren't exposed to the outside cannot be tested > in isolation, you can't access them through help() > interactively. Given the choice between: [...] > so not expensive, but not free

Re: syntax difference

2018-06-25 Thread Bart
To: boB Stepp From: Bart On 24/06/2018 16:37, boB Stepp wrote: > On Sun, Jun 24, 2018 at 5:21 AM Bart wrote: > "... And of course, you would have to know how to use Python properly in > idiomatic style. No. I want to program in /my/ style, one more like the pseudo-code that was mentioned els

Re: moving to Python from Java/C++/C

2018-06-25 Thread Chris Angelico
On Tue, Jun 26, 2018 at 2:35 AM, Dan Stromberg wrote: > On Mon, Jun 25, 2018 at 3:40 AM, wrote: > >> Hey, >> I already have quite an experience in programming, and I wish to study >> Python as well. I need to study it before I continue with my comp. science >> academic studies. >> How do you reco

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Abdur-Rahmaan Janhangeer
From: Abdur-Rahmaan Janhangeer see for example https://en.m.wikipedia.org/wiki/Bresenham%27s_line_algorithm see the pseudocode, i was implementing some raster algos when i found myself aux anges so close to py. i guess it was written in prehistoric times with the author trying to simplify stuf

Re: Anyone here on Python-Dev mailing list?

2018-06-25 Thread Abdur-Rahmaan Janhangeer
From: Abdur-Rahmaan Janhangeer i follow the dev list so far no but that particular mail might be related to pythan rather than random messages over the times i've talked to users of other langs (academics) one of the fault they find with python is the virtual env setup, too boring a task. env

Anyone here on Python-Dev mailing list?

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano Anyone on the Python-Dev mailing list, are you getting private emails containing nothing but stream of consciousness word-salad from somebody (some bot?) calling himself "Chanel Marvin" with a gmail address? Typical example: "I refuse to create my environment on a comp

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Mon, Jun 25, 2018 at 2:23 AM, Abdur-Rahmaan Janhangeer wrote: > Python is rightly called executable pseudocode. i appreciated the fact that > you can go on wikipaedia, find the pseudocode of algorithms remove curly > braces and replace by py's more powerful syntax and po

Re: syntax difference

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Mon, Jun 25, 2018 at 1:02 AM, Steven D'Aprano wrote: > On Mon, 25 Jun 2018 00:46:00 +1000, Chris Angelico wrote: > >> On Sun, Jun 24, 2018 at 8:40 PM, Steven D'Aprano >> wrote: >>> On Sun, 24 Jun 2018 11:18:37 +0100, Bart wrote: >>> I wonder why it is just me that c

Re: Anyone here on Python-Dev mailing list?

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Mon, 25 Jun 2018 02:15:42 +1000, Chris Angelico wrote: > On Mon, Jun 25, 2018 at 2:07 AM, Steven D'Aprano > wrote: >> Anyone on the Python-Dev mailing list, are you getting private emails >> containing nothing but stream of consciousness word-salad from somebody >> (som

Re: syntax difference

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sun, 24 Jun 2018 16:39:19 +0100, Bart wrote: > More like utter disbelief at how it works. Surely it cannot work like > that because it would be too inefficient? Apparently, yes it can... Apparently, no it doesn't, because the fact that Python is used by tens of thousand

Re: syntax difference

2018-06-25 Thread boB Stepp
From: boB Stepp On Sun, Jun 24, 2018 at 5:21 AM Bart wrote: > > On 24/06/2018 00:44, boB Stepp wrote: > > On Sat, Jun 23, 2018 at 5:35 PM Bart wrote: > > >> I'm not a user... > > > > Then I am truly puzzled, Bart. Why do you even bother to hang out on > > this list? If you do not want to use

Re: syntax difference

2018-06-25 Thread Rick Johnson
To: Steven D'Aprano From: Rick Johnson On Sunday, June 24, 2018 at 10:05:14 AM UTC-5, Steven D'Aprano wrote: [...] > Be fair. It's more like 50% of the time. Let's not dogpile > onto Bart. He asked a question, I answered it, we don't all > need to sink the boot in as well. And why am i _not_ s

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Abdur-Rahmaan Janhangeer
From: Abdur-Rahmaan Janhangeer Python is rightly called executable pseudocode. i appreciated the fact that you can go on wikipaedia, find the pseudocode of algorithms remove curly braces and replace by py's more powerful syntax and poof, suddenly it becomes too easy. Abdur-Rahmaan Janhangeer h

Re: syntax difference

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Mon, 25 Jun 2018 00:46:00 +1000, Chris Angelico wrote: > On Sun, Jun 24, 2018 at 8:40 PM, Steven D'Aprano > wrote: >> On Sun, 24 Jun 2018 11:18:37 +0100, Bart wrote: >> >>> I wonder why it is just me that constantly needs to justify his >>> existence in this group? >> >

Re: Anyone here on Python-Dev mailing list?

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Mon, Jun 25, 2018 at 2:07 AM, Steven D'Aprano wrote: > Anyone on the Python-Dev mailing list, are you getting private emails > containing nothing but stream of consciousness word-salad from somebody > (some bot?) calling himself "Chanel Marvin" with a gmail address? > > T

Re: Introducing Coconut

2018-06-25 Thread justin walters
From: justin walters On Sun, Jun 24, 2018 at 5:51 AM, Steven D'Aprano < steve+comp.lang.pyt...@pearwood.info> wrote: > Coconut, the functional programming language which compiles to Python: > > http://coconut.readthedocs.io/en/master/FAQ.html > > http://coconut-lang.org/ > > (Its not my language

Re: Introducing Coconut

2018-06-25 Thread Abdur-Rahmaan Janhangeer
From: Abdur-Rahmaan Janhangeer hum syntactic coating exists even in py. nice! Abdur-Rahmaan Janhangeer https://github.com/Abdur-rahmaanJ > > --- BBBS/Li6 v4.10 Toy-3 * Origin: Prism bbs (1:261/38) -- https://mail.python.org/mailman/listinfo/python-list

Re: syntax difference

2018-06-25 Thread Bart
To: Chris Angelico From: Bart On 24/06/2018 15:46, Chris Angelico wrote: > On Sun, Jun 24, 2018 at 8:40 PM, Steven D'Aprano > wrote: >> On Sun, 24 Jun 2018 11:18:37 +0100, Bart wrote: >> >>> I wonder why it is just me that constantly needs to justify his >>> existence in this group? >> >> Beca

Re: syntax difference

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sun, Jun 24, 2018 at 8:40 PM, Steven D'Aprano wrote: > On Sun, 24 Jun 2018 11:18:37 +0100, Bart wrote: > >> I wonder why it is just me that constantly needs to justify his >> existence in this group? > > Because its just you who spends 90% of his time here complaining abo

Introducing Coconut

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano Coconut, the functional programming language which compiles to Python: http://coconut.readthedocs.io/en/master/FAQ.html http://coconut-lang.org/ (Its not my language. I just think its cool.) -- Steven D'Aprano "Ever since I learned about confirmation bias, I've been see

Package directory question

2018-06-25 Thread Robert Latest
From: Robert Latest Hello, I'm building an application which consists of two largely distinct parts, a frontend and a backend. The directory layout is like this: |-- jobwatch | |-- backend | | |-- backend.py | | |-- __init__.py | | `-- tables.py | |-- frontend | | |-- __init

Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 14:52:24 -0500, boB Stepp wrote: [...] >> There is a place for various levels of programming language. I'm saying >> that Python which is always touted as a 'simple' language suitable for >> beginners, is missing a surprising number of basics. > > I stil

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Stefan Ram
To: Steven D'Aprano From: r...@zedat.fu-berlin.de (Stefan Ram) Steven D'Aprano writes: >It has been a long, long time since Python has been a "simple" language >suitable for rank beginners, if it ever was. Python is not Scratch. Python is simpler insofar as you can write on a higher level

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Bart
To: Ben Bacarisse From: Bart On 24/06/2018 01:53, Ben Bacarisse wrote: > Bart writes: >> Wow. (Just think of all the times you write a function containing a >> neat bunch of local functions, every time it's called it has to create >> a new function instances for each of those functions, even

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sun, 24 Jun 2018 11:23:12 +0100, Bart wrote: > On 24/06/2018 01:53, Ben Bacarisse wrote: >> Bart writes: > >>> Wow. (Just think of all the times you write a function containing a >>> neat bunch of local functions, every time it's called it has to create >>> a new functi

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Jim Lee
From: Jim Lee On 06/23/2018 11:02 PM, Chris Angelico wrote: > On Sun, Jun 24, 2018 at 3:44 PM, Jim Lee wrote: >> >> On 06/23/2018 10:03 PM, Steven D'Aprano wrote: >>> I'd like to run a quick survey. There is no right or wrong answer, since >>> this is about your EXPECTATIONS, not what Python a

Re: syntax difference

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sun, 24 Jun 2018 11:18:37 +0100, Bart wrote: > I wonder why it is just me that constantly needs to justify his > existence in this group? Because its just you who spends 90% of his time here complaining about how Python does it wrong. -- Steven D'Aprano "Ever since I

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Jim Lee
From: Jim Lee On 06/23/2018 10:03 PM, Steven D'Aprano wrote: > I'd like to run a quick survey. There is no right or wrong answer, since > this is about your EXPECTATIONS, not what Python actually does. > > Given this function: > > > def test(): > a = 1 > b = 2 > result = [value f

Re: nltk related issue

2018-06-25 Thread Glenn Hutchings
To: Sharan Basappa From: Glenn Hutchings On 21/06/18 04:40, Sharan Basappa wrote: > Folks, > > I am trying to run a simple example associated with nltk. > I get some error and I don't know what the issue is. > I need some guidance please. > [...] > LookupError: > *

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sun, 24 Jun 2018 15:18:49 +1000, Chris Angelico wrote: > Personally, I think it should give you [1, 2], the two values from the > function's locals. Thank you, that's the sort of answer I'm looking for. (I'm not saying I didn't read your long and involved analysis, onl

Re: syntax difference

2018-06-25 Thread Bart
To: boB Stepp From: Bart On 24/06/2018 00:44, boB Stepp wrote: > On Sat, Jun 23, 2018 at 5:35 PM Bart wrote: >> I'm not a user... > > Then I am truly puzzled, Bart. Why do you even bother to hang out on > this list? If you do not want to use Python and you do not want to > improve Python's

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sun, Jun 24, 2018 at 3:03 PM, Steven D'Aprano wrote: > I'd like to run a quick survey. There is no right or wrong answer, since > this is about your EXPECTATIONS, not what Python actually does. > > Given this function: > > > def test(): > a = 1 > b = 2 > resul

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Jim Lee
From: Jim Lee On 06/23/2018 11:16 PM, Chris Angelico wrote: > On Sun, Jun 24, 2018 at 4:08 PM, Jim Lee wrote: >> There are three locals: a, b, and result. Since result cannot be assigned >> a value until the list comp has been evaluated, I would expect the comp to >> return a value of "None"

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sun, Jun 24, 2018 at 4:08 PM, Jim Lee wrote: > There are three locals: a, b, and result. Since result cannot be assigned > a value until the list comp has been evaluated, I would expect the comp to > return a value of "None" for result. An argument could also be made f

Re: translating foreign data

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sun, Jun 24, 2018 at 1:23 PM, Steven D'Aprano wrote: > On Sun, 24 Jun 2018 12:53:49 +1000, Chris Angelico wrote: > > [...] >>> Okay, you want a bit-pattern. In hex: >>> >>> '0x313030e282ac' > [...] > >> Hmm. Actually, I'm a bit confused. >> > hex("100ΓΘ¼".encode()) >>

Re: translating foreign data

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sun, 24 Jun 2018 12:53:49 +1000, Chris Angelico wrote: [...] >> Okay, you want a bit-pattern. In hex: >> >> '0x313030e282ac' [...] > Hmm. Actually, I'm a bit confused. > hex("100ΓΘ¼".encode()) > Traceback (most recent call last): > File "", line 1, in > TypeErro

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sun, Jun 24, 2018 at 3:44 PM, Jim Lee wrote: > > > On 06/23/2018 10:03 PM, Steven D'Aprano wrote: >> >> I'd like to run a quick survey. There is no right or wrong answer, since >> this is about your EXPECTATIONS, not what Python actually does. >> >> Given this function: >

Re: translating foreign data

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sun, Jun 24, 2018 at 12:44 PM, Steven D'Aprano wrote: > You're joking, right? You can't possibly be so ignorant as to actually > believe that. You have, right in front of you, a news post or email > containing the text string "100ΓΘ¼", and yet you are writing apparently i

Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano I'd like to run a quick survey. There is no right or wrong answer, since this is about your EXPECTATIONS, not what Python actually does. Given this function: def test(): a = 1 b = 2 result = [value for key, value in locals().items()] return result what

Re: translating foreign data

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 17:52:55 -0400, Richard Damon wrote: > If you have more than just a number representing a value in the locale > currency, you can't ask the locale how to present/accept it. You're the only one saying that it has to be handled by the locale. -- Steven

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 18:29:51 +0100, MRAB wrote: > You can already do something similar like this: > > def f(): > f.x += 1 > return f.x > f.x = 0 > > [snip] You can, but only as an illustration, not as a serious implementation. The whole point of static local v

Re: translating foreign data

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 17:05:17 -0400, Richard Damon wrote: > On 6/23/18 11:27 AM, Steven D'Aprano wrote: >> On Sat, 23 Jun 2018 09:42:29 -0400, Richard Damon wrote: >> >>> On 6/23/18 9:05 AM, Marko Rauhamaa wrote: Ok. Here's a value for you: 100ΓΘ¼ [...] >

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 21:44:00 +0100, Bart wrote: > Since these references are created via the return g statement here: > > def f(): > def g(): > > return g > > (say to create function references i and j like this: > > i = f() >

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sun, 24 Jun 2018 00:37:36 +0100, Bart wrote: > Do you mean that if the same 'def' block is re-executed, it will create > a different instance of the function? (Same byte-code, but a different > set of everything else the function uses.) That's not as slow as you think i

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Gregory Ewing
To: Bart From: Gregory Ewing Bart wrote: > Wow. (Just think of all the times you write a function containing a neat > bunch of local functions, every time it's called it has to create a new > function instances for each of those functions, even if they are not used.) Fortunately, function obje

Re: syntax difference

2018-06-25 Thread boB Stepp
From: boB Stepp On Sat, Jun 23, 2018 at 5:35 PM Bart wrote: > > On 23/06/2018 20:52, boB Stepp wrote: > The first programming exercise I ever did involved asking for three > numbers, then determining whether those numbers could form the sides of > a triangle. > > Then [40 years ago], the easy p

Re: syntax difference

2018-06-25 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 23:26:43 +0100, Bart wrote: > Then [40 years ago], the easy part was reading the three numbers. Now > that would be the more challenging part. # Get three numbers, separated by spaces, with no error-recovery. # If you try to read bad data, the process w

Re: syntax difference

2018-06-25 Thread Gregory Ewing
To: Bart From: Gregory Ewing Bart wrote: > But 40 years > ago it was just 'readln a,b,c'; it was just taken for granted. The problem with something like that is that it's really only useful for throwaway code. For any serious application, you need to deal with the possibility of malformed inpu

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sun, Jun 24, 2018 at 9:37 AM, Bart wrote: > On 23/06/2018 23:25, Ben Bacarisse wrote: >> >> Bart writes: >> >>> On 23/06/2018 21:13, Chris Angelico wrote: On Sat, Jun 23, 2018 at 10:41 PM, Bart wrote: >>> >>> > (At what point would that happen anyway; if y

Re: syntax difference

2018-06-25 Thread Bart
To: boB Stepp From: Bart On 23/06/2018 20:52, boB Stepp wrote: > I've finally found time to examine this rather long, rambling thread. >> There is a place for various levels of programming language. I'm saying that Python which is always touted as a 'simple' language suitable for beginners, is

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Ben Bacarisse
To: Bart From: Ben Bacarisse Bart writes: > On 23/06/2018 23:25, Ben Bacarisse wrote: >> Bart writes: >> >>> On 23/06/2018 21:13, Chris Angelico wrote: On Sat, Jun 23, 2018 at 10:41 PM, Bart wrote: >>> > (At what point would that happen anyway; if you do this: >>> NONE of your

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Ben Bacarisse
To: Bart From: Ben Bacarisse Bart writes: > On 23/06/2018 21:13, Chris Angelico wrote: >> On Sat, Jun 23, 2018 at 10:41 PM, Bart wrote: > >>> (At what point would that happen anyway; if you do this: > >> NONE of your examples are taking copies of the function. They all are >> making REFERENC

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Bart
To: Ben Bacarisse From: Bart On 23/06/2018 23:25, Ben Bacarisse wrote: > Bart writes: > >> On 23/06/2018 21:13, Chris Angelico wrote: >>> On Sat, Jun 23, 2018 at 10:41 PM, Bart wrote: >> (At what point would that happen anyway; if you do this: >> >>> NONE of your examples are taking copi

Re: translating foreign data

2018-06-25 Thread Richard Damon
From: Richard Damon On 6/23/18 5:31 PM, Ben Finney wrote: > Richard Damon writes: > >> On 6/23/18 11:27 AM, Steven D'Aprano wrote: On 6/23/18 9:05 AM, Marko Rauhamaa wrote: > Richard Damon wrote: >> Data presented to the user should normally use his locale >> (unless he has spec

Re: translating foreign data

2018-06-25 Thread Ben Finney
From: Ben Finney Richard Damon writes: > On 6/23/18 11:27 AM, Steven D'Aprano wrote: > >> On 6/23/18 9:05 AM, Marko Rauhamaa wrote: > >>> Richard Damon wrote: > >>> > Data presented to the user should normally use his locale > >>> > (unless he has specified something different). > >>> > >>> Ok.

Re: translating foreign data

2018-06-25 Thread Richard Damon
From: Richard Damon On 6/23/18 11:27 AM, Steven D'Aprano wrote: > On Sat, 23 Jun 2018 09:42:29 -0400, Richard Damon wrote: > >> On 6/23/18 9:05 AM, Marko Rauhamaa wrote: >>> Ok. Here's a value for you: >>> >>> 100ΓΘ¼ >>> >>> I see '1', '0', '0', 'ΓΘ¼'. What do you see in your locale (LC_MONET

Re: syntax difference

2018-06-25 Thread boB Stepp
From: boB Stepp I've finally found time to examine this rather long, rambling thread. On Wed, Jun 20, 2018 at 5:46 AM wrote: > > Yeah, people keep bringing that up when they run out of arguments. > > So, every programmer must always use the most advanced, most esoteric features possible at ever

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Bart
To: Chris Angelico From: Bart On 23/06/2018 21:13, Chris Angelico wrote: > On Sat, Jun 23, 2018 at 10:41 PM, Bart wrote: >> (At what point would that happen anyway; if you do this: > NONE of your examples are taking copies of the function. They all are > making REFERENCES to the same functio

Re: Static variables [was Re: syntax difference]

2018-06-25 Thread Chris Angelico
From: Chris Angelico On Sat, Jun 23, 2018 at 10:41 PM, Bart wrote: > This is an example of a simple concept getting so out of hand that it will > either never be implemented, or the resulting implementation becomes > impractical to use. > > This is what we're trying to do: > > def nextx(): >

Re: moving to Python from Java/C++/C

2018-06-25 Thread Dan Stromberg
On Mon, Jun 25, 2018 at 3:40 AM, wrote: > Hey, > I already have quite an experience in programming, and I wish to study > Python as well. I need to study it before I continue with my comp. science > academic studies. > How do you recommend studying it? As mentioned in the headline, I already > kn

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Mark Lawrence
On 25/06/18 17:15, jkn wrote: On Monday, June 25, 2018 at 4:23:57 PM UTC+1, Chris Angelico wrote: On Mon, Jun 25, 2018 at 11:15 PM, jkn wrote: (as well as pedanticism ;-o). Pedantry. ChrisA (You know I can't let that one pass.) I was chanel[l]ing the TimBot, as any fule kno... Ritten b

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread jkn
On Monday, June 25, 2018 at 4:23:57 PM UTC+1, Chris Angelico wrote: > On Mon, Jun 25, 2018 at 11:15 PM, jkn wrote: > > (as well as pedanticism ;-o). > > Pedantry. > > ChrisA > (You know I can't let that one pass.) I was chanel[l]ing the TimBot, as any fule kno... -- https://mail.python.org/mai

Proper way to download stylesheets and templates

2018-06-25 Thread T Berger
I’m creating a webapp and trying to download a stylesheet and templates from my manual’s support site. I must be doing something wrong, because when I try to run my app, I get a 404 error message. I downloaded the files by dragging them off the screen into my webapp folder. But I’m getting a wei

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Alister via Python-list
On Mon, 25 Jun 2018 11:42:27 +0100, Mark Lawrence wrote: > On 25/06/18 10:10, Alister via Python-list wrote: >> On Mon, 25 Jun 2018 11:36:25 +0400, Abdur-Rahmaan Janhangeer wrote: >> >>> i think he means like for a loop to iterate over a list you might do >>> >>> list = [1,2,3] >>> for i in range

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Chris Angelico
On Mon, Jun 25, 2018 at 11:15 PM, jkn wrote: > (as well as pedanticism ;-o). Pedantry. ChrisA (You know I can't let that one pass.) -- https://mail.python.org/mailman/listinfo/python-list

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Grant Edwards
On 2018-06-25, Steven D'Aprano wrote: > And the specific line you reference is *especially* a joke, one which > flies past nearly everyone's head: > > There should be one-- and preferably only one --obvious way to do it. > > Notice the dashes? There are *two* traditional ways to use an pair > o

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Tim Chase
On 2018-06-23 23:08, Jim Lee wrote: >>> On 06/23/2018 10:03 PM, Steven D'Aprano wrote: def test(): a = 1 b = 2 result = [value for key, value in locals().items()] return result what would you expect the result of calling test() to be? >>>

Re: Quick survey: locals in comprehensions (Python 3 only)

2018-06-25 Thread Tim Chase
On 2018-06-24 05:03, Steven D'Aprano wrote: > I'd like to run a quick survey. There is no right or wrong answer, > since this is about your EXPECTATIONS, not what Python actually > does. > > Given this function: > > def test(): > a = 1 > b = 2 > result = [value for key, value in local

Accessing the Python list

2018-06-25 Thread Paul St George
Understanding and having an interest in Python does not imply knowledge of Usenet, mailing lists, NNTP, gateways, gmane, bottom-posting, vanilla-flopping, /et al/. But, knowledge of these seems to be needed (or is at least useful) in order to fully benefit from the Python list. Would it be a

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread jkn
On Monday, June 25, 2018 at 12:17:29 PM UTC+1, Paul Moore wrote: > On 25 June 2018 at 11:53, Steven D'Aprano > wrote: > > > And the specific line you reference is *especially* a joke, one which > > flies past nearly everyone's head: > > > > There should be one-- and preferably only one --obvious

Re: moving to Python from Java/C++/C

2018-06-25 Thread edmondo . giovannozzi
Il giorno lunedì 25 giugno 2018 12:40:53 UTC+2, itai...@gmail.com ha scritto: > Hey, > I already have quite an experience in programming, and I wish to study Python > as well. I need to study it before I continue with my comp. science academic > studies. > How do you recommend studying it? As m

moving to Python from Java/C++/C

2018-06-25 Thread itaiyz97
Hey, I already have quite an experience in programming, and I wish to study Python as well. I need to study it before I continue with my comp. science academic studies. How do you recommend studying it? As mentioned in the headline, I already know Java, C++ and C. Thanks! -- https://mail.pyth

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Mark Lawrence
On 25/06/18 10:10, Alister via Python-list wrote: On Mon, 25 Jun 2018 11:36:25 +0400, Abdur-Rahmaan Janhangeer wrote: i think he means like for a loop to iterate over a list you might do list = [1,2,3] for i in range(len(list)): print(list[i]) but the you might as well go for the simple

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Paul Moore
On 25 June 2018 at 11:53, Steven D'Aprano wrote: > And the specific line you reference is *especially* a joke, one which > flies past nearly everyone's head: > > There should be one-- and preferably only one --obvious way to do it. > > > Notice the dashes? There are *two* traditional ways to use

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Steven D'Aprano
On Sun, 24 Jun 2018 10:46:09 -0700, Jim Lee wrote: > On 06/24/2018 04:35 AM, Steven D'Aprano wrote: >> >> Indeed. That's one of the beauties of Python -- even when there's an >> advanced way to do it, there's generally a simple way too. >> >> > What happened to the Python maxim "There should be on

Re: syntax difference

2018-06-25 Thread Bart
On 25/06/2018 01:52, Steven D'Aprano wrote: On Sun, 24 Jun 2018 21:21:57 +0100, Bart wrote: I've had half a dozen users Come back when you've had *half a million users* then we'll take your experiences seriously. That being the case with Python (maybe even ten times as many), why would any

Re: [ANN] pdfposter 0.7

2018-06-25 Thread jkn
On Sunday, June 24, 2018 at 10:02:05 PM UTC+1, Hartmut Goebel wrote: > I'm pleased to announce pdftools.pdfposter 0.7, a tool to scale and > tile PDF images/pages to print on multiple pages. > > :Homepage: https://pdfposter.readthedocs.io/ > :Author:   Hartmut Goebel > :Licence:  GNU Public Licen

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Abdur-Rahmaan Janhangeer
we must maybe fibd an example where both are pythonic but one is simpler unless my type of example was intented by @steve Abdur-Rahmaan Janhangeer https://github.com/Abdur-rahmaanJ > -- https://mail.python.org/mailman/listinfo/python-list

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Alister via Python-list
On Mon, 25 Jun 2018 11:36:25 +0400, Abdur-Rahmaan Janhangeer wrote: > i think he means like for a loop to iterate over a list you might do > > list = [1,2,3] > for i in range(len(list)): > print(list[i]) > > > but the you might as well go for the simpler : > > > for elem in list: > >

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Abdur-Rahmaan Janhangeer
i think he means like for a loop to iterate over a list you might do list = [1,2,3] for i in range(len(list)): print(list[i]) but the you might as well go for the simpler : for elem in list: print(elem) Abdur-Rahmaan Janhangeer https://github.com/Abdur-rahmaanJ > -- https://mail.

Where's the junk coming from?

2018-06-25 Thread Mark Lawrence
Hi folks, In the last hour or so I've seen via thunderbird and gmane around 15 emails from various people where the from field is name@1261/38.remove-r7u-this. The part after the @ symbol never changes. I've seen the contents previously, apart from one from the RUE. Users' complete email a

Re: syntax difference

2018-06-25 Thread Mark Lawrence
On 24/06/18 00:44, boB Stepp wrote: I imagine that the transition from version 2 to 3 was not undertaken halfheartedly, but only after much thought and discussion since it did break backwards compatibility. So much so that a specific mailing list was set up just to discus the transition, arch

Re: Anyone here on Python-Dev mailing list?

2018-06-25 Thread Mark Lawrence
On 24/06/18 17:07, Steven D'Aprano wrote: Anyone on the Python-Dev mailing list, are you getting private emails containing nothing but stream of consciousness word-salad from somebody (some bot?) calling himself "Chanel Marvin" with a gmail address? Typical example: "I refuse to create my

Re: Python for beginners or not? [was Re: syntax difference]

2018-06-25 Thread Jim Lee
On 06/24/2018 04:35 AM, Steven D'Aprano wrote: Indeed. That's one of the beauties of Python -- even when there's an advanced way to do it, there's generally a simple way too. What happened to the Python maxim "There should be one—and preferably only one—obvious way to do it"? -Jim -- http

I'm getting a spamassassin party here

2018-06-25 Thread Gene Heskett
Greetings list; Generally spamassassin only gets picky about this occasionally, but for the past several hours its working overtime on python list messages, with the major problem being the servers time stamp, a day or more in the past. Anyboy ever hear of ntpd? -- Cheers, Gene Heskett -- "The