Re: [Python-Dev] New Python Initialization API

2019-03-30 Thread Nick Coghlan
On Sat, 30 Mar 2019 at 12:45, Steve Dower wrote: > > On 29Mar.2019 1830, Victor Stinner wrote: > > The purpose of the PEP 587 is to have a working document so everyone > > can look at the proposed API (stay focused to the API rather than > > bothering with the implementation). IMHO it's now time

Re: [Python-Dev] PEP 578: Python Runtime Audit Hooks

2019-03-30 Thread Nick Coghlan
On Sat, 30 Mar 2019 at 06:14, Steve Dower wrote: > On 29Mar2019 1218, Christian Heimes wrote: > > On 28/03/2019 23.35, Steve Dower wrote: > >> There is no Python API provided for changing the open hook. To modify > >> import behavior from Python code, use the existing functionality > >> provided

Re: [Python-Dev] BDFL-Delegate appointments for several PEPs

2019-03-30 Thread Nick Coghlan
On Mon, 25 Mar 2019 at 20:34, Cameron Simpson wrote: > Clearly the above needs to accomodate this, possibly with a fallback > guess. Is sniffing the end components of __file__ at all sane? ending in > idlelib/pyshell.py or pyshell.py? Or is that just getting baroque? > > I don't think these are

Re: [Python-Dev] Removing PendingDeprecationWarning

2019-03-30 Thread Nick Coghlan
On Thu, 28 Mar 2019 at 12:31, Inada Naoki wrote: > I didn't know "right way" to chose DeprecationWarning or > PendingDeprecationWarning. That's just a documentation fix: "If you're not sure whether to use DeprecationWarning or PendingDeprecationWarning, use DeprecationWarning". Cheers, Nick.

Re: [Python-Dev] Tests for internal functionality

2019-03-30 Thread Nick Coghlan
On Sun, 17 Mar 2019 at 07:27, Terry Reedy wrote: > > On 3/16/2019 3:10 AM, Ivan Pozdeev via Python-Dev wrote: > > In https://github.com/python/cpython/pull/6541 , I was requested to add > > tests for an internal C function. > > > > As I wrote in > >

Re: [Python-Dev] Removing PendingDeprecationWarning

2019-03-30 Thread Nick Coghlan
On Wed, 27 Mar 2019 at 20:29, Inada Naoki wrote: > > On Mon, Mar 25, 2019 at 10:11 PM Inada Naoki wrote: > > > > C, Rust, Java, Ruby, PHP, don't have PendingDeprecation. > > Programmers only need Deprecation. Why programmers need PendingDeprecation > > only in Python? > > > > Any comments about

Re: [Python-Dev] Strange umask(?)/st_mode issue

2019-03-30 Thread Steve Dower
On 29Mar.2019 1944, Steve Dower wrote: > On 29Mar.2019 1939, Cameron Simpson wrote: >> Can you get a branch into your pipeline? Then you could just hack the >> tarfile test with something quick and dirty like: >> >>    pid = os.getpid() >>    system("strace -p %d 2>/path/to/strace.out &" % pid) >>

Re: [Python-Dev] Strange umask(?)/st_mode issue

2019-03-30 Thread Kushal Kumaran
Steve Dower writes: > On 29Mar.2019 1944, Steve Dower wrote: >> On 29Mar.2019 1939, Cameron Simpson wrote: >>> Can you get a branch into your pipeline? Then you could just hack the >>> tarfile test with something quick and dirty like: >>> >>>    pid = os.getpid() >>>    system("strace -p %d

Re: [Python-Dev] PEP 578: Python Runtime Audit Hooks

2019-03-30 Thread Steve Dower
On 29Mar.2019 2020, Inada Naoki wrote: > I don't like adding more Python callback from low level. > > Python runtime is very complicated already, especially __del__, > shutdown process, and multi threading. Python callback from low level > is source of very difficult bugs always. Asynchronous

Re: [Python-Dev] BDFL-Delegate appointments for several PEPs

2019-03-30 Thread Mark Shannon
Hi Petr, On 27/03/2019 1:50 pm, Petr Viktorin wrote: On Sun, Mar 24, 2019 at 4:22 PM Mark Shannon wrote: Hi Petr, Regarding PEPs 576 and 580. Over the new year, I did a thorough analysis of possible approaches to possible calling conventions for use in the CPython ecosystems and came up

Re: [Python-Dev] Strange umask(?)/st_mode issue

2019-03-30 Thread Gregory P. Smith
I wouldn't expect it to be the case in a CI environment but I believe a umask can be overridden if the filesystem is mounted and configured with acls set? (oh, hah, Ivan just said the same thing) -gps On Sat, Mar 30, 2019 at 9:05 AM Steve Dower wrote: > On 29Mar.2019 1944, Steve Dower wrote:

Re: [Python-Dev] PEP 578: Python Runtime Audit Hooks

2019-03-30 Thread Steve Dower
On 30Mar.2019 0747, Nick Coghlan wrote: > I like this PEP in principle, but the specific "open_for_import" name > bothers me a lot, as it implies that "importing" is the only situation > where a file will be opened for code execution. > > If this part of the API were lower down the stack (e.g. >

Re: [Python-Dev] Strange umask(?)/st_mode issue

2019-03-30 Thread Ivan Pozdeev via Python-Dev
On 30.03.2019 19:00, Steve Dower wrote: On 29Mar.2019 1944, Steve Dower wrote: On 29Mar.2019 1939, Cameron Simpson wrote: Can you get a branch into your pipeline? Then you could just hack the tarfile test with something quick and dirty like:    pid = os.getpid()    system("strace -p %d

[Python-Dev] PEP 580/590 discussion

2019-03-30 Thread Jeroen Demeyer
On 2019-03-30 17:30, Mark Shannon wrote: 2. The claim that PEP 580 allows "certain optimizations because other code can make assumptions" is flawed. In general, the caller cannot make assumptions about the callee or vice-versa. Python is a dynamic language. PEP 580 is meant for extension

Re: [Python-Dev] New Python Initialization API

2019-03-30 Thread Steve Dower
Here is my first review of https://www.python.org/dev/peps/pep-0587/ and in general I think it's very good. There are some things I'd like to consider changing before we embed them permanently in a public API, and as I'm still keen to have the ability to write Python code for configuration (to