zope
[Arriba] [Todas las Listas]

Re: [Zope] Dirige_renameObjects con remoto ZEO

To: Tres Seaver <tseaver@xxxxxxxxxxxxx>
Subject: Re: [Zope] Dirige_renameObjects con remoto ZEO
From: Sebastian Tänzer <st@xxxxxxxxxx>
Date: Wed, 6 May 2015 01:04:25 +0200
Cc: zope@xxxxxxxx
Delivered-to: zope@xxxxxxxx
Delivery-date: Tue, 05 May 2015 19:10:35 -0400
Envelope-to: traductor@xxxxxxxxxxx
In-reply-to: <554949A9.8020307@palladion.com>
List-archive: <http://mail.zope.org/pipermail/zope/>
List-help: <mailto:zope-request@zope.org?subject=help>
List-id: Users of the Z Object Publishing Environment <zope.zope.org>
List-post: <mailto:zope@zope.org>
List-subscribe: <https://mail.zope.org/mailman/listinfo/zope>, <mailto:zope-request@zope.org?subject=subscribe>
List-unsubscribe: <https://mail.zope.org/mailman/options/zope>, <mailto:zope-request@zope.org?subject=unsubscribe>
References: <DD0F2480-4E8A-4BFB-8080-AE8CB07B9F30@taenzer.me> <554949A9.8020307@palladion.com>
Sender: "Zope" <zope-bounces@xxxxxxxx>
*Tres, *thanks para la respuesta.

En mi caso, *meta_el tipo de ambos objetos es „Carpeta“ y más allá comprobando mostrado ambos son *OFS.Clases de carpeta. Mi prueba *ist intentando rebautizar una carpeta dentro de otra carpeta.
*obj.Todo_*meta_tipo() siempre regresa una lista vacía, el cual *isn’*t vacío cuando utilizando la misma orden de dentro de un normal *Zope2 producto con el mismo objeto.

Era capaz a *bypass el problema por escribir mi propio rebautizar rutinario utilizando _*setObject, _*getObject pero todavía gustaría para saber por qué dirige_*renameObject falla.

Más, Sebastian

> Soy 06.05.2015 *um 00:52 *schrieb *Tres *Seaver <tseaver@xxxxxxxxxxxxx>:
> 
> 
> 
> -----EMPEZAR PGP MENSAJE FIRMADO-----
> *Hash: *SHA1
> 
> En 05/05/2015 01:42 PM, Sebastian *Tänzer escribió:
>> Hola *Zope comunidad,
>> 
>>  cualquiera sabe cómo para rebautizar un *OFS.Objeto de carpeta de un guión
>> de pitón remoto (*i.*e. Línea de orden)? Yo’*m probando este *via
>> *ZEO.*ClientStorage, pero falla con El "objeto <*em>*renametest1</*em>
>> no apoya esta operación.“ ,provocado por *OFS/*CopySupport.*py",
>> línea 537, en _*verifyObjectPaste.
> 
> Aquel error ocurre porque el ser de objeto *pasted es de un *meta_tipo que
> no puede ser creado dentro de la carpeta de objetivo.
> 
> 
> *Tres.
> - -- 
> ===================================================================
> *Tres *Seaver          +1 540-429-0999          tseaver@xxxxxxxxxxxxx
> *Palladion Excelencia   "de Software por Diseño"    *http://*palladion.*com
> -----EMPEZAR FIRMA de PGP-----
> Versión: *GnuPG *v1.4.11 (*GNU/Linux)
> 
> *iQIcBAEBAgAGBQJVSUmpAAoJEPKpaDSJE9*HYjR8*P/0*EJQ1*qublRfPp2*OGHewEezI
> *mBXBdtibaXDb2VG6*P4*nThMFmqmbkHS/*kmvGzn3*grqTHIYXsevrU/*NMoESMp2*lrbn
> *Mcfv3*fx0*OGp/*Fuge2*HuRs4*M8*fSV4*mPP8*l+0*jom4*LadQ+*wKicFaIdjKr326*CpIDH9
> *Ee/*vi3*uWNOYCVV0*OGbmsfQBSmTXrQWDbAQkyPHq5*UDzSp+*sQjjl3*yv6*oGhz4*Ddip
> *f9*AeY2*FpsY57*ylEN4*Y85*fbA+*HxSadYeKyY0*zW5*f8*sZc+*rOFi9*DJyNqov2*xcAiV3*N
> *UnN39*nyfsF0*ZBdu8*EKXQaBKVQZO/*udLjz4*UY97*kuatL4*QBOYXEYA5*u6*ZLlZ1*e2BF
> *jH3*zOqgIuPF+*R5*TDy2*K/*SQGYUE/*U4*VwPl+*ybVgC0*xCmG7*VyVMIAAa6*Kk5*DscM+mi
> *Ced9*ZC+8*dOXDvt6*AXRJlto5*kEQjdbnljZHU5*syCqGNsRm31*c5+6/*lOh+*xKMG0OWL
> *e8*CGsFw9*xKu6*nmV67*YHqWgXYOOK2*wARtvg3*Di9*gY/*gW3*mArybWvDUXsLNDo+*Qd3F
> *U15*Q2*MmP6*tQ6*n1*lnJRjMff1*M4*MQer/*E/*KAG4*BMXHXP4*GTY56*oIHrN6*KDJ+*Lo0*X5#uno
> 6*z9*LJf4#Uno9*Dk54*AXMZTvXxJQHMg6*OJBITiiewc4*ETbuHSPM7*emjwHJ1*x5*eRv2+*cst
> *Mtnm6*wIjy9*R4*pVHxn+5*m
> =9*rg7
> -----FIRMA de PGP del FIN-----
> 


_______________________________________________
*Zope *maillist  -  Zope@xxxxxxxx
*https://correo.*zope.*org/*mailman/*listinfo/*zope
**   #Ninguno correos de cruz o HTML *encoding!  **
(Listas relacionadas -
 *https://correo.*zope.*org/*mailman/*listinfo/*zope-Anunciar
 *https://correo.*zope.*org/*mailman/*listinfo/*zope-*dev )
Tres, thanks for the reply.

In my case, meta_type of both objects is „Folder“ and further checking showed both are OFS.Folder classes. My test ist trying to rename a folder inside another folder.
obj.all_meta_types() always returns an empty list, which isn’t empty when using the same command from inside a normal Zope2 product with the same object.

I was able to bypass the problem by writing my own rename routine using _setObject, _getObject but still would like to know why manage_renameObject fails.

Best, Sebastian

> Am 06.05.2015 um 00:52 schrieb Tres Seaver <tseaver@xxxxxxxxxxxxx>:
> 
> 
> 
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On 05/05/2015 01:42 PM, Sebastian Tänzer wrote:
>> Hello Zope community,
>> 
>> does anyone know how to rename a OFS.Folder object from a remote
>> python script (i.e. command line)? I’m trying this via
>> ZEO.ClientStorage, but it fails with "The object <em>renametest1</em>
>> does not support this operation.“ ,triggered by OFS/CopySupport.py",
>> line 537, in _verifyObjectPaste.
> 
> That error occurs because the object being pasted is of a meta_type which
> cannot be created within the target folder.
> 
> 
> Tres.
> - -- 
> ===================================================================
> Tres Seaver          +1 540-429-0999          tseaver@xxxxxxxxxxxxx
> Palladion Software   "Excellence by Design"    http://palladion.com
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.11 (GNU/Linux)
> 
> iQIcBAEBAgAGBQJVSUmpAAoJEPKpaDSJE9HYjR8P/0EJQ1qublRfPp2OGHewEezI
> mBXBdtibaXDb2VG6P4nThMFmqmbkHS/kmvGzn3grqTHIYXsevrU/NMoESMp2lrbn
> Mcfv3fx0OGp/Fuge2HuRs4M8fSV4mPP8l+0jom4LadQ+wKicFaIdjKr326CpIDH9
> Ee/vi3uWNOYCVV0OGbmsfQBSmTXrQWDbAQkyPHq5UDzSp+sQjjl3yv6oGhz4Ddip
> f9AeY2FpsY57ylEN4Y85fbA+HxSadYeKyY0zW5f8sZc+rOFi9DJyNqov2xcAiV3N
> UnN39nyfsF0ZBdu8EKXQaBKVQZO/udLjz4UY97kuatL4QBOYXEYA5u6ZLlZ1e2BF
> jH3zOqgIuPF+R5TDy2K/SQGYUE/U4VwPl+ybVgC0xCmG7VyVMIAAa6Kk5DscM+mY
> Ced9ZC+8dOXDvt6AXRJlto5kEQjdbnljZHU5syCqGNsRm31c5+6/lOh+xKMG0OWL
> e8CGsFw9xKu6nmV67YHqWgXYOOK2wARtvg3Di9gY/gW3mArybWvDUXsLNDo+Qd3F
> U15Q2MmP6tQ6n1lnJRjMff1M4MQer/E/KAG4BMXHXP4GTY56oIHrN6KDJ+Lo0X5a
> 6z9LJf4A9Dk54AXMZTvXxJQHMg6OJBITiiewc4ETbuHSPM7emjwHJ1x5eRv2+cst
> Mtnm6wIjy9R4pVHxn+5m
> =9rg7
> -----END PGP SIGNATURE-----
> 


_______________________________________________
Zope maillist  -  Zope@xxxxxxxx
https://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope-dev )
<Anterior por Tema] Tema Actual [Siguiente por Tema>