diff --git a/news/6852.feature b/news/6852.feature index 8f822b38a9c..30097e82a8f 100644 --- a/news/6852.feature +++ b/news/6852.feature @@ -2,3 +2,4 @@ Cache wheels that ``pip wheel`` built locally, matching what ``pip install`` does. This particularly helps performance in workflows where ``pip wheel`` is used for `building before installing `_. +Users desiring the original behavior can use ``pip wheel --no-cache-dir``. diff --git a/src/pip/_internal/wheel.py b/src/pip/_internal/wheel.py index 5ff108cc2ca..62937eaf0a1 100644 --- a/src/pip/_internal/wheel.py +++ b/src/pip/_internal/wheel.py @@ -1170,7 +1170,6 @@ def build( python_tag=python_tag, ) if wheel_file: - build_success.append(req) self.wheel_filenames.append( os.path.relpath(wheel_file, output_dir) ) @@ -1213,6 +1212,7 @@ def build( ) build_failure.append(req) continue + build_success.append(req) else: build_failure.append(req)