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

Importing flwr before wandb causes deprecation warnings #4086

Open
scarere opened this issue Aug 26, 2024 · 1 comment
Open

Importing flwr before wandb causes deprecation warnings #4086

scarere opened this issue Aug 26, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@scarere
Copy link

scarere commented Aug 26, 2024

Describe the bug

Deprecation warnings due to importing flwr and then subsequently importing wandb. Deprecation warnings are not generated if wandb is imported first

Steps/Code to Reproduce

python -m venv test
source test/bin/activate
pip install --upgrade pip flwr wandb
python -c "import flwr;import wandb"

Expected Results

Actual Results

/home/shawn/venvs/test/lib/python3.10/site-packages/dockerpycreds/utils.py:1: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
  import distutils.spawn
/home/shawn/venvs/test/lib/python3.10/site-packages/wandb/analytics/sentry.py:90: SentryHubDeprecationWarning: `sentry_sdk.Hub` is deprecated and will be removed in a future major release. Please consult our 1.x to 2.x migration guide for details on how to migrate `Hub` usage to the new API: https://docs.sentry.io/platforms/python/migration/1.x-to-2.x
  self.hub = sentry_sdk.Hub(client)
@scarere scarere added the bug Something isn't working label Aug 26, 2024
@scarere
Copy link
Author

scarere commented Aug 26, 2024

Note that although it is only a single warning here, it actually results in the same deprecation warning a bunch of times when dependencies that import wandb are used

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants
@scarere and others