SNN 2.8b1 fails to upgrade from SNN 2.5

Bug #584201 reported by Tuomas Tonteri
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SilvaNewsNetwork
Fix Released
Critical
Sylvain Viollon

Bug Description

The upgrade button at: "silva-root/service_extensions/manage_extensions" fails as in the included traceback.

I am upgrading Silva from 2.1 to 2.2 and SNN from 2.5 to 2.8b1, which came with Silva 2.2.

Traceback:

2010-05-22 16:08:43 INFO silva.core.upgrade upgrading from 2.1 to 2.2.
2010-05-22 16:08:43 INFO silva.core.upgrade upgrading root to version 2.2a1.
/root/packages/Silva/eggs/Products.FileSystemSite-2.2-py2.4.egg/Products/FileSystemSite/DirectoryView.py:418: UserWarning: DirectoryView SilvaLayout refers to a non-existing path SilvaLayout/views
  % (self.id, dirpath), UserWarning)
2010-05-22 16:08:43 INFO silva.core.upgrade upgrading root to version 2.2a2.
2010-05-22 16:08:43 INFO silva.core.upgrade upgrading root to version 2.2b1.
2010-05-22 16:08:43 INFO silva.core.upgrade upgrading metadata for /xxx
2010-05-22 16:08:43 WARNING OFS.Uninstalled Could not import class 'ProxyIndex' from module 'Products.ProxyIndex.ProxyIndex'
2010-05-22 16:08:43 ERROR Zope.SiteErrorLog 1274533723.330.074382763165 http://192.168.0.1:8250/xxx/service_extensions/manage_extensions
Traceback (innermost last):
  Module ZPublisher.Publish, line 119, in publish
  Module ZPublisher.mapply, line 88, in mapply
  Module ZPublisher.Publish, line 42, in call_object
  Module silva.core.views.views, line 108, in __call__
   - Class: Products.Silva.ExtensionService.ManageExtensions
   - Object path: /xxx/service_extensions
   - Object type: Silva Extension Service
  Module grokcore.view.components, line 55, in __call__
  Module zope.publisher.publish, line 108, in mapply
   - __traceback_info__: <bound method ManageExtensions.update of <Products.Silva.ExtensionService.ManageExtensions object at 0xc325fcc>>
  Module zope.publisher.publish, line 114, in debug_call
  Module Products.Silva.ExtensionService, line 388, in update
  Module Products.Silva.ExtensionService, line 114, in upgrade_all
  Module Products.Silva.Root, line 173, in upgrade_silva
  Module silva.core.upgrade.upgrade, line 181, in upgrade
  Module silva.core.upgrade.upgrade, line 126, in upgradeObject
   - Object Info:
      {'object': <Silva Root instance xxx>,
       'object_path': '/xxx',
       'upgrader': <Products.SilvaNews.upgrade_28.SNNRefresher object at 0xa34b54c>}
  Module Products.SilvaNews.upgrade_28, line 36, in upgrade
  Module Products.Silva.ExtensionService, line 69, in install
  Module Products.Silva.ExtensionRegistry, line 268, in install
  Module Products.SilvaNews.installer, line 19, in install
  Module silva.core.conf.installer, line 63, in install
  Module Products.SilvaMetadata.MetadataTool, line 222, in addTypesMapping
  Module Products.SilvaMetadata.MetadataTool, line 235, in addTypeMapping
  Module Products.SilvaMetadata.TypeMapping, line 65, in editMappings
  Module Products.SilvaMetadata.TypeMapping, line 29, in setDefaultChain
  Module Products.SilvaMetadata.TypeMapping, line 117, in verifyChain
  Module Products.SilvaMetadata.TypeMapping, line 111, in getMetadataSets
  Module zope.component._api, line 206, in getUtility
ComponentLookupError: (<InterfaceClass Products.SilvaMetadata.interfaces.IMetadataService>, '')

Revision history for this message
Tuomas Tonteri (tuomas-tonteri) wrote :

I also tried to upgrade through SNN 2.7 by first going to service_news and upgrading content first to version 2.7. However, I get the same error upon trying to upgrade to 2.8b1.

Revision history for this message
Roman Joost (romanofski) wrote :

I've investigated this problem, because I'm trying to do the same. I found out that the metadata service and the catalog service was not registered as a utility in the local site manager. My guess is, that the upgrade script of SilvaNews starts earlier before services are registered?

I've wrote a little Zope run script to register the metadata_service and the catalog in the local site manager. I hope it helps - at least it's a quick fix.

Revision history for this message
Sylvain Viollon (thefunny) wrote :

The good way to upgrade to 2.2 a Silva that have SilvaNews installed is to take away SilvaNews during the migration and to add it back after.

SilvaNews 2.8 is only for Silva 2.2, and won't (is not expected to) work properly on 2.1 or before.

Revision history for this message
Sylvain Viollon (thefunny) wrote :

I am going to release a new version of SilvaNews and silva.core.upgrade that reorder the upgrader and fixes that issue.

Changed in silva-news-network:
assignee: nobody → Sylvain Viollon (thefunny)
importance: Undecided → Critical
milestone: none → 2.8
status: New → In Progress
Revision history for this message
Roman Joost (romanofski) wrote :

Thank's Sylvain for this!

Revision history for this message
Tuomas Tonteri (tuomas-tonteri) wrote :

I tried to remove SilvaNewsNetwork during Silva Core upgrade and then put it back later and upgrade again, but SilvaNews content didn't seem to get upgraded. I get error about missing attribute '_addables_allowed_in_container', when trying to navigate to NewsPublication in SMI. The attribute was either missing or had a different name in earlier SilvaNewsNetwork releases and thus the objects don't have the new attribute.

Revision history for this message
Sylvain Viollon (thefunny) wrote :

I released 2.8 today that should fix this problem.
To use it, edit buildout.cfg and add the following:

[versions]
Products.SilvaNews = 2.8

I will make a new version of Silva 2.2 soon.

Changed in silva-news-network:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.