Hi I am having an issue with patch 9767 here are the errors I am getting, can anyone suggest what would be the issue?

We do not use downloader which is why they are failing but as for the other errors I am unsure? How can I get this patch to successfully apply?

checking file app/etc/config.xml
Hunk #1 FAILED at 141 (different line endings).
1 out of 1 hunk FAILED
checking file app/locale/en_US/Mage_Adminhtml.csv
Hunk #1 FAILED at 1287.
1 out of 1 hunk FAILED
checking file app/locale/en_US/Mage_Core.csv
Hunk #1 FAILED at 407.
1 out of 1 hunk FAILED

checking file app/locale/en_US/Mage_XmlConnect.csv
can't find file to patch at input line 1020
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git downloader/Maged/Connect.php downloader/Maged/Connect.php
|index 5c4faf6..1535a4a 100644
|--- downloader/Maged/Connect.php
|+++ downloader/Maged/Connect.php
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
3 out of 3 hunks ignored
can't find file to patch at input line 1052
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git downloader/Maged/Controller.php downloader/Maged/Controller.php
|index 84a0184..bef60c0 100644
|--- downloader/Maged/Controller.php
|+++ downloader/Maged/Controller.php
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
2 out of 2 hunks ignored
can't find file to patch at input line 1115
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git downloader/Maged/Model/Session.php downloader/Maged/Model/Session.php
|index 8fb1a03..1cc5e56 100644
|--- downloader/Maged/Model/Session.php
|+++ downloader/Maged/Model/Session.php
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
2 out of 2 hunks ignored
checking file js/lib/jquery/jquery-1.12.0.js
checking file js/lib/jquery/jquery-1.12.0.min.js
checking file js/lib/jquery/jquery-1.12.0.min.map
checking file js/varien/payment.js
checking file skin/frontend/base/default/js/opcheckout.js
Hunk #1 succeeded at 711 (offset 27 lines).
有帮助吗?

解决方案

The 'hunk failed' messages indicate that the file it's trying to patch has been altered. This is why we don't edit the core files.

The simplest thing you can do is make sure the patch you're applying is correct for the version of Magento you're using. Usually the patches are good for a range of versions. You can get the version from the command line like this:

$ grep -A10 'function getVersionInfo' app/Mage.php

If it's the wrong patch version, then just get the correct version and it should run just fine.

If that's all good, next make sure you have any prior patches installed as well. Any patches released between the release date of your version and the release date of the SUPEE-9767 patch should be applied. You can find the list of applied patches in the appropriately named file

app/etc/applied.patches.list

If neither of those two solutions solved it, then roll up your sleeves, this is gonna take some work.

For each of the filenames occurring before a "hunk failed" error, you'll need to compare that file to the original version of the file (including any prior patches), figure out what the differences are, and get it to match close enough for the patch to work.

If you need the changes in your version of the file, you'll have to apply the code from the patch yourself, then remove that section from the patch shell script.

For instance, the first file looks like a simple fix, given the error message. Someone probably edited the file on a Windows computer, and the line endings were changed. The Magento developers, like most devs, prefer to use the Unix line endings. This is usually a setting in your editor/IDE, if not the default for your system.

Fix the file to use Unix line endings and that file should be patchable.

Good luck!

许可以下: CC-BY-SA归因
scroll top