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

Update Python dependencies #17982

Merged
merged 3 commits into from
Apr 17, 2024

Conversation

galaxybot
Copy link
Contributor

Run make update-dependencies.

@github-actions github-actions bot added this to the 24.1 milestone Apr 13, 2024
@nsoranzo nsoranzo force-pushed the dev_auto_update_dependencies branch from 069abbf to e289006 Compare April 16, 2024 11:51
@nsoranzo
Copy link
Member

nsoranzo commented Apr 16, 2024

The new 1.0.0 version of pytest-celery moves towards a Docker-based approach for smoke and production-like testing while the previous version was just a shim for celery.contrib.pytest, which is based on mocking for unit and integration testing.
The new version also brings in a number of extra dependencies (debugpy, decorator, docker, py, pytest-docker-tools, pywin32, retry), which we don't currently need.
Is there interest in the new functionalities of pytest-celery, or should we just replace it with the loading of the celery.contrib.pytest plugin ?

@nsoranzo nsoranzo force-pushed the dev_auto_update_dependencies branch from e289006 to 26c7b70 Compare April 16, 2024 16:16
nsoranzo and others added 3 commits April 16, 2024 17:16
The new 1.0.0 version of pytest-celery will move towards a Docker-based
approach for smoke and production-like testing, bringing in a number of
dependencies that we don't currently need.
Since the pre-1.0.0 version of pytest-celery was just a shim for
``celery.contrib.pytest``, we can simply load the latter for API,
integration and Selenium tests.
@nsoranzo nsoranzo force-pushed the dev_auto_update_dependencies branch from 26c7b70 to edf06c5 Compare April 16, 2024 16:17
@nsoranzo
Copy link
Member

Ready to review/merge.

@mvdbeek mvdbeek merged commit bc248ef into galaxyproject:dev Apr 17, 2024
56 checks passed
@mvdbeek
Copy link
Member

mvdbeek commented Apr 17, 2024

Thank you!

@davelopez
Copy link
Contributor

@nsoranzo after this change, when VSCode tries to discover the tests I'm getting:

ValueError: Plugin already registered under a different name: celery.contrib.pytest=<module 'celery.contrib.pytest' from '/home/dlopez/dev/galaxy/.venv/lib/python3.11/site-packages/celery/contrib/pytest.py'>

Before this change you could run: pytest --collect-only lib/galaxy_test and it will succeed but now it fails and makes debugging tests in VSCode not possible 😞

Any idea how to fix that? 🙏

@mvdbeek
Copy link
Member

mvdbeek commented Apr 23, 2024

Did you install the dev dependencies ? pip install -r lib/galaxy/dependencies/dev-requirements.txt or use the run_test.sh or run.sh wrapper to get them automatically.

@davelopez
Copy link
Contributor

davelopez commented Apr 23, 2024

I installed them with pip install -r lib/galaxy/dependencies/dev-requirements.txt

is it working for you if you run: pytest --collect-only lib/galaxy_test?

@nsoranzo
Copy link
Member

Is it working for you if you run: pytest --collect-only lib/galaxy_test?

Yes, works fine for me. Maybe try to recreate the .venv?

@mvdbeek
Copy link
Member

mvdbeek commented Apr 23, 2024

Might also be worth checking that pytest is coming from the venv ... my zsh occasionally needs a rehash.

@davelopez
Copy link
Contributor

Yes, works fine for me. Maybe try to recreate the .venv?

That did the trick! Thank you both!

@nsoranzo
Copy link
Member

Replicated in another venv, just pip uninstall pytest-celery and it works.

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

Successfully merging this pull request may close these issues.

4 participants