[issue33934] locale.getlocale() seems wrong when the locale is yet unset (python3 on linux)

2018-06-24 Thread Nicolas Hainaux
Nicolas Hainaux added the comment: I understand that the statement "when python starts, it runs using the C locale..." should not be correct anymore (and the doc should then be updated), but in fact this statement is still true on the systems I tested; only, the output of locale.getlocale()

[issue33897] Add a restart option to logging.basicConfig()

2018-06-24 Thread Vinay Sajip
Change by Vinay Sajip : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue33897] Add a restart option to logging.basicConfig()

2018-06-24 Thread Vinay Sajip
Vinay Sajip added the comment: New changeset cf67d6a934b51b1f97e72945b596477b271f70b8 by Vinay Sajip (Dong-hee Na) in branch 'master': bpo-33897: Add a 'force' keyword argument to logging.basicConfig(). (GH-7873)

[issue33952] doc Fix typo in str.upper() documentation

2018-06-24 Thread Andrés Delfino
Change by Andrés Delfino : -- keywords: +patch pull_requests: +7504 stage: -> patch review ___ Python tracker ___ ___

[issue33952] doc Fix typo in str.upper() documentation

2018-06-24 Thread Andrés Delfino
New submission from Andrés Delfino : Doc says: Note that str.upper().isupper() might be False if s... Should say: Note that s.upper().isupper() might be False if s... PR fixes this. -- assignee: docs@python components: Documentation messages: 320395 nosy: adelfino, docs@python

[issue24567] random.choice IndexError due to double-rounding

2018-06-24 Thread Tim Peters
Tim Peters added the comment: There are a couple bug reports here that have been open for years, and it's about time we closed them. My stance: if any platform still exists on which "double rounding" is still a potential problem, Python _configuration_ should be changed to disable double

[issue33944] Deprecate and remove pth files

2018-06-24 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: On Jun 23, 2018, at 18:56, Nick Coghlan wrote: > > My request (wearing my "BDFL-delegate for packaging interoperability > standards" hat) is that proponents of the change resist the temptation to > view the problem that way :) > > Path files are used

[issue24567] random.choice IndexError due to double-rounding

2018-06-24 Thread Raymond Hettinger
Raymond Hettinger added the comment: Attaching a patch for 3.6 and 3.7. Haven't had a chance to run timings yet. Since it involves adding code to the inner loop, presumably it will have a noticeable affect on speed. Am not sure how to test this (I don't seem to be able to reproduce the

Re: syntax difference

2018-06-24 Thread Steven D'Aprano
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. https://blog.pythonanywhere.com/67/ https://stackoverflow.blog/2017/09/06/incredible-growth-python/ For a language which

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

2018-06-24 Thread Ben Finney
Paul Moore writes: > On 24 June 2018 at 06:03, Steven D'Aprano > wrote: > > Given this function: > > > > 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: Anyone here on Python-Dev mailing list?

2018-06-24 Thread Ben Finney
Steven D'Aprano writes: > 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? I am on that forum (via Gmane), and am not receiving

Re: Package directory question

2018-06-24 Thread Ben Finney
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 it should be done? It looks

[issue33711] Could not find externals/db-* in msi.py on license generation

2018-06-24 Thread Zachary Ware
Zachary Ware added the comment: Thanks for the patch, Ivan, and the review, Anselm! -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker ___

[issue33711] Could not find externals/db-* in msi.py on license generation

2018-06-24 Thread Zachary Ware
Zachary Ware added the comment: New changeset b18f09835720e14ac7d4cca1815fdcdcecd5d8d4 by Zachary Ware (native-api) in branch '2.7': bpo-33711: Fix license generation error in installer build script (GH-7241) https://github.com/python/cpython/commit/b18f09835720e14ac7d4cca1815fdcdcecd5d8d4

[issue33089] Add multi-dimensional Euclidean distance function to the math module

2018-06-24 Thread Tim Peters
Tim Peters added the comment: Raymond, I'd say scaling is vital (to prevent spurious infinities), but complications beyond that are questionable, slowing things down for an improvement in accuracy that may be of no actual benefit. Note that your original "simple homework problems for kids

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

2018-06-24 Thread Paul Moore
On 24 June 2018 at 06: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

[issue33951] IDLE test failing only when called by itself: HighPageTest.test_highlight_target_text_mouse

2018-06-24 Thread miss-islington
miss-islington added the comment: New changeset cef5da5441776090026c735ca1c9fa277f8b9931 by Miss Islington (bot) in branch '3.6': bpo-33951: IDLE test_configdialog: call page.update in setUpClass (GH-7892) https://github.com/python/cpython/commit/cef5da5441776090026c735ca1c9fa277f8b9931

[ANN] pdfposter 0.7

2018-06-24 Thread Hartmut Goebel
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 Licence v3 (GPLv3) :Quick Installation:     pip install -U pdftools.pdfposter

[issue33944] Deprecate and remove pth files

2018-06-24 Thread Antoine Pitrou
Antoine Pitrou added the comment: I would also add that editable installs should not break in the process. They are important. -- nosy: +pitrou ___ Python tracker ___

[issue33951] IDLE test failing only when called by itself: HighPageTest.test_highlight_target_text_mouse

2018-06-24 Thread miss-islington
Change by miss-islington : -- pull_requests: +7503 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue33951] IDLE test failing only when called by itself: HighPageTest.test_highlight_target_text_mouse

2018-06-24 Thread miss-islington
miss-islington added the comment: New changeset b3bac968fe5beb6e6e334903519b2c8ce5bb366b by Miss Islington (bot) in branch '3.7': bpo-33951: IDLE test_configdialog: call page.update in setUpClass (GH-7892) https://github.com/python/cpython/commit/b3bac968fe5beb6e6e334903519b2c8ce5bb366b

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: I have modified the PR to avoid creating an extra pipe in the tracker (the pipe is created as part of the test). To allow testing with the -R option: ./python -m test test_multiprocessing_fork -v -m test_semaphore_tracker_sigint -R 3:3 I had to

Re: syntax difference

2018-06-24 Thread Bart
On 24/06/2018 20:02, Steven D'Aprano wrote: On Sun, 24 Jun 2018 19:37:33 +0100, Bart wrote: I want to program in /my/ style Python is not Java, and Java is not Python either. Nor is it "Bart's Language", or C, or Forth, or Lisp, or bash.

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

2018-06-24 Thread Abdur-Rahmaan Janhangeer
naaa it was not meant to be python ^^ Abdur-Rahmaan Janhangeer https://github.com/Abdur-rahmaanJ > > -- https://mail.python.org/mailman/listinfo/python-list

Re: translating foreign data

2018-06-24 Thread Stefan Ram
To: Richard Damon From: r...@zedat.fu-berlin.de (Stefan Ram) Richard Damon writes: >Now, if I have a parser that doesn't use the locale, but some other rule >base than I just need to provide it with the right rules, which is >basically just defining the right locale. Here's an example C++

Re: translating foreign data

2018-06-24 Thread Peter J. Holzer
From: "Peter J. Holzer" --b2wbudmypdkmv7il Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2018-06-23 12:11:34 -0400, Richard Damon wrote: > On 6/23/18 10:05 AM, Peter J. Holzer wrote: > > On 2018-06-23 08:41:38 -0400,

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread MRAB
From: MRAB On 2018-06-23 05:16, Chris Angelico wrote: > On Sat, Jun 23, 2018 at 1:51 PM, Steven D'Aprano > wrote: >> On Wed, 20 Jun 2018 14:18:19 +1000, Chris Angelico wrote: >> >>> Ah. Yeah, that would be a plausible feature to add to Python. But in C, >>> a static variable is basically the

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread Bart
To: Stefan Ram From: Bart On 23/06/2018 14:32, Stefan Ram wrote: > r...@zedat.fu-berlin.de (Stefan Ram) writes: >> def f(): >> def g(): >> g.x += 1 >> return g.x >> g.x = 0 >> return g > >Or, "for all g to share the same x": > >main.py > > def f(): >

[issue33951] IDLE test failing only when called by itself: HighPageTest.test_highlight_target_text_mouse

2018-06-24 Thread Terry J. Reedy
Change by Terry J. Reedy : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue33951] IDLE test failing only when called by itself: HighPageTest.test_highlight_target_text_mouse

2018-06-24 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset 2af9f5d334eeca58887d177faf0012c63a03 by Terry Jan Reedy (Tal Einat) in branch 'master': bpo-33951: IDLE test_configdialog: call page.update in setUpClass (GH-7892)

[issue33951] IDLE test failing only when called by itself: HighPageTest.test_highlight_target_text_mouse

2018-06-24 Thread miss-islington
Change by miss-islington : -- pull_requests: +7502 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

Re: translating foreign data

2018-06-24 Thread Richard Damon
From: Richard Damon On 6/23/18 11:44 AM, Steven D'Aprano wrote: > On Sat, 23 Jun 2018 08:12:52 -0400, Richard Damon wrote: > >> On 6/23/18 7:46 AM, Steven D'Aprano wrote: >>> On Sat, 23 Jun 2018 06:26:22 -0400, Richard Damon wrote: >>> If you know the Locale, then you do know what the

Re: translating foreign data

2018-06-24 Thread Richard Damon
From: Richard Damon On 6/23/18 10:05 AM, Peter J. Holzer wrote: > On 2018-06-23 08:41:38 -0400, Richard Damon wrote: >> On 6/23/18 8:28 AM, Peter J. Holzer wrote: >>> On 2018-06-23 08:12:52 -0400, Richard Damon wrote: On 6/23/18 7:46 AM, Steven D'Aprano wrote: > If I'm in Australia,

Re: translating foreign data

2018-06-24 Thread Peter J. Holzer
From: "Peter J. Holzer" --ngg56dmsr6vcxzs5 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2018-06-23 12:41:33 -0400, Richard Damon wrote: > On 6/23/18 11:44 AM, Steven D'Aprano wrote: > > You're assuming that there will be

Re: "Data blocks" syntax specification draft

2018-06-24 Thread Rick Johnson
From: Rick Johnson On Sunday, May 20, 2018 at 5:29:11 PM UTC-5, Mikhail V wrote: > What against PDF? I'm not a big fan of PDF either. Adobe Reader is one the most bloated POS software i have ever had the misfortune of hosting on my computers, and i absolutely refuse to host that crapware any

Re: translating foreign data

2018-06-24 Thread Dennis Lee Bieber
From: Dennis Lee Bieber On Sat, 23 Jun 2018 15:44:14 + (UTC), Steven D'Aprano declaimed the following: >1.234.567,012345678 > >which is understandable to anyone who is aware of the possibility that >comma may mean decimal separator and period the thousands separator. > Or it is

Re: translating foreign data

2018-06-24 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 08:12:52 -0400, Richard Damon wrote: > On 6/23/18 7:46 AM, Steven D'Aprano wrote: >> On Sat, 23 Jun 2018 06:26:22 -0400, Richard Damon wrote: >> >>> If you know the Locale, then you do know what the decimal separator >>> is, as that is part of what a

Re: translating foreign data

2018-06-24 Thread Steven D'Aprano
From: Steven D'Aprano 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_MONETARY)? > > If I processed that on my system I

Re: "Data blocks" syntax specification draft

2018-06-24 Thread Abdur-Rahmaan Janhangeer
From: Abdur-Rahmaan Janhangeer the tab separated idea is used in : e.g. see last section of files 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: translating foreign data

2018-06-24 Thread Peter J. Holzer
From: "Peter J. Holzer" --p4u6dkqn7e5fhtwt Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2018-06-23 08:41:38 -0400, Richard Damon wrote: > On 6/23/18 8:28 AM, Peter J. Holzer wrote: > > On 2018-06-23 08:12:52 -0400,

Re: translating foreign data

2018-06-24 Thread Peter J. Holzer
From: "Peter J. Holzer" --jbhqoow7s7225t6e Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2018-06-23 16:05:49 +0200, Peter J. Holzer wrote: > I don't think that's a useful way to look at it. "Locale" in > (non-technical)

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread Stefan Ram
To: Steven D'Aprano From: r...@zedat.fu-berlin.de (Stefan Ram) Steven D'Aprano writes: >def f(): >static x = 0 >def g(): >x += 1 >return x >return g What one can do today: main.py def g(): g.x += 1 return g.x g.x = 0 print( g() ) print( g() ) print(

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread Ed Kellett
From: Ed Kellett This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --Xw5fa1GFtucLPGBT1sLtLtUpmbraGkiYl Content-Type: multipart/mixed; boundary="lDyl22ZCUIEM3fl5YMnfJ3B8O9bwBCY9r"; protected-headers="v1" From: Ed Kellett To: python-list@python.org Message-ID:

Re: translating foreign data

2018-06-24 Thread Marko Rauhamaa
To: Richard Damon From: Marko Rauhamaa Richard Damon : > On 6/23/18 9:05 AM, Marko Rauhamaa wrote: >> Richard Damon : >> >>> On 6/23/18 8:03 AM, Marko Rauhamaa wrote: I always know my locale. The locale is tied to the human user. >>> No, it should be tied to the data you are processing.

Re: translating foreign data

2018-06-24 Thread Richard Damon
From: Richard Damon On 6/23/18 9:05 AM, Marko Rauhamaa wrote: > Richard Damon : > >> On 6/23/18 8:03 AM, Marko Rauhamaa wrote: >>> I always know my locale. The locale is tied to the human user. >> No, it should be tied to the data you are processing. >In computing, a locale is a set of

Re: translating foreign data

2018-06-24 Thread Richard Damon
From: Richard Damon On 6/23/18 8:03 AM, Marko Rauhamaa wrote: > Richard Damon : >> If you know the Locale, then you do know what the decimal separator >> is, as that is part of what a locale defines. > I don't know what that sentence means. When you set the locale > >> The issue is that if you

Re: translating foreign data

2018-06-24 Thread Richard Damon
From: Richard Damon On 6/23/18 7:46 AM, Steven D'Aprano wrote: > On Sat, 23 Jun 2018 06:26:22 -0400, Richard Damon wrote: > >> If you know the Locale, then you do know what the decimal separator is, >> as that is part of what a locale defines. > A locale defines a set of common cultural

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread Stefan Ram
To: Stefan Ram From: r...@zedat.fu-berlin.de (Stefan Ram) r...@zedat.fu-berlin.de (Stefan Ram) writes: >def f(): >def g(): >g.x += 1 >return g.x >g.x = 0 >return g Or, "for all g to share the same x": main.py def f(): def g(): f.x += 1

Re: translating foreign data

2018-06-24 Thread Steven D'Aprano
From: Steven D'Aprano On Sat, 23 Jun 2018 06:26:22 -0400, Richard Damon wrote: > If you know the Locale, then you do know what the decimal separator is, > as that is part of what a locale defines. A locale defines a set of common cultural conventions. It doesn't mandate the actual conventions

Re: translating foreign data

2018-06-24 Thread Marko Rauhamaa
To: Richard Damon From: Marko Rauhamaa Richard Damon : > On 6/23/18 8:03 AM, Marko Rauhamaa wrote: >> I always know my locale. The locale is tied to the human user. > No, it should be tied to the data you are processing. In computing, a locale is a set of parameters that defines the

Re: ironpython not support py3.6

2018-06-24 Thread Peter J. Holzer
From: "Peter J. Holzer" --prnws536gtytpj5v Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2018-06-22 17:20:29 -0700, denis.akhiya...@gmail.com wrote: > Either wait for IronPython 3.6, use COM interop, pythonnet, >

Re: translating foreign data

2018-06-24 Thread Richard Damon
From: Richard Damon On 6/23/18 8:28 AM, Peter J. Holzer wrote: > On 2018-06-23 08:12:52 -0400, Richard Damon wrote: >> On 6/23/18 7:46 AM, Steven D'Aprano wrote: >>> On Sat, 23 Jun 2018 06:26:22 -0400, Richard Damon wrote: If you know the Locale, then you do know what the decimal separator

Re: ironpython not support py3.6

2018-06-24 Thread wxjmfauth
To: Steven D'Aprano From: wxjmfa...@gmail.com Le vendredi 22 juin 2018 11:07:15 UTC+2, Steven D'Aprano a ─CcritΓ : > > C# <--> IronPython 2.7 <--> CPython 3.6 > C# <--> IronPython 2.7. It will not work. Coding of characters ! Try with IronPython 2.7.8. PS Yes, I know, it is based on .NET !!!

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread Bart
To: Steven D'Aprano From: Bart On 23/06/2018 04:51, Steven D'Aprano wrote: > On Wed, 20 Jun 2018 14:18:19 +1000, Chris Angelico wrote: > >> Ah. Yeah, that would be a plausible feature to add to Python. But in C, >> a static variable is basically the same thing as a global variable, >> except

Re: translating foreign data

2018-06-24 Thread Peter J. Holzer
From: "Peter J. Holzer" --drblskvcly73v23o Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2018-06-23 08:12:52 -0400, Richard Damon wrote: > On 6/23/18 7:46 AM, Steven D'Aprano wrote: > > On Sat, 23 Jun 2018 06:26:22 -0400,

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread Chris Angelico
From: Chris Angelico On Sat, Jun 23, 2018 at 1:51 PM, Steven D'Aprano wrote: > On Wed, 20 Jun 2018 14:18:19 +1000, Chris Angelico wrote: > >> Ah. Yeah, that would be a plausible feature to add to Python. But in C, >> a static variable is basically the same thing as a global variable, >> except

Re: translating foreign data

2018-06-24 Thread Marko Rauhamaa
To: Richard Damon From: Marko Rauhamaa Richard Damon : > If you know the Locale, then you do know what the decimal separator > is, as that is part of what a locale defines. I don't know what that sentence means. > The issue is that if you just know the encoding, you don't necessarily > know

Static variables [was Re: syntax difference]

2018-06-24 Thread Steven D'Aprano
From: Steven D'Aprano On Wed, 20 Jun 2018 14:18:19 +1000, Chris Angelico wrote: > Ah. Yeah, that would be a plausible feature to add to Python. But in C, > a static variable is basically the same thing as a global variable, > except that its name is scoped to the function. There is only one of

Re: translating foreign data

2018-06-24 Thread Steven D'Aprano
From: Steven D'Aprano On Fri, 22 Jun 2018 20:06:35 +0100, Ben Bacarisse wrote: > Steven D'Aprano writes: > >> On Fri, 22 Jun 2018 11:14:59 +0100, Ben Bacarisse wrote: >> > The code page remark is curious. Will some "code pages" have digits > that are not ASCII digits? Good

Re: translating foreign data

2018-06-24 Thread Richard Damon
From: Richard Damon On 6/22/18 11:21 PM, Steven D'Aprano wrote: > On Fri, 22 Jun 2018 20:06:35 +0100, Ben Bacarisse wrote: > >> Steven D'Aprano writes: >> >>> On Fri, 22 Jun 2018 11:14:59 +0100, Ben Bacarisse wrote: >>> >> The code page remark is curious. Will some "code pages" have digits

RE: ironpython not support py3.6

2018-06-24 Thread denis akhiyarov
To: Schachner, Joseph From: denis.akhiya...@gmail.com Either wait for IronPython 3.6, use COM interop, pythonnet, subprocess, or things like gRPC. Based on PyPy experience, it is probably 1-2 years of sponsored development to get a working IronPython 3.6. --- BBBS/Li6 v4.10 Toy-3 * Origin:

Re: Static variables [was Re: syntax difference]

2018-06-24 Thread Chris Angelico
From: Chris Angelico On Sat, Jun 23, 2018 at 2:16 PM, Chris Angelico wrote: > For getting rid of the "len=len" trick, though, I would REALLY like to > transform those into LOAD_CONST. That'd be a fun bytecode hack all on > its own. In fact, I'm gonna have a shot at that. An "early bind these >

Re: translating foreign data

2018-06-24 Thread Ben Bacarisse
To: Steven D'Aprano From: Ben Bacarisse Steven D'Aprano writes: > On Fri, 22 Jun 2018 11:14:59 +0100, Ben Bacarisse wrote: > The code page remark is curious. Will some "code pages" have digits that are not ASCII digits? >>> >>> Good question. I have no idea. >> >> It's much more

Re: Feeding the trolls

2018-06-24 Thread mm0fmf
To: Steven D'Aprano From: mm0fmf On 22/06/2018 00:51, Steven D'Aprano wrote: > On Thu, 21 Jun 2018 21:49:15 +0100, mm0fmf wrote: > > [snip unnecessary quoting] >> Design requirements for python newsreader client: >> >> 1. Block all top posters > > I think it would be far more useful to block

Re: translating foreign data

2018-06-24 Thread Richard Damon
On 6/23/18 10:44 PM, Steven D'Aprano wrote: > 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

[issue32554] random.seed(tuple) uses the randomized hash function and so is not reproductible

2018-06-24 Thread Raymond Hettinger
Raymond Hettinger added the comment: I'm thinking of something like this: $ git diff diff --git a/Lib/random.py b/Lib/random.py index 1e0dcc87ed..f479e66ada 100644 --- a/Lib/random.py +++ b/Lib/random.py @@ -136,12 +136,17 @@ class Random(_random.Random): x ^= len(a)

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: The process seems to use its own stderr and it cannot be captured from the parent without modifying it AFAIK. -- ___ Python tracker

[issue31861] aiter() and anext() built-in functions

2018-06-24 Thread Joshua Bronson
Change by Joshua Bronson : -- nosy: +jab ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

Re: syntax difference

2018-06-24 Thread Richard Damon
On 6/24/18 3:02 PM, Steven D'Aprano wrote: > On Sun, 24 Jun 2018 19:37:33 +0100, Bart wrote: > >> I want to program in /my/ style > Python is not Java, and Java is not Python either. Nor is it "Bart's > Language", or C, or Forth, or Lisp, or bash. > >

Re: syntax difference

2018-06-24 Thread Steven D'Aprano
On Sun, 24 Jun 2018 19:37:33 +0100, Bart wrote: > I want to program in /my/ style Python is not Java, and Java is not Python either. Nor is it "Bart's Language", or C, or Forth, or Lisp, or bash. https://dirtsimple.org/2004/12/python-is-not-java.html

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

2018-06-24 Thread Bart
On 24/06/2018 19:36, Abdur-Rahmaan Janhangeer wrote: 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

Re: Anyone here on Python-Dev mailing list?

2018-06-24 Thread Terry Reedy
On 6/24/2018 12:07 PM, 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

Re: syntax difference

2018-06-24 Thread Terry Reedy
On 6/24/2018 11:39 AM, Bart wrote: Bart, I agree that people should not dogpile onto you. As with Rick, I read your posts or not, depending on whether I feel like being entertained at the moment, and usually move on without comment. I know I'm going to get flak for bringing this up this

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Antoine Pitrou
Antoine Pitrou added the comment: Is it possible to notify the ping / noop reply on stderr instead of introducing a new pipe? -- ___ Python tracker ___

[issue33089] Add multi-dimensional Euclidean distance function to the math module

2018-06-24 Thread Raymond Hettinger
Raymond Hettinger added the comment: Would it be reasonable for me to get started with a "mostly good enough" version using scaling and Kahan summation? from operator import sub from math import sqrt, fabs def kahan_summation(seq): #

Re: syntax difference

2018-06-24 Thread 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 elsewhere, and that is

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

2018-06-24 Thread 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 stuffs Abdur-Rahmaan Janhangeer

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: I have updated the PR implementing a PONG command in the semaphore and updating the test. I have tested on the failing buildbots (gcc110.fsffrance.org) and it works. Notice that a new pipe for the child to write was needed as the child is

[issue33945] concurrent.futures ProcessPoolExecutor submit() blocks on results being written

2018-06-24 Thread Thomas Moreau
Thomas Moreau added the comment: This behavior results from the fact that in 3.6, the result_queue is used to pass messages to the queue_manager_thread. This behavior has been changed in 3.7 as we rely on a _ThreadWakeup object. In 3.6, when the result_queue is filled with many large

[issue33945] concurrent.futures ProcessPoolExecutor submit() blocks on results being written

2018-06-24 Thread Antoine Pitrou
Antoine Pitrou added the comment: I'm not sure what happens exactly in your workload, but waiting 20 seconds when posting some data on an unbounded queue sounds enormous. -- nosy: +tomMoral ___ Python tracker

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Tal Einat
Tal Einat added the comment: For the "no-op" we'll need a way to know that it was processed. To that end, I'd make the semaphore tracker recognize a new command e.g. "PING", upon which it would write something e.g. "PONG" into its end of the pipe. --

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

2018-06-24 Thread 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 poof, suddenly it >

Re: Anyone here on Python-Dev mailing list?

2018-06-24 Thread 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. environment in that case may refer

Re: Anyone here on Python-Dev mailing list?

2018-06-24 Thread 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 >> (some bot?) calling himself

Re: syntax difference

2018-06-24 Thread 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 thousands of programmers for

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

2018-06-24 Thread 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 https://github.com/Abdur-rahmaanJ

Re: Anyone here on Python-Dev mailing list?

2018-06-24 Thread 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? > > Typical example: > >

Anyone here on Python-Dev mailing list?

2018-06-24 Thread 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 computer. Stalls and

[issue33711] Could not find externals/db-* in msi.py on license generation

2018-06-24 Thread Anselm Kruis
Anselm Kruis added the comment: I'm build msi installers regularly and I can confirm the issue. PR 7241 is ok and should be merged. -- nosy: +anselm.kruis ___ Python tracker

Re: Introducing Coconut

2018-06-24 Thread Abdur-Rahmaan Janhangeer
hum syntactic coating exists even in py. nice! Abdur-Rahmaan Janhangeer https://github.com/Abdur-rahmaanJ > > -- https://mail.python.org/mailman/listinfo/python-list

Re: syntax difference

2018-06-24 Thread 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 constantly needs to

Re: syntax difference

2018-06-24 Thread 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? Because its just you who spends 90% of his time here

Re: syntax difference

2018-06-24 Thread 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 Python and you do

Re: syntax difference

2018-06-24 Thread 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? >> >> Because its just you

Re: Introducing Coconut

2018-06-24 Thread 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. I just think its

Re: syntax difference

2018-06-24 Thread 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 about > how Python does

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: @pitrou I think that should be ideal. The reason is that if we send an invalid command the cache is not cleared and the semaphore tracker will warn when the process finishes which is precisely what the test is avoiding. --

Package directory question

2018-06-24 Thread Robert Latest via Python-list
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__.py | | |--

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Additionally, as I commented in the PR, apart from the race condition I think the test should be modified so it fails if the warning is raised and not expected: >The problem is that the test was silently failing when SIGINT was >being >delivered as

[issue33613] test_multiprocessing_fork: test_semaphore_tracker_sigint() fails with -W error

2018-06-24 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Sorry, I was wrong, it does not die. I am investigating this solution using stderr. -- ___ Python tracker ___

  1   2   >