open-telemetry / open-telemetry/opentelemetry-python-contrib
`test_0.yml` runtime is 1 hour 45 minutes
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.1k
- Forks
- 1.1k
- Avg merge
- 4d 15h
- Merged PRs (30d)
- 16
Description
Hello,
I've observed that test_0.yml takes an hour and 45 minutes to run [recent example, scroll to the bottom of the page to see the total time].
Would you be open to me submitting PRs to reduce the total runtime?
Some of the things that I'm seeing that are contributing to that long runtime include:
- Python 3.9 has to be downloaded and set up for ~35 jobs. 3.9 is not cached on the Ubuntu runners anymore, so each download and install contributes to the runtime.
- tox-uv is installed ~250 times (once per runner).
- The package has to be built (first as a
.tar.gzfile, and then converted to a wheel per tox defaults) for each run.
If you're open to it, I'd like to explore speeding up test_0.yml runtimes in the following ways:
- Aggregating environments so that, say,
py3{9,10,11,12,13,14}-test-instrumentation-aiopgall run on the same runner. - Building the opentelemetry wheel once, uploading it as an artifact, and then downloading it so that it doesn't have to be built for each tox environment
- Using the setup-uv action and using
uv pip install tox-uvto install tox, rather thanpip install tox-uv, which should reduce the time required to install tox.
These are all examples of what's possible. I have a lot of experience speeding up CI runs, but it always involves reducing duplication, which can affect the shape of the jobs. If you're open to me submitting PRs for this, let me know! If you'd like to keep CI as it is, that's fine too. I'm interested in helping, but don't want to waste anybody's time, my own included. 😁
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the test_0.yml workflow and the linked Actions run, reviewing how its jobs install Python 3.9, install tox-uv, and build the package. Compare the duplicated setup and build work across environments. Done means the workflow preserves its test coverage while reducing repeated CI work and total runtime.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, python
- Domain
- ci-cd, performance
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100