Submitted by : simon at: 2003-10-26T21:31:45+00:00 (14 years ago)
Name :
Category : Severity : Status :
Optional subject :  
Optional comment :

When exporting and importing a folder certain properties are modified, causing annoyances and strangeness in RecentChanges? and other time comparison methods. Also, the page hierarchy cache is lost ?

Details from GeneralDiscussion:

> John - What did your dates and last editor values look like when the site was imported?

If we have a page, say last edited by Bob a month ago, then I import today at 5pm we get:

last_editor Bob correct
last_editor_ip xx.xxx.xx.xxx correct
last_edit_time 2002-10-20 12:58:00 correct

creator John wrong
creator_ip my ip wrong
creation_time 2002-11-20 17:00:00 wrong

The three creation properties take on my details, rather than keep the originals. The three last_xxx properties remain correct. So we end up with a creation_time later than the last_edit_time... -- Verified on Zope 2.5.1 w/ ZWiki 0.11.0

Ramifications:

Version control and paper trail features are obscured.

SubWikiPortability? is weakened.

ie --SimonMichael, 2003/08/03 00:59 GMT reply

the three creation metadata properties get reset during import.

When exporting a ZWiki, and then Importing certain property values are lost:

creator , creator_ip , creation_time

also the tree hierarchy is lost --Fri, 02 Jul 2004 15:05:09 -0700 reply

What is more important to preserve in export/import operations, is imho the tree hierarchy. Consider the case where you are upgrading from Zope2.7 to Zope2.7.1. How do I transfer my Wiki without screwing up the tree hierarchy? Is there another way instead of exporting and importing? Whenever I try to import a ZWiki, all pages are marked as singletons. In fact this is probably not due to data loss, because the parents-field is preserved and its entries are transfered as well. Thanks for any suggestions, Benedikt

property change --SimonMichael, Sat, 03 Jul 2004 14:58:28 -0700 reply

Name: 'IssueNo0391? Export Import property changes' => 'IssueNo0391? export and import of a wiki loses info'

also the tree hierarchy is lost --SimonMichael, Sat, 03 Jul 2004 15:03:35 -0700 reply

Yes, you can restore the hierarchy by visiting SOMEPAGE/updateWikiOutline after import. I'm a little surprised the folder's outline attribute doesn't make it through export/import. It probably needs to be made a real zmi-visible zope object, perhaps adding SimpleItem? to PersistentOutline? in OutlineSupport? will do it.

ZopeWiki:ZSyncer is another way to move a wiki.

also the tree hierarchy is lost --Sun, 04 Jul 2004 06:41:55 -0700 reply

Thanks for the quick reply! The function updateWikiOutline works fine, just didn't know about it before. I will also try if it works by making the outline attribute zmi-visible. Benedikt

Backlinks are Lost --Tue, 22 Mar 2005 22:28:17 -0800 reply

After exporting from one Zope server and importing to another, all of my pages now say that they have no backlinks. I do not know how to restore the information about backlinks to my pages.

Backlinks are Lost --Simon Michael, Wed, 23 Mar 2005 08:52:07 -0800 reply

Strange. Random suggestion: try SOMEPAGE/setupCatalog ?

property change --simon, Mon, 05 Sep 2005 21:53:24 -0700 reply

Status: open => closed

As of Zwiki 0.45 I expect all properties, a Catalog, and the outline cache to survive export/import. Please confirm if possible.

Still Lose Outlines With 0.45 --Tue, 20 Sep 2005 05:21:58 -0700 reply

I had to move pages - not the folder to a new ZWiki instance and the hierarchy tree was not there. Fortunately, the function updateWikiOutline works. it would be nice if wedidn't lose the tree in the process.

Still Lose Outlines With 0.45 --Simon Michael, Tue, 20 Sep 2005 07:05:06 -0700 reply

updateWikiOutline regenerated the tree as it was before, I assume.

I think you had to do this because your old outline cache object was not ZMI-manageable. ReleaseNotes talks about this. I think next time you do this the updateWikiOutline will not be needed, and we can close this ?

alert --simon, Tue, 20 Sep 2005 07:12:04 -0700 reply

(My last post wasn't mailed out to page subscribers, click link below to see it.)

To continue.. reading your comment more carefully I see what you mean. You moved some pages not the whole wiki. In that case you'll always have to manually visit /updateWikiOutline, so it knows to merge new pages into the existing cached outline structure. If someone has a better solution, let me know.

alert --Simon Michael, Tue, 20 Sep 2005 07:16:00 -0700 reply

Or send patches, of course.

another case --Simon Michael, Tue, 20 Sep 2005 07:25:53 -0700 reply

(sending a lot of mail-ins to test setup)

One more wrinkle that people will notice:

assuming a new 0.45-created outline cache object, if you select all pages + outline in the ZMI and paste them into an existing wiki, the existing wiki's outline cache will be overwritten, so only the old wiki's contents will appear, until you do /updateWikiOutline.

This is because outline has the special __replaceable__ attribute, which we did to fix portal migration in plone 2.1 rc releases. In theory noone will be migrating to a plone 2.1 rc release any more so we could remove this. Then trying to overwrite the new wiki's outline as above would give an error. I don't know if this would be better.

As another step towards "it just works", we could do a check of the outline cache's validity - eg compare the number of outline nodes with the number of catalog entries or page objects in the folder - whenever displaying the contents view. And at other places ?