We need to make sure that the patch output was clean.
In a log file from Oleksandr, he had the following output, which includes a couple of issues:
1) We should reformat the patches to not have trailing CRs (since we are applying on Linux)
2) We should remove irrelevant hunks (e.g. patches to etc/xapi.d/plugins/xenhost)
3) We should fail if any hunks failed to apply or were skipped
4) We should check if a patch has already been applied
DEBUG:root:(Stripping trailing CRs from patch; use --binary to disable.) patching file nova/tests/unit/virt/xenapi/stubs.py (Stripping trailing CRs from patch; use --binary to disable.) patching file nova/tests/unit/virt/xenapi/test_vif.py (Stripping trailing CRs from patch; use --binary to disable.) patching file nova/tests/unit/virt/xenapi/test_vmops.py (Stripping trailing CRs from patch; use --binary to disable.) patching file nova/virt/xenapi/vif.py (Stripping trailing CRs from patch; use --binary to disable.) patching file nova/virt/xenapi/vm_utils.py (Stripping trailing CRs from patch; use --binary to disable.) patching file nova/virt/xenapi/vmops.py (Stripping trailing CRs from patch; use --binary to disable.) can't find file to patch at input line 669 Perhaps you used the wrong -p or --strip option? T -------------------------- File to patch: Skip this patch? [y] Skipping patch. 1 out of 1 hunk ignored (Stripping trailing CRs from patch; use --binary to disable.) can't find file to patch at input line 687 Perhaps you used the wrong -p or --strip option? The text leading up to this was: -------------------------- |diff --git a/plugins/xenserver/xenapi/etc/xapi.d/plugins/xenhost b/plugins/xenserver/xena -------------------------- File to patch: Skip this patch? [y] Skipping patch. 2 out of 2 hunks ignored
INFO:root:patch -d /usr/lib/python2.7/dist-packages/ -p1 -i /etc/fuel/plugins/fuel-plugin-xenserver-3.1/patchset/neutron-security-group.patch
DEBUG:root:(Stripping trailing CRs from patch; use --binary to disable.) patching file nova/tests/unit/virt/xenapi/test_vif.py (Stripping trailing CRs from patch; use --binary to disable.) patching file nova/virt/xenapi/vif.py (Stripping trailing CRs from patch; use --binary to disable.) can't find file to patch at input line 405 Perhaps you used the wrong -p or --strip option? The text leading up to this w -------------------------- File to patch: Skip this patch? [y] Skipping patch. 1 out of 1 hunk ignoreds/xenserver/xenapi/etc/xapi.d/plugins/xenhost
Reviewed: https:/ /review. openstack. org/360284 /git.openstack. org/cgit/ openstack/ fuel-plugin- xenserver/ commit/ ?id=a860fc500d0 5a8e75a1e3ad8e9 0a6ff97ce42910
Committed: https:/
Submitter: Jenkins
Branch: master
commit a860fc500d05a8e 75a1e3ad8e90a6f f97ce42910
Author: John Hua <email address hidden>
Date: Thu Aug 25 15:02:42 2016 +0800
Put pre-test earlier after network configuration
Change-Id: I1ea8a6a898913b 6a7b13fdf31e5a2 42cf04bf821
Related-bug: 1587454