Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation Issues: ModuleNotFoundError: No module named 'distutils.msvccompiler' #178

Open
Yangyizehui opened this issue Feb 18, 2025 · 2 comments
Assignees
Labels
dependencies Pull requests that update a dependency file

Comments

@Yangyizehui
Copy link

Thank you for developing this wonderful tool! But I encountered some problems during installation.
When I tried to install on python=3.9 version, I got the following problem which you answered in your previous question:
AttributeError: module 'bento' has no attribute 'io'.
Then I followed your solution:

pip uninstall bento-tools
git clone https://github.com/YeoLab/bento-tools.git
cd bento-tools
pip install -e .

Here comes a new problem:
ERROR: Package 'bento-tools' requires a different Python: 3.9.21 not in >=3.10
Then I reinstalled on python=3.10 version, The following problem occurred:

from distutils.msvccompiler import get_build_version as get_build_msvc_version
      ModuleNotFoundError: No module named 'distutils.msvccompiler'
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

However, distutils is deprecated in Python 3.10. Does anyone know what might be going wrong here?

@ckmah
Copy link
Collaborator

ckmah commented Feb 18, 2025

Hi @Yangyizehui thanks for reporting the installation error. It seems to stem from installing an older version of scikit-learn related to #177 . I am hoping to deprecate part of the code to address this, but that will require a deep dive that I hope to have time for soon. For now, please adjust the versioning in pyproject.toml to the following and perform the local pip install as you have so far:

...
dependencies = [
    "scikit-learn>1.0.1,<1.6.0",
...

Let me know if this solves your issue. Thanks!

@ckmah ckmah self-assigned this Feb 18, 2025
@ckmah ckmah added the dependencies Pull requests that update a dependency file label Feb 18, 2025
@Yangyizehui
Copy link
Author

This is useful, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

No branches or pull requests

2 participants