Magento – Resolve Upgrade Conflict and Unsupported Resource Type Errors

magento-1.6magento-1.9upgrade

I'm trying to upgrade from 1.6.2 to 1.9.1

I'm following this tutorial: http://astrio.net/blog/magento-upgrade-guide/

I have run ./mage upgrade-list and got this

Updates for community: 
Interface_Adminhtml_Default: 1.6.2.0 => 1.9.1.1
Interface_Frontend_Base_Default: 1.6.2.0 => 1.9.1.1
Interface_Frontend_Default: 1.6.2.0 => 1.9.1.1
Interface_Install_Default: 1.6.1.0 => 1.9.1.1
Lib_Google_Checkout: 1.5.0.0 => 1.9.1.1
Lib_Js_Calendar: 1.51.1 => 1.51.1.1-rc1
Lib_Js_Ext: 1.6.0.0 => 1.7.0.0-rc1
Lib_Js_Mage: 1.6.1.0 => 1.9.1.1
Lib_Js_Prototype: 1.7.0.0.2 => 1.7.0.0.5
Lib_Js_TinyMCE: 3.3.7.0 => 3.5.11.0
Lib_LinLibertineFont: 2.8.14.0 => 2.8.14.1-rc1
Lib_Mage: 1.6.1.0 => 1.9.1.1
Lib_Varien: 1.6.1.0 => 1.9.1.1
Lib_ZF: 1.11.1.0 => 1.12.7.0
Lib_ZF_Locale: 1.11.1.0 => 1.12.7.0
Mage_All_Latest: 1.6.2.0 => 1.9.1.1
Mage_Centinel: 1.6.1.0 => 1.9.1.1
Mage_Compiler: 1.6.2.0 => 1.9.1.1
Mage_Core_Adminhtml: 1.6.2.0 => 1.9.1.1
Mage_Core_Modules: 1.6.2.0 => 1.9.1.1
Mage_Downloader: 1.6.2.0 => 1.9.1.1
Mage_Locale_en_US: 1.6.2.0 => 1.9.1.1
Magento_Mobile: 1.6.0.0.22.1 => 1.9.1.1
Phoenix_Moneybookers: 1.3.0.1 => 1.3.2.1
Mage_GoogleShopping: 1.6.0.0 => 1.7.0.0
m2epro_ebay_magento: 4.2.8 => 6.3.3
CLS_Paypal_Credit_Card_Tokenization: 1.1.2 => 1.1.10

Than I've run ./mage upgrade-all –force but everything brake and magento stop working. I got a huge 1570 line error list. There are 15 error relative to conflic:

upgrade-all: Package community/Interface_Adminhtml_Default 1.9.1.1 conflicts with: community/Mage_All_Latest 1.6.2.0
upgrade-all: Package community/Mage_Core_Adminhtml 1.9.1.1 conflicts with: community/Mage_All_Latest 1.6.2.0, community/Mage_Compiler 1.6.2.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Interface_Frontend_Base_Default 1.6.2.0,     community/Interface_Frontend_Default 1.6.2.0, community/Interface_Install_Default 1.6.1.0, community/Mage_All_Latest 1.6.2.0,     community/Mage_Centinel 1.6.1.0, community/Mage_Compiler 1.6.2.0, community/Magento_Mobile 1.6.0.0.22.1, community/Phoenix_Moneybookers 1.3.0.    1, community/Mage_GoogleShopping 1.6.0.0
upgrade-all: Package community/Interface_Frontend_Base_Default 1.9.1.1 conflicts with: community/Mage_All_Latest 1.6.2.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Interface_Frontend_Default 1.6.2.0,     community/Interface_Install_Default 1.6.1.0, community/Mage_All_Latest 1.6.2.0, community/Mage_Centinel 1.6.1.0, community/Mage_Compiler 1.6.2    .0, community/Magento_Mobile 1.6.0.0.22.1, community/Phoenix_Moneybookers 1.3.0.1, community/Mage_GoogleShopping 1.6.0.0
upgrade-all: Package community/Interface_Frontend_Default 1.9.1.1 conflicts with: community/Mage_All_Latest 1.6.2.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Interface_Install_Default 1.6.1.0,     community/Mage_All_Latest 1.6.2.0, community/Mage_Centinel 1.6.1.0, community/Mage_Compiler 1.6.2.0, community/Magento_Mobile 1.6.0.0.22.1,     community/Phoenix_Moneybookers 1.3.0.1, community/Mage_GoogleShopping 1.6.0.0
upgrade-all: Package community/Interface_Install_Default 1.9.1.1 conflicts with: community/Mage_All_Latest 1.6.2.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Mage_All_Latest 1.6.2.0, community/Mage_Centinel 1.6.1.0,     community/Mage_Compiler 1.6.2.0, community/Magento_Mobile 1.6.0.0.22.1, community/Phoenix_Moneybookers 1.3.0.1, community/Mage_GoogleShopping     1.6.0.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Magento_Mobile 1.6.0.0.22.1, community/Mage_GoogleShopping     1.6.0.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Magento_Mobile 1.6.0.0.22.1, community/Mage_GoogleShopping     1.6.0.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Magento_Mobile 1.6.0.0.22.1, community/Mage_GoogleShopping     1.6.0.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Magento_Mobile 1.6.0.0.22.1, community/Mage_GoogleShopping     1.6.0.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Magento_Mobile 1.6.0.0.22.1, community/Mage_GoogleShopping     1.6.0.0
upgrade-all: Package community/Mage_Core_Modules 1.9.1.1 conflicts with: community/Magento_Mobile 1.6.0.0.22.1, community/Mage_GoogleShopping 1.6.0.0

after each of these conflict error there are a group of errors link this one:

Error: 
upgrade-all: Package community/Interface_Adminhtml_Default 1.9.1.1 conflicts with: community/Mage_All_Latest 1.6.2.0
Starting to download Interface_Adminhtml_Default-1.9.1.1.tgz ...
...done: 1,013,014 bytes

Warning: fopen(): Filename cannot be empty in /xxxxxx/downloader/lib/Mage/Connect/Package/Reader.php on line 119

Warning: get_resource_type() expects parameter 1 to be resource, boolean given in /xxxxxx/downloader/lib/Mage/Connect/Package/Reader.php on line 140

Warning: fclose() expects parameter 1 to be resource, boolean given in /xxxxxx/downloader/lib/Mage/Connect/Package/Reader.php on line 123
Error: 
upgrade-all: Unsupported resource type

totally I got more than 1500 line of errors…
now the magento install is completely broken. and the mage file is not there any more.
I can restore form a bck I've made before try to upgrade. But before try to upgrade again I'd like to understand how to prevent all these conflict problem!

I'll really appreciate any help and advice.

Best Answer

Ok, I've understood something...
the main problem was about the "Unsupported resource type" error. Because of this error the package are not decompressed nor installed, so the package after the first fail get a conflicts error.

Accordingly to this answer, the "Unsupported resource type" error is triggered by a change in the unpack function. After the change suggested in the answer I didn't get the error any more.

Now I'm able to upgrade... But I've got a new error about Magento_Mobile package when I try to upgrade to 1.9.1.1:

Package community/Magento_Mobile failed: Package release 'Magento_Mobile' not found on server

This is a known error when upgrading to 1.9.1.1 and the unique solution (I've found out) is to manually upgrade Magento_Mobile downloading the new version (XMLConnect Module) from the bottom of the official download page: https://www.magentocommerce.com/download

For now I have upgraded to magento 1.9.1.0 and now I'm manually upgrading Magento_Mobile to take the last step and get magento 1.9.1.1!