PDBe CCD Utils
raw JSON → 1.0.3 verified Fri May 01 auth: no python
A toolkit to parse and process small molecules (chemical components) from the wwPDB Chemical Component Dictionary (CCD), including PRD and CLC entries. Current version 1.0.3, updated to work with modern RDKit and NumPy. Releases are irregular but focused on bug fixes and dependency updates.
pip install pdbeccdutils Common errors
error ImportError: cannot import name 'PDBeComponent' from 'pdbeccdutils' ↓
cause PDBeComponent is not exposed at package level; it is in the core.component submodule.
fix
Use: from pdbeccdutils.core.component import PDBeComponent
error RDKit ERROR: [14:11:29] Cannot find matching atom for bond ... ↓
cause Sanitisation may fail for some molecules; v0.8.4 introduced non-sanitised fallback.
fix
Ensure you are using v0.8.4 or later; if problem persists, the molecule may be invalid.
Warnings
breaking Version 1.0.0 introduced breaking changes: updated RDKit and NumPy dependencies, and fixed a 2D depiction error. Code written for v0.8.x may not work without adjustments. ↓
fix Check RDKit version compatibility and update depiction calls if needed.
gotcha The download_components helper requires an active internet connection; it fetches data from wwPDB. Offline use is not supported. ↓
fix Ensure network access when using download_components; cache results locally if needed.
Imports
- PDBeComponent wrong
from pdbeccdutils import PDBeComponentcorrectfrom pdbeccdutils.core.component import PDBeComponent
Quickstart
from pdbeccdutils.core.component import PDBeComponent
from pdbeccdutils.helpers import download_components
# Download a component by CCD code
comp = PDBeComponent('ATP') # ATP as example
print(comp.code, comp.name)