Registry / communication / musicbrainzngs

musicbrainzngs

JSON →
library0.7.1pypypi✓ verified 84d ago

Python bindings for the MusicBrainz XML Web Service and Cover Art Archive. Current version 0.7.1, stable but infrequent updates; supports Python 2.7 and 3.4+.

pip install musicbrainzngs
INSTALL
IMPORT
SIG · MUSICBRAINZNGS
M
musicbrainzngs
communicationpythonv0.7.1
Install
1.5s avg
Import
222ms
Disk
16MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.7.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.300s · 18MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 1.5s · import 0.144s · 18MB
16MB installed
● package 16MB
Code
Verified usage

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

musicbrainzngs
import musicbrainzngs
No submodules; top-level functions are accessed via musicbrainzngs.*

Set user agent (required by MusicBrainz) and search for an artist.

import musicbrainzngs musicbrainzngs.set_useragent("MyApp", "1.0", "me@example.com") result = musicbrainzngs.search_artists(artist="Nirvana") print(result['artist-list'][0]['name'])
Debug
Known issues
breakingUser-Agent must be set before any request. Calls without it raise musicbrainzngs.ResponseError.
fix
Always call musicbrainzngs.set_useragent(app, version, contact) at the start.
affects: all
deprecatedmusicbrainzngs.set_rate_limit() is deprecated; rate limiting is now handled server-side.
fix
Remove calls to set_rate_limit().
affects: >=0.7
gotchaSearch results are paginated. The default limit is 25 items; use limit and offset parameters.
fix
Pass limit=100, offset=0 to get more results and loop until empty.
affects: all
Errors
Common errors & fixes
musicbrainzngs.ResponseError: status: 503
MusicBrainz server is temporarily unavailable or rate-limited.
fix
Wait and retry with exponential backoff.
musicbrainzngs.musicbrainz.ResponseError: status: 401
Invalid or missing OAuth credentials for authenticated endpoints.
fix
Call musicbrainzngs.auth(username, password) before accessing user-specific data.
Upgrade
Version history
0.7.1latest on PyPI · released Jan 11, 2020
Audit
Dependencies

No dependency data recorded yet.

Agent activity
21 hits · last 30 days
node
20
OpenAI (training)
1
Resources
musicbrainzngs — pip install musicbrainzngs · libregistry