-
Notifications
You must be signed in to change notification settings - Fork 671
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
Use UV to install all needed packages locally #3124
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Loved this. I would say other than speed-up local development, this paves the way to adopt uv in opentelemetry-python.
I think it will be necessary to add some instructions on how to use that. But just a note for reviewers:
With a simple command like uv sync
you can have all packages from the project installed locally. If you want to install only one package you can run: uv sync --package opentelemetry-instrumentation-sqlalchemy
for example.
Sure but aren't we adding another source of dependabot warnings? I'm fine on adding the metadata to the pyproject for people using uv but isn't this duplicating what we use tox for? |
Unfortunately/Fortunately, Dependabot doesn't see the
Not really. The idea here is to have a single virtual environment that can be used by the IDE, and to simplify local development (running some scripts locally to test some integrations, etc). The tox is used to run the tests with multiple different environments, it doesn't really create this virtual environment. |
Is it possible that |
This is not related with this PR, please create an issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Kludex could you please write a guide on how people can use this setup? Maybe a small section in CONTRIBUTING.md is enough.
I'm ready. |
Looks like the uv.lock is confusing ruff? Also curious aws xray propagator test failures. |
No...
Calling the test ruff but running pre-commit doesn't help 👀 |
It seems it's looking to the |
@emdneto we talked about this at some point. Do you remember why? |
I dropped xray from the list of packages. It seems the problem is that on the tests, we try to install a package that is listed in the pyproject, but on the pyproject it references a commit, and in the tox it references a version. I asked on their discord to see if I can do something about it. But the test suite has their own virtual environments, so it's all good. |
Just a note: The same will happen for all packages that are tested using pinned released versions of api/sdk in test requirements e.g., gen-ai stuff |
🥳 |
This is specifically to have a single virtual environment with all dependencies to make it easier to develop here.