Upgrading/Migrating from 5.1.5 to 5.1.6

Hello, I am trying to upgrade Plone 5.1.5 to Plone 5.1.5 from an already created site. But it shows me this error:

And this is error from console:

2019-10-25 20:21:24 INFO plone.app.upgrade Starting the migration from version: 5115
2019-10-25 20:21:24 INFO plone.app.upgrade End of upgrade path, main migration has finished.
2019-10-25 20:21:24 ERROR plone.app.upgrade The upgrade path did NOT reach current version.
2019-10-25 20:21:24 ERROR plone.app.upgrade Migration has failed

I'm trying correct this error editing the file:
./eggs/Products.CMFPlone-5.1.6-py2.7.egg/Products/CMFPlone/MigrationTool.py line 138
replace
if version == 'unknown':
with
if version != 'unknown':

With this change i solved the error

I don't know if I'm doing well, can someone help me?

Oscar Sanchez V via Plone Community wrote at 2019-10-25 23:48 +0000:

Hello, I am trying to upgrade Plone 5.1.5 to Plone 5.1.5 from an already created site. But it shows me this error:
...
I'm trying correct this error editing the file:
./eggs/Products.CMFPlone-5.1.6-py2.7.egg/Products/CMFPlone/MigrationTool.py line 138
replace
if version == 'unknown':
with
if version != 'unknown':

With this change i solved the error

At least the original (==) is what was intended and your change (!=)
was not: getInstanceVersion expects, that usually the proper version
information is managed by portal_setup. But in some cases
portal_setup may return 'unknown';
in this case, the method tries to determine the version by local means.
Your change causes the version to be computed locally if portal_setup
does not return 'unknown' (and returns 'unknown' otherwise --
which surely is not correct).

The real problem is likely that the version information in
portal_setup was not updated correctly during the migration
(but I cannot tell you why this may have happened).

2019-10-30 19:41:10 INFO ZServer HTTP server started at Wed Oct 30 19:41:10 2019
Hostname: 0.0.0.0
Port: 8080
/home/scmos/scmos.elmirador03/eggs/plone.jsonserializer-0.9.6-py2.7.egg/plone/jsonserializer/serializer/converters.py:43: DeprecationWarning: getSiteEncoding: getSiteEncoding is deprecated. Plone only supports UTF-8 currently. This method always returns "utf-8"
from Products.CMFPlone.utils import getSiteEncoding
2019-10-30 19:41:13 INFO chameleon.config directory cache: /home/scmos/scmos.elmirador03/var/chameleon-cache.
/home/scmos/scmos.elmirador03/eggs/Products.CMFPlone-5.1.6-py2.7.egg/Products/CMFPlone/browser/syndication/views.py:17: DeprecationWarning: wrap_form is deprecated. Import from plone.z3cform.layout instead.
from plone.app.z3cform.layout import wrap_form
2019-10-30 19:41:16 WARNING fingerpointing common No audit log file specified; audit log view will be disabled
2019-10-30 19:41:16 WARNING plone.behavior Specifying 'for' in behavior 'Page refresh' if no 'factory' is given has no effect and is superfluous.
/home/scmos/scmos.elmirador03/eggs/collective.cover-2.2.0-py2.7.egg/collective/cover/tiles/file.py:11: DeprecationWarning: MimeTypeException is deprecated. Import from Products.MimetypesRegistry.interfaces instead
from Products.MimetypesRegistry.common import MimeTypeException
2019-10-30 19:41:17 WARNING Init Class plone.app.tiles.browser.add.DefaultAddView has a security declaration for nonexistent method 'browserDefault'
2019-10-30 19:41:17 WARNING Init Class plone.app.tiles.browser.add.DefaultAddView has a security declaration for nonexistent method 'publishTraverse'
2019-10-30 19:41:17 WARNING Init Class plone.app.tiles.browser.edit.DefaultEditView has a security declaration for nonexistent method 'browserDefault'
2019-10-30 19:41:17 WARNING Init Class plone.app.tiles.browser.edit.DefaultEditView has a security declaration for nonexistent method 'publishTraverse'
2019-10-30 19:41:17 WARNING Init Class plone.app.tiles.browser.delete.DefaultDeleteView has a security declaration for nonexistent method 'browserDefault'
2019-10-30 19:41:17 WARNING Init Class plone.app.tiles.browser.delete.DefaultDeleteView has a security declaration for nonexistent method 'publishTraverse'
2019-10-30 19:41:17 WARNING Init Class collective.cover.tiles.configuration_view.DefaultConfigureView has a security declaration for nonexistent method 'browserDefault'
2019-10-30 19:41:17 WARNING Init Class collective.cover.tiles.configuration_view.DefaultConfigureView has a security declaration for nonexistent method 'publishTraverse'
2019-10-30 19:41:17 WARNING Init Class collective.cover.tiles.edit.CustomTileEdit has a security declaration for nonexistent method 'browserDefault'
2019-10-30 19:41:17 WARNING Init Class collective.cover.tiles.edit.CustomTileEdit has a security declaration for nonexistent method 'publishTraverse'
/home/scmos/scmos.elmirador03/eggs/Zope2-2.13.29-py2.7.egg/OFS/Application.py:102: DeprecationWarning: Expected text
transaction.get().note("Created Zope Application")
/home/scmos/scmos.elmirador03/eggs/Zope2-2.13.29-py2.7.egg/OFS/Application.py:267: DeprecationWarning: Expected text
transaction.get().note(note)
/home/scmos/scmos.elmirador03/eggs/Zope2-2.13.29-py2.7.egg/OFS/Application.py:523: DeprecationWarning: Expected text
transaction.get().note('Prior to product installs')
2019-10-30 19:41:17 INFO Zope Ready to handle requests
/home/scmos/scmos.elmirador03/eggs/Zope2-2.13.29-py2.7.egg/Zope2/App/startup.py:344: DeprecationWarning: Expected text
T.note(path)
/home/scmos/scmos.elmirador03/eggs/Zope2-2.13.29-py2.7.egg/Zope2/App/startup.py:357: DeprecationWarning: Expected text
T.setUser(auth_user.getId(), auth_path)
uno

/home/scmos/scmos.elmirador03/eggs/Chameleon-2.25-py2.7.egg/chameleon/exc.py(219)init()
-> kwargs = rcontext.copy()
(Pdb) c
kwargs
{'here': <PloneSite at /Plone>, 'options': {}, 'modules': <Products.PageTemplates.ZRPythonExpr._SecureModuleImporter instance at 0x7f9e23f42680>, 'context': <PloneSite at /Plone>, 'wrapped_repeat': <Products.PageTemplates.Expressions.SafeMapping object at 0x7f9e1c5d0578>, 'nothing': None, 'args': (), 'report': None, 'template': <Products.Five.browser.pagetemplatefile.ViewPageTemplateFile object at 0x7f9e1ec22c90>, 'traverse_subpath': , 'user': <PropertiedUser 'admin'>, 'view': <Products.Five.metaclass.SimpleViewClass from /home/scmos/scmos.elmirador03/eggs/Products.CMFPlone-5.1.6-py2.7.egg/Products/CMFPlone/browser/templates/plone-upgrade.pt object at 0x7f9e1c599890>, 'translate': <function translate at 0x7f9e1c4186e0>, 'default': <object object at 0x7f9e2ca8b540>, 'repeat': {}, 'loop': {}, 'views': <Products.Five.browser.pagetemplatefile.ViewMapper object at 0x7f9e1c4192d0>, 'root': , 'target_language': 'en', 'container': <PloneSite at /Plone>, 'versions': {'corelist': {'CMF': '2.2.13', 'Debug mode': 'Yes', 'PIL': '5.2.0 (Pillow)', 'Python': '2.7.15+ (default, Oct 7 2019, 17:39:04) \n[GCC 7.4.0]', 'Zope': '2.13.29', 'Plone': '5.1.6', 'Platform': 'linux2', 'Plone Instance': u'5115', 'Plone File System': u'5116'}, 'instance_lt': True, 'equal': False, 'instance': u'5115', 'fs': u'5116', 'instance_gt': False}, 'request': <HTTPRequest, URL=http://localhost:8080/Plone/@@plone-upgrade>}
2019-10-30 19:42:31 ERROR Zope.SiteErrorLog 1572475351.840.514475158403 http://localhost:8080/Plone/@@plone-upgrade
Traceback (innermost last):
Module ZPublisher.Publish, line 138, in publish
Module ZPublisher.mapply, line 77, in mapply
Module ZPublisher.Publish, line 48, in call_object
Module Products.CMFPlone.browser.admin, line 322, in call
Module Products.Five.browser.pagetemplatefile, line 125, in call
Module Products.Five.browser.pagetemplatefile, line 59, in call
Module zope.pagetemplate.pagetemplate, line 137, in pt_render
Module five.pt.engine, line 98, in call
Module z3c.pt.pagetemplate, line 163, in render
Module chameleon.zpt.template, line 261, in render
Module chameleon.template, line 204, in render
Module chameleon.template, line 182, in render
Module e53daf60d7ed4b1f3b4c79d4a5d0f09c, line 958, in render
Module five.pt.expressions, line 161, in call
Module Products.CMFPlone.browser.admin, line 284, in upgrades
Module Products.CMFPlone.MigrationTool, line 246, in listUpgrades
Module pdb, line 1238, in run
Module bdb, line 398, in run
TypeError: can only concatenate list (not "str") to list

  • Expression: "view/upgrades"
  • Filename: ... egg/Products/CMFPlone/browser/templates/plone-upgrade.pt
  • Location: (line 134: col 48)
  • Source: ... k tal:repeat="upgrade_info view/upgrades">
    ^^^^^^^^^^^^^
  • Arguments: here: <ImplicitAcquisitionWrapper Plone at 0x7f9e1f03b320>
    options: {...} (0)
    modules: <instance - at 0x7f9e23f42680>
    context: <ImplicitAcquisitionWrapper Plone at 0x7f9e1f03b320>
    wrapped_repeat: <SafeMapping - at 0x7f9e1c5d0578>
    nothing: <NoneType - at 0x560dbe154560>
    args: <tuple - at 0x7f9e2cb6a050>
    report: <NoneType - at 0x560dbe154560>
    template: <ViewPageTemplateFile - at 0x7f9e1ec22c90>
    traverse_subpath: <list - at 0x7f9e1eae65a8>
    user: <ImplicitAcquisitionWrapper - at 0x7f9e1f044e10>
    view: <SimpleViewClass from /home/scmos/scmos.elmirador03/eggs/Products.CMFPlone-5.1.6-py2.7.egg/Products/CMFPlone/browser/templates/plone-upgrade.pt plone-upgrade at 0x7f9e1c599890>
    translate: <function translate at 0x7f9e1c4186e0>
    default: <object - at 0x7f9e2ca8b540>
    repeat: {...} (0)
    loop: {...} (0)
    views: <ViewMapper - at 0x7f9e1c4192d0>
    root: <ImplicitAcquisitionWrapper Zope at 0x7f9e1f036c30>
    target_language: en
    container: <ImplicitAcquisitionWrapper Plone at 0x7f9e1f03b320>
    versions: {...} (6)
    request: <instance - at 0x7f9e1ebccfc8>

Plone Foundation Code of Conduct