not able to download PyAudio

2021-04-02 Thread ᗷᑌᑎᑎY
Hello everyone I am not able to download PyAudio. I tried by typing pip install in PyAudio in cmd but it show's no compatible version availbale. What should I do? . Y -- https://mail.python.org/mailman/listinfo/python-list

how to separate the strings in a string

2021-04-02 Thread Egon Frerich
I have a string like '"ab,c" , def' and need to separate it into "ab,c" and "def". split separates at the first ',': >>> bl '"a,bc", def' >>> bl.split(',') ['"a', 'bc"', ' def'] Egon signature.asc Description: OpenPGP digital signature -- https://mail.python.org/mailman/listinfo/python

Aw: not able to download PyAudio

2021-04-02 Thread Karsten Hilbert
The same as with speech recognition. Research. Karsten > Gesendet: Freitag, 02. April 2021 um 10:40 Uhr > Von: "ᗷᑌᑎᑎY" > An: "Igor Korot" > Cc: "python-list@python.org" > Betreff: not able to download PyAudio > >Hello everyone >I am not able to download PyAudio. I tried by typing pip

Re: not able to download PyAudio

2021-04-02 Thread Benjamin Schollnick
> On Apr 2, 2021, at 4:40 AM, ᗷᑌᑎᑎY wrote: > > Hello everyone > I am not able to download PyAudio. I tried by typing pip install in > PyAudio in cmd but it show's no compatible version availbale. What should > I do? . There seems to be some confusion, which I can understand… “No com

Re: how to separate the strings in a string

2021-04-02 Thread Peter Otten
On 02/04/2021 11:16, Egon Frerich wrote: I have a string like '"ab,c" , def' and need to separate it into "ab,c" and "def". split separates at the first ',': bl '"a,bc", def' bl.split(',') ['"a', 'bc"', ' def'] The initial string looks like it's close enough to the CSV format. Unfortu

Re: how to separate the strings in a string

2021-04-02 Thread Peter Otten
On 02/04/2021 12:38, Peter Otten wrote: On 02/04/2021 11:16, Egon Frerich wrote: I have a string like '"ab,c" , def' and need to separate it into "ab,c" and "def". split separates at the first ',': bl '"a,bc", def' bl.split(',') ['"a', 'bc"', ' def'] The initial string looks like it'

Re: memory consumption

2021-04-02 Thread Alexey
> I had the (mis)pleasure of dealing with a multi-terabyte postgresql > instance many years ago and figuring out why random scripts were eating > up system memory became quite common. > > All of our "ETL" scripts were either written in Perl, Java, or Python > but the results were always the sa

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread Chris Angelico
On Fri, Apr 2, 2021 at 10:43 AM dn via Python-list wrote: > > On 02/04/2021 10.13, Chris Angelico wrote: > > Well, it's a simple matter of chronology. First you have crude oil, > > then time passes, and then you have plastic and residue. It makes > > sense ONLY if you think of it with a specific o

all versions of python fail to indent after conditional statement

2021-04-02 Thread mikedianeterry
The following snap shot of system prompt illustrates my problem. I have tried 3.8, 3.92 and 3.10 with the same result. When I run in the window interface it doesn't even display one row of ... but does print if I hit return twice. I'm new to Python and was excited about learning it b

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread Alan Gauld via Python-list
On 02/04/2021 00:42, dn via Python-list wrote: > Contrarily "tuck" in (old) English slang represented "sweets" (or Not that old. We still use it occasionally today. And we certainly had a "tuck shop" at school. It was where you bought lunch if not eating in the refectory. ie. sandwiches, crisps,

Re: not able to download PyAudio

2021-04-02 Thread Terry Reedy
On 4/2/2021 6:09 AM, Benjamin Schollnick wrote: On Apr 2, 2021, at 4:40 AM, ᗷᑌᑎᑎY wrote: Hello everyone I am not able to download PyAudio. I tried by typing pip install in PyAudio in cmd but it show's no compatible version availbale. What should I do? . There seems to be some c

Re: all versions of python fail to indent after conditional statement

2021-04-02 Thread MRAB
On 2021-04-02 01:40, mikedianete...@gmail.com wrote: The following snap shot of system prompt illustrates my problem. I have tried 3.8, 3.92 and 3.10 with the same result. When I run in the window interface it doesn't even display one row of ... but does print if I hit return tw

Re: all versions of python fail to indent after conditional statement

2021-04-02 Thread Joe Pfeiffer
It's not a bug, it's a design choice you are disagreeing with: managing indentation is your job, not the interpreter's. For anything other than an absolutely trivial three-line script, I write in an editor that does a good job helping me manage indentation (in my case, emacs in Python mode). wr

Re: all versions of python fail to indent after conditional statement

2021-04-02 Thread Mats Wichmann
On 4/2/21 9:42 AM, Joe Pfeiffer wrote: It's not a bug, it's a design choice you are disagreeing with: managing indentation is your job, not the interpreter's. For anything other than an absolutely trivial three-line script, I write in an editor that does a good job helping me manage indentation

RE: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread Avi Gross via Python-list
Chris, Now that it is April 2, I have to ask which of the methods for dealing with chocolate is more pythonic and is there a module for that? Next April, can we switch beans and discuss different grades of coffee and which ones are best to shave at home with a potato peeler? I think that would

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread Chris Angelico
On Sat, Apr 3, 2021 at 3:51 AM Avi Gross via Python-list wrote: > > Chris, > > Now that it is April 2, I have to ask which of the methods for dealing with > chocolate is more pythonic and is there a module for that? I have a JavaScript front end package called "Chocolate Factory", which works wel

[RELEASE] Python 3.9.3 and 3.8.9 are now available

2021-04-02 Thread Łukasz Langa
Those are expedited security releases, recommended to all users. Get them here: https://www.python.org/downloads/release/python-393/ https://www.python.org/downloads/release/python-389/

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread dn via Python-list
On 02/04/2021 21.32, Alan Gauld via Python-list wrote: > On 02/04/2021 00:42, dn via Python-list wrote: > >> Contrarily "tuck" in (old) English slang represented "sweets" (or > > Not that old. We still use it occasionally today. And we > certainly had a "tuck shop" at school. It was where you > b

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread dn via Python-list
On 02/04/2021 13.00, Chris Angelico wrote: > On Fri, Apr 2, 2021 at 10:43 AM dn via Python-list > wrote: >> >> On 02/04/2021 10.13, Chris Angelico wrote: >>> Well, it's a simple matter of chronology. First you have crude oil, >>> then time passes, and then you have plastic and residue. It makes >>

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread Chris Angelico
On Sat, Apr 3, 2021 at 8:16 AM dn via Python-list wrote: > Is there such a thing as F/LOSS in the chocolate world? What does it > mean to fork a block of chocolate? Where is their repository? > It means exactly what you'd expect. The tricky part comes when you try to knife the block of chocolate,

Friday Finking: initialising values and implied tuples

2021-04-02 Thread dn via Python-list
When there are several items to be defined and initialised, how do you prefer to format the code, and why? Apprentice: learn options Journeyman: consider and discuss Python Master: define, declare, and correct/advise/tutor Some do not realise that using a tuple is a convenient way to convey mul

Re: Friday Finking: initialising values and implied tuples

2021-04-02 Thread Marco Ippolito
> (a) basic linear presentation: > > resource = "Oil" > time = 1 > crude = 2 > residue = 3 > my_list = "long" > > (b) using explicit tuples: > > ( resource, time, crude, residue, my_list ) = ( "Oil", 1, 2, 3, "long" ) > > (c) linear and indented tuples: > > ( > resource, > time, >

Re: Friday Finking: initialising values and implied tuples

2021-04-02 Thread 2QdxY4RzWzUUiLuE
On 2021-04-02 at 19:25:07 -0300, Marco Ippolito wrote: > > (a) basic linear presentation: > > > > resource = "Oil" > > time = 1 > > crude = 2 > > residue = 3 > > my_list = "long" > > > > (b) using explicit tuples: > > > > ( resource, time, crude, residue, my_list ) = ( "Oil", 1, 2, 3, "long" )

Re: Friday Finking: initialising values and implied tuples

2021-04-02 Thread Rob Cliffe via Python-list
On 02/04/2021 23:10, dn via Python-list wrote: (f) the space-saver: resource = "Oil"; time = 1; crude = 2; residue = 3; my_list = "long" IMO This can be OK when the number of items is VERY small (like 2) and not expected to increase (or decrease).  Especially if there are multiple simil

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread Alan Gauld via Python-list
On 02/04/2021 21:33, dn via Python-list wrote: > Bournville was the only Cadbury chocolate I would > consider. Today, even that seems to lack Cadbury has always been a budget chocolate brand(*) here; its a mass market option loaded with sugar and little else. Certainly doesn't compare to Suchards

Re: Friday Finking: initialising values and implied tuples

2021-04-02 Thread Alan Gauld via Python-list
On 02/04/2021 23:10, dn via Python-list wrote: > When there are several items to be defined and initialised, how do you > prefer to format the code, and why? > (a) basic linear presentation: > > resource = "Oil" > time = 1 > crude = 2 > residue = 3 > my_list = "long" In production code I'd almos

Re: Friday Finking: initialising values and implied tuples

2021-04-02 Thread 2QdxY4RzWzUUiLuE
On 2021-04-03 at 02:41:59 +0100, Rob Cliffe via Python-list wrote: >     x1 = 42; y1 =  3;  z1 = 10 >     x2 = 41; y2 = 12; z2 = 9 >     x3 =  8;  y3 =  8;  z3 = 10 > (please imagine it's in a fixed font with everything neatly vertically > aligned). > This has see-at-a-glance STRUCTURE: the lette

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread Greg Ewing
On 3/04/21 10:36 am, Chris Angelico wrote: It means exactly what you'd expect. The tricky part comes when you try to knife the block of chocolate, and it makes for a hilarious party game. A guillotine could be useful in the case of Whittaker's. IMO they don't make the grooves deep enough, makin

Python curses question: How to separate foreground and background colors from the value returned by inch()?

2021-04-02 Thread pjfarley3
The window.inch(([y, x])) function returns the character and attributes of the character at the current or specified window position. But how does one separate the foreground and background colors from the resulting value? colors = window.inch(0.0) & A_ATTRIBUTES That should return the combined

Re: Horrible abuse of __init_subclass__, or elegant hack?

2021-04-02 Thread dn via Python-list
On 03/04/2021 18.45, Greg Ewing wrote: > On 3/04/21 10:36 am, Chris Angelico wrote: >> It means exactly what you'd expect. The tricky part comes when you try >> to knife the block of chocolate, and it makes for a hilarious party >> game. > > A guillotine could be useful in the case of Whittaker's.