[Bug]: Clean install cannot import audio_separator — ModuleNotFoundError: No module named 'audioread' (undeclared dependency)
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 1/5
- Thời gian dự kiến
- Dưới một giờ
- Mức phù hợp với người mới
- 95/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- python
- Lĩnh vực
- build-system
Hướng nghiên cứu
Bắt đầu với pyproject.toml, nơi khai báo các phụ thuộc lúc chạy, và kiểm tra các import trong audio_separator/separator/uvr_lib_v5/spec_utils.py và audio_separator/separator/architectures/vr_separator.py. Khai báo rõ ràng audioread, sau đó xác minh trong môi trường sạch bằng pip install --ignore-installed . rồi đến python -c "import audio_separator". Hoàn thành khi bản cài đặt mới giải quyết được audioread và việc import diễn ra mà không có ModuleNotFoundError.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
- I have searched and found no existing issues.
Describe the bug
A clean install of audio-separator==0.48.0 cannot be imported at all:
ModuleNotFoundError: No module named 'audioread'
audioread is imported and used at runtime, but it is not declared as a dependency. It used to arrive transitively through librosa, and librosa 1.0 dropped it, so the librosa>=0.10 constraint no longer guarantees its presence.
I confirmed this without installing anything, by resolving a fresh install:
$ pip install --dry-run --ignore-installed --report resolve.json "audio-separator==0.48.0"
$ python -c "import json;d=json.load(open('resolve.json'));p={i['metadata']['name'].lower():i['metadata']['version'] for i in d['install']};print(p.get('librosa'), 'audioread' in p)"
1.0.1 False
So the default resolution today picks librosa 1.0.1 and installs no audioread — the package is broken out of the box, no upgrade step needed.
It is not a dead import
audioread is really used, so removing the import is not the right fix:
audio_separator/separator/uvr_lib_v5/spec_utils.py:1—import audioread, used at line 1332:with audioread.audio_open(audio_file) as f:audio_separator/separator/architectures/vr_separator.py:12—import audioread, used at line 397
The import chain that triggers it first:
separator/separator.py:27 from audio_separator.separator.ensembler import Ensembler
separator/ensembler.py:3 from audio_separator.separator.uvr_lib_v5 import spec_utils
uvr_lib_v5/spec_utils.py:1 import audioread
Workaround
pip install audioread
After that, import and separation both work normally (verified on 4-stem separation).
Suggested fix
Add it explicitly to dependencies in pyproject.toml, e.g. audioread>=3.0. Because librosa>=1.0 no longer provides it, relying on the transitive path will break for every new install from now on.
Logs
Traceback (most recent call last):
File "/path/to/site-packages/audio_separator/separator/separator.py", line 27, in <module>
from audio_separator.separator.ensembler import Ensembler
File "/path/to/site-packages/audio_separator/separator/ensembler.py", line 3, in <module>
from audio_separator.separator.uvr_lib_v5 import spec_utils
File "/path/to/site-packages/audio_separator/separator/uvr_lib_v5/spec_utils.py", line 1, in <module>
import audioread
ModuleNotFoundError: No module named 'audioread'
Package metadata for 0.48.0 shows no audioread requirement anywhere, including extras:
$ python -c "import importlib.metadata as m;print([r for r in m.requires('audio-separator') if 'audio' in r.lower()])"
['audioop-lts (>=0.2.1) ; python_version >= "3.13" and python_version < "4.0"']
System Info
Operating System: macOS 26.6.2 (arm64, Apple Silicon)
Python version: 3.14.6
audio-separator: 0.48.0 (latest on PyPI, released 2026-10-29)
librosa: 1.0.1
numpy: 2.5.5
torch: 2.15.0 (darwin arm64 wheel)
Install method: pip in a virtualenv, as a dependency of a desktop app
Additional Information
Found while installing a third-party app that depends on audio-separator[cpu]; the failure is in this package's own dependency metadata, so it should affect any consumer, not just that app.
If 3.14 support is a concern, note requires_python currently allows 3.14.x (!=3.14.1,>=3.10) — but this failure is unrelated to the Python version, it is the missing dependency.
Happy to test a patch release.
- Ngôn ngữ chính
- Python
- Star
- 1.5k
- Fork
- 216
- Merge trung bình
- 1 giờ
- Pull request đã merge (30 ngày)
- 2
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của nomadkaraoke/python-audio-separator
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
nomadkaraoke/python-audio-separator#292 · 2 bình luận ·
-
Confusing info in READMECó thể làm lại được Pull request cho issue này đã bị đóng mà không được merge. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 65/100
nomadkaraoke/python-audio-separator#246 · 1 bình luận ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
-
[Bug]: MDX models: vocals scaled down by the input's peak when the input peak is below normalization_threshold , leaving voice in the instrumental stemCó thể đã có người làm @Rahul-cs50 đã nhận 24 ngày trước. Đang mởbug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 65/100
Tất cả issue của nomadkaraoke/python-audio-separator
Issue tương tự
-
request_access
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
-
blocker bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
achisolomon/software-factory#305 ·
-
free_port can hand one port to two callers, so the fixed-port http tests fail in parallel runsĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 92/100
erkamyaman/rust-anything#963 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
commonmark/commonmark-spec#850 ·
-
Documentation websiteĐang mởdocumentation good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100