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

Setuptool bug to watch #199

Open
EmmaRenauld opened this issue Sep 14, 2023 · 3 comments
Open

Setuptool bug to watch #199

EmmaRenauld opened this issue Sep 14, 2023 · 3 comments

Comments

@EmmaRenauld
Copy link
Collaborator

Installing as developper (pip install -e .) makes a warning:

l2t_train_model.py -h:

DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
import('pkg_resources').require('dwi-ml==0.1.0.dev0')

In my environment:

cat bin/l2t_train_model.py: The buggy line is: import('pkg_resources').require('dwi-ml==0.1.0.dev0')

See their PR: pypa/setuptools#3878

@jhlegarreta
Copy link
Contributor

Indeed, pkg_resources​ is deprecated. I don't see pkg_resources​ being imported explicitly in dwi_ml​, so after searching a bit, here's what I'd try:

We can discuss tomorrow/Monday/next week if none of the above works for you.

@EmmaRenauld
Copy link
Collaborator Author

Thanks!

  • My pip version is already the latest (23.2.1)
  • I had setuptools 68.0.0. I upgraded to 68.2.2 and reinstalled dwi_ml, it didn't fix it.

If it can help, here is my file my_env/bin/dwiml_visualize_logs.py:

# EASY-INSTALL-DEV-SCRIPT: 'dwi-ml==0.1.0.dev0','dwiml_visualize_logs.py'
__requires__ = 'dwi-ml==0.1.0.dev0'
__import__('pkg_resources').require('dwi-ml==0.1.0.dev0')
__file__ = '/home/local/USHERBROOKE/rene2201/my_applications/scil_vital/dwi_ml/scripts_python/dwiml_visualize_logs.py'
with open(__file__) as f:
    exec(compile(f.read(), __file__, 'exec'))

@scil-vital scil-vital deleted a comment from jhlegarreta Sep 22, 2023
@EmmaRenauld
Copy link
Collaborator Author

(The requests version is now updated and the issue is not fixed, so I deleted previous comments. I can't reproduce a "clean" environment anymore.).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants