[issue35993] incorrect use of released memory in Python/pystate.c line 284

2019-02-13 Thread Stéphane Wirtel
Change by Stéphane Wirtel : -- assignee: -> matrixise nosy: +matrixise ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue35991] potential double free in Modules/_randommodule.c line 295 and line 317

2019-02-13 Thread miss-islington
Change by miss-islington : -- pull_requests: +11883 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35991] potential double free in Modules/_randommodule.c line 295 and line 317

2019-02-13 Thread Benjamin Peterson
Benjamin Peterson added the comment: New changeset bb3c05d7efca8d23bf39bc2640297ba2598899f3 by Benjamin Peterson (Zackery Spytz) in branch 'master': closes bpo-35991: Fix a potential double free in Modules/_randommodule.c. (GH-11849)

[issue35994] In WalkTests of test_os.py, sub2_tree missed the dir "SUB21" if symlink can't be supported.

2019-02-13 Thread Peixing Xin
New submission from Peixing Xin : Looking into the setUp method of WalkTests class in test_os.py, sub2_tree missed "SUB21" in its directory list if support.can_symlink() returns False. -- components: Tests messages: 335505 nosy: pxinwr priority: normal severity: normal status: open

[issue35155] Clarify Protocol Handlers in urllib.request Docs

2019-02-13 Thread Denton Liu
Denton Liu added the comment: Unfortunately, inline markup can't be combined with roles. Using asterisks, it shows up as `**_open()` and using braces, `{}_open`. I'm not sure how this works but it _might_ be possible to change how :meth: role is interpreted but I believe that's outside the

[issue23460] Decimals do not obey ':g' exponential notation formatting rules

2019-02-13 Thread Brennan D Baraban
Brennan D Baraban <3...@holbertonschool.com> added the comment: I submitted a PR just now. I only pushed the change to `string.rst`, as per Stefan Krah's suggestion. -- ___ Python tracker

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread ast
Le 13/02/2019 à 14:21, ast a écrit : Hello >>> float('Nan') == float('Nan') False Why ? Regards Thank you for answers. If you wonder how I was trapped with it, here is the failing program. r = float('Nan') while r==float('Nan'): inp = input("Enter a number\n") try: r =

[issue23460] Decimals do not obey ':g' exponential notation formatting rules

2019-02-13 Thread Brennan D Baraban
Change by Brennan D Baraban <3...@holbertonschool.com>: -- pull_requests: +11881 stage: needs patch -> patch review ___ Python tracker ___

[issue35991] potential double free in Modules/_randommodule.c line 295 and line 317

2019-02-13 Thread Zackery Spytz
Change by Zackery Spytz : -- keywords: +patch pull_requests: +11880 stage: -> patch review ___ Python tracker ___ ___

[issue35993] incorrect use of released memory in Python/pystate.c line 284

2019-02-13 Thread wangjiangqiang
New submission from wangjiangqiang <767563...@qq.com>: the code is trying to visit a link list in a loop, it tries to visit the next node in line 284 "interp = interp->next" while the current node is freed in line 296 "PyMem_RawFree(interp);" --

[issue35899] '_is_sunder' function in 'enum' module fails on empty string

2019-02-13 Thread Brennan D Baraban
Brennan D Baraban <3...@holbertonschool.com> added the comment: Thank you, Stéphane. I submitted a change request to your PR just now. -- ___ Python tracker ___

[issue35991] potential double free in Modules/_randommodule.c line 295 and line 317

2019-02-13 Thread wangjiangqiang
wangjiangqiang <767563...@qq.com> added the comment: line 295 calls PyMem_Free(key),then "key" was freed again in line 317 which causes the bug. -- ___ Python tracker ___

[issue35992] Metaclasses interfere with __class_getitem__

2019-02-13 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +levkivskyi ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35993] incorrect use of released memory in Python/pystate.c line 284

2019-02-13 Thread wangjiangqiang
Change by wangjiangqiang <767563...@qq.com>: -- nosy: wjq-security priority: normal severity: normal status: open title: incorrect use of released memory in Python/pystate.c line 284 type: security ___ Python tracker

[issue35991] potential double free in Modules/_randommodule.c line 295 and line 317

2019-02-13 Thread Karthikeyan Singaravelan
New submission from Karthikeyan Singaravelan : Though random module doesn't receive frequent changes can you please add the relevant lines in the description or the relevant commit with the corresponding line number in the report with a description. On master with commit [0] line 295 calls

[issue35992] Metaclasses interfere with __class_getitem__

2019-02-13 Thread Caleb Donovick
New submission from Caleb Donovick : OS: Debian testing python3 -VV: Python 3.7.2+ (default, Feb 2 2019, 14:31:48) [gcc 8.2.0] The following: ``` class Meta(type): pass class X(metaclass=Meta): def __class_getitem__(cls, key): return key X[10] ``` Results in ``` TypeError:

[issue35991] potential double free in Modules/_randommodule.c line 295 and line 317

2019-02-13 Thread wangjiangqiang
Change by wangjiangqiang <767563...@qq.com>: -- nosy: wjq-security priority: normal severity: normal status: open title: potential double free in Modules/_randommodule.c line 295 and line 317 type: security ___ Python tracker

[issue21150] Add quick links table to argparse docs

2019-02-13 Thread Susan Su
Susan Su added the comment: I'm available to start working on this bug. Please let me know if any suggestions, concerns or comments come up! Thank you. -- nosy: +suhearsawho ___ Python tracker

[issue33043] Add a 'Contributing to Docs' link at the bottom of docs.python.org

2019-02-13 Thread Susan Su
Susan Su added the comment: I am available to start working on this bug. Please let me know if any issues, concerns, or suggestions come up! Thank you. -- nosy: +suhearsawho ___ Python tracker

[issue29466] pickle does not serialize Exception __cause__ field

2019-02-13 Thread Tim Burgess
Change by Tim Burgess : -- nosy: +tjb900 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35155] Clarify Protocol Handlers in urllib.request Docs

2019-02-13 Thread Terry J. Reedy
Terry J. Reedy added the comment: For file names, the result is in italics. Looking at https://devguide.python.org/exploring/, that seems to work well. Can we just use **? -- ___ Python tracker

[issue35132] python-gdb error: Python Exception Type does not have a target

2019-02-13 Thread Lisa Roach
Change by Lisa Roach : -- keywords: +patch pull_requests: +11879 stage: -> patch review ___ Python tracker ___ ___

[issue35962] Slight error in words in [ 2.4.1. String and Bytes literals ]

2019-02-13 Thread Lisa Roach
Lisa Roach added the comment: The updated line sounds good to me, please make a PR. -- nosy: +lisroach ___ Python tracker ___ ___

[issue21150] Add quick links table to argparse docs

2019-02-13 Thread Lisa Roach
Lisa Roach added the comment: It looks like @louielu might not be around anymore to finish this PR? If there are no objections I'd like to give a new contributor @suhearsawho a shot at this. -- nosy: +lisroach ___ Python tracker

[issue35500] Align expected and actual calls on mock.assert_called_with error message

2019-02-13 Thread Lisa Roach
Lisa Roach added the comment: New changeset 2bdd5858e3f89555c8de73a0f307d63536129dbd by Lisa Roach (Susan Su) in branch 'master': bpo-35500: align expected and actual calls on mock.assert_called_with error message. (GH-11804)

[issue35155] Clarify Protocol Handlers in urllib.request Docs

2019-02-13 Thread Denton Liu
Denton Liu added the comment: I gave that a try but it seems like it just outputs the {} literally in the case of the method role. -- ___ Python tracker ___

[issue35920] Windows 10 ARM32 platform support

2019-02-13 Thread Steve Dower
Steve Dower added the comment: Issue35976 was broken out for the more mechanical changes. -- ___ Python tracker ___ ___

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Joe Pfeiffer
u...@speedy.net writes: > There are more integers than odd numbers, and more odd numbers than prime > numbers. An infinite set may be a subset of another infinite set although > they may both have the same cardinality. Or in other words, the number of > elements in each set is not equal. One has

[issue1054041] Python doesn't exit with proper resultcode on SIGINT

2019-02-13 Thread Eryk Sun
Eryk Sun added the comment: For Windows, the default console control handler calls ExitProcess(STATUS_CONTROL_C_EXIT). If CMD is waiting on an application that exits with STATUS_CONTROL_C_EXIT, it prints "^C" to indicate the process was killed by Ctrl+C. For example: >>>

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Joe Pfeiffer
songbird writes: > Chris Angelico wrote: >> On Thu, Feb 14, 2019 at 7:12 AM Test Bot wrote: >>> >>> This definition of NaN is much better in mentally visualizing all the so >>> called bizarreness of IEEE. This also makes intuitive that no 2 NaN will be >>> equal just as no 2 infinities would be

[issue35155] Clarify Protocol Handlers in urllib.request Docs

2019-02-13 Thread Cheryl Sabella
Cheryl Sabella added the comment: I found this issue that Serhiy did on the devguide where he added {} around the placeholder: https://github.com/python/devguide/pull/444 I think that might be the correct way to do it. -- ___ Python tracker

[issue35899] '_is_sunder' function in 'enum' module fails on empty string

2019-02-13 Thread Cheryl Sabella
Change by Cheryl Sabella : -- Removed message: https://bugs.python.org/msg335483 ___ Python tracker ___ ___ Python-bugs-list

[issue35927] Intra-package References Documentation Incomplete

2019-02-13 Thread ADataGman
ADataGman added the comment: Terry, thank you for the detailed list of alternatives on how to approach this, that's helpful in how to tackle this issue in my current development. Nick, for the relative imports of relative imports I think the error message is fine. It makes sense. It doesn't

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Chris Angelico
On Thu, Feb 14, 2019 at 11:01 AM songbird wrote: > all such proofs i have ever seen are based upon the > assumptions that there are infinite numbers of such > things like primes. I posted an abbreviated proof of that in a footnote. It's a proof by contradiction. First, assume that there are,

Re: Best way to remove unused pip installed modules/module dependencies from a virtual env?

2019-02-13 Thread Malcolm Greene
[Reformatted as original post got mangled] Looking for advice on the best way to remove unused modules from a Python virtual environment. My setup is Python 3.6.6 running on macOS although I believe my use case is OS independent. Background: Long running project that, over the course of time,

[issue1054041] Python doesn't exit with proper resultcode on SIGINT

2019-02-13 Thread Gregory P. Smith
Gregory P. Smith added the comment: I expect that'll work as desired and avoids the re-raising of the signal. Unless told otherwise I assume this should be a POSIX specific platform behavior. ie: no return value alteration due to an uncaught KeyboardInterrupt on the Windows API build.

[issue22213] Make pyvenv style virtual environments easier to configure when embedding Python

2019-02-13 Thread Steve Dower
Steve Dower added the comment: Thanks, Victor, that's great information. > Memory allocator, context, different structures for configuration... it's > really not an easy topic :-( There are so many constraints put into a single > API! This is why I'm keen to design the ideal *user* API

[issue35899] '_is_sunder' function in 'enum' module fails on empty string

2019-02-13 Thread Cheryl Sabella
Cheryl Sabella added the comment: I found this issue that Serhiy did on the devguide where he added {} around the placeholder: https://github.com/python/devguide/pull/444 I think that might be the correct way to do it. -- ___ Python tracker

[issue1054041] Python doesn't exit with proper resultcode on SIGINT

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: > A question that leads to is what _is_ the correct value. What do you think of using a short test program (ex: uses raise(SIGINT)) in ./configure to get the "default exit code" to define a constant, and then use the constant for exit() in Python? I

[issue1054041] Python doesn't exit with proper resultcode on SIGINT

2019-02-13 Thread Gregory P. Smith
Change by Gregory P. Smith : -- stage: patch review -> needs patch ___ Python tracker ___ ___ Python-bugs-list mailing list

Best way to remove unused pip installed modules/module dependencies from a virtual env?

2019-02-13 Thread Malcolm Greene
Looking for advice on the best way to remove unused modules from a Python virtual environment. My setup is Python 3.6.6 running on macOS although I believe my use case is OS independent. Background: Long running project that, over the course of time, pip installed modules that are no longer used

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread songbird
Chris Angelico wrote: > On Thu, Feb 14, 2019 at 7:12 AM Test Bot wrote: >> >> This definition of NaN is much better in mentally visualizing all the so >> called bizarreness of IEEE. This also makes intuitive that no 2 NaN will be >> equal just as no 2 infinities would be equal. I believe in a

[issue1054041] Python doesn't exit with proper resultcode on SIGINT

2019-02-13 Thread Gregory P. Smith
Gregory P. Smith added the comment: Taking a renewed look at this 8 years later... I agree, re-triggering the signal with the SIG_DFL handler would prevent us from doing the existing interpreter shutdown cleanup if we did it too early which would be a behavior change other than the exit

[issue1054041] Python doesn't exit with proper resultcode on SIGINT

2019-02-13 Thread Gregory P. Smith
Change by Gregory P. Smith : -- versions: +Python 3.8 -Python 3.3 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue35887] Doc string for updating the frozen version of importlib in _bootstrap.py incorrect

2019-02-13 Thread Brett Cannon
Brett Cannon added the comment: New changeset 1dc5cb9cb3447211069a7788208254b1cfa8ec98 by Brett Cannon (Nina Zakharenko) in branch 'master': bpo-35887: Add make regen-importlib step to importlib._bootstrap docstring (GH-11777)

What's up with Activestate Python?

2019-02-13 Thread Grant Edwards
For many, many years I've always installed ActiveState's ActivePython Community edition when forced to use Windows. It has always included all of the "extra" libraries that I didn't wan't to install (or couldn't because I didn't have a C compiler for Windows). I recently decided to upgrade my

[issue22213] Make pyvenv style virtual environments easier to configure when embedding Python

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: > It seems that the disagreement about the design is fundamentally a > disagreement between a "quick, painful but complete fix" and "slow, careful > improvements with a transition period". Both are valid approaches, and since > Victor is putting actual

[issue20523] global .pdbrc on windows 7 not reachable out of the box

2019-02-13 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +11878 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Chris Angelico
On Thu, Feb 14, 2019 at 9:07 AM Avi Gross wrote: > But that means that normal mathematics is warped. Well yes. Yes, it is. That's why people think "Alice's Adventures in Wonderland" is the result of a drug-induced dream - in actual fact, it's the result of the Dean of Mathematics telling

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Avi Gross
I think we should realize that Nan and NA and so on are human constructs people Define in programming languages. Some have subdivisions as in not an int as compared to not a float. Python also has an Inf as well as a -Inf that are abstractions and not a real, so to speak. Number. Mathematics

[issue20523] global .pdbrc on windows 7 not reachable out of the box

2019-02-13 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +11877 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Chris Angelico
‪On Thu, Feb 14, 2019 at 8:24 AM ‫אורי‬‎ wrote:‬ > On Wed, Feb 13, 2019 at 10:20 PM Chris Angelico wrote: >> >> Why would no two infinities be equal? In mathematics, there's one >> best-known infinity (aleph null, aka the number of counting numbers), >> and many many infinities are provably

[issue17703] Trashcan mechanism segfault during interpreter finalization in Python 2.7.4

2019-02-13 Thread Jeroen Demeyer
Jeroen Demeyer added the comment: See also https://bugs.python.org/issue35983 for another trashcan-related issue. -- nosy: +jdemeyer ___ Python tracker ___

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread אורי
אורי u...@speedy.net On Wed, Feb 13, 2019 at 10:20 PM Chris Angelico wrote: > On Thu, Feb 14, 2019 at 7:12 AM Test Bot wrote: > > > > This definition of NaN is much better in mentally visualizing all the so > > called bizarreness of IEEE. This also makes intuitive that no 2 NaN will > be > >

How do/can I generate a PKCS#12 file the cryptography module?

2019-02-13 Thread Travis Griggs
I’m using the cryptography module (https://cryptography.io/en/latest/) to try and generate some cert/key/identities. It's pretty easy using said module to generate the contents of .pem file for a private key: keyPEMBytes = privateKey.private_bytes(

[issue35984] test__xxsubinterpreters leaked [3, 4, 3] memory blocks, sum=1

2019-02-13 Thread Alexey Izbyshev
Alexey Izbyshev added the comment: Thank you for your introduction about _xxsubinterpreters, Eric. This particular leak is easy: it's right in _channel_send(). I've submitted a PR. I've also done a quick scan of neighboring code, and it seems there are other leaks as well, e.g.: *

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Rob Gaddi
On 2/13/19 12:32 PM, Marko Rauhamaa wrote: "Avi Gross" : A NaN is a bit like a black hole. Anything thrown in disappears and that is about all we know about it. No two black holes are the same even if they seem to have the same mass, spin and charge. All they share is that we don't know what

[issue35984] test__xxsubinterpreters leaked [3, 4, 3] memory blocks, sum=1

2019-02-13 Thread Alexey Izbyshev
Change by Alexey Izbyshev : -- keywords: +patch pull_requests: +11876 stage: test needed -> patch review ___ Python tracker ___ ___

[issue35983] tp_dealloc trashcan shouldn't be called for subclasses

2019-02-13 Thread Jeroen Demeyer
Jeroen Demeyer added the comment: NOTE: also OrderedDict currently uses trashcan hacking to work around this problem: /* Call the base tp_dealloc(). Since it too uses the trashcan mechanism, * temporarily decrement trash_delete_nesting to prevent triggering it * and putting

[issue35989] ipaddress.IPv4Network allows prefix > 32

2019-02-13 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: I proposed my PR but I prefer a review because in the code of ipaddress, there is a function for the validation of an address with the netmask. Maybe we could use this function and try to refactor/improve the current code. -- nosy: +matrixise

[issue35989] ipaddress.IPv4Network allows prefix > 32

2019-02-13 Thread Stéphane Wirtel
Change by Stéphane Wirtel : -- keywords: +patch pull_requests: +11875 stage: test needed -> patch review ___ Python tracker ___ ___

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Marko Rauhamaa
"Avi Gross" : > A NaN is a bit like a black hole. Anything thrown in disappears and > that is about all we know about it. No two black holes are the same > even if they seem to have the same mass, spin and charge. All they > share is that we don't know what is in them. Then, how do you explain:

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Chris Angelico
On Thu, Feb 14, 2019 at 7:12 AM Test Bot wrote: > > This definition of NaN is much better in mentally visualizing all the so > called bizarreness of IEEE. This also makes intuitive that no 2 NaN will be > equal just as no 2 infinities would be equal. I believe in a hypothesis(of > my own

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Test Bot
This definition of NaN is much better in mentally visualizing all the so called bizarreness of IEEE. This also makes intuitive that no 2 NaN will be equal just as no 2 infinities would be equal. I believe in a hypothesis(of my own creation) that any arithmetic on a data type of NaN would be

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Dan Sommers
On 2/13/19 1:53 PM, Grant Edwards wrote: Floating point is sort of the quantum mechanics of computer science. At first glance, it seems sort of weird. But after you work with it a while, it gets even worse. Yep! :-) -- https://mail.python.org/mailman/listinfo/python-list

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Chris Angelico
On Thu, Feb 14, 2019 at 6:55 AM Grant Edwards wrote: > > On 2019-02-13, Schachner, Joseph wrote: > > > This makes some sense because NAN is Not A Number, so any comparison > > to a number fails. > > Ah, but you now seem to be conflating "comparison fails" with > "comparison has a boolean value

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Chris Angelico
On Thu, Feb 14, 2019 at 6:40 AM Schachner, Joseph wrote: > > Because all comparisons with NAN return false, that's the spec. Apart from !=, because it would be insane (I mean, even more insane than it is) to have nan == nan be false AND nan != nan. IEEE NAN has several purposes, including

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Grant Edwards
On 2019-02-13, Schachner, Joseph wrote: > This makes some sense because NAN is Not A Number, so any comparison > to a number fails. Ah, but you now seem to be conflating "comparison fails" with "comparison has a boolean value of False". The alternative to (nan == nan) => False is probably not

RE: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Schachner, Joseph
Because all comparisons with NAN return false, that's the spec. is NAN > 0? False. Is NAN< 0? False. Is NAN == 0? False. Is NAN == ? False. So: Is NAN == NAN? False. And one more: Is NAN < 1.0e18? False This makes some sense because NAN is Not A Number, so any comparison to a number

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Joe Pfeiffer
ast writes: > Hello > float('Nan') == float('Nan') > False > > Why ? > > Regards Others have given the real answer -- IEEE says so, and the people who wrote the standard are smarter than me. All the same, this is my take on the reason for it: NaN is specifically a representation for

[issue35990] ipaddress.IPv4Interface won't accept 2-tuple (address, mask)

2019-02-13 Thread John Florian
New submission from John Florian : The docs say """The meaning of address is as in the constructor of IPv4Network, except that arbitrary host addresses are always accepted.""" However, that doesn't seem to be entirely true: >>> tup1 = ('192.168.123.234', 24) >>> tup2 = ('192.168.123.234',

RE: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Avi Gross
I won't speak for the IEEE but NOT A NUMBER does not tell you what something IS. If "Hello, World!" is not a number as in an int or a float and we throw away the content and simply call it a NaN or something and then we notice that an object that is a list of fruits is also not a number so we

[issue15753] No-argument super in method with variable arguments raises SystemError

2019-02-13 Thread Rémi Lapeyre
Change by Rémi Lapeyre : -- nosy: +remi.lapeyre ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15753] No-argument super in method with variable arguments raises SystemError

2019-02-13 Thread Josh Rosenberg
Josh Rosenberg added the comment: Moving from pending back to open (not sure what was "pending" about it?). The workaround is viable (and used by Python implemented dict subclasses in the standard library since they must accept **kwargs with arbitrary strings, including self), but it does

[issue5038] urrlib2/httplib doesn't reset file position between requests

2019-02-13 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch pull_requests: +11873 stage: test needed -> patch review ___ Python tracker ___ ___

[issue35988] Python interpreter segfault

2019-02-13 Thread Josh Rosenberg
Josh Rosenberg added the comment: "your application is using more memory than what is available in the system." Well, it alone may not be using more memory, but the cumulative usage on the system is "too high" by whatever metric the OOM killer is using (IIRC the default rule is that actual

Re: Why float('Nan') == float('Nan') is False

2019-02-13 Thread Grant Edwards
On 2019-02-13, ast wrote: > Hello > > >>> float('Nan') == float('Nan') > False If you think that's odd, how about this? >>> n = float('nan') >>> n nan >>> n is n True >>> n == n False >>> > Why ? IEEE says so. -- Grant Edwards grant.b.edwards

[issue22213] Make pyvenv style virtual environments easier to configure when embedding Python

2019-02-13 Thread Steve Dower
Steve Dower added the comment: I just closed 35706 as a duplicate of this one (the titles are basically identical, which feels like a good hint ;) ) It seems that the disagreement about the design is fundamentally a disagreement between a "quick, painful but complete fix" and "slow, careful

[issue35706] Make it easier to use a venv with an embedded Python interpreter

2019-02-13 Thread Steve Dower
Steve Dower added the comment: That's not a "see also" - it's just a duplicate :) I'll close this one as the other one has been around longer. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> Make pyvenv style virtual environments easier to

[issue35706] Make it easier to use a venv with an embedded Python interpreter

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: PEP 432 will allow to give with fine control on parameters used to initialize Python. Sadly, I failed to agree with Nick Coghlan and Eric Snow on the API. The current implementation (_PyCoreConfig and _PyMainInterpreterConfig) has some flaw (don't separate

[issue22213] Make pyvenv style virtual environments easier to configure when embedding Python

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: PEP 432 will allow to give with fine control on parameters used to initialize Python. Sadly, I failed to agree with Nick Coghlan and Eric Snow on the API. The current implementation (_PyCoreConfig and _PyMainInterpreterConfig) has some flaw (don't separate

[issue35706] Make it easier to use a venv with an embedded Python interpreter

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: See also bpo-22213. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35907] Unnecessary URL scheme exists to allow file:// reading file in urllib

2019-02-13 Thread Sihoon Lee
Change by Sihoon Lee : -- keywords: +patch pull_requests: +11872 stage: needs patch -> patch review ___ Python tracker ___ ___

[issue35949] Move PyThreadState into Include/internal/pycore_pystate.h

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: Same ratione than for PyInterpreterState: https://bugs.python.org/issue35886#msg335464 Except that I expect that a few more projects rely on PyThreadState fields. Maybe not. It's hard to guess :-( I mean that I'm ok-ish with the change but it should be

[issue35989] ipaddress.IPv4Network allows prefix > 32

2019-02-13 Thread SilentGhost
Change by SilentGhost : -- components: +Library (Lib) nosy: +pitrou stage: -> test needed type: -> behavior ___ Python tracker ___

[issue35886] Move PyInterpreterState into Include/internal/pycore_pystate.h

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: > @Victor, do you see any problems with doing this? It will help simplify > other changes I'm working on. I'm quite sure that they are users of the PyInterpreterState structure outside CPython internals and stdlib, but I expect that the number is quite

[issue35983] tp_dealloc trashcan shouldn't be called for subclasses

2019-02-13 Thread Eric Snow
Eric Snow added the comment: On Wed, Feb 13, 2019 at 8:42 AM Antoine Pitrou wrote: > Antoine Pitrou added the comment: > > By "relatively new thing", you mean less than 20 years old? :-) Yeah, looks like it was in the 2.2 release (Dec 2001) for PEP 253. Anyway, I know of several core devs

[issue35984] test__xxsubinterpreters leaked [3, 4, 3] memory blocks, sum=1

2019-02-13 Thread Eric Snow
Eric Snow added the comment: FYI, the _xxsubinterpreters module serves several purposes. First, it allows us to more thoroughly test the subinterpreter functionality of CPython (doing so via _testembed and _testcapi is messy), effectively in test__xxsubinterpreters. Second, it is the

[issue35984] test__xxsubinterpreters leaked [3, 4, 3] memory blocks, sum=1

2019-02-13 Thread Eric Snow
Eric Snow added the comment: Alexey, even though the refleak does not appear to be related to your earlier PR, you are welcome to keep working on this issue. :) If you do then please add me as a reviewer on whatever PR you make. Also, I'd be glad to answer any questions you have about the

[issue35989] ipaddress.IPv4Network allows prefix > 32

2019-02-13 Thread Rémi Lapeyre
Change by Rémi Lapeyre : -- nosy: +remi.lapeyre ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35989] ipaddress.IPv4Network allows prefix > 32

2019-02-13 Thread John Florian
New submission from John Florian : I wanted a simple is_valid_ipv4_network() function, so I wrote one and a bunch of unit tests where I discovered that I can legally: >>> n = IPv4Network(('192.168.123.234', 12345678)) >>> n IPv4Network('192.168.123.234/12345678') >>> n.prefixlen 12345678 >>>

[issue35983] tp_dealloc trashcan shouldn't be called for subclasses

2019-02-13 Thread Jeroen Demeyer
Change by Jeroen Demeyer : -- keywords: +patch pull_requests: +11871 stage: test needed -> patch review ___ Python tracker ___ ___

[issue35972] _xxsubinterpreters: channel_send() may truncate ints on 32-bit platforms

2019-02-13 Thread Eric Snow
Eric Snow added the comment: ack -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35988] Python interpreter segfault

2019-02-13 Thread Hinko Kocevar
Hinko Kocevar added the comment: Using python3.6 now. I've also used the 'handle SIGPIPE nostop noprint' to skip SIGPIPE. Now the interpreter is killed instead: INF 2019-02-13 15:42:19,131 web:2162 log_request - 200 GET /NPM.html (10.0.6.209) 1.10ms [Thread 0x7fffe76eb700 (LWP 8411)

[issue35224] PEP 572: Assignment Expressions

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: > If anyone has another area they think the documentation should be updated, > please let me know! If we forget something, it's not an issue: it can be added later! -- ___ Python tracker

[issue35988] Python interpreter segfault

2019-02-13 Thread STINNER Victor
STINNER Victor added the comment: > [26194250.314042] Out of memory: Kill process 8399 (python3.6) score 574 or > sacrifice child That's not a bug in Python: your application is using more memory than what is available in the system. -- ___

[issue35983] tp_dealloc trashcan shouldn't be called for subclasses

2019-02-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: By "relatively new thing", you mean less than 20 years old? :-) -- ___ Python tracker ___ ___

[issue35988] Python interpreter segfault

2019-02-13 Thread Hinko Kocevar
Hinko Kocevar added the comment: > Are you able to reproduce the crash on Python 3.6 or 3.7? I'm running it under python3.6 as we speak. -- ___ Python tracker ___

[issue35983] tp_dealloc trashcan shouldn't be called for subclasses

2019-02-13 Thread Eric Snow
Eric Snow added the comment: FWIW, subclassing builtin types is a relatively new thing. There are still a number of lingering (older) implementation details throughout CPython that were written assuming no subclassing. I'd guess that this is one of them. -- nosy: +eric.snow stage:

[issue35224] PEP 572: Assignment Expressions

2019-02-13 Thread Emily Morehouse
Emily Morehouse added the comment: I have a work-in-progress (WIP) documentation branch I've been working on that I'll push up this week to address the following: - Add summary to What's New in Doc/whatsnew/3.8.rst - Add to list of delimiters in Doc/reference/lexical_analysis.rst - Add usage

  1   2   >