<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Uli Fouquet wrote:
<blockquote cite="mid:1214137078.5825.11.camel@lo" type="cite">
  <pre wrap="">Hi there,

Craeg Strong wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">I would like to see full capability for editing/replacing/creating new 
objects, where some of that functionality may be provided via escaping to
an interactive session, for example a little TTW interface to a python 
interpreter.  
The ability to dynamically/interactively fix "broken" objects in my app 
in ZODB would be IMO a major use case for this facility.
    </pre>
  </blockquote>
  <pre wrap=""><!---->
I have not much experience with broken objects, although I managed the
admin UI to recognize and delete broken objects on request (something,
that is difficult with the stock Zope 3 UI).

To build such a feature (fixing of broken objects) I would appreciate
any hints on how people cope with that problem normally. Please note,
that you can often start your Grok instance in debug mode (`bin/zopectl
debug`). Then you get a Python interpreter with the ZODB data available,
where you can modify objects manually. How would you fix any broken
objects in such an interactive Python shell at least in simple use cases
(vanished attributes for instance)?
  </pre>
</blockquote>
If you can get ahold of object instances in the ZODB, then you can
presumably do whatever you need to in the interactive shell.&nbsp; I suppose
if all else fails you could create another instance of an object (using
the new schema) and then manually copy over all the attributes you want
from the old broken instance.&nbsp; When you finish, you can delete the old
instance and make the new instance take its place (a sort of selective
deep copy).<br>
<br>
I suppose there would be a number of specific cases that tend to crop
up--all the various refactorings.&nbsp; Through the shell you can do
whatever you need toby hand, but we can eventually provide some
convenience shortcuts.&nbsp; I don't have enough recent experience with ZODB
to know what those specific cases might be-- I am just getting serious
with Zope again after a long hiatus.&nbsp; But I remember the old "broken
object" icon in Zope2 TTW fondly ;-)<br>
<br>
--Craeg<br>
</body>
</html>