[issue27442] expose Android API level in sys.implementation

2016-07-03 Thread Xavier de Gaye
Xavier de Gaye added the comment: Well, issue 16353 has been entered upon attempting to fix issue 16255 (see msg173477). So an alternative exists. Issue 16353 could be closed as 'wont't fix'. The list of locations where '/bin/sh' is hard coded in the standard library in msg266084 shows that

[issue27442] expose Android API level in sys.implementation

2016-07-03 Thread Xavier de Gaye
Xavier de Gaye added the comment: @Ned The information that the interpreter is an Android built, is needed in issue 16353 [1][2]. In msg266135, the corresponding patch adds the 'is_android' attribute to the already bloated sys module. I had thought then about using sysconfig.get_config_var() a

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread Ned Deily
Ned Deily added the comment: Typically, for other sorts of build configuration data, we have relied on extracting that from the ./configure-produced Makefile and making it available via sysconfig.get_config_var(). I think we should be cautious about bloating sys.implementation with platform-s

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread STINNER Victor
STINNER Victor added the comment: I woupd prefer to have a public attribute. -- ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: OK I see the rationale. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread Xavier de Gaye
Xavier de Gaye added the comment: > I don't think sys.implementation is a good place to contain the information > of the underlying platform. Quite the opposite, the ndk API level gives an information about the implementation of the currently running Python interpreter saying that this Python

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: Sorry, it's Doc/library/sys.rst -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread Chi Hsuan Yen
Chi Hsuan Yen added the comment: I don't think sys.implementation is a good place to contain the information of the underlying platform. By Doc/sys.rst: An object containing information about the implementation of the currently running Python interpreter. -- nosy: +Chi Hsuan Yen

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread Xavier de Gaye
Xavier de Gaye added the comment: Patch added. -- keywords: +patch stage: -> patch review Added file: http://bugs.python.org/file43610/android_api.patch ___ Python tracker ___ _

[issue27442] expose Android API level in sys.implementation

2016-07-02 Thread Xavier de Gaye
New submission from Xavier de Gaye: Expose the Android API level that python was built against, in sys.implementation as _android_api. Purposes: * Identify the platform as Android. * Allow detecting a mismatch with the runtime sdk version returned by platform.android_ver() (issue 26855)