[Zope] WorldPilot - Regular messages are attachments? (Patch Fix)

Bryan Stillwell arcane@verinet.com
Thu, 8 Jun 2000 10:15:24 -0600 (MDT)


On Thu, 8 Jun 2000, Paul Gresham wrote:

> Be careful here ... I think you'll also find that should you try to download
> the attachement, It'll kill Zope. If you're running Zope with -D it'll
> restart, otherwise you'll find you have no web site after trying to
> download. I'm not sure what it does to kill Zope as there is no error, just
> death. It seems to be a bit intermittent as well, which doesn't help.

Actually that traceback was from when I tried to view the
message(attachment), and it didn't kill my Zope process.


> I'm trying to fix the problem and will post the patch once it's ready,
> hopefully next week when I get back from China. (I'm nothing to do with the
> WorldPilot chaps, I just want to use the s/ware)

I'm already ahead of you there.  I went ahead and debugged it myself and
was able to fix the problem!  Here's the patch I came up with:

---------------- CUT ----------------
--- WorldPilot.py~	Fri Mar 10 13:04:29 2000
+++ WorldPilot.py	Thu Jun  8 10:01:04 2000
@@ -648,8 +648,8 @@
                                 ))
                 else:
                         offset=0
-	                BodyType=ST[0]
-                        BodySubtype=ST[1]
+                        BodyType=string.upper(ST[0])
+                        BodySubtype=string.upper(ST[1])
                         BodyParameterList=ST[2]
                         BodyId=ST[3]
                         BodyDescription=ST[4]
---------------- CUT ----------------


Enjoy!  I hope you had fun in China!

Bryan