classification
Title: xxsubtype.bench does not function correctly on CPython 3+
Type: behavior Stage: resolved
Components: Extension Modules Versions: Python 3.8, Python 3.7, Python 3.6
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Gorialis, miss-islington, serhiy.storchaka
Priority: normal Keywords: patch

Created on 2018-04-09 22:46 by Gorialis, last changed 2018-04-10 08:07 by serhiy.storchaka. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 6439 merged Gorialis, 2018-04-09 23:16
PR 6440 merged miss-islington, 2018-04-10 05:22
PR 6441 merged miss-islington, 2018-04-10 05:22
Messages (5)
msg315154 - (view) Author: Gorialis (Gorialis) Date: 2018-04-09 22:46
Due to the `OS|i` signature of `xxsubtype.bench`, it accepts `bytes` as its second argument in CPython 3+, however, it does a call `PyObject_GetAttr` which only accepts `PyString`.

This means that if you give the function `bytes`, it fails on the getattr call, but if you give it anything else, it rejects it as it doesn't match the signature.

While the module itself does not contribute to CPython's functionality (and is infact optional), since it serves as an example, it should actually function, as it does in CPython 2.
msg315159 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2018-04-10 05:21
New changeset f178028f37c9dafb72608b719eb03e5a70af4ff5 by Serhiy Storchaka (Devon R) in branch 'master':
bpo-33253: Fix xxsubtype.bench() to accept correct str signature. (GH-6439)
https://github.com/python/cpython/commit/f178028f37c9dafb72608b719eb03e5a70af4ff5
msg315160 - (view) Author: miss-islington (miss-islington) Date: 2018-04-10 06:00
New changeset 9bb8cebdce99db7e7a94f15141a8e0514b51aa72 by Miss Islington (bot) in branch '3.7':
bpo-33253: Fix xxsubtype.bench() to accept correct str signature. (GH-6439)
https://github.com/python/cpython/commit/9bb8cebdce99db7e7a94f15141a8e0514b51aa72
msg315161 - (view) Author: miss-islington (miss-islington) Date: 2018-04-10 06:07
New changeset 910d71b839755baa31258bcc083be9191563819e by Miss Islington (bot) in branch '3.6':
bpo-33253: Fix xxsubtype.bench() to accept correct str signature. (GH-6439)
https://github.com/python/cpython/commit/910d71b839755baa31258bcc083be9191563819e
msg315163 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2018-04-10 08:07
3.4 and 3.5 are at security bug fixes only stage.
History
Date User Action Args
2018-04-10 08:07:41serhiy.storchakasetstatus: open -> closed
versions: - Python 3.4, Python 3.5
messages: + msg315163

resolution: fixed
stage: patch review -> resolved
2018-04-10 06:07:16miss-islingtonsetmessages: + msg315161
2018-04-10 06:00:59miss-islingtonsetnosy: + miss-islington
messages: + msg315160
2018-04-10 05:22:30miss-islingtonsetpull_requests: + pull_request6137
2018-04-10 05:22:02miss-islingtonsetpull_requests: + pull_request6136
2018-04-10 05:21:21serhiy.storchakasetnosy: + serhiy.storchaka
messages: + msg315159
2018-04-09 23:16:49Gorialissetkeywords: + patch
stage: patch review
pull_requests: + pull_request6135
2018-04-09 22:46:08Gorialiscreate