Welcome to Squishdot Websites Squishdot How-To
 about
 search
 post article
 Documentation
 Mailing Lists
 Bug Tracking
 Development
 Installation
 Upgrading
 Download
 admin
 rdf
 main
 parent


Re: Solution
by I. Valdes on Friday January 20, @02:02PM
Hello all, thanks to Chris Withers magic, here is the fix for old Squishdot sites migrating to Zope 2.8:

First, the problem: "intSet has been deprecated for about 5 years, and Squishdot hasn't used it in about as long. Sadly, Squishdot sites created before then will, apparently, still have some intSet's in them. In 2.8, the class was finally removed, and so Zope no longer knows what to do with the data that makes up the intSet object, hence the KeyErrors you were getting. fixdot basically goes through all the postings and replaces any intSets it finds with IISets, which are the new version."

To run fixdot, create the file fixdot.py in the Extensions subdirectory in the filesystem of your current zope that is NOT 2.8.x ie you must run this BEFORE you migrate to 2.8.x. fixdot.py should contain the following code:

from StringIO import StringIO
from intSet import intSet
from BTrees.IIBTree import IISet

def fixdot(self):
output = StringIO()
for id,posting in self.data.items():
if isinstance(posting.ids,intSet):
posting.ids = IISet(posting.ids)
print >> output, 'Fixed ',id

print >> output, 'Done!'
return output.getvalue()

After creating fixdot.py in the Extensions folder, go to the ZMI and in the Squishdot site subdirectory, Add an External Method. Fill in fixdot for all of the fields it asks for. Then run it. For example, it can be invoked as follows: http://localhost:8080/squishinstance/fixdot

where squishinstance is the name of your old squishinstance. After this has run, it should be migratable to 2.8.x Good luck!

Other edits I did:

http://download.soth.at/Squishdot-Zope-2.8.1-final-addSquishdotForm-patch.txt Which are linked from the article discussion at:
http://www.squishdot.org/1120592957/index_html

There may also be an issue with TinyTablePlus on 2.8.x that requires a small edit but I'm no longer sure what that is.

-- IV
Post Reply

Name
Email
Notify Notify me via email of responses to this message
Title
Comment
(Check those URLs! Don't forget the http://!)
Encoding
If none of the above mean anything to you, select 'Plain'!
Attachment
(You can attach a file to your reply which can then be retrieved by other readers.
Try to keep the file sizes below 500Kb in order to conserve network and server resources.)
Allowed HTML <B> <I> <P> <A> <LI> <OL> <UL> <EM> <BR> <TT> <HR> <STRONG> <BLOCKQUOTE> <DIV .*> <DIV> <P .*>
Important Stuff:
  • Note: Fields with bold titles are required.
  • Please try to keep posts on topic.
  • Try to reply to other people comments instead of starting new threads,
  • Read other people's messages before posting your own to avoid simply duplicating what has already been said.
  • Use a clear subject that describes what your message is about.
  • Please do not post offtopic, inflammatory, inappropriate, illegal, or offensive comments. Repeat offenders will be sanctioned.
  • Powered by Zope  Squishdot Powered
      "Any system that depends on reliability is unreliable." -- Nogg's Postulate
    All trademarks and copyrights on this page are owned by their respective companies. Comments are owned by the Poster. The Rest ©1999 Butch Landingin, ©2000-2002 Chris Withers.