Quick Answer
uv 0.13.8 changes how concurrent processes handle a missing cached environment. After an initial cache lookup finds nothing usable, uv locks the relevant environment cache entry and checks again. It creates the environment only if that second lookup still finds nothing. A waiting process can therefore reuse the environment another process has just built.
The November 12, 2026 release lists this under performance improvements for concurrent uvx and uv run --with invocations. The underlying change, PR 23123, merged on November 5. Its practical target is duplicate construction when multiple processes need the same resolved environment. The supplied evidence includes implementation changes and a regression test, but no measured speedup or test-run results.
In Plain English
A cache helps only when a process can find something reusable inside it. When several processes arrive at an empty cache together, each can make the same reasonable observation: the environment is missing, so it needs to be built. Without coordination around that decision, they can all start doing equivalent work.
The PR author describes eight concurrent uvx pycowsay --help processes as an example. According to that account, the processes could build eight environments and publish to the same cache entry, leaving only the last environment reusable through that entry. That is the author’s reported scenario, not a reproduction performed for this article.
The new sequence gives those processes a shared decision point. One process obtains the relevant lock; another waits. Crucially, the waiting process does not treat its earlier cache miss as permanent knowledge. Once it obtains the lock, it asks again whether the environment exists. If the first process has made it available, the second process can reuse it.
Code Evidence
The changed environment implementation puts a cache lookup before lock acquisition. This preserves a direct path for a usable cache hit: the process can return the existing environment without taking the new lock. Coordination is introduced after a miss, where concurrent builders need it.
The lock is associated with the environment cache entry, with a lock filename derived from the resolution hash. After acquiring it, the implementation performs another cache lookup before proceeding with environment creation. The second lookup is the essential companion to the lock. A lock alone would serialize builders, but without reconsidering the cache, each waiting process could still repeat work after its turn arrived.
The PR description also says different resolutions can build concurrently. Together, the lock identity and lookup sequence support a focused interpretation: processes requesting the same resolved environment coordinate their cache-miss work. This does not describe a single global queue for every environment build.
The added tool_run_concurrent_cache_miss test makes the intended outcome concrete. It starts two tool-run processes against a local wheel while holding a wheel-cache lock to coordinate the run. The test waits until each process reports waiting on a lock, then releases the wheel lock.

Its assertions require both processes to succeed and print the same output. It also checks that one archived environment containing pyvenv.cfg remains. Those assertions connect successful execution with the cache outcome the change is meant to protect. They establish what the repository test checks; the supplied material does not establish that it was executed or passed.
A supporting change in environment error handling adds uv_cache::Error to EnvironmentError and its mappings. This accompanies the cache coordination work, while the user-visible behavior centers on the lock and second lookup.
Why It Matters
The intended benefit is avoiding duplicate environment builds and the disk use associated with those duplicate environments. For developers launching matching tool invocations concurrently, the relevant improvement is that a cache miss can become shared work: one process builds, and later processes can consume the result.
This is also a useful distinction between protecting publication and coordinating construction. If several processes can publish to one cache entry, the final entry alone does not show how much duplicate work happened beforehand. The PR addresses the earlier decision to build by checking again inside the coordinated section.
The first lookup matters too. Existing usable environments do not need the new lock, according to the implementation sequence and PR description. Editorially, this makes the change interesting as a targeted concurrency fix: it adds coordination around the contested miss while retaining the cache-hit path. Actual time and storage savings remain workload-dependent and unmeasured in the supplied sources.
An Open Question
How much time and storage does this save under representative concurrent workloads? The answer would require measurements that distinguish cold-cache runs from cache hits and matching resolutions from different ones. The PR author’s eight-process example explains the failure scenario, but it is not a benchmark of the released change.
The two-process regression test asks a narrower question: can coordinated concurrent tool runs succeed while leaving the expected single archived environment? That is valuable behavioral coverage, but it cannot supply a general performance figure.
Scope and Limitations
The release notes name uvx and uv run --with. The supplied test specifically exercises concurrent tool runs, so it should not be presented as direct test coverage for both invocation paths. The evidence supports coordination for matching cached environments, without establishing broader guarantees about unrelated cache operations.
This article relies on the supplied official-source research. No independent execution, benchmark, or test pass is claimed. The implementation and assertions explain the intended behavior; runtime verification and quantitative results remain outside this evidence.
