ctypes Structures with subclassed types in the _fields_ list

Open
#59,664 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
30/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
python
Domain
backend

Research direction

Start with showbug.py, which demonstrates the bitfield bug, and inspect bitfields.patch to understand the proposed change. Reproduce the behavior in the ctypes area and determine whether subclassed types in a Structure's fields list are handled correctly; done means the demonstrated bug is resolved and the patch's intended behavior is verified.

Written by the indexing model from the issue text.

Description

3.7 (EOL) topic-ctypes type-bug
BPO 15459
Nosy @theller, @amauryfa, @abalkin, @meadori, @tsparber
Files
  • showbug.py: demonstrates the bitfield bug
  • bitfields.patch
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = None
    created_at = <Date 2012-07-26.18:35:05.031>
    labels = ['ctypes', 'type-bug', '3.7']
    title = 'ctypes Structures with subclassed types in the _fields_ list'
    updated_at = <Date 2019-07-30.16:24:58.405>
    user = 'https://github.com/theller'
    

    bugs.python.org fields:

    activity = <Date 2019-07-30.16:24:58.405>
    actor = 'tsparber'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['ctypes']
    creation = <Date 2012-07-26.18:35:05.031>
    creator = 'theller'
    dependencies = []
    files = ['26529', '26530']
    hgrepos = []
    issue_num = 15459
    keywords = ['patch', 'needs review']
    message_count = 4.0
    messages = ['166496', '166497', '167285', '348756']
    nosy_count = 6.0
    nosy_names = ['theller', 'amaury.forgeotdarc', 'belopolsky', 'Arfrever', 'meador.inge', 'tsparber']
    pr_nums = []
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue15459'
    versions = ['Python 2.7', 'Python 3.2', 'Python 3.3', 'Python 3.5', 'Python 3.6', 'Python 3.7']
    

    Dominant language
    Python
    Stars
    77.2k
    Forks
    36k
    Avg merge
    1d 9h
    Merged PRs (30d)
    558

    Contributor guide

    Open the contributing guide

    First steps

    1. Read the whole issue, then the project's contributing guide.
    2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
    3. Fork the repository and make your change on a branch.
    4. Open a pull request that references the issue number.

    More from python/cpython

    All issues in python/cpython

    Similar issues

    More Python issues

    Get new issues in your inbox

    A short digest of beginner-friendly GitHub issues.