[issue32013] _pickle: Py_DECREF seems to be missing from a failure case in fast_save_enter()

2017-11-12 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +4333 ___ Python tracker ___

[issue32013] _pickle: Py_DECREF seems to be missing from a failure case in fast_save_enter()

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset f76231f89a7231fd486b37f728fbb4aab389e4d7 by Serhiy Storchaka (Mat M) in branch 'master': bpo-32013: _pickle: Add missing Py_DECREF in error case in fast_save_enter() (#4384)

[issue27494] 2to3 parser failure caused by a comma after a generator expression

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Actually this syntax isn't allowed by the Python language specification. See issue32012 for fixing the Python parser. -- ___ Python tracker

[issue32012] Disallow ambiguous syntax f(x for x in [1],)

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: PR 4382 doesn't change the grammar, it changes only checks in the CST to AST transformer. Maybe it would be better to change the grammar. Currently it doesn't match the language specification and allows the following

[issue31948] [EASY] Broken MSDN links in msilib docs

2017-11-12 Thread Akash Jain
Akash Jain added the comment: Hi, I am new to contributing in Python, Can I work on this issue? -- nosy: +Akash Jain ___ Python tracker

[issue31956] Add start and stop parameters to the array.index()

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Just take list.index as an example. -- components: +Extension Modules -Library (Lib) nosy: +serhiy.storchaka type: -> enhancement versions: +Python 3.7 -Python 3.8 ___ Python tracker

[issue32014] multiprocessing Server's shutdown method useless send message to manager

2017-11-12 Thread stevezh
New submission from stevezh : When shutdown the manager, Server's handle_request will send back message to the manager, so is useless for the Server's shutdown method send back "None" to the manager? Source code from Lib/multiprocessing/managers.py: def shutdown(self,

[issue1539925] warnings in interactive sessions

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Looks reasonable to me. Perhaps we should port the solution from IPython: https://github.com/ipython/ipython/issues/6611. -- versions: +Python 3.7 -Python 3.5 ___ Python tracker

[issue32010] Multiple get "itemgetter"

2017-11-12 Thread Raymond Hettinger
Raymond Hettinger added the comment: I also don't think this should be done to itemgetter() which should remain focused on its core task. Thank you for the suggestion, but am marking this as closed. Perhaps consider posting a recipe to the ASPN cookbook (I've

[issue32013] _pickle: Py_DECREF seems to be missing from a failure case in fast_save_enter()

2017-11-12 Thread Mathew M.
Change by Mathew M. : -- keywords: +patch pull_requests: +4331 stage: -> patch review ___ Python tracker ___

[issue32013] _pickle: Py_DECREF seems to be missing from a failure case in fast_save_enter()

2017-11-12 Thread Mathew M.
New submission from Mathew M. : Hey there! I'm fairly new to the development process for Python, so I figured I'd start off with something tiny and then work on up from there. I'm not sure if this sort of minor fix warrants an issue being created, but I made this just to

[issue32007] nis module fails to build against glibc-2.26

2017-11-12 Thread Benjamin Peterson
Benjamin Peterson added the comment: Rather than investing any effort in nis, we should probably just deprecate and eventually remove it. (If glibc is actually getting rid of something, you know must be very very deprecated.) -- nosy: +benjamin.peterson

[issue24294] DeprecationWarnings should be visible by default in the interactive REPL

2017-11-12 Thread Nathaniel Smith
Nathaniel Smith added the comment: See also PEP 565. -- ___ Python tracker ___ ___

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Nick Coghlan
Nick Coghlan added the comment: The default command line UX of Python developer tools is also more unambiguously python-dev's responsibility, though. That's where my own initial line of argument for full reversion (i.e. that we should be letting app developers manage

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Guido van Rossum
Guido van Rossum added the comment: I simply don't think developer tools are the prime example of command line tools (it's just that because we are Python developers here, *everything* we use tends to be a developer tool). And "app" does not mean or imply "GUI app".

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Nick Coghlan
Nick Coghlan added the comment: Reviewing the original thread yet again, you're right the original decision wasn't specifically about developer tools (and I guess at some level I knew that, or I wouldn't have been motivated to suggest the change to FutureWarning's

[issue31956] Add start and stop parameters to the array.index()

2017-11-12 Thread Anders Lorentsen
Anders Lorentsen added the comment: I decided to work on this, and I would like some review, as this would be my second contribution to cpython. Also, a general question: As I defined the start and end arguments Py_ssize_t, bigger indexes (more negative or more positive)

[issue32012] Disallow ambiguous syntax f(x for x in [1],)

2017-11-12 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +4330 stage: -> patch review ___ Python tracker ___

[issue32012] Disallow ambiguous syntax f(x for x in [1],)

2017-11-12 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : The syntax f(x for x in [1],) is ambiguous and reasons that allow it (omitting parenthesis in generator expression and using trailing comma in call expression) are not applicable in this case. Rationales see on Python-Dev:

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread R. David Murray
R. David Murray added the comment: My *personal* memory (as in, the reason I gave a sigh of relief when we made this change) was other tools, regardless of what core's rationale was :) (If I remember correctly it was some sysadmin-type tool I was using just about every

[issue32011] Restore loading of TYPE_INT64 in marshal

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Example: $ python2 -c 'import sys, marshal; marshal.dump(1234567890, sys.stdout)' | python3 -c 'import sys, marshal; print(marshal.load(sys.stdin.buffer))' 1234567890 $ python2 -c 'import sys, marshal;

[issue32011] Restore loading of TYPE_INT64 in marshal

2017-11-12 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +4329 stage: -> patch review ___ Python tracker ___

[issue28789] valgrind shows "invalid file descriptor" when calling platform.system() on my machine.

2017-11-12 Thread Stefan Krah
Stefan Krah added the comment: Okay, it is probably this: https://bugs.kde.org/show_bug.cgi?id=331311 The question is whether we should add a suppression or a perhaps a comment in _posixsubprocess.c -- nosy: +gregory.p.smith

[issue32011] Restore loading of TYPE_INT64 in marshal

2017-11-12 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : TYPE_INT64 is supported in the marshal module since Python 1.5. Since its use causes instability of marhalled files produced on different platforms, the marshal module in Python 3.3 no longer use it when write new files (see

[issue28759] access to mkfifo, mknod and hard links is controled by SELinux MAC on Android

2017-11-12 Thread Xavier de Gaye
Change by Xavier de Gaye : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue28759] access to mkfifo, mknod and hard links is controled by SELinux MAC on Android

2017-11-12 Thread Xavier de Gaye
Xavier de Gaye added the comment: New changeset ad004f9b5a581f577374c56d8ab27e9ef2e73452 by xdegaye in branch '3.6': [3.6] bpo-28759: Skip some tests on PermissionError raised by Android (GH-4350) (#4380)

[issue28789] valgrind shows "invalid file descriptor" when calling platform.system() on my machine.

2017-11-12 Thread Stefan Krah
Stefan Krah added the comment: More info: ==22845== Warning: invalid file descriptor 1024 in syscall close() ==22845==at 0x4E493F0: __close_nocancel (syscall-template.S:81) ==22845==by 0xF0BAA74: _close_open_fds_safe (_posixsubprocess.c:297) ==22845==by

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Guido van Rossum
Guido van Rossum added the comment: > the original rationale was about developer tools emitting unhelpful noise (rather than general Python applications) I don't recall that, and I'm not sure I agree (either that this is a good reason or that that was the reason stated when

[issue28789] valgrind shows "invalid file descriptor" when calling platform.system() on my machine.

2017-11-12 Thread Stefan Krah
Change by Stefan Krah : -- nosy: +skrah stage: -> needs patch type: -> behavior ___ Python tracker ___

[issue29181] skip tests that raise PermissionError in test_tarfile (non-root user on Android)

2017-11-12 Thread Xavier de Gaye
Xavier de Gaye added the comment: New changeset d7d4fea4a39da4bfdea1de22fe040023eb4ddc17 by xdegaye in branch 'master': bpo-29181: Skip test_tarfile tests on PermissionError raised by Android (GH-4375)

[issue29181] skip tests that raise PermissionError in test_tarfile (non-root user on Android)

2017-11-12 Thread Xavier de Gaye
Change by Xavier de Gaye : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue29180] skip tests that raise PermissionError in test_os (non-root user on Android)

2017-11-12 Thread Xavier de Gaye
Change by Xavier de Gaye : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue29180] skip tests that raise PermissionError in test_os (non-root user on Android)

2017-11-12 Thread Xavier de Gaye
Xavier de Gaye added the comment: New changeset 6a55d09573e5c35c9e4a24a6f811120b41a2a994 by xdegaye in branch 'master': bpo-29180: Skip test_os tests on PermissionError raised by Android (GH-4374)

[issue31993] pickle.dump allocates unnecessary temporary bytes / str

2017-11-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Agreed. We shouldn't issue very small writes, but 64 kB is generally considered a reasonable buffer size for many kinds of I/O. Besides, it wouldn't be difficult to make the target frame size configurable if a use case arose for it, but I

[issue28759] access to mkfifo, mknod and hard links is controled by SELinux MAC on Android

2017-11-12 Thread Xavier de Gaye
Change by Xavier de Gaye : -- pull_requests: +4328 ___ Python tracker ___ ___

[issue31993] pickle.dump allocates unnecessary temporary bytes / str

2017-11-12 Thread Olivier Grisel
Olivier Grisel added the comment: Flushing the buffer at each frame commit will cause a medium-sized write every 64kB on average (instead of one big write at the end). So that might actually cause a performance regression for some users if the individual file-object

[issue30696] infinite loop in PyRun_InteractiveLoopFlags()

2017-11-12 Thread Xavier de Gaye
Change by Xavier de Gaye : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue30696] infinite loop in PyRun_InteractiveLoopFlags()

2017-11-12 Thread Xavier de Gaye
Xavier de Gaye added the comment: New changeset ea5b545e38b3fec7ff29276b5cd59dec583ebf34 by xdegaye in branch '3.6': [3.6] bpo-30696: Fix the REPL looping endlessly when no memory (GH-4160). (#4379)

[issue28759] access to mkfifo, mknod and hard links is controled by SELinux MAC on Android

2017-11-12 Thread Xavier de Gaye
Xavier de Gaye added the comment: New changeset 92c2ca7633c881a56157f2fb8b2e1b8c7114e5fb by xdegaye in branch 'master': bpo-28759: Skip some tests on PermissionError raised by Android (GH-4350)

[issue30696] infinite loop in PyRun_InteractiveLoopFlags()

2017-11-12 Thread Xavier de Gaye
Change by Xavier de Gaye : -- pull_requests: +4327 ___ Python tracker ___ ___

[issue30696] infinite loop in PyRun_InteractiveLoopFlags()

2017-11-12 Thread Xavier de Gaye
Xavier de Gaye added the comment: New changeset e0582a37c8d1776a2fd4968e9216f3a05f780276 by xdegaye in branch 'master': bpo-30696: Fix the REPL looping endlessly when no memory (GH-4160) https://github.com/python/cpython/commit/e0582a37c8d1776a2fd4968e9216f3a05f780276

[issue31993] pickle.dump allocates unnecessary temporary bytes / str

2017-11-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Framing was originally intended to improve unpickling (since you don't have to issue lots of tiny file reads anymore). No objection to also improve pickling, though :-) -- ___ Python tracker

[issue31993] pickle.dump allocates unnecessary temporary bytes / str

2017-11-12 Thread Olivier Grisel
Olivier Grisel added the comment: > While we are here, wouldn't be worth to flush the buffer in the C > implementation to the disk always after committing a frame? This will save a > memory when dump a lot of small objects. I think it's a good idea. The C pickler

[issue32010] Multiple get "itemgetter"

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: As you have said, this will break existing code. And this is not applicable to non-string indices. I think that it would be easier to use a lambda or local function for this: `lambda x: x['a']['b']`. It is shorter and cleaner.

[issue32010] Multiple get "itemgetter"

2017-11-12 Thread Mario Corchero
New submission from Mario Corchero : At the moment we can get an operator that performs multiple "gets" in object attributes. Example: >>> getter = operator.attrgetter("child1.child2") >>> o = mock.Mock() >>> getter(o) On the other hand, itemgetter -which can be used for

[issue31691] Include missing info on required build steps and how to build installer

2017-11-12 Thread Ivan Pozdeev
Change by Ivan Pozdeev : Removed file: https://bugs.python.org/file47192/0001-Add-missing-build-steps-in-build-procedure.patch ___ Python tracker

[issue31691] Include missing info on required build steps and how to build installer

2017-11-12 Thread Ivan Pozdeev
Change by Ivan Pozdeev : Removed file: https://bugs.python.org/file47191/0001-Add-missing-build-steps-in-build-procedure.patch ___ Python tracker

[issue31691] Include missing info on required build steps and how to build installer

2017-11-12 Thread Ivan Pozdeev
Ivan Pozdeev added the comment: Indeed, other branches can use this info as well. -- versions: +Python 3.5, Python 3.6, Python 3.7, Python 3.8 Added file: https://bugs.python.org/file47260/0001-Add-missing-but-required-build-steps-and-how-to-buil.patch

[issue31993] pickle.dump allocates unnecessary temporary bytes / str

2017-11-12 Thread Olivier Grisel
Olivier Grisel added the comment: Thanks Antoine, I updated my code to what you suggested. -- ___ Python tracker ___

[issue31993] pickle.dump allocates unnecessary temporary bytes / str

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: While we are here, wouldn't be worth to flush the buffer in the C implementation to the disk always after committing a frame? This will save a memory when dump a lot of small objects. --

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Nick Coghlan
Nick Coghlan added the comment: I also learned we need more concrete examples of useful PYTHONWARNINGS and -W settings in the docs - I believe PEP 565 currently contains more of those than all of our existing warnings related documentation put together :) I'll look into

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Nick Coghlan
Nick Coghlan added the comment: I relearned a fair bit myself in writing it - I'd completely forgotten the original rationale was about developer tools emitting unhelpful noise (rather than general Python applications), and that's far more persuasive than the rationale

[issue28180] Implementation of the PEP 538: coerce C locale to C.utf-8

2017-11-12 Thread Xavier de Gaye
Xavier de Gaye added the comment: New changeset 1588be66d7b0eeebc4614309cd0fc837ff52776a by xdegaye in branch 'master': bpo-28180: Fix the implementation of PEP 538 on Android (GH-4334) https://github.com/python/cpython/commit/1588be66d7b0eeebc4614309cd0fc837ff52776a

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Le 12/11/2017 à 12:40, Nick Coghlan a écrit : > > My impression is that you've been arguing that my changes don't go far enough > (i.e. you'd prefer full reversion to the pre-2.7 behaviour), not that the > status quo is superior. Ideally

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Nick Coghlan
Nick Coghlan added the comment: My impression is that you've been arguing that my changes don't go far enough (i.e. you'd prefer full reversion to the pre-2.7 behaviour), not that the status quo is superior. My PEP covers both why I think the status quo is problematic,

[issue28197] Add start and stop parameters to the range.index() ABC method

2017-11-12 Thread Nitish
Change by Nitish : -- keywords: +patch pull_requests: +4326 stage: needs patch -> patch review ___ Python tracker ___

[issue31975] Add a default filter for DeprecationWarning in __main__

2017-11-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Le 12/11/2017 à 02:17, Nick Coghlan a écrit : > > If someone else wants a different change, they can write their own > competing PEP that explains why they think mine would be worse than the > status quo. Nobody needs a PEP to advocate for the

[issue31829] Portability issues with pickle

2017-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Updated PR correctly loads Unicode strings saved in text mode. As a mark used some corrected opcodes followed by newline. If any of previous newlines is \r\n, thus the file was written in text mode and is read in binary mode. If

[issue16055] incorrect error text for int(base=1000, x='1')

2017-11-12 Thread Sanyam Khurana
Change by Sanyam Khurana : -- pull_requests: +4325 stage: needs patch -> patch review ___ Python tracker ___