Skip to content

'NoneType' object has no attribute 'with_suffix' #36

@unfuug

Description

@unfuug

Description

I ran into the same issue described in #15 when trying to download the large model for German. But I also get the error when running the script without parameters:

Note: I am using uv to manage venvs.

python chapterize_ab.py



──────────────────────────────────────────────────────────────────────────────────── Starting script ─────────────────────────────────────────────────────────────────────────────────────


Preparing chapterfying magic ⚡...


Traceback (most recent call last):
  File "/home/lutz/Hörbücher/Chapterize-Audiobooks/chapterize_ab.py", line 1078, in <module>
    main()
    ~~~~^^
  File "/home/lutz/Hörbücher/Chapterize-Audiobooks/chapterize_ab.py", line 970, in main
    audiobook_file, in_metadata, lang, model_name, model_type, cue_file = parse_args()
                                                                          ~~~~~~~~~~^^
  File "/home/lutz/Hörbücher/Chapterize-Audiobooks/chapterize_ab.py", line 316, in parse_args
    args.audiobook.with_suffix('.cue').exists()
    ^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'with_suffix'

System

OS: CachyOS (based on Arch)
uv version: 0.10.9
Python version: 3.14.3 (also tried 3.11)

Steps to reproduce

Create venv:

❯ uv venv -p 3.14
Using CPython 3.14.3 interpreter at: /usr/bin/python3.14
Creating virtual environment at: .venv
Activate with: source .venv/bin/activate.fish

Install requirements:

❯ uv pip install vosk rich requests
Resolved 15 packages in 3ms
Installed 15 packages in 22ms
 + certifi==2026.2.25
 + cffi==2.0.0
 + charset-normalizer==3.4.5
 + idna==3.11
 + markdown-it-py==4.0.0
 + mdurl==0.1.2
 + pycparser==3.0
 + pygments==2.19.2
 + requests==2.32.5
 + rich==14.3.3
 + srt==3.5.3
 + tqdm==4.67.3
 + urllib3==2.6.3
 + vosk==0.3.45
 + websockets==16.0

Run:

❯ uv run chapterize_ab.py

Notes

  • I also tested .venv/bin/python chapterize_ab.py and source .venv/bin/activate.fish, followed by python chapterize_ab.py with the same result.
  • I did not modify any files. I cloned the repo and ran whats listed above.

Output of pip list -v:

❯ uv pip list -v
DEBUG uv 0.10.9 (f675560f3 2026-03-06)
DEBUG Searching for default Python interpreter in virtual environments, managed installations, or search path
DEBUG Found `cpython-3.14.3-linux-x86_64-gnu` at `/home/lutz/Hörbücher/Chapterize-Audiobooks/.venv/bin/python3` (active virtual environment)
DEBUG Using Python 3.14.3 environment at: .venv
Package            Version
------------------ ---------
certifi            2026.2.25
cffi               2.0.0
charset-normalizer 3.4.5
idna               3.11
markdown-it-py     4.0.0
mdurl              0.1.2
pycparser          3.0
pygments           2.19.2
requests           2.32.5
rich               14.3.3
srt                3.5.3
tqdm               4.67.3
urllib3            2.6.3
vosk               0.3.45
websockets         16.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions