On 2022-04-16, Dennis Lee Bieber wrote:
> On Sat, 16 Apr 2022 20:35:22 - (UTC), Jon Ribbens
> declaimed the following:
>>I can categorically guarantee you it is not. But let's put it a
>>different way, if you like, if I want to add 24 hours, i.e. 86,400
>>seconds (or indeed any other fixed tim
On 2022-04-19, Loris Bennett wrote:
> I now realise that timedelta is not really what I need. I am interested
> solely in pure periods, i.e. numbers of seconds,
That's exactly what timedelta is.
> that I can convert back and forth from a format such as
>
> 11-22::44:55
I don't recognise that
On 2022-04-19, Loris Bennett wrote:
> Jon Ribbens writes:
>> On 2022-04-19, Loris Bennett wrote:
>>> I now realise that timedelta is not really what I need. I am interested
>>> solely in pure periods, i.e. numbers of seconds,
>>
>> That's exactly what timedelta is.
>>
>>> that I can convert bac
On 2022-04-19, Loris Bennett wrote:
> If I am merely trying to represent part a very large number of seconds
> as a number of years, 365 days per year does not seem that controversial
> to me. Obviously there are issues if you expect all periods of an
> integer number of years which start on a gi
On 2022-04-19, Barry wrote:
>> On 19 Apr 2022, at 19:38, Dennis Lee Bieber wrote:
>> *I /think/ this is the year used for leap-day calculations, and
>> why some leap centuries are skipped as it is really less than a
>> quarter day per year, so eventually one gets to over-correcting
On 2022-04-28, Stephen Tucker wrote:
> Hi PythonList Members,
>
> Consider the following log from a run of IDLE:
>
>==
>
> Python 2.7.10 (default, May 23 2015, 09:40:32) [MSC v.1500 32 bit (Intel)]
> on win32
> Type "copyright", "credits" or "license()" for more information.
p
On 2022-05-18, ^Bart wrote:
> THE INPUT
> -
> import nmap
> nm.scan(hosts='192.168.205.0/24', arguments='-n -sP -PE -PA21,23,80,3389')
> hosts_list = [(x, nm[x]['status']['state']) for x in nm.all_hosts()]
> for host, status i
On 2022-06-08, Dave wrote:
> I misunderstood how it worked, basically I’ve added this function:
>
> def filterCommonCharacters(theString):
> myNewString = theString.replace("\u2019", "'")
> return myNewString
> Which returns a new string replacing the common characters.
>
> This can easil
On 2022-06-26, Rob Cliffe wrote:
> This 2-line program
>
> def f(): pass
> def g(): pass
>
> runs silently (no Exception). But:
>
> 23:07:02 c:\>python
> Python 3.8.3 (tags/v3.8.3:6f8c832, May 13 2020, 22:20:19) [MSC v.1925 32
> bit (Intel)] on win32
> Type "help", "copyright", "credits" or "lic
On 2022-07-28, Ben Hirsig wrote:
> Hi, I noticed this when using the requests library in the response.elapsed
> object (type timedelta). Tested using the standard datetime library alone
> with the example displayed on
> https://docs.python.org/3/library/datetime.html#examples-of-usage-timedelta
>
On 2022-08-17, Tobiah wrote:
> I get data from various sources; client emails, spreadsheets, and
> data from web applications. I find that I can do some_string.decode('latin1')
> to get unicode that I can use with xlsxwriter,
> or put in the header of a web page to display
> European characters
On 2022-08-17, Tobiah wrote:
>> That has already been decided, as much as it ever can be. UTF-8 is
>> essentially always the correct encoding to use on output, and almost
>> always the correct encoding to assume on input absent any explicit
>> indication of another encoding. (e.g. the HTML "standa
On 2022-08-17, Barry wrote:
>> On 17 Aug 2022, at 18:30, Jon Ribbens via Python-list
>> wrote:
>> On 2022-08-17, Tobiah wrote:
>>> I get data from various sources; client emails, spreadsheets, and
>>> data from web applications. I find that I can do
>
On 2022-08-18, Tobiah wrote:
>> Generally speaking browser submisisons were/are supposed to be sent
>> using the same encoding as the page, so if you're sending the page
>> as "latin1" then you'll see that a fair amount I should think. If you
>> send it as "utf-8" then you'll get 100% utf-8 back.
On 2022-08-18, Tobiah wrote:
>> You configure the web server to send:
>>
>> Content-Type: text/html; charset=...
>>
>> in the HTTP header when it serves HTML files.
>
> So how does this break down? When a person enters
> Montréal, Quebéc into a form field, what are they
> doing on the keyb
On 2022-08-19, Chris Angelico wrote:
> What's the best way to precisely reconstruct an HTML file after
> parsing it with BeautifulSoup?
>
> Using the Alice example from the BS4 docs:
>
html_doc = """The Dormouse's story
>
>The Dormouse's story
>
>Once upon a time there were three little siste
On 2022-08-20, Chris Angelico wrote:
> On Sun, 21 Aug 2022 at 03:27, Stefan Ram wrote:
>> 2qdxy4rzwzuui...@potatochowder.com writes:
>> >textual representations. That way, the following two elements are the
>> >same (and similar with a collection of sub-elements in a different order
>> >in anoth
On 2022-08-20, Stefan Ram wrote:
> Jon Ribbens writes:
>>... or you could avoid all that faff and just do re.sub()?
>
> import bs4
> import re
>
> source = ''
>
> # Use Python to change the source, keeping the order of attributes.
>
> result = re.sub( r'href\s*=\s*"http"', r'href="https"', source
On 2022-08-21, Chris Angelico wrote:
> On Sun, 21 Aug 2022 at 09:31, Jon Ribbens via Python-list
> wrote:
>> On 2022-08-20, Chris Angelico wrote:
>> > On Sun, 21 Aug 2022 at 03:27, Stefan Ram wrote:
>> >> 2qdxy4rzwzuui...@potatochowder.com writes:
>> >
On 2022-08-21, Peter J. Holzer wrote:
> On 2022-08-20 21:51:41 -0000, Jon Ribbens via Python-list wrote:
>> On 2022-08-20, Stefan Ram wrote:
>> > Jon Ribbens writes:
>> >>... or you could avoid all that faff and just do re.sub()?
>
>> > source =
On 2022-08-21, Chris Angelico wrote:
> On Mon, 22 Aug 2022 at 05:43, Jon Ribbens via Python-list
> wrote:
>> On 2022-08-21, Chris Angelico wrote:
>> > On Sun, 21 Aug 2022 at 09:31, Jon Ribbens via Python-list
>> > wrote:
>> >> On 2022-08-20, Chris Angel
On 2022-08-22, Peter J. Holzer wrote:
> On 2022-08-22 00:45:56 -0000, Jon Ribbens via Python-list wrote:
>> With the offset though, BeautifulSoup made an arbitrary decision to
>> use ISO-8859-1 encoding and so when you chopped the bytestring at
>> that offset it only worked
On 2022-09-26, Stefan Ram wrote:
> So, I wanted to try to download all pages in parallel with
> processes to avoid any GIL effect, while I don't understand
> what the GIL actuall is. But processes didn't work here, so
> I tried threads. This worked and now the total run time is
> down to
On 2022-10-10, Calvin Spealman wrote:
> On Sat, Oct 8, 2022 at 5:35 PM rbowman wrote:
>> On 10/7/22 21:32, Axy wrote:
>> > So, seriously, why they needed else if the following pieces produce same
>> > result? Does anyone know or remember their motivation?
>>
>> In real scenarios there would be mo
On 2022-10-12, Michael F. Stemper wrote:
> On 12/10/2022 07.20, Chris Green wrote:
>> ... and rm will just about always be in /usr/bin.
>
> On two different versions of Ubuntu, it's in /bin.
It will almost always be in /bin in any Unix or Unix-like system,
because it's one of the fundamental util
On 2022-10-12, Joe Pfeiffer wrote:
> Jon Ribbens writes:
>
>> On 2022-10-12, Michael F. Stemper wrote:
>>> On 12/10/2022 07.20, Chris Green wrote:
... and rm will just about always be in /usr/bin.
>>>
>>> On two different versions of Ubuntu, it's in /bin.
>>
>> It will almost always be in /
On 2022-10-12, Paulo da Silva wrote:
> Às 05:00 de 12/10/22, Paulo da Silva escreveu:
>> Hi!
>>
>> The simple question: How do I find the full path of a shell command
>> (linux), i.e. how do I obtain the corresponding of, for example,
>> "type rm" in command line?
>>
>> The reason:
>> I have py
On 2022-10-12, Jon Ribbens wrote:
> On 2022-10-12, Joe Pfeiffer wrote:
>> Jon Ribbens writes:
>>
>>> On 2022-10-12, Michael F. Stemper wrote:
On 12/10/2022 07.20, Chris Green wrote:
> ... and rm will just about always be in /usr/bin.
On two different versions of Ubuntu, it's
On 2022-10-12, Paulo da Silva wrote:
> Às 19:14 de 12/10/22, Jon Ribbens escreveu:
>> On 2022-10-12, Paulo da Silva wrote:
>>> Às 05:00 de 12/10/22, Paulo da Silva escreveu:
Hi!
The simple question: How do I find the full path of a shell command
(linux), i.e. how do I obtain t
On 2022-10-12, Jon Ribbens wrote:
> On 2022-10-12, Paulo da Silva wrote:
>> Às 19:14 de 12/10/22, Jon Ribbens escreveu:
>>> On 2022-10-12, Paulo da Silva wrote:
Às 05:00 de 12/10/22, Paulo da Silva escreveu:
> Hi!
>
> The simple question: How do I find the full path of a shell c
On 2022-10-12, Paulo da Silva wrote:
> Às 22:38 de 12/10/22, Jon Ribbens escreveu:
>> On 2022-10-12, Jon Ribbens wrote:
>>> On 2022-10-12, Paulo da Silva wrote:
Às 19:14 de 12/10/22, Jon Ribbens escreveu:
> On 2022-10-12, Paulo da Silva
> wrote:
>> Às 05:00 de 12/10/22, Paulo
On 2022-10-19, Robert Latest wrote:
> If the XML input has namespaces, tags and attributes with prefixes
> in the form prefix:sometag get expanded to {uri}sometag where the
> prefix is replaced by the full URI.
>
> Which means that given an Element e, I cannot directly access its attri
On 2022-10-24, Chris Angelico wrote:
> On Mon, 24 Oct 2022 at 23:22, Peter J. Holzer wrote:
>> Yes, I got that. What I wanted to say was that this is indeed a bug in
>> html.parser and not an error (or sloppyness, as you called it) in the
>> input or ambiguity in the HTML standard.
>
> I describe
On 2022-10-24, Chris Angelico wrote:
> On Tue, 25 Oct 2022 at 02:45, Jon Ribbens via Python-list
> wrote:
>>
>> On 2022-10-24, Chris Angelico wrote:
>> > On Mon, 24 Oct 2022 at 23:22, Peter J. Holzer wrote:
>> >> Yes, I got that. What I wanted
On 2022-11-13, DFS wrote:
> In code, list.clear is just ignored.
> At the terminal, list.clear shows
>
>
>
> in code:
> x = [1,2,3]
> x.clear
> print(len(x))
> 3
>
> at terminal:
> x = [1,2,3]
> x.clear
>
> print(len(x))
> 3
>
>
> Caused me an hour of frustration before I noticed list.clear() was
On 2022-11-13, DFS wrote:
> On 11/13/2022 5:20 PM, Jon Ribbens wrote:
>> On 2022-11-13, DFS wrote:
>>> In code, list.clear is just ignored.
>>> At the terminal, list.clear shows
>>>
>>>
>>>
>>> in code:
>>> x = [1,2,3]
>>> x.clear
>>> print(len(x))
>>> 3
>>>
>>> at terminal:
>>> x = [1,2,3]
>>>
On 2022-11-14, Greg Ewing wrote:
> On 14/11/22 1:31 pm, Jon Ribbens wrote:
>> On 2022-11-13, DFS wrote:
>>> But why is it allowed in the first place?
>>
>> Because it's an expression, and you're allowed to execute expressions.
>
> To put it a bit more clearly, you're allowed to evaluate
> an exp
On 2022-11-14, Stefan Ram wrote:
> Jon Ribbens writes:
>>"""Create an array and print its length"""
>>array = [1, 2, 3]
>>array.clear
>
> BTW: Above, there are /two/ expression statements
> with no effect; the other one is
>
> """Create an array and print its length"""
>
> . Apparently, lin
On 2022-12-06, ^Bart wrote:
> Hi Guys,
>
> usually I use this code on my Debian Bullseye:
>
> # python3 -m pyftpdlib -i 192.168.0.71 -p 21 -d /home/my_user/ftp
>
> It works, it's simply easy and perfect but... a device in my lan needs a
> ftp folder without username and password!
>
> I tried to s
On 2023-01-20, Dino wrote:
>
> let's say I have this list of nested dicts:
>
> [
>{ "some_key": {'a':1, 'b':2}},
>{ "some_other_key": {'a':3, 'b':4}}
> ]
>
> I need to turn this into:
>
> [
>{ "value": "some_key", 'a':1, 'b':2},
>{ "value": "some_other_key", 'a':3, 'b':4}
> ]
[{"v
On 2023-01-28, Peter J. Holzer wrote:
> On 2023-01-27 21:04:58 +, Ben Bacarisse wrote:
>> It looks like you posted this question via Usenet. comp.lang.python is
>> essentially dead as a Usenet group. It exists, and gets NNTP versions
>> of mail sent to the mailing list, but nothing posted to
On 2023-01-29, Ben Bacarisse wrote:
> "Peter J. Holzer" writes:
>
>> On 2023-01-27 21:04:58 +, Ben Bacarisse wrote:
>>> mutt...@dastardlyhq.com writes:
>>>
>>> > Hi
>>>
>>> It looks like you posted this question via Usenet. comp.lang.python is
>>> essentially dead as a Usenet group. It ex
On 2023-01-29, Peter J. Holzer wrote:
> On 2023-01-29 02:09:28 -0000, Jon Ribbens via Python-list wrote:
>> I'm not aware of any significant period in the last twenty-one years
>> that
> [the gateway]
>> hasn't been working. Although sometimes it does feel like
On 2023-02-02, Stefan Ram wrote:
> Many licenses in the Python world are like: "You can make
> changes, but have to leave in my Copyright notice.".
>
> Would it be possible that the original author could not
> claim a Copyright anymore when code has been changed?
No. If you change someone
On 2023-02-03, Greg Ewing wrote:
> On 3/02/23 6:38 am, Jon Ribbens wrote:
>> If you change someone else's code then you have created a derived
>> work, which requires permission from both the original author and you
>> to copy. (Unless you change it so much that nothing remains of the
>> original
On 2023-02-25, Paul Rubin wrote:
> Skip Montanaro writes:
>> from threading import Lock
>
> 1) you generally want to use RLock rather than Lock
Why?
> 2) I have generally felt that using locks at the app level at all is an
> antipattern. The main way I've stayed sane in multi-threaded Python
>
On 2023-02-25, Paul Rubin wrote:
> Jon Ribbens writes:
>>> 1) you generally want to use RLock rather than Lock
>> Why?
>
> So that a thread that tries to acquire it twice doesn't block itself,
> etc. Look at the threading lib docs for more info.
Yes, I know what the docs say, I was asking why y
On 2023-02-26, Barry Scott wrote:
> On 25/02/2023 23:45, Jon Ribbens via Python-list wrote:
>> I think it is the case that x += 1 is atomic but foo.x += 1 is not.
>
> No that is not true, and has never been true.
>
>:>>> def x(a):
>:... a += 1
>:...
>
On 2023-02-26, Chris Angelico wrote:
> On Sun, 26 Feb 2023 at 16:16, Jon Ribbens via Python-list
> wrote:
>> On 2023-02-25, Paul Rubin wrote:
>> > The GIL is an evil thing, but it has been around for so long that most
>> > of us have gotten used to it, and some u
On 2023-02-28, Thomas Passin wrote:
> On 2/28/2023 10:05 AM, Roel Schroeven wrote:
>> Op 28/02/2023 om 14:35 schreef Thomas Passin:
>>> On 2/28/2023 4:33 AM, Roel Schroeven wrote:
[...]
(2) Searching for a string in another string, in a performant way, is
not as simple as it first
On 2023-03-01, Simon Ward wrote:
> On Tue, Feb 28, 2023 at 04:05:19PM -0500, avi.e.gr...@gmail.com wrote:
>>Is it rude to name something "black" to make it hard for some of us to
>>remind them of the rules or claim that our personal style is so often
>>the opposite that it should be called "whit
On 2023-03-02, Chris Angelico wrote:
> On Thu, 2 Mar 2023 at 08:01, <2qdxy4rzwzuui...@potatochowder.com> wrote:
>> On 2023-03-01 at 14:35:35 -0500,
>> avi.e.gr...@gmail.com wrote:
>> > What would have happened if all processors had been required to have
>> > some low level instruction that effecti
On 2023-03-02, Stephen Tucker wrote:
> The range function in Python 2.7 (and yes, I know that it is now
> superseded), provokes a Memory Error when asked to deiliver a very long
> list of values.
>
> I assume that this is because the function produces a list which it then
> iterates through.
>
> 1
On 2023-03-13, Morten W. Petersen wrote:
> I was working in Python today, and sat there scratching my head as the
> numbers for calculations didn't add up. It went into negative numbers,
> when that shouldn't have been possible.
>
> Turns out I had a very small typo, I had =- instead of -=.
>
> I
On 2023-03-19, Stefan Ram wrote:
> Peng Yu writes:
>>But when I try the following code, get_body() is not found. How to get
>>get_body() to work?
>
> Did you know that this post of mine here was posted to
> Usenet with a Python script I wrote?
>
> That Python script has a function to show t
On 2023-03-19, Stefan Ram wrote:
> Jon Ribbens writes:
>>(Also, I too find it annoying to have to avoid, but calling a local
>>variable 'file' is somewhat suspect since it shadows the builtin.)
>
> Thanks for your remarks, but I'm not aware
> of such a predefined name "file"!
Ah, apparently
On 2023-03-19, Greg Ewing wrote:
> On 20/03/23 7:07 am, Jon Ribbens wrote:
>> Ah, apparently it got removed in Python 3, which is a bit odd as the
>> last I heard it was added in Python 2.2 in order to achieve consistency
>> with other types.
>
> As far as I remember, the file type came into exist
On 2023-05-22, Skip Montanaro wrote:
>> My understanding is that nntplib isn't being erased from reality,
>> it's merely being removed from the set of modules that are provided
>> by default.
>>
>> I presume that once it's removed from the core, it will still be
>> possible to install it via pip o
io.TextIOWrapper() wraps a binary stream so you can write text to it.
It takes an 'encoding' parameter, which it uses to look up the codec
in the codecs registry, and then it uses the IncrementalEncoder and
IncrementalDecoder classes for the appropriate codec.
The IncrementalEncoder.encode() funct
On 2023-06-19, Inada Naoki wrote:
> I checked TextIOWrapper source code and confirmed that it doesn't call
> encoder.write(text, finish=True) on close.
> Since TextIOWrapper allows random access, it is difficult to call it
> automatically. So please think it as just limitation rather than bug.
> P
On 2023-08-02, dn wrote:
> Can you please explain why a multi-part second-argument must be a tuple
> and not any other form of collection-type?
The following comment may hold a clue:
if (PyTuple_Check(cls)) {
/* Not a general sequence -- that opens up the road to
recursio
On 2023-09-27, Larry Martell wrote:
> I was under the impression that in a venv the python used would be in
> the venv's bin dir. But in my venvs I see this in the bin dirs:
>
> lrwxrwxrwx 1 larrymartell larrymartell7 Sep 27 11:21 python -> python3
> lrwxrwxrwx 1 larrymartell larrymartell 16
On 2023-09-27, Larry Martell wrote:
> On Wed, Sep 27, 2023 at 12:42 PM Jon Ribbens via Python-list
> wrote:
>> On 2023-09-27, Larry Martell wrote:
>> > I was under the impression that in a venv the python used would be in
>> > the venv's bin dir. But in
On 2023-11-01, Chris Angelico wrote:
> On Thu, 2 Nov 2023 at 05:21, Simon Connah via Python-list
> wrote:
>> Could someone push me in the right direction please? I just want to
>> find out if a string is a valid email address.
>
> There is only one way to know that a string is a valid email addres
On 2023-11-02, D'Arcy Cain wrote:
> On 2023-11-01 17:17, Chris Angelico via Python-list wrote:
>> On Thu, 2 Nov 2023 at 08:09, Grant Edwards via Python-list
>> wrote:
>>> Make sure it has an '@' in it. Possibly require at least one '.'
>>> after the '@'.
>>
>> No guarantee that there'll be a do
On 2023-11-02, Simon Connah wrote:
> Valid as in conforms to the standard. Although having looked at the
> standard that might be more difficult than originally planned.
Yes. Almost nobody actually implements "the standard" as in RFC 2822
section 3.4.1 (which can contain, for example, non-printab
On 2023-11-02, Dieter Maurer wrote:
> Chris Green wrote at 2023-11-2 10:58 +:
>> ...
>>So, going on from this, how do I do the equivalent of "apt update; apt
>>upgrade" for my globally installed pip packages?
>
> `pip list -o` will tell you for which packages there are upgrades
> available.
>
On 2023-11-02, Chris Green wrote:
> I have a couple of systems which used to have python2 as well as
> python3 but as Ubuntu and Debian verions have moved on they have
> finally eliminated all dependencies on python2.
>
> So they now have only python3 and there is no python executable in
> PATH.
On 2023-11-02, Chris Green wrote:
> Jon Ribbens wrote:
>> On 2023-11-02, Chris Green wrote:
>> > I have a couple of systems which used to have python2 as well as
>> > python3 but as Ubuntu and Debian verions have moved on they have
>> > finally eliminated all dependencies on python2.
>> >
>> > S
On 2023-11-02, Chris Green wrote:
> Jon Ribbens wrote:
>> On 2023-11-02, Dieter Maurer wrote:
>> > Chris Green wrote at 2023-11-2 10:58 +:
>> >> ...
>> >>So, going on from this, how do I do the equivalent of "apt update; apt
>> >>upgrade" for my globally installed pip packages?
>> >
>> > `pi
On 2023-11-03, Chris Angelico wrote:
> On Fri, 3 Nov 2023 at 12:21, AVI GROSS via Python-list
> wrote:
>> My guess is that a first test of an email address might be to see if
>> a decent module of that kind fills out the object to your
>> satisfaction. You can then perhaps test parts of the object
On 2023-11-03, Karsten Hilbert wrote:
> Am Thu, Nov 02, 2023 at 09:35:43PM - schrieb Jon Ribbens via Python-list:
>
> Regardless of ...
>
>> Because pip barely plays well by itself, let alone with other package
>> managers at the same time.
>
> ... being true
On 2023-11-05, D'Arcy Cain wrote:
> On 2023-11-05 00:39, Grant Edwards via Python-list wrote:
>> Definitely. Syntactic e-mail address "validation" is one of the most
>> useless and widely broken things on the Interwebs. People who do
>> anything other than require an '@' (and optionally make you
On 2023-11-03, Karsten Hilbert wrote:
> Am Thu, Nov 02, 2023 at 04:07:33PM -0600 schrieb Mats Wichmann via
> Python-list:
>> >So they now have only python3 and there is no python executable in
>> >PATH.
>>
>> FWIW, for this you install the little stub package python-is-python3.
>> Especially if y
On 2023-11-05, Chris Green wrote:
> Jon Ribbens wrote:
>> On 2023-11-03, Karsten Hilbert wrote:
>> > Am Thu, Nov 02, 2023 at 04:07:33PM -0600 schrieb Mats Wichmann via
>> > Python-list:
>> >> >So they now have only python3 and there is no python executable in
>> >> >PATH.
>> >>
>> >> FWIW, for
On 2023-11-05, Grant Edwards wrote:
> On 2023-11-05, D'Arcy Cain via Python-list wrote:
>> On 2023-11-05 00:39, Grant Edwards via Python-list wrote:
>>> Definitely. Syntactic e-mail address "validation" is one of the most
>>> useless and widely broken things on the Interwebs. People who do
>>> a
On 2023-11-05, Karsten Hilbert wrote:
> Am Fri, Nov 03, 2023 at 01:53:32PM - schrieb Jon Ribbens via Python-list:
>
>> >> Are they not available in your system's package manager?
>> >
>> > ... this clearly often answers to "no" for applic
On 2023-11-06, D'Arcy Cain wrote:
> On 2023-11-05 06:48, Jon Ribbens via Python-list wrote:
>> Sometimes I think that these sorts of stupid, wrong, validation are the
>> fault of idiot managers. When it's apostrophes though I'm suspicious
>> that it may be idi
On 2023-11-06, Mats Wichmann wrote:
> On 11/6/23 01:57, Simon Connah via Python-list wrote:
>> The thing I truly hate is when you have two telephone number fields.
>> One for landline and one for mobile. I mean who in hell has a
>> landline these days?
>
> People who live in places with spotty, o
On 2023-11-07, Stefan Ram wrote:
> I read this in a shell newsgroup:
>
> perl -anE '$s += $F[1]; END {say $s}' in
>
> , so I wrote
>
> py -c "import sys; print(sum(int(F.split()[1])for F in sys.stdin))"
> to show that this is possible with Python too.
>
> But now people complain that it'
On 2023-11-07, wrote:
> Discussions like this feel a bit silly after a while. How long
> something is to type on a command line is not a major issue and
> brevity can lead to being hard to remember too especially using
> obscure references.
Of course it's silly, that's why it's called "golf"!
I
On 2021-02-09, Skip Montanaro wrote:
> I downloaded US hospital ICU capacity data this morning from this page:
>
> https://healthdata.gov/dataset/covid-19-reported-patient-impact-and-hospital-capacity-facility
>
> (The download link is about halfway down the page.)
>
> Trying to read it using my p
On 2021-03-20, Cameron Simpson wrote:
> On 20Mar2021 12:53, Sibylle Koczian wrote:
>>Am 20.03.2021 um 09:34 schrieb Alan Bawden:
>>>The real reason Python strings support a .title() method is surely
>>>because Unicode supports upper, lower, _and_ title case letters, and
>>>tells you how to map be
On 2021-03-30, Loris Bennett wrote:
> If I have dict of dicts, say
>
> dod = {
> "alice":
> {
> "lang": "python",
> "level": "expert"
> },
> "bob":
> {
> "lang": "perl",
> "level": "noob"
> }
> }
>
> is there a canonic
On 2021-03-30, Chris Angelico wrote:
> I dunno about "canonical", but here's how I'd do it:
>
> lod = [info | {"name": name} for name, info in dod.items()]
>
> You could use {"name":name}|info instead if you prefer to have the
> name show up first in the dictionary.
It's probably worth noting thi
On 2021-03-30, Chris Angelico wrote:
> On Tue, Mar 30, 2021 at 11:01 PM Jon Ribbens via Python-list
> wrote:
>>
>> On 2021-03-30, Chris Angelico wrote:
>> > I dunno about "canonical", but here's how I'd do it:
>> >
>> > lod = [i
On 2021-04-19, Paul Bryan wrote:
> Calling them options—when they're required—seems like a problem. 🙂
The option is what the value is, not whether there is a value at all.
If you order a coffee then you may have an option as to what temperature
it is, that doesn't mean the coffee having a tempera
On 2021-04-20, Paul Rubin wrote:
> Ethan Furman writes:
>> List, my apologies -- not sure how that one got through.
>
> It was trollishly written but was a reasonable observation on the state
> of the Usenet group. I didn't realize it had come through (or reached)
> the mailing list. Anyway the
On 2021-05-06, Chris Angelico wrote:
> On Thu, May 6, 2021 at 10:32 AM Paul Bryan wrote:
>>
>> Given the ease of spoofing sender addresses, and its propensity for use
>> in anonymous spamming and trolling (thanks python-list-owner for
>> staying on top of that!), I propose to disconnect comp.lang
On 2021-05-06, Paul Bryan wrote:
> What's involved in moderating c.l.p? Would there be volunteers willing
> to do so?
Nothing at all is involved, apart from changing the status of the group.
The moderation would be done by the same people, in the same way, as the
moderation of the list is done no
On 2021-05-06, Richard Damon wrote:
> On 5/5/21 9:40 PM, Jon Ribbens via Python-list wrote:
>> On 2021-05-06, Paul Bryan wrote:
>>> What's involved in moderating c.l.p? Would there be volunteers willing
>>> to do so?
>> Nothing at all is involved, apart
On 2021-05-06, Richard Damon wrote:
> On 5/5/21 10:44 PM, Jon Ribbens via Python-list wrote:
>> On 2021-05-06, Richard Damon wrote:
>>> As someone with a long usenet background, converting the existing group
>>> to moderated would be practically impossible. It just is
On 2021-05-06, Skip Montanaro wrote:
>> Are you unaware that the group is already gatewayed to a moderated
>> mailing list for which all of that work is already done?
>
> What is this moderation of which you speak? I'm one of the Python
> postmasters (I maintain the SpamBayes setup) and am aware o
On 2021-05-06, Richard Damon wrote:
> On 5/6/21 6:12 AM, Jon Ribbens via Python-list wrote:
>> I think you're fundamentally missing the point that the newsgroup is
>> *already gatewayed to the mailing list*. Marking the group moderated
>> will not result in any more w
On 2021-05-06, Skip Montanaro wrote:
>> Are you saying that the messages that appear occasionally from people
>> such as Ethan Furman claiming to be moderators and alleging that
>> particular people have been banned or suspended are lies? And that the
>> message I received once saying that my comp
On 2021-05-06, Richard Damon wrote:
> On 5/6/21 9:12 AM, Jon Ribbens via Python-list wrote:
>> Are you saying that the messages that appear occasionally from people
>> such as Ethan Furman claiming to be moderators and alleging that
>> particular people have been banned or su
On 2021-05-06, Richard Damon wrote:
> On 5/6/21 9:44 AM, Jon Ribbens via Python-list wrote:
>> Sounds like nearly all moderated lists/forums then.
>
> Then perhaps you have never been on a real Moderated mailing list or
> Forum.
Ah, the "no true scotsforum" argum
On 2021-05-06, Stestagg wrote:
> Where's this discussion going?
>
> Let's not get too caught up on definitions or the sizes of everyone's
> respective .. newsgroups.
>
> Which of the practically possible options are best for this list <->
> newsgroup setup?
As before I'd suggest that changing the
On 2021-05-15, Jason C. McDonald wrote:
> During the Steering Committee presentation at PyCon, it was mentioned
> that no one has formally proposed TOML be added to the standard library
> (emphasis on formal). THe joke went forth that there would be a flood
> of proposals to that end.
>
> So, just
On 2021-05-18, Michael F. Stemper wrote:
> On 17/05/2021 18.48, Terry Reedy wrote:
>> I disagree. Rehashing *opinions* is pretty useless. The issues were
>> already discussed on
>> https://discuss.python.org/t/adopting-recommending-a-toml-parser/4068
>>
>> There are multiple packages. There is
1 - 100 of 215 matches
Mail list logo