Don't fail entirely when can't install requirements for a specific benchmark #350
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
When running multiple benchmarks, pyperformance first creates a venv with the dependencies for each benchmark. More specifically, it actually first tries to install the dependencies into a "global" venv (to reduce the number of total venvs created), and if that fails installs into a new venv specific to the benchmark. If something is broken in one of the dependencies (usually it's because upstream CPython broke backward compatibility on purpose and the dependency no longer compiles), it fails on both attempts, and pyperformance just moves along to the next benchmark.
However, a recent change to
setuptoolsnow leaves the package cache in a bad state on the first attempt such that installingwheelon the second attempt fails. This creates an exception where one wasn't expected and the whole pyperformance run comes to a halt.I think it's safe to expect that creating the venv fails in this way on the second attempt and we should handle it gracefully.
I also plan to investigate the
setuptoolschange further and report there, but in the meantime, I think it makes sense to makepyperformancemore robust to that.