GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — platform.libc_ver() raises TypeError on a threaded libc without a version · Issue #155454 · python/cpython

platform.libc_ver() raises TypeError on a threaded libc without a version #155454

New issue
Copy link
New issue
Copy link
Open
Open
platform.libc_ver() raises TypeError on a threaded libc without a version#155454
Copy link
Labels
stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error

Description

@tonghuaroot
tonghuaroot
opened on Aug 10, 2026
Issue body actions

Bug report

platform.libc_ver() raises TypeError when it scans a binary that references
a threaded C library (such as libc_r) with no version number:

>>> platform.libc_ver(executable=some_binary_referencing_libc_r_so)
Traceback (most recent call last):
  ...
TypeError: 'NoneType' object is not subscriptable

In the so branch of the scanning loop, when a match has a thread suffix
(_r/_pthread) but no version, ver is still None and gets subscripted.
This is a regression from gh-90548 (PR #131313), so 3.14 and later are affected.

CPython versions tested on:

3.16 (main)

Operating systems tested on:

Linux, macOS

Linked PRs

  • gh-155454: Fix platform.libc_ver() crash on threaded libc without version #155455

Activity

  1. cocolato
    added
    type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
    stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directory
    on Aug 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.