Re: [Zope-dev] Fw: [Zope] xmlrpc redirect response

2002-09-03 Thread Toby Dickenson

On Monday 02 Sep 2002 4:30 am, Casey Duncan wrote:
 What do you all think of this? Do redirects ever make sense to an xml-rpc
 call?

 In reading the spec it says (in reference to the response status value):

   Unless there's a lower-level error, always return 200 OK.

 Now granted this problem stems from calling a ZMI API through xml-rpc, but
 for better or for worse, that is the de-facto TTW API into Zope.

For a long long time I have been using a patched xmlrpc module which returns 
the redirect target as an xmlrpc string in this case. 




___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



[Zope-dev] What does error code 136 mean?

2002-09-03 Thread Peter Keller

Hi,

I am having trouble with the current version of ZWiki. ZWiki's author
is puzzled, and suggested that I try one of the Zope lists. I set up a
ZCatalog on a ZWiki folder as described at
http://zwiki.org/HowToInstallAZwikiCatalog

The following DTML from ZWiki's RecentChanges:

   dtml-in Catalog sort=lastEditTime reverse

causes a python core file to be produced, and with stupid log enabled I
get this message:

  2002-09-02T09:57:30 ERROR(200) zdaemon zdaemon: Mon Sep 2 10:57:30 2002:
  Aiieee! 322190 exited with error code: 136

I am using Zope 2.5.1 with python 2.1.3 under HP (was Compaq) Tru64 Unix
version 5.0

Does anyone have any suggestions about what is going wrong?

Thanks,
Peter.

-- 

Peter Keller. | Research without indebtedness is
European Bioinformatics Institute,|  suspect, and somebody must always,
Hinxton Hall, |  somehow, be thanked.
Cambridge, CB10 1SD, UK   | --- Umberto Eco
---
Email: [EMAIL PROTECTED] |
Tel. (+44/0)1223 494637 | Macromolecular Structure Database
Fax. (+44/0)1223 494468 | http://msd.ebi.ac.uk






___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Relations

2002-09-03 Thread chrisw_ml

I wish to be removed from the list.  I tried clicking change subscription
info but it said I was not a member but I keep getting these emails from
zope.

thanks

chris williams

- Original Message -
From: Jens Bjerre [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, September 02, 2002 5:49 AM
Subject: [Zope-dev] Relations


Hi

Can anyone please explain to me, how it's possible to make relations
using ZClasses.
Let's say that i would like to make a product catalog with x numbers of
pictures, and sometimes no pictures. I guess it's something about making
a ZClass wich can contain objects???

Regards

Jens Bjerre

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Fw: [Zope] xmlrpc redirect response

2002-09-03 Thread Casey Duncan

On Tuesday 03 September 2002 03:53 am, Toby Dickenson wrote:
 On Monday 02 Sep 2002 4:30 am, Casey Duncan wrote:
  What do you all think of this? Do redirects ever make sense to an xml-rpc
  call?
 
  In reading the spec it says (in reference to the response status value):
 
Unless there's a lower-level error, always return 200 OK.
 
  Now granted this problem stems from calling a ZMI API through xml-rpc, but
  for better or for worse, that is the de-facto TTW API into Zope.
 
 For a long long time I have been using a patched xmlrpc module which returns 
 the redirect target as an xmlrpc string in this case. 

This is interesting. Do you ever do anything with the redirect value?

-Casey


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Fw: [Zope] xmlrpc redirect response

2002-09-03 Thread Toby Dickenson

On Tuesday 03 Sep 2002 3:23 pm, Casey Duncan wrote:

  For a long long time I have been using a patched xmlrpc module which
  returns the redirect target as an xmlrpc string in this case.

 This is interesting. Do you ever do anything with the redirect value?

Occasionally yes.

I have some object-add methods that automatically choose a unique id, and 
redirect to a view of the new object. Sometimes it is nice to add an object 
over xmlrpc, and know where it was added.



___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



[Zope-dev] [ANNOUNCE] emacs html helper mode with dtml support

2002-09-03 Thread de ZORZI Frederic

http://www.zope.org/Members/fredz/html-helper-mode

Here you can find a modified version of html-helper-mode.el (3.0.4jolly) 
for emacs who supports dtml tags :

- Auto-indentation (with a little help :))
- Shortcuts / Completion
- Tag regions

I'd be pleased to receive feedback

Fredz.


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



[Zope-dev] Pretty print from Python Script

2002-09-03 Thread Andy McKay

If im doing quick debugging its simple to write a Python Script TTW and view
the results. However using printed for a large data structure can be a
nightmare for debugging as it scrolls off the end of the page. So I imported
pprint.pformat and I was happy again.

But now I want by default printed to return pformat text. Since this will
break nothing of mine, but stop me worrying when I want to quickly print a
dict / list etc for debugging purposes. I thought it would be a simple
matter of changing lib\python\RestrictedPython\PrintCollector.py, but it
gets a string already in the write method.

After that it got complicated and figuring I've spent 10 more minutes on
this than necessary I thought I'd ask if anyone knew off the answer off the
top of their head...

Cheers.
--
  Andy McKay
  Agmweb Consulting
  http://www.agmweb.ca




___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] What does error code 136 mean?

2002-09-03 Thread Leonardo Rochael Almeida

On Tue, 2002-09-03 at 06:25, Peter Keller wrote:
 Hi,
 
 I am having trouble with the current version of ZWiki. ZWiki's author
 is puzzled, and suggested that I try one of the Zope lists. I set up a
 ZCatalog on a ZWiki folder as described at
 http://zwiki.org/HowToInstallAZwikiCatalog
 
 The following DTML from ZWiki's RecentChanges:
 
dtml-in Catalog sort=lastEditTime reverse
 
 causes a python core file to be produced, and with stupid log enabled I
 get this message:
 
   2002-09-02T09:57:30 ERROR(200) zdaemon zdaemon: Mon Sep 2 10:57:30 2002:
   Aiieee! 322190 exited with error code: 136

The Zope file which prints that message is lib/python/zdaemon/Daemon.py,
line 88, which gets the signal number from the waitpid() function in
line 80 (or 82, depending on some heartbeat stuff I didn't care to
check).

Let's see what python has to say about this error code:

   import os
   os.WIFSIGNALED(136)
  1

hmm, the process was killed by a signal... let's see what signal that
was:

   os.WTERMSIG(136)   
  8

hmm, never seen that before, what is that signal?

  leo@spitfire:~$ kill -l 8
  FPE

Floating point exception?! Shouldn't python trap that and raise proper
exception instead?

 
 I am using Zope 2.5.1 with python 2.1.3 under HP (was Compaq) Tru64 Unix
 version 5.0
 
 Does anyone have any suggestions about what is going wrong?

Try to run zope under a debugger. Follow instructions here:
http://www.zope.org/Members/4am/debugspinningzope

but type continue (w/out quotes) as soon as you get the gdb prompt to
get zope to run normally.

Then try to cause the error condition you saw. When Zope gets the sigfpe
signal, this will cause gdb to step in and show you a prompt. Follow the
last part of the instructions in the url above to get a python traceback
(the proper python thread will probably already be selected).

Of course, this all depends on how well gdb (or your preferred debugger,
should you chose to adapt the instructions) works correctly with threads
on True64.

Would it be possible to try and reproduce your problem on a recent Linux
installation? This is the only configuration I know for sure the above
gdb recipe works

Cheers, Leo

-- 
Ideas don't stay in some minds very long because they don't like
solitary confinement.


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Fw: [Zope] xmlrpc redirect response

2002-09-03 Thread Dieter Maurer

Casey Duncan writes:
  What do you all think of this? Do redirects ever make sense to an xml-rpc
  call?
I do not think so.

If necessary, the call can be wrapped to avoid a redirect.


Dieter

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] What does error code 136 mean?

2002-09-03 Thread Dieter Maurer

Peter Keller writes:
  ...
  with stupid log enabled I
  get this message:
  
2002-09-02T09:57:30 ERROR(200) zdaemon zdaemon: Mon Sep 2 10:57:30 2002:
Aiieee! 322190 exited with error code: 136
This is signal 8 (136 - 128).

On my Linux, this is SIGFPE (Floating Point Exception).
Check what it is for yours.

I think, Python has a way to control the generation of floating
point exceptions. At least, one should be able
to disable Floating Point Underflow signals.


Dieter

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )