summaryrefslogtreecommitdiff
path: root/src/pip/_vendor/README.rst
diff options
context:
space:
mode:
Diffstat (limited to 'src/pip/_vendor/README.rst')
-rw-r--r--src/pip/_vendor/README.rst24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/pip/_vendor/README.rst b/src/pip/_vendor/README.rst
index 077f1abf7..a21314543 100644
--- a/src/pip/_vendor/README.rst
+++ b/src/pip/_vendor/README.rst
@@ -118,6 +118,30 @@ Vendoring is automated via the `vendoring <https://pypi.org/project/vendoring/>`
``pip/_vendor/vendor.txt`` and the different patches in
``tools/vendoring/patches``.
Launch it via ``vendoring sync . -v`` (requires ``vendoring>=0.2.2``).
+Tool configuration is done via ``pyproject.toml``.
+
+
+Managing Local Patches
+======================
+
+The ``vendoring`` tool automatically applies our local patches, but updating,
+the patches sometimes no longer apply cleanly. In that case, the update will
+fail. To resolve this, take the following steps:
+
+1. Revert any incomplete changes in the revendoring branch, to ensure you have
+ a clean starting point.
+2. Run the revendoring of the library with a problem again: ``nox -s vendoring
+ -- --upgrade <library_name>``.
+3. This will fail again, but you will have the original source in your working
+ directory. Review the existing patch against the source, and modify the patch
+ to reflect the new version of the source. If you ``git add`` the changes the
+ vendoring made, you can modify the source to reflect the patch file and then
+ generate a new patch with ``git diff``.
+4. Now, revert everything *except* the patch file changes. Leave the modified
+ patch file unstaged but saved in the working tree.
+5. Re-run the vendoring. This time, it should pick up the changed patch file
+ and apply it cleanly. The patch file changes will be committed along with the
+ revendoring, so the new commit should be ready to test and publish as a PR.
Debundling