Programmatic access to Python's limited API and abi3 information

Overview

abi3info

CI

abi3info exposes information about CPython's "limited API" (including the stable ABI, called abi3) as a Python library.

Installation

abi3info is available via pip:

$ pip install abi3info

Usage

abi3info exposes limited API and stable ABI information in the form of a set of top-level dictionaries, namely:

import abi3info

abi3info.FEATURE_MACROS
abi3info.MACROS
abi3info.STRUCTS
abi3info.TYPEDEFS
abi3info.FUNCTIONS
abi3info.DATAS

Each of these is a mapping of a name (either as str or Symbol) to a data model describing the kind of item (e.g. FeatureMacro or Function).

See the generated documentation for more details, including comprehensive type hints and explanations of each data model.

See also the stable_abi.toml file, taken from the CPython sources, which describes each model and their semantics.

Examples

Get information about a particular function:

from abi3info import FUNCTIONS
from abi3info.models import Symbol

func = FUNCTIONS[Symbol("_Py_NegativeRefcount")]
print(func.symbol, func.added, func.ifdef, func.abi_only)

Get information about the feature macros that control the limited API:

from abi3info import FEATURE_MACROS

print(fm for fm in FEATURE_MACROS.values())

Licensing

abi3info is licensed under the MIT license.

abi3info is partially generated from metadata retrieved from the CPython sources, which is licensed under the PSF license.

Comments
  • Switch to date-based releases

    Switch to date-based releases

    This library involves a periodically updated data source, so we should use date versioning.

    This switch should occur once I'm confident about the API.

    opened by woodruffw 1
  • build(deps): bump sigstore/gh-action-sigstore-python from 0.1.0 to 0.2.0

    build(deps): bump sigstore/gh-action-sigstore-python from 0.1.0 to 0.2.0

    Bumps sigstore/gh-action-sigstore-python from 0.1.0 to 0.2.0.

    Release notes

    Sourced from sigstore/gh-action-sigstore-python's releases.

    Release 0.2.0

    What's Changed

    Full Changelog: https://github.com/sigstore/gh-action-sigstore-python/compare/v0.1.0...v0.2.0

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 0
  • build(deps): bump pypa/gh-action-pypi-publish from 1.5.2 to 1.6.4

    build(deps): bump pypa/gh-action-pypi-publish from 1.5.2 to 1.6.4

    Bumps pypa/gh-action-pypi-publish from 1.5.2 to 1.6.4.

    Release notes

    Sourced from pypa/gh-action-pypi-publish's releases.

    v1.6.4

    oh, boi! again?

    This is the last one tonight, promise! It fixes this embarrassing bug that was actually caught by the CI but got overlooked due to the lack of sleep. TL;DR GH passed $HOME from the external env into the container and that tricked the Python's site module to think that the home directory is elsewhere, adding non-existent paths to the env vars. See #115.

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.6.3...v1.6.4

    v1.6.3

    Another Release!? Why?

    In pypa/gh-action-pypi-publish#112, it was discovered that passing a $PATH variable even breaks the shebang. So this version adds more safeguards to make sure it keeps working with a fully broken $PATH.

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.6.2...v1.6.3

    v1.6.2

    What's Fixed

    • Made the $PATH and $PYTHONPATH environment variables resilient to broken values passed from the host runner environment, which previously allowed the users to accidentally break the container's internal runtime as reported in pypa/gh-action-pypi-publish#112

    Internal Maintenance Improvements

    New Contributors

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.6.1...v1.6.2

    v1.6.1

    What's happened?!

    There was a sneaky bug in v1.6.0 which caused Twine to be outside the import path in the Python runtime. It is fixed in v1.6.1 by updating $PYTHONPATH to point to a correct location of the user-global site-packages/ directory.

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.6.0...v1.6.1

    v1.6.0

    Anything's changed?

    The only update is that the Python runtime has been upgraded from 3.9 to 3.11. There are no functional changes in this release.

    Full Changelog: https://github.com/pypa/gh-action-pypi-publish/compare/v1.5.2...v1.6.0

    Commits
    • c7f29f7 🐛 Override $HOME in the container with /root
    • 644926c 🧪 Always run smoke testing in debug mode
    • e71a4a4 Add support for verbose bash execusion w/ $DEBUG
    • e56e821 🐛 Make id always available in twine-upload
    • c879b84 🐛 Use full path to bash in shebang
    • 57e7d53 🐛Ensure the default $PATH value is pre-loaded
    • ce291dc 🎨🐛Fix the branch @ pre-commit.ci badge links
    • 102d8ab 🐛 Rehardcode devpi port for GHA srv container
    • 3a9eaef 🐛Use different ports in/out of GHA containers
    • a01fa74 🐛 Use localhost @ GHA outside the containers
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 0
  • build(deps): bump pypa/gh-action-pypi-publish from 1.6.1 to 1.6.3

    build(deps): bump pypa/gh-action-pypi-publish from 1.6.1 to 1.6.3

    Bumps pypa/gh-action-pypi-publish from 1.6.1 to 1.6.3.

    Release notes

    Sourced from pypa/gh-action-pypi-publish's releases.

    v1.6.3

    Another Release!? Why?

    In pypa/gh-action-pypi-publish#112, it was discovered that passing a $PATH variable even breaks the shebang. So this version adds more safeguards to make sure it keeps working with a fully broken $PATH.

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.6.2...v1.6.3

    v1.6.2

    What's Fixed

    • Made the $PATH and $PYTHONPATH environment variables resilient to broken values passed from the host runner environment, which previously allowed the users to accidentally break the container's internal runtime as reported in pypa/gh-action-pypi-publish#112

    Internal Maintenance Improvements

    New Contributors

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.6.1...v1.6.2

    Commits
    • e71a4a4 Add support for verbose bash execusion w/ $DEBUG
    • e56e821 🐛 Make id always available in twine-upload
    • c879b84 🐛 Use full path to bash in shebang
    • 57e7d53 🐛Ensure the default $PATH value is pre-loaded
    • ce291dc 🎨🐛Fix the branch @ pre-commit.ci badge links
    • 102d8ab 🐛 Rehardcode devpi port for GHA srv container
    • 3a9eaef 🐛Use different ports in/out of GHA containers
    • a01fa74 🐛 Use localhost @ GHA outside the containers
    • ee892fd 🐛Move Twine repository URL definitions to steps
    • 47622d7 🎨 Add CI/CD badges to README
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 0
  • build(deps): bump pypa/gh-action-pypi-publish from 1.5.2 to 1.6.1

    build(deps): bump pypa/gh-action-pypi-publish from 1.5.2 to 1.6.1

    Bumps pypa/gh-action-pypi-publish from 1.5.2 to 1.6.1.

    Release notes

    Sourced from pypa/gh-action-pypi-publish's releases.

    v1.6.1

    What's happened?!

    There was a sneaky bug in v1.6.0 which caused Twine to be outside the import path in the Python runtime. It is fixed in v1.6.1 by updating $PYTHONPATH to point to a correct location of the user-global site-packages/ directory.

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.6.0...v1.6.1

    v1.6.0

    Anything's changed?

    The only update is that the Python runtime has been upgraded from 3.9 to 3.11. There are no functional changes in this release.

    Full Changelog: https://github.com/pypa/gh-action-pypi-publish/compare/v1.5.2...v1.6.0

    Commits
    • 5d1679f Use py3.11 user-global site-packages in PYTHONPATH
    • d2a2496 Switch the runtime from Python 3.9 to Python 3.11
    • See full diff in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 0
  • build(deps): bump pypa/gh-action-pypi-publish from 1.5.1 to 1.5.2

    build(deps): bump pypa/gh-action-pypi-publish from 1.5.1 to 1.5.2

    Bumps pypa/gh-action-pypi-publish from 1.5.1 to 1.5.2.

    Release notes

    Sourced from pypa/gh-action-pypi-publish's releases.

    v1.5.2

    What's Improved

    Full Diff: https://github.com/pypa/gh-action-pypi-publish/compare/v1.5.1...v1.5.2

    Commits
    • d7edd4c Add user-global site-packages to $PYTHONPATH
    • 8d5f27c Install Twine in the user-global site-packages
    • b0dc178 Disable pip cache dir with an env var
    • bbf6e0b Copy requirements to corresponding dir @ container
    • 0b69a8c Document broken pkginfo==1.9.0 transitive dep
    • c54db9c Integrate pip-tools-generated constraint files
    • 480ec4e Inherit yamllint config from the default preset
    • 5fb2f04 Drop __token__ from README code usage snippets
    • 7bbdccd Update the mention of master with unstable/v1
    • 328cf89 📝 Fix a link to the "Distribution Package" term
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 0
  • build(deps): bump peter-evans/create-pull-request from 3 to 4

    build(deps): bump peter-evans/create-pull-request from 3 to 4

    Bumps peter-evans/create-pull-request from 3 to 4.

    Release notes

    Sourced from peter-evans/create-pull-request's releases.

    Create Pull Request v4.0.0

    Breaking changes

    • The add-paths input no longer accepts -A as a valid value. When committing all new and modified files the add-paths input should be omitted.
    • If using self-hosted runners or GitHub Enterprise Server, there are minimum requirements for v4 to run. See "What's new" below for details.

    What's new

    • Updated runtime to Node.js 16
      • The action now requires a minimum version of v2.285.0 for the Actions Runner.
      • If using GitHub Enterprise Server, the action requires GHES 3.4 or later.

    What's Changed

    New Contributors

    Full Changelog: https://github.com/peter-evans/create-pull-request/compare/v3.14.0...v4.0.0

    Create Pull Request v3.14.0

    This release reverts a commit made to bump the runtime to node 16. It inadvertently caused an issue for users on GitHub Enterprise. Apologies. 🙇‍♂️

    What's Changed

    Full Changelog: https://github.com/peter-evans/create-pull-request/compare/v3.13.0...v3.14.0

    Create Pull Request v3.13.0

    What's Changed

    New Contributors

    Full Changelog: https://github.com/peter-evans/create-pull-request/compare/v3.12.1...v3.13.0

    Create Pull Request v3.12.1

    What's Changed

    New Contributors

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 0
Releases(v2022.12.06-2)
Owner
William Woodruff
R&E @trailofbits, maintainer @Homebrew
William Woodruff
This library provides programmatic access to the DALL·E 2 API in Python

pydalle: A DALL·E 2 API Wrapper for Python This library provides basic programmatic access to the DALL·E 2 API. The intent of this library is to provi

Michael Phelps 56 Dec 12, 2022
In this Repo there are many small and big pythons projects are there Created By me! i hope you will enjoy! Thank you

Python-Projects In this Repo there are many small and big pythons projects are there Created By me! i hope you will enjoy! Thank you *********** 1.Fir

DHRUV TILVA 2 Aug 25, 2022
The open-source data-centric IDE for NLP. Combining programmatic labeling, extensive data management and neural search capabilities.

Open-source data-centric IDE for NLP. Combining (semi-)automated labeling, extensive data management and neural search capabilities. Kern AI refinery

Kern AI 1.1k Dec 29, 2022
A programmatic attempt to find yourself on Google Maps Streetview using your Google Maps Location history.

Streetview Collision Detector A programmatic attempt to help you find yourself on Google Maps Streetview using your Google Maps Location history. What

Ryan Bateman 4 Nov 16, 2022
A simple system information gathering tool, displays variety of system information such as hardware information, network configuration and more

SystemParser_0.0.3-alpha A simple system information gathering tool written in python, displays a medley of system information reported by the systems

El Codigo Dominicano 1 Aug 10, 2022
ZarrDAP is a FastAPI project that provides access to Zarr and NetCDF data in remote object storage using the Open-source Project for a Network Data Access Protocol (OPeNDAP).

ZarrDAP OPeNDAP for Zarr! ZarrDAP is a FastAPI project that provides access to Zarr and NetCDF data in remote object storage using the Open-source Pro

null 33 Dec 10, 2022
Coreference resolution for English, French, German and Polish, optimised for limited training data and easily extensible for further languages

Coreferee Author: Richard Paul Hudson, Explosion AI 1. Introduction 1.1 The basic idea 1.2 Getting started 1.2.1 English 1.2.2 French 1.2.3 German 1.2

Explosion 70 Dec 12, 2022
BroSnip is the newest and FASTEST Roblox Limited Sniper made by me!

Roblox Limit Sniper BroSnip Snipes Limited Items when the prices match the amount of robux you want to pay. How does it work? Roblox has api which sho

Brobz 2 Sep 12, 2022
A mindspore implementation of our novel model to solve the VQA problem under limited computing resources setting.

VQA-under-different-settings A mindspore implementation of our novel model to solve the VQA problem under limited computing resources setting. We refe

Jiateng Liu 1 Jul 20, 2022
Automatically updates the price of your limited to always be first in the resellers list!

Automatically update your limiteds price to always be on the top of the list What does this do? This simply makes sure you're always on top of the res

null 2 Aug 12, 2022
[NeurIPS2022] FreGAN: Exploiting Frequency Components for Training GANs under Limited Data

FreGAN: Exploiting Frequency Components for Training GANs under Limited Data Exploiting Frequency Components for Training GANs under Limited Data Meng

Just call me 科大侠 :) 31 Dec 28, 2022
A student management system with tkinter for interface and with mysql-DBMS to store student information and manage student information

a student management system with tkinter for interface and with mysql-DBMS to store student information and manage student information

null 1 Nov 1, 2022
pypimc is a library to get minecraft account information and get hypixel stats information.

Install $ pip install pypimc Examples from pypimc import Minecraft # Minecraft account information info = Minecraft() print(info.minecraft(usernam

Manu+ 5 Jul 9, 2022
Template for fast api with uvicorn, straight access and http basic auth

FastAPI Framework with Free and Authenticated Routes Required / Recommended Virtual Environment for running directly on your machine Docker and Docker

Timo Ufermann 1 Dec 15, 2022
Python package providing access to the Keycloak API forked from python-keycloak

Adamatics Keycloak adamatics-keycloak is a Python package providing access to the Keycloak API. This is a forked version of the python-keycloak librar

Adamatics ApS 4 May 19, 2022
Build API with ASGI in AWS Lambda with API Gateway HTTP API or REST API, or with Function URL ✨

asgi-aws Build API with ASGI in AWS Lambda with API Gateway HTTP API or REST API, or with Function URL ✨ Installation pip install asgi_aws Example Cre

Yasser Tahiri 20 Sep 23, 2022
A dashboard and API to upload, analyse, and view the information collected by the in car Roadsage sensors and display from Unitic

Roadsage Metrics API and Dashboard Overview A dashboard to view and analyse the information collected by the in car Roadsage sensors and display from

Ben Brown 1 Apr 1, 2022
FHIRPACK (FHIR Python Analysis Conversion Kit) is a general purpose library that simplifies the access, analysis and representation of FHIR and EHR data

FHIRPACK (FHIR Python Analysis Conversion Kit) is a general purpose library that simplifies the access, analysis and representation of FHIR and EHR data. FHIRPACK was designed and developed at Institute for Artificial Intelligence in Medicine (IKIM) and the Database Systems Research Group of the University of Heidelberg (HDDBS).

FHIR Python Analysis Conversion Kit (FHIRPACK) 28 Dec 17, 2022