Reference only

Missing safetensors package or unreadable weights? Diagnose them separately

Distinguish the Python library from the weight file before reinstalling packages or downloading models again.

A file extension is not a Python installation

Safetensors documents a Python package and file-reading interfaces. An import failure occurs before a particular weight file can be parsed. A later SafetensorError reports a read or format problem, but its class name alone does not prove download corruption: upstream also has distinct invalid-header, size-limit, offset and incomplete-buffer errors. Safetensors docs Reader error definitions

python -c "import sys; print(sys.executable); import safetensors; print(safetensors.__version__)"

Run that command with the Python interpreter used to start ComfyUI; an installed package in another interpreter does not resolve the active import. If import succeeds, preserve the exact exception and failing path. For a file-reading error, record repository, revision, path, actual byte size and any publisher-provided integrity value before deciding whether the download is incomplete, the file format is unsupported, or the selected file is wrong. A model family name alone is not a file identity.

Our recommended replacement procedure preserves the original: download a separate candidate, compare it, then decide whether to replace the active file. Do not rename a suffix or alter a header to suppress validation errors.

Record library import, standalone file reading and workflow loading as separate checks. The documented safetensors.torch.load_file reads tensors from a named file; reading successfully does not establish that its keys or architecture fit a ComfyUI loader. Torch API A locally computed hash can compare two local copies; it verifies publisher identity only when compared with a trusted publisher value.

Sources and English text reviewed 2026-09-26. No package installation, local file read, ComfyUI run or GPU reproduction. Steps are editorial guidance, not a diagnosis of your file.

Didn't solve it?

Check the next possible cause

The same symptom can come from a different cause. Work through these related entries in order.

  1. Spandrel is installed but the model will not load: check architecture supportNo module named spandrelSeparate the library import from architecture support and the identity of the weights.
  2. Transformers errors: separate imports, API changes and model downloadsNo module named transformersLocate the failing stage before changing Transformers, model files or network settings.
Paste your full log into the error finder

Was this page helpful?

Anonymous. Only a yes/no counter is stored; no account, IP address or device details.

Sources & references

2026-09-26 checked official Safetensors documentation, Torch file-reader API and upstream Rust error definitions; English text reviewed. No package installation, file read, ComfyUI/GPU run or user-file diagnosis.

01Safetensors documentationSource checked: 2026-09-2602Safetensors Torch file-reader APISource checked: 2026-09-2603Safetensors reader error definitionsSource checked: 2026-09-26

Report an issue · 23af650b-130f-5f24-8dc9-341a4dc7314c