[Zope-CMF] edit() 3 arguments waiting, 4 given

Pascal Samuzeau samuzeau@oreka.com
Tue, 10 Sep 2002 23:06:55 +0100


Hi,                                                                   
                                                                      
If I understand well, It's because I haven't a Document that I raise  
this error.                                                           
                                                                      
Ok, I cretad a Document and I did the same ( I mean I did a           
document_edit which calls context.edit)                               
                                                                      
Sorry, but I raise the same error :                                   
                                                                      
3 arguments expected (4 given).                                       
                                                                      
So Have you another solution ?                                        
                                                                      
Sincerily                                                             
PS                                                                    
-------------------                                                   
> Pascal Samuzeau wrote:                                              
> > If I want test document_edit under content ( generic ) I have this
                                                                      
> > error :                                                           
                                                                      
> >                                                                   
                                                                      
> > edit() wait for 3 arguments 4 given ( It's not really this error  
                                                                      
> > scripting, but it's the same meaning).                            
                                                                      
> >                                                                   
                                                                      
> > So Do I have missed anything ?                                    
                                                                      
>                                                                     
> You can't test it this way. Your 'context' isn't a document. So     
> context.edit() is not the right edit method.                        
>                                                                     
> > Where I have to look to find the function edit() callinng by the  
                                                                      
> > Python Script document_edit ?                                     
                                                                      
>                                                                     
> If you know the class of your context object, you'll find the edit  
> method in the python file defining this class.                      
> E.g. Products/CMFDefault/Document.py for Document.                  
>                                                                     
> Yuppie                                                              
>                                                                     
>                                                                     
>                                                                     
Cordialement                                                          
PS                                                                    
--------------------------------------------------                    
Oreka ! Nous sommes l'internet moins cher !                           
Surfez 25% moins cher avec http://www.oreka.com