Registry / devops / pybadges

pybadges

JSON →
library3.0.1pypypiunverified

A library and command-line tool for generating Github-style badges (SVG images). Current version: 3.0.1, requires Python >=3.4, release cadence is irregular.

pip install pybadges
INSTALL
IMPORT
SIG · PYBADGES
P
pybadges
devopspythonv3.0.1
Install
2.4s avg
Import
1050ms
Disk
21MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v3.0.1 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.700s · 23MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 2.4s · import 0.560s · 23MB
21MB installed
● package 21MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

badge
import pybadges
from pybadges import badge

Generate a simple SVG badge and print its beginning.

from pybadges import badge svg = badge(left_text='version', right_text='3.0.1', right_color='green') print(svg[:100]) # prints first 100 characters of SVG
pybadges --version
Debug
Known issues
breakingIn version 3.0.0, the import path and function signature changed. `from pybadges import badge` is the only supported import; the old `generate_badge` function was removed.
fix
Use `from pybadges import badge` and call `badge(left_text='...', right_text='...', ...)`.
affects: >=3.0.0
deprecatedThe command-line tool `pybadges` is still available but may be deprecated in future releases. Use programmatic API instead.
fix
Use `from pybadges import badge` in Python scripts.
affects: >=3.0.0
gotchaThe `whole_link` parameter does not exist. To make the whole badge clickable, use `<a>` tags around the SVG output manually.
fix
Wrap the SVG string with `<a href="...">...</a>` in your HTML.
affects: all
Upgrade
Version history
3.0.1latest on PyPI · released Oct 11, 2023
Audit
Dependencies
xml.etree.ElementTreerequiredUsed internally for SVG generation
Agent activity
9 hits · last 30 days
node
8
Resources
pybadges — pip install pybadges · libregistry