Un problema curioso

Ignacio González López - iSOCO Mad igonza en isoco.com
Jue Mayo 8 10:27:59 CEST 2003


Efectivamente. En el código no habia nada raro porque estába en el
entorno de pruebas. Teniamos una funcion llamada sqlInsertGroups que
parece que, o bien interfería con esta, o bien nos estaba fastidiando.

Ha sido eliminar esa función y funcionar todo correctamente.

Muchas gracias por vuestro tiempo.

On Wed, May 07, 2003 at 12:07:18PM -0500, Cesar Cardenas wrote:
> Tienes disponible el código de createUser, para ver
> qué es lo que tiene, porque hasta ahora no encuentro
> nada raro.
> 
>  --- Ignacio_González_López_-_iSOCO_Mad
> <igonza en isoco.com> escribió: > Hola. Este es un
> problema que no se como resolver:
> > 
> > Tengo estas funciones:
> > 
> > en el fichero, principal, la función al a que llamo
> > desde un formulario:
> > 
> >         def manage_signupGroup(self, REQUEST):
> >                 """ Signup a new group """
> >                 """ This is seperate so you can add
> > users using the normal """
> >                 """ interface w/o going through
> > membership policy """
> >                                                     
> >                                                     
> >                                  
> >                
> > groupname=self.reqattr(REQUEST,'groupname')
> >                
> > subjects=self.reqattr(REQUEST,'subjects')
> >                                                     
> >                                                     
> >                                  
> >                 if not username:
> >                         return
> > self.MessageDialog(self,REQUEST=REQUEST,
> >                                 title  ='Illegal
> > value',
> >                                 message='A username
> > must be specified',
> >                                 action
> > ='manage_main')
> >                                                     
> >                                                     
> >                                  
> >                 if (self.getUser(username) or
> >                         (self._emergency_user and
> >                          username ==
> > self._emergency_user.getUserName())):
> >                         return
> > self.MessageDialog(self,REQUEST=REQUEST,
> >                                 title  ='Illegal
> > value',
> >                                 message='A user with
> > the specified name already exists',
> >                                 action
> > ='manage_main')
> >                                                     
> >                                                     
> >                                  
> >                 if self.currentMembershipSource:
> >                         return
> > self.currentMembershipSource.createUser(REQUEST)
> > 
> > y en currentMembershipSource:
> > 
> >         def createGroup(self, group, subjects):
> >                
> >
> self.sqlInsertGroup(groupname=group,subjectname=subjects)
> > 
> >         def addSQLQueries(self):
> > 	[...]
> > 	[...]
> > 	[...]
> >                 if not hasattr(self,
> > 'sqlInsertGroup'):
> >                         sqlInsertGroup=SQL(
> >                                 'sqlInsertGroup',
> >                                 'Create a Group',
> >                                 self.connection,
> >                                 'groupname
> > subjectname',
> >                                 _sqlInsertGroup)
> >                                                     
> >                                                     
> >                                                     
> >                        
> > self._setObject('sqlInsertGroup',sqlInsertGroup)
> >        [...]
> >        [...]
> >        [...]
> > 
> >        def __setstate__(self, state):
> >                 Persistent.__setstate__(self, state)
> >                 self.addSQLQueries()
> > 
> > _sqlInsertGroup='''
> > INSERT INTO groups (group, subject)
> > VALUES(<dtml-sqlvar groupname type=string>,
> >         <dtml-sqlvar subjectname type=string>)
> > '''
> > 
> > ------------------------------------
> > 
> > El problema que tengo es que cuando intento llamar a
> > manage_singupGroup,
> > y este ejectua createUser, el sistema me devuelve
> > "mising input variable
> > group"
> > 
> > Traceback (innermost last):
> >   Module ZPublisher.Publish, line 98, in publish
> >   Module ZPublisher.mapply, line 88, in mapply
> >   Module ZPublisher.Publish, line 39, in call_object
> >   Module Products.exUserFolder.exUserFolder, line
> > 542, in
> > manage_createGroup
> >   Module
> > Products.exUserFolder.pgPropSource.pgPropSource,
> > line 172, in
> > createGroup
> >   Module Shared.DC.ZRDB.DA, line 415, in __call__
> >   Module DocumentTemplate.DT_String, line 474, in
> > __call__
> >   Module Shared.DC.ZRDB.sqlvar, line 99, in render
> > Missing Input: Missing input variable,
> > <em>group</em>
> > 
> > ¿¿será que no me coge la variable group??
> > 
> > Os suena??
> > 
> > -- 
> > ¡Televisión!... ¡maestra, madre, amante secreta!
> > -- Homer Simpson
> >                                                     
> >    :o) + LSSI = :oX
> >
> ________________________________________________________________________
> > Ignacio González López <igonza en isoco.com>
> > I.T. Dept @ iSOCO http://www.isoco.com              
> >  #T(+34) 91 3349797
> > Intelligent Software Components, S.A.               
> >  #F(+34) 91 3349799
> > iSOCO Madrid - Francisca Delgado 11, Alcobendas
> > (Madrid).       CP 28108
> > 
> > 
> > 
> > 
> > ----- End forwarded message -----
> > 
> > -- 
> > Huye de las tentaciones despacio, para que puedan
> > alcanzarte.
> > -- Les Luthiers.
> >                                                     
> >    :o) + LSSI = :oX
> >
> ________________________________________________________________________
> > Ignacio González López <igonza en isoco.com>
> > I.T. Dept @ iSOCO http://www.isoco.com              
> >  #T(+34) 91 3349797
> > Intelligent Software Components, S.A.               
> >  #F(+34) 91 3349799
> > iSOCO Madrid - Francisca Delgado 11, Alcobendas
> > (Madrid).       CP 28108
> > 
> 
> > ATTACHMENT part 1.2 application/pgp-signature 
> > _______________________________________________
> > Python-es mailing list
> > Python-es en aditel.org
> > http://listas.aditel.org/listinfo/python-es
> >  
> 
> _________________________________________________________
> Do You Yahoo!?
> La mejor conexión a internet y 25MB extra a tu correo por $100 al mes. http://net.yahoo.com.mx
> _______________________________________________
> Python-es mailing list
> Python-es en aditel.org
> http://listas.aditel.org/listinfo/python-es

-- 
Cuando no estoy seguro de algo, consulto a mis calzoncillos. Ellos
tienen la respuesta a todas mis preguntas
-- Abuelo Simpson
                                                        :o) + LSSI = :oX
________________________________________________________________________
Ignacio González López <igonza en isoco.com>
I.T. Dept @ iSOCO http://www.isoco.com                #T(+34) 91 3349797
Intelligent Software Components, S.A.                 #F(+34) 91 3349799
iSOCO Madrid - Francisca Delgado 11, Alcobendas (Madrid).       CP 28108
------------ próxima parte ------------
A non-text attachment was scrubbed...
Name: no disponible
Type: application/pgp-signature
Size: 189 bytes
Desc: no disponible
URL: <http://mail.python.org/pipermail/python-es/attachments/20030508/790d0d87/attachment.pgp>
------------ próxima parte ------------
_______________________________________________
Python-es mailing list
Python-es en aditel.org
http://listas.aditel.org/listinfo/python-es


Más información sobre la lista de distribución Python-es