[Zope-dev] Fw: [Zope] copy / paste support

2000-08-23 Thread Andy McKay

I know some people have helped me on this thread before but Ive had chance
to look at this again and Im still stumped on this.

Newly created 2.2 objects still have a problem. Using custom class in Zope
2.2.0.

 Thanks.

> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, August 15, 2000 11:05 AM
> Subject: [Zope] copy / paste support
>
>
> > When trying to copy an item I get the following item on paste:
> >
> > One or more items referred to in the clipboard data was not found. The
> item
> > may have been moved or deleted after you copied it.
> >
> > This is a custom python class which is catalogued. Ive no idea why this
is
> > happening. Any ideas?
> >
> > --
> >  Andy McKay, Developer, ActiveState
> >  http://www.ActiveState.com
> >  Programming for the People
> >
> >
> > ___
> > Zope maillist  -  [EMAIL PROTECTED]
> > http://lists.zope.org/mailman/listinfo/zope
> > **   No cross posts or HTML encoding!  **
> > (Related lists -
> >  http://lists.zope.org/mailman/listinfo/zope-announce
> >  http://lists.zope.org/mailman/listinfo/zope-dev )
> >
>
>
> ___
> Zope maillist  -  [EMAIL PROTECTED]
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://lists.zope.org/mailman/listinfo/zope-announce
>  http://lists.zope.org/mailman/listinfo/zope-dev )
>


___
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] _setObject error - urgent!

2000-09-01 Thread Andy McKay

Sorry for the cross post and so on, panicked with a deadline approaching.
The error was caused my a cataloguing error after intialisation.

Thanks.

- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Thursday, August 31, 2000 10:00 AM
Subject: [Zope-dev] _setObject error - urgent!


> Hi,
>
> I think I have traced my error with cut and paste, I am getting an error
on
> _setObject. If the object is not registered with Zope properly this will
be
> a problem. Basic synopsis:
>
> Im importing an object from a script so Im getting a handle to the folder
I
> would like the object to be in: this is obj.
>
> Then I call add and set object:
>
> obj._setObject(id, globals()[doctype](id, m))
>
> This rather unusual syntax allows me to use a constructor for man
different
> objects. The type is specified in 'doctype', I then get this error:
>
> 2000-08-31T16:56:57 PROBLEM(100) ASPNDoc Error: [exceptions.NameError:
> cat]
>
> Any ideas?
>
> Thanks in advance
>
>
> ___
> 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 )




[Zope-dev] Folderish objects and multiple inheritance

2000-09-05 Thread Andy McKay

Hi there,

Ok so I have a class that has multiple inheritance. My main class (A) works
fine, but I wanted to add in folderish properties. The problem is the order
of multiple inheritance and viewing folder objects. When you view a folder
from you call index_html and this gives a content list.

By inheriting this way:

class B(A, Folder):

I have kept all my A methods. However viewing it does not produce the
content list since its overwritten by A. Of course inheriting:

class B(Folder, A):

Does work for that, but breaks all my other methods.

Solutions:

Well I tried defining a tab - view_folder which was something along the line
of:

def view_folder(self, client=None, REQUEST={}):
''' doc string '''
return Folder(self, client, REQUEST)

But get an attribute error on manage_tabs.

Any ideas?

Thanks.

--
  Andy McKay, Developer.
  ActiveState.


___
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] Folderish objects and multiple inheritance

2000-09-05 Thread Andy McKay


- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, September 05, 2000 2:13 PM
Subject: [Zope] Re: [Zope-dev] Folderish objects and multiple inheritance


> Hmmm I can override inheritance in a simple class... I guess theres
> something in Zope thats annoying this:
>
> class A:
>  var = 'A'
>
>  def test(self):
>   return self.var
>
> class B:
>  var = 'B'
>
>  def test(self):
>   return self.var
>
> class C(B, A):
>  var = 'C'
>
>  def test(self):
>   return A.var
>
> c = C()
> print c.test()
>
> OUTPUT>> A
>
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, September 05, 2000 11:35 AM
> Subject: [Zope-dev] Folderish objects and multiple inheritance
>
>
> > Hi there,
> >
> > Ok so I have a class that has multiple inheritance. My main class (A)
> works
> > fine, but I wanted to add in folderish properties. The problem is the
> order
> > of multiple inheritance and viewing folder objects. When you view a
folder
> > from you call index_html and this gives a content list.
> >
> > By inheriting this way:
> >
> > class B(A, Folder):
> >
> > I have kept all my A methods. However viewing it does not produce the
> > content list since its overwritten by A. Of course inheriting:
> >
> > class B(Folder, A):
> >
> > Does work for that, but breaks all my other methods.
> >
> > Solutions:
> >
> > Well I tried defining a tab - view_folder which was something along the
> line
> > of:
> >
> > def view_folder(self, client=None, REQUEST={}):
> > ''' doc string '''
> > return Folder(self, client, REQUEST)
> >
> > But get an attribute error on manage_tabs.
> >
> > Any ideas?
> >
> > Thanks.
> >
> > --
> >   Andy McKay, Developer.
> >   ActiveState.
> >
> >
> > ___
> > 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 maillist  -  [EMAIL PROTECTED]
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://lists.zope.org/mailman/listinfo/zope-announce
>  http://lists.zope.org/mailman/listinfo/zope-dev )
>


___
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] Folderish objects and multiple inheritance

2000-09-07 Thread Andy McKay

Well if anybody is interested I did solve this but instead of trying to
inherit A, Folder and then fix the folderish methods broken I did Folder, A
and then overrode class A methods I wanted.

- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, September 05, 2000 2:20 PM
Subject: Re: [Zope-dev] Folderish objects and multiple inheritance


>
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, September 05, 2000 2:13 PM
> Subject: [Zope] Re: [Zope-dev] Folderish objects and multiple inheritance
>
>
> > Hmmm I can override inheritance in a simple class... I guess theres
> > something in Zope thats annoying this:
> >
> > class A:
> >  var = 'A'
> >
> >  def test(self):
> >   return self.var
> >
> > class B:
> >  var = 'B'
> >
> >  def test(self):
> >   return self.var
> >
> > class C(B, A):
> >  var = 'C'
> >
> >  def test(self):
> >   return A.var
> >
> > c = C()
> > print c.test()
> >
> > OUTPUT>> A
> >
> > - Original Message -
> > From: "Andy McKay" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Tuesday, September 05, 2000 11:35 AM
> > Subject: [Zope-dev] Folderish objects and multiple inheritance
> >
> >
> > > Hi there,
> > >
> > > Ok so I have a class that has multiple inheritance. My main class (A)
> > works
> > > fine, but I wanted to add in folderish properties. The problem is the
> > order
> > > of multiple inheritance and viewing folder objects. When you view a
> folder
> > > from you call index_html and this gives a content list.
> > >
> > > By inheriting this way:
> > >
> > > class B(A, Folder):
> > >
> > > I have kept all my A methods. However viewing it does not produce the
> > > content list since its overwritten by A. Of course inheriting:
> > >
> > > class B(Folder, A):
> > >
> > > Does work for that, but breaks all my other methods.
> > >
> > > Solutions:
> > >
> > > Well I tried defining a tab - view_folder which was something along
the
> > line
> > > of:
> > >
> > > def view_folder(self, client=None, REQUEST={}):
> > > ''' doc string '''
> > > return Folder(self, client, REQUEST)
> > >
> > > But get an attribute error on manage_tabs.
> > >
> > > Any ideas?
> > >
> > > Thanks.
> > >
> > > --
> > >   Andy McKay, Developer.
> > >   ActiveState.
> > >
> > >
> > > ___
> > > 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 maillist  -  [EMAIL PROTECTED]
> > http://lists.zope.org/mailman/listinfo/zope
> > **   No cross posts or HTML encoding!  **
> > (Related lists -
> >  http://lists.zope.org/mailman/listinfo/zope-announce
> >  http://lists.zope.org/mailman/listinfo/zope-dev )
> >
>
>
> ___
> 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 )




[Zope-dev] Custom dtml tag

2000-09-11 Thread Andy McKay

Im playing with a custom dtml-tag along the lines of 
constructs a url to a catalog query. It works fine, I would just like to
extend it a bit and for this I would need to get to the calling object.

For example, there will be a different query depending upon the object the
dtml-query tag is contained in. Does this make sense, does anyone know the
answer?

Thanks in advance.

--
  Andy McKay, Developer.
  ActiveState.




___
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] Custom dtml tag

2000-09-12 Thread Andy McKay

Hmm well ive found i have  object and of course my self.
Perhaps there is a pythonism I have to research here.

- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, September 11, 2000 4:03 PM
Subject: [Zope-dev] Custom dtml tag


> Im playing with a custom dtml-tag along the lines of 
> constructs a url to a catalog query. It works fine, I would just like to
> extend it a bit and for this I would need to get to the calling object.
>
> For example, there will be a different query depending upon the object the
> dtml-query tag is contained in. Does this make sense, does anyone know the
> answer?
>
> Thanks in advance.
>
> --
>   Andy McKay, Developer.
>   ActiveState.
>
>
>
>
> ___
> 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] Custom dtml tag

2000-09-12 Thread Andy McKay

I can see how this would be useful in a situation where I dont have an
instance of self. But in this case I do, so Im not sure how this helps.

I guess you're saying once I have self I can find out what called the
function. More fiddling I guess.

- Original Message -
From: "Martijn Pieters" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, September 12, 2000 11:29 AM
Subject: Re: [Zope-dev] Custom dtml tag


> On Tue, Sep 12, 2000 at 09:26:49AM -0700, Andy McKay wrote:
> > Hmm well ive found i have  object and of course my self.
> > Perhaps there is a pythonism I have to research here.
> >
> > - Original Message -
> > From: "Andy McKay" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Monday, September 11, 2000 4:03 PM
> > Subject: [Zope-dev] Custom dtml tag
> >
> >
> > > Im playing with a custom dtml-tag along the lines of 
> > > constructs a url to a catalog query. It works fine, I would just like
to
> > > extend it a bit and for this I would need to get to the calling
object.
> > >
> > > For example, there will be a different query depending upon the object
the
> > > dtml-query tag is contained in. Does this make sense, does anyone know
the
> > > answer?
> > >
> > > Thanks in advance.
> > >
> > > --
> > >   Andy McKay, Developer.
> > >   ActiveState.
>
> The namespace just reflects the attributes of the current object, plus
> whatever other tags push onto that stack (such as the in tag, which pushes
> the current element of the list it iterates over on top).
>
> If you retrieve the 'this' method from the stack, and call it, it'll
> return the topmost object on the stack. It is implemented in
> SimpleItem.Item:
>
> def this(self):
> # Handy way to talk to ourselves in document templates.
> return self
>
> --
> Martijn Pieters
> | Software Engineermailto:[EMAIL PROTECTED]
> | Digital Creations  http://www.digicool.com/
> | Creators of Zope   http://www.zope.org/
> | ZopeStudio: http://www.zope.org/Products/ZopeStudio
> -
>


___
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] Custom dtml tag

2000-09-12 Thread Andy McKay

Really? Ive looked up this and get nothing (an attribute error actually) and
its not in globals. If that would work that would be great - but a it
certainly doesnt seem to on a standard DTMLDocument / Method.

- Original Message -
From: "Brett Carter" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, September 12, 2000 4:17 PM
Subject: Re: [Zope-dev] Custom dtml tag


> Andy: here's what I've gleaned - in a dtml tag's render() method, you
> get passed in self and a template dict, in my example let's call it
> 'md'.  md is essentially a stack/dictionaryish object of the *current*
> namespace - and one of the handy things that's always around in the
> namespace is the 'this' function, which returns the object on the top
> of the stack.
>
> Just lookup 'this', run it, and there you have a reference to the
> calling object!  Ex:
>
> def render(self, md)
>   this = md.getitem('this')
>   callingObj = this()
>   return "Calling object was %s" % (callingObj.id())
>
> Note I haven't tested this code.  Good luck!
> -Brett
>
> >>>>> "Andy" == Andy McKay <[EMAIL PROTECTED]> writes:
>
> Andy> I can see how this would be useful in a situation where I dont
have an
> Andy> instance of self. But in this case I do, so Im not sure how this
helps.
>
> Andy> I guess you're saying once I have self I can find out what
called the
> Andy> function. More fiddling I guess.
>
> Andy> - Original Message -
> Andy> From: "Martijn Pieters" <[EMAIL PROTECTED]>
> Andy> To: "Andy McKay" <[EMAIL PROTECTED]>
> Andy> Cc: <[EMAIL PROTECTED]>
> Andy> Sent: Tuesday, September 12, 2000 11:29 AM
> Andy> Subject: Re: [Zope-dev] Custom dtml tag
>
>
> >> On Tue, Sep 12, 2000 at 09:26:49AM -0700, Andy McKay wrote:
> >> > Hmm well ive found i have  object and of course my
self.
> >> > Perhaps there is a pythonism I have to research here.
> >> >
> >> > - Original Message -
> >> > From: "Andy McKay" <[EMAIL PROTECTED]>
> >> > To: <[EMAIL PROTECTED]>
> >> > Sent: Monday, September 11, 2000 4:03 PM
> >> > Subject: [Zope-dev] Custom dtml tag
> >> >
> >> >
> >> > > Im playing with a custom dtml-tag along the lines of 
> >> > > constructs a url to a catalog query. It works fine, I would
just like
> Andy> to
> >> > > extend it a bit and for this I would need to get to the calling
> Andy> object.
> >> > >
> >> > > For example, there will be a different query depending upon the
object
> Andy> the
> >> > > dtml-query tag is contained in. Does this make sense, does
anyone know
> Andy> the
> >> > > answer?
> >> > >
> >> > > Thanks in advance.
> >> > >
> >> > > --
> >> > >   Andy McKay, Developer.
> >> > >   ActiveState.
> >>
> >> The namespace just reflects the attributes of the current object,
plus
> >> whatever other tags push onto that stack (such as the in tag, which
pushes
> >> the current element of the list it iterates over on top).
> >>
> >> If you retrieve the 'this' method from the stack, and call it,
it'll
> >> return the topmost object on the stack. It is implemented in
> >> SimpleItem.Item:
> >>
> >> def this(self):
> >> # Handy way to talk to ourselves in document templates.
> >> return self
> >>
> >> --
> >> Martijn Pieters
> >> | Software Engineermailto:[EMAIL PROTECTED]
> >> | Digital Creations  http://www.digicool.com/
> >> | Creators of Zope   http://www.zope.org/
> >> | ZopeStudio: http://www.zope.org/Products/ZopeStudio
> >> -
> >>
>
>
> Andy> ___
> Andy> Zope-Dev maillist  -  [EMAIL PROTECTED]
> Andy> http://lists.zope.org/mailman/listinfo/zope-dev
> Andy> **  No cross posts or HTML encoding!  **
> Andy> (Related lists -
> Andy> http://lists.zope.org/mailman/listinfo/zope-announce
> Andy> 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 )
>


___
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] Advice on DTMLDocument

2000-09-14 Thread Andy McKay

Hi there,

Well a while ago I came across a bug that I couldnt cut and paste and
object. A few people helped me out on that, thanks. Ive had a week of
squishing bugs and finally got to this one. The reason why? I was
subclassing DTMLDocument but using my own __init__ (similar to one where I
dont subclass from DTMLDocument), where I didnt fiddle with __name__. The
result was when absolute_url() was called I was getting:
http://fork:8080/code/test/ElementWithAttributes  !

Solutions I have found for this:
-Dont subclass from DTMLDocument. This is not an option for me.
-Dont try to use your own __init__, use DTMLDocument. This works great,
but now I have to recreate all my objects. My current scheme is create the
object in manage_addObject, let DTMLDocument do the __init__, then
manipulate it then and there in the manage_addObject.

Help would be appreciated on:
-Why is this happening? A class fine breaks if you subclass
DTMLDocument, it would seem __name__ is being used some times, not in
others.
-Is something funky happening in DTMLDocument __init__, which subclasses
DTMLMethod etc...?

Ive got a fix, but I only sort of know why and that bugs me.

Thanks.

--
  Andy McKay, Developer.
  ActiveState.



___
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] Zope Error message

2000-09-14 Thread Andy McKay

So now I need to change it so most normal errors (such as 404) are handled
by standard_error_message. So I went to HTTPResponse.py and found this:

def _error_html(self,title,body):
# XXX could this try to use standard_error_message somehow?

I gather someone smarter than me has tried this before. Before waste a day
going down this path, does anyone have any advice?

--
  Andy McKay, Developer.
  ActiveState.


___
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] __del__

2000-09-18 Thread Andy McKay

Is there an method that I can use as a hook when an object is destroyed? (Im
trying to save some _v_ data prior to destruction. Ive tried __del__ but
this doesnt seem to get called.

Thanks.

--
  Andy McKay, Developer.
  ActiveState.


___
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] Custom dtml tag

2000-09-18 Thread Andy McKay

Finally woke up on this problem.

Got this working by simply calling resolve_url upon the request object. But
what I want is a result that changes depending upon the object. Let's face
it, this can be acheived a whole lot easier by creating a method for the
objects and calling that.

So thats what Ive done and stayed away from using a dtml-tag.

Thanks for your help.

- Original Message -
From: "Brett Carter" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, September 13, 2000 9:51 AM
Subject: Re: [Zope-dev] Custom dtml tag


> Andy - looking up 'this' in a dtml method or document won't work
> unless you expose it in your python product/tag definition.  I'm
> talking about getting 'this' inside a dtml tag that I have defined
> myself (i.e. ).  If you want 'this'
> available in dtml, write an external method and just return 'self'
> def this(self): return self
> -Brett
>
> >>>>> "Andy" == Andy McKay <[EMAIL PROTECTED]> writes:
>
> Andy> Really? Ive looked up this and get nothing (an attribute error
actually) and
> Andy> its not in globals. If that would work that would be great - but
a it
> Andy> certainly doesnt seem to on a standard DTMLDocument / Method.
>
> Andy> - Original Message -
> Andy> From: "Brett Carter" <[EMAIL PROTECTED]>
> Andy> To: "Andy McKay" <[EMAIL PROTECTED]>
> Andy> Cc: <[EMAIL PROTECTED]>
> Andy> Sent: Tuesday, September 12, 2000 4:17 PM
> Andy> Subject: Re: [Zope-dev] Custom dtml tag
>
>
> >> Andy: here's what I've gleaned - in a dtml tag's render() method,
you
> >> get passed in self and a template dict, in my example let's call it
> >> 'md'.  md is essentially a stack/dictionaryish object of the
*current*
> >> namespace - and one of the handy things that's always around in the
> >> namespace is the 'this' function, which returns the object on the
top
> >> of the stack.
> >>
> >> Just lookup 'this', run it, and there you have a reference to the
> >> calling object!  Ex:
> >>
> >> def render(self, md)
> >> this = md.getitem('this')
> >> callingObj = this()
> >> return "Calling object was %s" % (callingObj.id())
> >>
> >> Note I haven't tested this code.  Good luck!
> >> -Brett
> >>
>
> ___
> 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] __del__

2000-09-18 Thread Andy McKay

I was hoping to have this method fired Zope is shut down, restarted etc and
not call it implicitly. The theory being if this object is cached it will
have to be unloaded at some point?

Ive used manage_beforeDelete() elsewhere and it works fine when Im
destroying an object whilst ZODB is still running.

Thanks.

- Original Message -
From: "Chris McDonough" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Monday, September 18, 2000 2:32 PM
Subject: Re: [Zope-dev] __del__


> If it's an object in an objectmanager, you can define a
> manage_beforeDelete() method on it (see ObjectManager.py).
>
> How are you destroying it?
>
> [EMAIL PROTECTED] wrote:
> >
> > Is there an method that I can use as a hook when an object is destroyed?
(Im
> > trying to save some _v_ data prior to destruction. Ive tried __del__ but
> > this doesnt seem to get called.
> >
> > Thanks.
> >
> > --
> >   Andy McKay, Developer.
> >   ActiveState.
> >
> > ___
> > 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 )
>
> --
> Chris McDonough
> Digital Creations, Publishers of Zope
> http://www.zope.org
>
> ___
> 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] __del__

2000-09-18 Thread Andy McKay

Wow thanks. I'll see what I can do. I can think of a whole bunch of uses for
that.

- Original Message -
From: "Chris McDonough" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Monday, September 18, 2000 3:10 PM
Subject: Re: [Zope-dev] __del__


> Oh I see... objects don't get __del__ or manage_beforeDelete called on
> them when the ZODB is shut down, this only happens when they're
> explicitly deleted.  This is the wonder of transparent persistence :-)
>
> If you want things to happen only at Zope start and shutdown, I've had
> some success using an __init__.py that does things in an otherwise blank
> product in combination with the setting of a Python sys.exitfunc.  The
> following __init__.py in an otherwise blank Product directory sends an
> email when Zope is stopped or started:
>
> import os, sys, popen2, socket
>
> prefix = "StartStopNotifier:"
>
> def stop_hook():
> mailout(user, prefix, host, "Zope dev portal stop")
> if callable(existing_exitfunc):
> existing_exitfunc()
>
> def start_hook():
> mailout(user, prefix, host, "Zope dev portal start")
>
> def mailout(user, prefix, host, subject):
> cmd="/bin/mail %s -s '%s %s %s' < /dev/null" %
> (user,prefix,host,subject)
> popen2.popen2(cmd)
>
> user = os.environ.get('STARTSTOPNOTIFY', None)
> if user is not None:
> host = socket.gethostname()
> existing_exitfunc = getattr(sys, 'exitfunc', None)
> sys.exitfunc = stop_hook
> start_hook()
>
>
> [EMAIL PROTECTED] wrote:
> >
> > I was hoping to have this method fired Zope is shut down, restarted etc
and
> > not call it implicitly. The theory being if this object is cached it
will
> > have to be unloaded at some point?
> >
> > Ive used manage_beforeDelete() elsewhere and it works fine when Im
> > destroying an object whilst ZODB is still running.
> >
> > Thanks.
> --
> Chris McDonough
> Digital Creations, Publishers of Zope
> http://www.zope.org
>


___
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] Re: [Zope-ZEO] Advice

2000-09-20 Thread Andy McKay

> > One of the reasons our group is moving away from Zope is that it has
> > very poor support (if any) for the development/staging/live model.  We
> > like this model.  We think it's a good thing.  But sync'ing code across
> > multiple Zope installations is a royal PITA.
>
> I'd like to hear more about the problems you've had and how
> you overcome them in a different system.
>
> > And no, versions are *not* the answer.
>
> Well, they are a pretty good answer for lots of applications
> in my experience.

Version can work for small changes, but they certainly dont for large
numbers of changes across lots of objects. And since the catalog is a key
component for our site, its a real problem.


___
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] Re: __str__, DMTLFolder adn Squishdot]

2000-09-21 Thread Andy McKay

Yeah I'll do what works for now and make a science project out of it one
rainy weekend.

Part of the problem could be the API for instantiation of folderish objects
and DTML objects.
A DTML method is created:

DTMLMethod(file, __name__=id).

A folder is

ob = Folder()
ob.id = str(id)

Or something like that. Its in my source somewhere with nasty comments
around it :)

- Original Message -
From: "Chris Withers" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; "Andy McKay" <[EMAIL PROTECTED]>
Sent: Thursday, September 21, 2000 9:44 AM
Subject: [Fwd: __str__, DMTLFolder adn Squishdot]


> Andy McKay wrote:
> >
> > > Andy McKay wrote:
> > > > I've given it a __call__ method, but not a __str__. Ive most
problems
> > > > resolve around the objects name, absolute_url, __name__, so perhaps
> > fiddling
> > > > with __str__ might be an answer.
> > >
> > > Sorry, but none of that made sense... What are the actual problems
> > > you're having with names, absolute_url and __name__?
> >
> > This is probably not going to make much sense but you can create a
> > folderish DTML Document and on the surface it appears fine. However
cracks
> > appear when you:
> >
> > - view it in a tree
> > - copy and paste
> > - catalog
> >
> > The reason being that the absolute_url of the object is wrong, it
sometimes
> > comes out as http://fork:8080/a/b/c/ElementWithAttributes. In some cases
> > (cut and paste) __name__ is called, and that comes out wrong too.
>
> Now that is weird. Can anyone shed any light on what's going on here?
>
> > Ive given up on this now, I have an object and if I want some folderish
> > objects created tied to that object, I create a folder and do the
storage in
> > that and it works fine.
>
> That's probably going to be your best bet in the long run,
>
> cheers,
>
> Chris
>


___
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] Do I really understanding caching?

2000-09-22 Thread Andy McKay

We have been looking at caching in Zope as a way of tweaking performance.
Heres an example of what I think happens:

- Supposing I have a 1,000 object catalog. If one person changes an catalog
aware object, that instance of the catalog will be pulled out of the ZODB
and changed. It will then be written to the ZODB. That last copy will stay
in the cache for as long as the "Cache Parameters" are set to allow.

- If somebody changes another catalog aware object, that will repeat the
above process.

- However simply accessing the catalog (no changes) will pull the object
from the cache.

- What would be really nice is if the object only got written to the cache
when it is no longer used, that way every time the catalog changed it didnt
write to ZODB instead it changed the cached version. Of course that does
bring up the recovering from disaster problem.

So do I understand it correctly?

--
  Andy McKay, Developer.
  ActiveState.


___
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] Do I really understanding caching?

2000-09-22 Thread Andy McKay

Thanks
 
> (I'm only talking about text indices here.)
> 
> Note that the Catalog is actually a tree of database/cache objects. 
> There are a series of buckets and sub-buckets that end in a word
> object.  The buckets, sub-buckets, and words are all database objects
> and can be cached/updated separately.
> 
> Put another way, every branch and leaf on the tree in a Catalog is a
> separately stored and cached database object.
> 
> The 1,027 words in the document (and the branches on the tree to get to
> them) that was updated would obey the cache parameters.

Hmm, that is a significant optimization, and one I was not aware of.
 
> What problem are you trying to solve -- response time, memory usage,
> disk usage?

All of the above :)



___
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] why cant i rename an object from an external method

2000-09-28 Thread Andy McKay

Heres a treat. I'm trying to write an external method to rename objects. I
have approx 10,000 to rename so a script would be nice. No problem I
thought, imitate a forms manage_renameObject and CopySupport.py can do the
work.

Rename works fine from the web form, but not from a script.
(ASPNTools.getsomeobjectsfromstring returns a bunch of objects, Ive tried
replicating this with resolve_url and get different namespace error, could
this be a clue?).

Heres my script:

def search(self, REQUEST=None):
 l = ASPNTools.getsomeobjectsfromstring(self, REQUEST['path'], REQUEST)
 for obj in l:
  ob = obj.aq_parent # get the folder
  ob.manage_renameObject(obj.id(), 'Foo')

 return 'renamed'

Here's my problem:

The object 100BASEFX does not support this operation

  File d:\p4\Zope-dev\lib\python\Products\ASPN/Extensions/foo_rename.py,
line 6, in search
(Object: 100BASEFX)
  File d:\p4\Zope-dev\lib\python\OFS\CopySupport.py, line 288, in
manage_renameObject
(Object: Traversable)
  File d:\p4\Zope-dev\lib\python\OFS\CopySupport.py, line 406, in
_verifyObjectPaste
(Object: Traversable)
Copy Error: (see above)


There surely must be simple way of doing this so I dont have to resort to
writing a Perl script to imitate the browser, please!

Thanks in advance as ever.

--
  Andy McKay, Developer.
  ActiveState.


___
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] why cant i rename an object from an external method

2000-09-29 Thread Andy McKay

Grrr That works fine. But it annoys me I cant use a standard function to
that. I like to use a standard function and use the checking that someone
else wrote.

   old_id = obj.id()
   new_id = ASPNTools.safetymunge(obj.id())

   self = obj.aq_parent
  ob = obj

   self._delObject(old_id)
 if hasattr(ob, 'aq_base'):
   ob=ob.aq_base
  ob._setId(new_id)
   self._setObject(new_id, ob, set_owner=0)

Thanks Shane... phew no Perl necessary.

- Original Message -
From: "Shane Hathaway" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, September 28, 2000 8:26 PM
Subject: Re: [Zope-dev] why cant i rename an object from an external method


> Andy McKay wrote:
> >
> > Heres a treat. I'm trying to write an external method to rename objects.
I
> > have approx 10,000 to rename so a script would be nice. No problem I
> > thought, imitate a forms manage_renameObject and CopySupport.py can do
the
> > work.
> >
> > Rename works fine from the web form, but not from a script.
> > (ASPNTools.getsomeobjectsfromstring returns a bunch of objects, Ive
tried
> > replicating this with resolve_url and get different namespace error,
could
> > this be a clue?).
>
> I would try using _delObject and _setObject instead.
> manage_renameObject() does some security checks that don't apply in your
> case.
>
> Shane
>
> ___
> 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 )




[Zope-dev] _setObject error - urgent!

2000-08-31 Thread Andy McKay

Hi,

I think I have traced my error with cut and paste, I am getting an error on
_setObject. If the object is not registered with Zope properly this will be
a problem. Basic synopsis:

Im importing an object from a script so Im getting a handle to the folder I
would like the object to be in: this is obj.

Then I call add and set object:

obj._setObject(id, globals()[doctype](id, m))

This rather unusual syntax allows me to use a constructor for man different
objects. The type is specified in 'doctype', I then get this error:

2000-08-31T16:56:57 PROBLEM(100) ASPNDoc Error: [exceptions.NameError:
cat]

Any ideas?

Thanks in advance


___
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] Zope Suitability for Computer Lab Project

2000-10-04 Thread Andy McKay

Zope is just simply not suited to lots of writes. Use Access as the
relational database and use Zope as the reporting tool using ZODBCA to
connect to Access. Then you get the best of both worlds.

- Original Message -
From: "John Hopkins" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, October 02, 2000 10:04 PM
Subject: [Zope-dev] Zope Suitability for Computer Lab Project


Greetings from a "potential newbie".

I need to build an application for recording clients who use a computer lab.
The idea is to collect demographic information on clients who use the lab,
and session information such as date/time and whether the client attended a
class.  Objects include clients, sessions and classes (or I think they do;
I'm more used to thinking in relational terms.  I was going to build it in
MS-Access, since it's available on all the PC's in the lab, can do
everything I need (including reporting), and I know it well; on the other
hand, there are undeniable advantages to having something server-based with
minimal client dependencies.

I'm pretty sure it would take me more time to build it in Zope than in
Access, mainly because I don't know Zope yet.  What I don't know is whether
this is an appropriate application for Zope; it's not really what I think of
as "publishing"; more like data acquisition and subsequent reporting.

Observations based on experience will be gratefully received.

Thanks in advance,

John Hopkins
[EMAIL PROTECTED]



___
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] Acquisition/cDocumentTemplate bug

2000-10-05 Thread Andy McKay

Does anyone know of any progress on this bug its marked as "pending" in the
Collector, so I guess not.

http://classic.zope.org:8080/Collector/1441/view

- Original Message -
From: "Shane Hathaway" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, July 20, 2000 6:29 AM
Subject: Re: [Zope-dev] Acquisition/cDocumentTemplate bug


> Oleg Broytmann wrote:
> >Anyone is working on it? Should I put this into Collector or Tracker?
>
> Already there.  The Zope project manager is gone for the week.
>
> Shane
>
> >
> > On Mon, 17 Jul 2000, Shane Hathaway wrote:
> > > This is an excellent bug analysis.  I suggest that we create a new
> > > PyCallable_Check function that works in the presence of wrappers,
> > > perhaps called PyCallable_CheckW().  If it is placed in Acquisition.c
> > > then cDocumentTemplate.c will have to #include "Acquisition.h".  Then
> > > we need to replace PyCallable_Check in probably more than just
> > > cDocumentTemplate.
>
> ___
> 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] Acquisition/cDocumentTemplate bug

2000-10-05 Thread Andy McKay

Sorry ignore me, I thought I was being bitten by this bug, but Im not.

It was the old difference between  and  in
someone else's dtml.
- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, October 05, 2000 1:07 PM
Subject: Re: [Zope-dev] Acquisition/cDocumentTemplate bug


> Does anyone know of any progress on this bug its marked as "pending" in
the
> Collector, so I guess not.
>
> http://classic.zope.org:8080/Collector/1441/view
>
> - Original Message -
> From: "Shane Hathaway" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Cc: <[EMAIL PROTECTED]>
> Sent: Thursday, July 20, 2000 6:29 AM
> Subject: Re: [Zope-dev] Acquisition/cDocumentTemplate bug
>
>
> > Oleg Broytmann wrote:
> > >Anyone is working on it? Should I put this into Collector or
Tracker?
> >
> > Already there.  The Zope project manager is gone for the week.
> >
> > Shane
> >
> > >
> > > On Mon, 17 Jul 2000, Shane Hathaway wrote:
> > > > This is an excellent bug analysis.  I suggest that we create a new
> > > > PyCallable_Check function that works in the presence of wrappers,
> > > > perhaps called PyCallable_CheckW().  If it is placed in
Acquisition.c
> > > > then cDocumentTemplate.c will have to #include "Acquisition.h".
Then
> > > > we need to replace PyCallable_Check in probably more than just
> > > > cDocumentTemplate.
> >
> > ___
> > 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 )
>


___
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] Recursive folders from Python

2000-10-16 Thread Andy McKay

Try using getattr to get the object... heres a python script to do it a
little more cleanly:

import string

def create_folders(self):
 path = '/a/b/c'  # create a folder for each part of the string, nested.

 for p in string.split(path, '/'):
  if p != '':
   self = create_folder(self, p)

 return 'Done'


def create_folder(folder, id):
 try: folder.manage_addFolder(id)
 except: pass

 new_folder = getattr(folder, id)
 return new_folder


- Original Message -
From: "Jason Spisak" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, October 16, 2000 10:46 AM
Subject: [Zope-dev] Recursive folders from Python


> Zopists,
>
> Yesterday I was trying to create recursive folders from DTML.
> I'd like to do the same from Python.
> Does anyonw know why this code won't create a folder within a folder.
> It's tells me the id is already in use, so that means it's not
> descending into the newly created folder to make another folder.
>
> def create(self):
> for digit in range(0, 10):
> folder= self.manage_addFolder(str(digit), str(digit))
> subfolder = self.folder.manage_addFolder(str(digit), str(digit))
>
> All my best,
>
> Jason Spisak
> [EMAIL PROTECTED]
>
> ___
> 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] Writing my own request-handler

2000-10-24 Thread Andy McKay

http://www.zope.org/Members/4am/SiteAccess2

Site Access handles the incoming request and fiddles with it. Whilst this
isnt what you want, looking at the source might give you some ideas.

- Original Message -
From: "Thomas Weholt" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, October 24, 2000 6:10 AM
Subject: [Zope-dev] Writing my own request-handler


> Hi,
>
> I want to write my own request in Zope. I want a specially formatted
> request or a command to be intercepted and processed by my own modules. If
> the user tries to access a url like
> http://www.myserver.org/myhandler or using a specific port on the server
> Zope traps this and my request_handler sends data back to the user based
on
> the url .
>
> Why? I got a PostgreSQL database as a backend for a huge information
> organization project. I want to serve xml using a fast and stable solution
> like Zope or Medusa to do this, since I also need ftp for object-uploads,
> allthough these are not stored in ZODB. A normal ftp-server is used, and
> hopefully I could set up a normal medusa kind of ftp-server on a given
port
> to do this, and avoid all the files being stuffed into the ZODB. I got a
> lot of non-Linux ( therefore as far as a know, non-postgresql-python users
> ) so I want to give them xml to process using a know protocol like HTTP.
>
> How can I write my own class/handler that traps this and serves my data ?
I
> really want to use Zope cuz I use it for the rest of the site. I cannot
> serve all the postgresql data using plain zope-database methods cuz I want
> to write several clients in other programming languages that can receive
> and process the xml-format I use. The thing I want isn't xml-served as
> html, it's xml served to non-browser apps using HTML and ZOPE as means of
> delivery.
>
> Of course all of this is to be written in old-fashioned python, no
> Zope-products.
>
> Any hints, tips or guides is highly appreciated. I've looked at the Medusa
> source and found a couple of things that nearly does what I want them too,
> especially in the script_handler_demo-folder, but I'd like to get the
whole
> thing into Zope if I could.
>
> Thanks.
>
>
> ___
> 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] Migrating from ZClasses to Python Products

2000-10-24 Thread Andy McKay

> And now the big question...
>
> How do you migrate and existing application from ZClasses to Python
> products?  I've got about 50,000 objects.  Can it be done or am I stuck
> with ZClasses?

Well the number of objects doesnt really matter, but migrating it from
ZClass to Python - Ive never heard of that happening. It would be a cool
project though.

> Hopefully,
>
> Jason Spisak
> CIO
> HireTechs.com
> 6151 West Century Boulevard
> Suite 900
> Los Angeles, CA 90045
> P. 310.665.3444
> F. 310.665.3544
>
> Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email
> address may not be added to any commercial mail list with out my
> permission.  Violation of my privacy with advertising or SPAM will
> result in a suit for a MINIMUM of $500 damages/incident, $1500 for
> repeats.
>
> ___
> 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: FastCGI under IIS

2000-10-25 Thread Andy McKay

The fastCGI plugin for IIS is unfortunately not open source. FastCGI bought
it and you now have to pay for it. Try pcgi instead.

http://www.fastcgi.com/

- Original Message -
From: "Becker, Glen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, October 25, 2000 12:41 PM
Subject: [Zope-dev] FW: FastCGI under IIS


>
>
> -Original Message-
> From: ethan mindlace fremen [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, October 25, 2000 2:45 PM
> To: Glen Becker
> Cc: Zope Webmaster
> Subject: Re: FastCGI under IIS
>
>
> Glen Becker wrote:
> >
> > Apparently, Zope has support for FastCGI under IIS.   We want to find a
> FastCGI plug-in for IIS, but have been unable to do so.   Is this portion
of
> Zope segregable, so that it could be used by other FastCGI programs?
>
> I am but a lowly webmaster. We don't use fastcgi or IIS for zope.org,
> and so I haven't an idea on what it should be.  Please consider
> contacting the zope developer's list ( [EMAIL PROTECTED] ) for more
> information.
>
> Thanks,
> --
> -mindlace-
> Zopatista Community Liason
>
> ___
> 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] 2 Zopes

2000-10-25 Thread Andy McKay

Have a look at the excellent Client-Server product. Search for client on
Zope.org. I use this to move stuff between Zopes.

- Original Message -
From: "Ender" <[EMAIL PROTECTED]>
To: "Andre Schubert" <[EMAIL PROTECTED]>
Cc: "Zope Development Maillist" <[EMAIL PROTECTED]>
Sent: Tuesday, October 24, 2000 9:21 PM
Subject: Re: [Zope-dev] 2 Zopes


> Andre Schubert wrote:
> >
> > Hi,
> >
> > Can anyone tell me a way to get Zope Objects from the first
> > Zope-Installation to the second.
> > I need this because i have to program a Product to putting data into
> > different Zope Installations from one point of the Web.
> > My boss want this way because he want a central point for data input,
> > where the data are of different type and therefore they have to stored
> > in different locations( different Zope Installations) My idea is to use
> > ZPublisher.Client, but i don't find a way to use it.
> >
> > thanks as
>
> i've never done it before, but the options as always are multiple
> depending on your needs and requirements.
>
> if you can distill your objects down to simple python types (lists,
> dicts, etc) you can try using xml-rpc and reconstructing the object on
> the separate system. there is even a product that uses xml-rpc to
> facilitate sharing between zope installs.
>
> if you don't need to really replicate the info, and depending on the
> frequency which it will need to be accessed you can just use xml-rpc to
> a function on the second server and display the results directly on the
> first server.
>
> if you need to copy the actual objects verbatim you might want to
> investigate exporting to zexp and using file transfer between the hosts
> and (using Client to faciltate calling into zope) importing them on the
> second server.
>
> hth
>
> kapil
>
> ___
> 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 )




[Zope-dev] 2gb file size

2000-11-03 Thread Andy McKay

My database has suddenly ballooned to 2 gig's stopping my Zope from running.
Are there any utils to delete the last transaction or so?

This is kinda urgent... :(

Thanks.

--
  Andy McKay, Developer.
  ActiveState.



___
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] Fw: 2gb file size

2000-11-03 Thread Andy McKay

Hmmm ive looked at fsrecover.py and its not happy either. Anyone else solved
this problem? Im on Win2k BTW.

--
  Andy McKay, Developer.
  ActiveState.
- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, November 03, 2000 1:04 PM
Subject: 2gb file size


> My database has suddenly ballooned to 2 gig's stopping my Zope from
running.
> Are there any utils to delete the last transaction or so?
>
> This is kinda urgent... :(
>
> Thanks.
>
> --
>   Andy McKay, Developer.
>   ActiveState.
>
>


___
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: 2gb file size

2000-11-03 Thread Andy McKay

Ive tried truncating the file and then running fsrecover.py, but get:

  File "ZODB\FileStorage.py", line 1530, in read_index
if read(4) != packed_version: raise FileStorageFormatError, name
FileStorage.FileStorageFormatError: q:\var\Data.fs

As a desperation I commented out line 1530 and reran. It runs through the
entire file and reduces the data.fs to 1k. Am I totally hooped? I thought
ZODB could handle being truncated, ive never had an problems reading from a
data.fs even when my box has blown up. Anyway looks like Im talking to
myself here...


--
  Andy McKay, Developer.
  ActiveState.
- Original Message -----
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, November 03, 2000 1:28 PM
Subject: [Zope-dev] Fw: 2gb file size


> Hmmm ive looked at fsrecover.py and its not happy either. Anyone else
solved
> this problem? Im on Win2k BTW.
>
> --
>   Andy McKay, Developer.
>   ActiveState.
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, November 03, 2000 1:04 PM
> Subject: 2gb file size
>
>
> > My database has suddenly ballooned to 2 gig's stopping my Zope from
> running.
> > Are there any utils to delete the last transaction or so?
> >
> > This is kinda urgent... :(
> >
> > Thanks.
> >
> > --
> >   Andy McKay, Developer.
> >   ActiveState.
> >
> >
>
>
> ___
> 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: 2gb file size

2000-11-06 Thread Andy McKay

Thank you everyone for your help. I truncated the file and restarted Zope
successfully. I had a brief period of problems when I forgot use binary mode
for truncating the file - duh. Anyway, I am running 2.2.1 and it doesnt work
with a 2gb file. I didnt analyse where the problem lies, however I do
believe its a python issue.

Thanks.
--
  Andy McKay, Developer.
  ActiveState.
- Original Message -
From: "Itamar Shtull-Trauring" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, November 05, 2000 2:37 AM
Subject: Re: [Zope-dev] Fw: 2gb file size


> Shane Hathaway wrote:
>
> > Are you running Zope 2.2.1 or later?  There were pointer arithmetic
> > errors that occurred on earlier versions, even with operating systems
> > that support >2 GB files.
>
> So on W2K, Zope can have >2GB databases? I'd really like to hear if you
get
> it to work Andy (or if anyone else did.)
>
> --
> Itamar S.T.  [EMAIL PROTECTED]
> Fingerprint = D365 7BE8 B81E 2B18 6534  025E D0E7 92DB E441 411C
>
> ___
> 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: 2gb file size

2000-11-06 Thread Andy McKay

I did do a How-to as well http://www.zope.org/Members/andym/2gig

--
  Andy McKay, Developer.
  ActiveState.
- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, November 06, 2000 9:26 AM
Subject: Re: [Zope-dev] Fw: 2gb file size


> Thank you everyone for your help. I truncated the file and restarted Zope
> successfully. I had a brief period of problems when I forgot use binary
mode
> for truncating the file - duh. Anyway, I am running 2.2.1 and it doesnt
work
> with a 2gb file. I didnt analyse where the problem lies, however I do
> believe its a python issue.
>
> Thanks.
> --
>   Andy McKay, Developer.
>   ActiveState.
> - Original Message -
> From: "Itamar Shtull-Trauring" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Sunday, November 05, 2000 2:37 AM
> Subject: Re: [Zope-dev] Fw: 2gb file size
>
>
> > Shane Hathaway wrote:
> >
> > > Are you running Zope 2.2.1 or later?  There were pointer arithmetic
> > > errors that occurred on earlier versions, even with operating systems
> > > that support >2 GB files.
> >
> > So on W2K, Zope can have >2GB databases? I'd really like to hear if you
> get
> > it to work Andy (or if anyone else did.)
> >
> > --
> > Itamar S.T.  [EMAIL PROTECTED]
> > Fingerprint = D365 7BE8 B81E 2B18 6534  025E D0E7 92DB E441 411C
> >
> > ___
> > 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 )
>


___
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] ZCatalog index error

2000-11-06 Thread Andy McKay

Im running into an odd bug with ZCatalog:

I have am running a catalog query and Im getting this message.

  File D:\zope\lib\python\Products\ZCatalog\Lazy.py, line 193, in
__getitem__
  File D:\zope\lib\python\Products\ZCatalog\Catalog.py, line 197, in
__getitem__
KeyError:
52536

This is the line where it seems to be setting all the scores to one, and I
guess it can find the item 52536.

else:
# otherwise no score, set all scores to 1
r=self._v_result_class(self.data[index]).__of__(self.aq_parent)
r.data_record_id_ = index
r.data_record_score_ = 1
r.data_record_normalized_score_ = 1

The thing is my catalog is only 17,000 records in size, I have no item 52536
(no wonder it cant find it). I guess my best plan would be somehow to remove
that the record for that item if I could... hmm...

Any other ideas?

--
  Andy McKay, Developer.
  ActiveState.


___
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] ZCatalog index error

2000-11-06 Thread Andy McKay

Thanks, will look forward to 2.2.3!

I deleted an index and metadata, re created them and recatalogued the
affected objects. That seem to solve it in my initial tests... keeping my
fingers crossed.

--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Chris McDonough" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Monday, November 06, 2000 3:49 PM
Subject: Re: [Zope-dev] ZCatalog index error


> Andy,
>
> This is a known issue with the catalog (searching the collector for "key
> error" will show you how common it has been).  Chris Petrilli should be
> checking in some changes to the CVS 2.2 branch (and the trunk?) tomorrow
> that resolves it.  The problem is evidently related to the way
> catalog.index_object() and catalog.unindex_object() do their thing.  I'd
> advise you live with the issue until 2.2.3 comes out (which should be
> sometime this week, AFAIK).
>
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Monday, November 06, 2000 4:17 PM
> Subject: [Zope-dev] ZCatalog index error
>
>
> > Im running into an odd bug with ZCatalog:
> >
> > I have am running a catalog query and Im getting this message.
> >
> >   File D:\zope\lib\python\Products\ZCatalog\Lazy.py, line 193, in
> > __getitem__
> >   File D:\zope\lib\python\Products\ZCatalog\Catalog.py, line 197, in
> > __getitem__
> > KeyError:
> > 52536
> >
> > This is the line where it seems to be setting all the scores to one, and
I
> > guess it can find the item 52536.
> >
> > else:
> > # otherwise no score, set all scores to 1
> >
> r=self._v_result_class(self.data[index]).__of__(self.aq_parent)
> > r.data_record_id_ = index
> > r.data_record_score_ = 1
> > r.data_record_normalized_score_ = 1
> >
> > The thing is my catalog is only 17,000 records in size, I have no item
> 52536
> > (no wonder it cant find it). I guess my best plan would be somehow to
> remove
> > that the record for that item if I could... hmm...
> >
> > Any other ideas?
> >
> > --
> >   Andy McKay, Developer.
> >   ActiveState.
> >
> >
> > ___
> > 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 )
>


___
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] Zope Permission's Adjustment

2000-11-07 Thread Andy McKay

/lib/python/AccessControl/access.dtml contains the dtml for that page.
Fiddle away.

--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, November 07, 2000 7:54 AM
Subject: [Zope-dev] Zope Permission's Adjustment


> Hello,
>
> Does anyone know the file that I can edit to adjust the layout of the
> Security Tab?
>
> I would like to be able to add the Roles Headers to the bottom of the list
> as well as the top.
>
> Keith Larson
> Web Developer
>
>
>
> ___
> 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] ZCatalog index error

2000-11-07 Thread Andy McKay

Well im not sure how much deleting the index and then recreating the index
throught the management interface actually does. But I wrote an external
method to basically do a find and apply to recatalog bunches of objects.

--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Christopher Petrilli" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>; "Chris McDonough"
<[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Tuesday, November 07, 2000 7:27 AM
Subject: Re: [Zope-dev] ZCatalog index error


> How are you getting things indexed and reindexed in the Catalog, if I
might
> ask?
>
> Chris
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: "Chris McDonough" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
> Sent: Monday, November 06, 2000 6:42 PM
> Subject: Re: [Zope-dev] ZCatalog index error
>
>
> > Thanks, will look forward to 2.2.3!
> >
> > I deleted an index and metadata, re created them and recatalogued the
> > affected objects. That seem to solve it in my initial tests... keeping
my
> > fingers crossed.
> >
> > --
> >   Andy McKay, Developer.
> >   ActiveState.
> >
> > - Original Message -
> > From: "Chris McDonough" <[EMAIL PROTECTED]>
> > To: "Andy McKay" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
> > Sent: Monday, November 06, 2000 3:49 PM
> > Subject: Re: [Zope-dev] ZCatalog index error
> >
> >
> > > Andy,
> > >
> > > This is a known issue with the catalog (searching the collector for
"key
> > > error" will show you how common it has been).  Chris Petrilli should
be
> > > checking in some changes to the CVS 2.2 branch (and the trunk?)
tomorrow
> > > that resolves it.  The problem is evidently related to the way
> > > catalog.index_object() and catalog.unindex_object() do their thing.
I'd
> > > advise you live with the issue until 2.2.3 comes out (which should be
> > > sometime this week, AFAIK).
> > >
> > > - Original Message -
> > > From: "Andy McKay" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Monday, November 06, 2000 4:17 PM
> > > Subject: [Zope-dev] ZCatalog index error
> > >
> > >
> > > > Im running into an odd bug with ZCatalog:
> > > >
> > > > I have am running a catalog query and Im getting this message.
> > > >
> > > >   File D:\zope\lib\python\Products\ZCatalog\Lazy.py, line 193, in
> > > > __getitem__
> > > >   File D:\zope\lib\python\Products\ZCatalog\Catalog.py, line 197, in
> > > > __getitem__
> > > > KeyError:
> > > > 52536
> > > >
> > > > This is the line where it seems to be setting all the scores to one,
> and
> > I
> > > > guess it can find the item 52536.
> > > >
> > > > else:
> > > > # otherwise no score, set all scores to 1
> > > >
> > > r=self._v_result_class(self.data[index]).__of__(self.aq_parent)
> > > > r.data_record_id_ = index
> > > > r.data_record_score_ = 1
> > > > r.data_record_normalized_score_ = 1
> > > >
> > > > The thing is my catalog is only 17,000 records in size, I have no
item
> > > 52536
> > > > (no wonder it cant find it). I guess my best plan would be somehow
to
> > > remove
> > > > that the record for that item if I could... hmm...
> > > >
> > > > Any other ideas?
> > > >
> > > > --
> > > >   Andy McKay, Developer.
> > > >   ActiveState.
> > > >
> > > >
> > > > ___
> > > > 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 )
> > >
> >
> >
> > ___
> > 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 )
>


___
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] ZCatalog index error

2000-11-07 Thread Andy McKay

Ah sorry, I have custom CatalogAware class thats been a bit hacked but was
written by Mike Pelletier... when he was hanging around at ActiveState for a
few days. Theres a link to wiki on it somewhere

--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Christopher Petrilli" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>; "Chris McDonough"
<[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Tuesday, November 07, 2000 10:13 AM
Subject: Re: [Zope-dev] ZCatalog index error


>
> > Well im not sure how much deleting the index and then recreating the
index
> > throught the management interface actually does. But I wrote an external
> > method to basically do a find and apply to recatalog bunches of objects.
>
> Actually i meant originally, not the second time.  Are you using
> CatalogAware to get objects to automatically index themselves?  What
exactly
> are you doing to get them in the Catalog in the first place?
>
> Chris
>


___
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] Cache parameters

2000-11-08 Thread Andy McKay

Just wondering what kind of cache parameters people run on their Zope
installation.

It would seem running a high target size and maximum time between accesses
would speed up those requests it can find the cache, but not cached request
take longer since more RAM is used in the maintaining of the cache (guess).

Has anyone found a sweet spot away from the standard, I guess of course it
all depends on the individual Zope site, this one is particulary ZCatalog
heavy. Or should I just leave it at the default, which I found seems to work
fine.

--
  Andy McKay, Developer.
  ActiveState.



___
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] ZCatalog index error

2000-11-09 Thread Andy McKay

I found this in the archive. Is this the patch I need or is it more complex,
it seems strange that it hasnt been implemented...

http://zope.nipltd.com/public/lists/dev-archive.nsf/0a8715d5f3c7b6a3802568c1
006328f7/c15eb30d0faf1057802568b8002e1273?OpenDocument

[..]

In lib/python/SearchIndex/Lexicon.py the set method of the Lexicon
class, change:

else:
self._lexicon[intern(word)] = self.counter
self.counter = self.counter + 1
return self.counter

to

else:
self.counter = self.counter + 1
self._lexicon[intern(word)] = self.counter
return self.counter



--
  Andy McKay, Developer.
  ActiveState.
- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: "Christopher Petrilli" <[EMAIL PROTECTED]>; "Chris McDonough"
<[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Tuesday, November 07, 2000 12:02 PM
Subject: Re: [Zope-dev] ZCatalog index error


> Ah sorry, I have custom CatalogAware class thats been a bit hacked but was
> written by Mike Pelletier... when he was hanging around at ActiveState for
a
> few days. Theres a link to wiki on it somewhere
>
> --
>   Andy McKay, Developer.
>   ActiveState.
>
> - Original Message -
> From: "Christopher Petrilli" <[EMAIL PROTECTED]>
> To: "Andy McKay" <[EMAIL PROTECTED]>; "Chris McDonough"
> <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
> Sent: Tuesday, November 07, 2000 10:13 AM
> Subject: Re: [Zope-dev] ZCatalog index error
>
>
> >
> > > Well im not sure how much deleting the index and then recreating the
> index
> > > throught the management interface actually does. But I wrote an
external
> > > method to basically do a find and apply to recatalog bunches of
objects.
> >
> > Actually i meant originally, not the second time.  Are you using
> > CatalogAware to get objects to automatically index themselves?  What
> exactly
> > are you doing to get them in the Catalog in the first place?
> >
> > Chris
> >
>
>
> ___
> 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] ZCatalog index error

2000-11-09 Thread Andy McKay

Ah ok. I'll just wait impatiently then.

Thanks.
--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Chris McDonough" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>; "Christopher Petrilli"
<[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Thursday, November 09, 2000 12:03 PM
Subject: Re: [Zope-dev] ZCatalog index error


> I have no idea about this, but I know that this isn't all you need
>
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: "Andy McKay" <[EMAIL PROTECTED]>; "Christopher Petrilli"
> <[EMAIL PROTECTED]>; "Chris McDonough" <[EMAIL PROTECTED]>;
> <[EMAIL PROTECTED]>
> Sent: Thursday, November 09, 2000 2:31 PM
> Subject: Re: [Zope-dev] ZCatalog index error
>
>
> > I found this in the archive. Is this the patch I need or is it more
> complex,
> > it seems strange that it hasnt been implemented...
> >
> >
>
http://zope.nipltd.com/public/lists/dev-archive.nsf/0a8715d5f3c7b6a3802568c1
> > 006328f7/c15eb30d0faf1057802568b8002e1273?OpenDocument
> >
> > [..]
> >
> > In lib/python/SearchIndex/Lexicon.py the set method of the Lexicon
> > class, change:
> >
> > else:
> > self._lexicon[intern(word)] = self.counter
> > self.counter = self.counter + 1
> > return self.counter
> >
> > to
> >
> > else:
> > self.counter = self.counter + 1
> > self._lexicon[intern(word)] = self.counter
> > return self.counter
> >
> > 
> >
> > --
> >   Andy McKay, Developer.
> >   ActiveState.
> > - Original Message -
> > From: "Andy McKay" <[EMAIL PROTECTED]>
> > To: "Christopher Petrilli" <[EMAIL PROTECTED]>; "Chris McDonough"
> > <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
> > Sent: Tuesday, November 07, 2000 12:02 PM
> > Subject: Re: [Zope-dev] ZCatalog index error
> >
> >
> > > Ah sorry, I have custom CatalogAware class thats been a bit hacked but
> was
> > > written by Mike Pelletier... when he was hanging around at ActiveState
> for
> > a
> > > few days. Theres a link to wiki on it somewhere
> > >
> > > --
> > >   Andy McKay, Developer.
> > >   ActiveState.
> > >
> > > - Original Message -
> > > From: "Christopher Petrilli" <[EMAIL PROTECTED]>
> > > To: "Andy McKay" <[EMAIL PROTECTED]>; "Chris McDonough"
> > > <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
> > > Sent: Tuesday, November 07, 2000 10:13 AM
> > > Subject: Re: [Zope-dev] ZCatalog index error
> > >
> > >
> > > >
> > > > > Well im not sure how much deleting the index and then recreating
the
> > > index
> > > > > throught the management interface actually does. But I wrote an
> > external
> > > > > method to basically do a find and apply to recatalog bunches of
> > objects.
> > > >
> > > > Actually i meant originally, not the second time.  Are you using
> > > > CatalogAware to get objects to automatically index themselves?  What
> > > exactly
> > > > are you doing to get them in the Catalog in the first place?
> > > >
> > > > Chris
> > > >
> > >
> > >
> > > ___
> > > 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 )
> >
> >
>


___
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] unbuffered html from external method

2000-11-13 Thread Andy McKay

Is it possible to print unbuffered html output to the user from an external
method. It looks to me like I can't, output occurs upon the return and I
cant see a way of getting around that.

(I have a very long running and expensive external method, I'd like to print
out status to the user)

TIA.

--
  Andy McKay, Developer.
  ActiveState.


___
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] Two glaring omissions

2000-11-14 Thread Andy McKay

Of course all those points can be done in python, im assuming you are
talking about ZClasses.

--
  Andy McKay, Developer.
  ActiveState.
- Original Message -
From: "Alexander Limi" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, November 14, 2000 11:35 AM
Subject: [Zope-dev] Two glaring omissions


> Hi,
>
> I've been working with Zope for almost two years now, and there are two
> things that I feel is missing in the interface:
>
> 1. The ability to add a Base class after the class is created
>
> 2. The ability to rename properties after instances of the classes have
>been created (and have the data in those fields preserved)
>
> Are there any technical reasons why these are not present? I know it is
> possible to add base classes in retrospect via the hack described in
>
> http://www.zope.org/Members/AlexR/ChangingBaseClasses
>
> but are there plans for making this easier?
>
> As for #2, it is quite annoying and counter-productive not being able to
> change a variable name that was decided a long time ago, or maybe by
> others simply because there exist instantiated objects of that type.
>
> Both of the above are pretty essential OO techniques (for me, at least),
> and hinder my work quite a lot by not being there.
>
> Any chance of these being fixed at all? Or are there reasons that I do not
> know about that makes this impossible?
>
>
> Regards,
>
> --
> Alexander Limi
> [EMAIL PROTECTED]
>
>
> ___
> 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] How do I create folders/methods etc. within the code?

2000-11-16 Thread Andy McKay

> 1. To run python scripts written as dtml methods. Do I simply use
> dtml-call from another dtml document/method?

Many options, but one is make your python an external method and then yes
use call to actually call it.

> 2. To create folders, mthods etc in the code. I have found some functions
> manage_addDTMLMethod, manage_addFolder, but how do I use them?

well look at their signature in the code eg:

self.manage_addFolder(id='Testing')

> 3. I need to make a site that allows users to register ( i.e. to generate
> user folder with some standard documents in them). Anyone have hints
> regarding this? (or in fact a whole application I can use?)

Look at GenericUserFolder or LoginManager.

HTH.


___
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] Two glaring omissions

2000-11-17 Thread Andy McKay

Well no, not really. You can't change property foo to fi and expect to
remember foo's values. That's just wrong. But you can do silly tricks in
python, like keep old property names hanging around and do mappings to them,
or fiddle with variable properties  etc.

--
  Andy McKay, Developer.
  ActiveState.

> So it is possible to change the names of variables if the class is Python
> based?
>
> Confusingly,
>
> --
> Alexander Limi
> http://mp3.no
>
>
>
> ___
> 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 )




[Zope-dev] Re: [Zope] IIS and PCGI

2000-10-20 Thread Andy McKay

Well I fixed this using a ISAPI filter which I will release soon (once I
have some time) that takes a url /a/b/c/x.pcgi/f/g/h, and passes
/a/b/c/x.pcgi to IIS so the file will run and /f/g/h to Zope.

My next question is has anyone succeeded in getting this to work to another
box over a mapped or shared win32 drive?

I mapped g:\ to my zope host, and then specified
PCGI_PUBLISHER=g:\pcgi\pcgi_publisher.py in my pcgi file. The problem seems
to pcgi-wrapper.exe which does not like a mapped drive. (line 485 of
parseinfo.c keeps spitting out missing publisher)...

Thanks in advance and apologies for the cross post to zope-dev but it is
more of a zope-dev question.

- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, October 17, 2000 1:33 PM
Subject: [Zope] IIS and PCGI


> Im fiddling with IIS and PCGI, I've looked at
> (http://www.zope.org/Members/brianh/iis_howto) the docs and got the server
> to work correctly in that http://127.0.0.1/zope.pcgi is the same as
> http://127.0.0.1:8080/
>
> However it doesnt seem to be carrying through the trailing path info (or /
> 's) for example
> http://127.0.0.1/zope.pcgi/manage brings up 404. Using IIS 5.0, Win2k,
Zope
> 2.2.1.
>
> Anyone encountered this and know the solution?
>
> Thanks.
> --
>   Andy McKay, Developer.
>   ActiveState.
>
>
> ___
> Zope maillist  -  [EMAIL PROTECTED]
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://lists.zope.org/mailman/listinfo/zope-announce
>  http://lists.zope.org/mailman/listinfo/zope-dev )
>


___
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] A way to check what products are installed?

2000-11-20 Thread Andy McKay

Quick hack:







--
  Andy McKay, Developer.
  ActiveState.

- Original Message - 
From: "Morten W. Petersen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, November 19, 2000 9:36 PM
Subject: [Zope-dev] A way to check what products are installed?


> Is there a clean way to do this (preferrably from both Python and
> DTML) ?
> 
> Thanks.
> 
> -Morten
> 
> ___
> 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] ANNOUNCE: PartitionedFileStorage

2000-11-22 Thread Andy McKay

Thank Shane!
--
  Andy McKay, Developer.
  ActiveState.

- Original Message - 
From: "Shane Hathaway" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 22, 2000 1:48 PM
Subject: [Zope-dev] ANNOUNCE: PartitionedFileStorage


> For all who are interested in breaking database size barriers without
> moving to Oracle or Berkeley Storage, here's something to try out.
> 
> http://www.zope.org/Members/hathawsh/PartitionedFileStorage
> 
> I *highly* recommend you back up Data.fs before installing.
> 
> What is known to work:
>   - Reads and writes of logical files greater than 3 GB on versions of
> Linux that support only 2 GB files.
>   - Undo and packing.
>   - Fast random reads and writes.
>   - Using simple binary concatenation to move back to a standard single
> file.
>   - Using PartitionedFile completely independent of Zope or ZODB.
> 
> What has not been tested, but will very likely work:
>   - Tranalyzer.
>   - Putting the partitions on different physical devices.  (Poor man's
> RAID :-) )
> 
> What couldn't be tested by my limited resources:
>   - Platforms other than Linux.
>   - Running this on a busy Zope site.  (No, www.zope.org is not running
> PartitionedFileStorage. :-) )
> 
> BTW to all in the U.S., Happy Thanksgiving!
> 
> Shane
> 
> ___
> 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] objectValues performance

2000-11-28 Thread Andy McKay

Id recommend all the above but just for reference "objectIds" is faster than
"objectValues".
--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Casey Duncan" <[EMAIL PROTECTED]>
To: "Brett Carter" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Tuesday, November 28, 2000 7:58 AM
Subject: Re: [Zope-dev] objectValues performance


> Brett Carter wrote:
>
> > I have a folder with greater than 5000 ZClass instances in it.  It
> > takes > 5mins to do an objectValues for every object in the folder -
> > is there a higher perfomance call I could make?
> > -Brett
>
> Standard folder performance degrades pretty quickly once you get
> a lot of objects in it. There are two solutions to this:
>
> Subdivide your objects into multiple folders.
> Use a BTreeFolder which should be much faster.
>
> You can download the BTreeFolder product
> here: http://www.zope.org/Members/hathawsh/BTreeFolder/
>
> hth,
> Casey Duncan
>
>
>
>
>
>
> ___
> 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 )




[Zope-dev] Fw: PythonLabs Team Moves to Digital Creations

2000-10-28 Thread Andy McKay

This is great news for Zope...

(well I think it is anyway)

>  Original Message 
> Subject: PythonLabs Team Moves to Digital Creations
> Date: Fri, 27 Oct 2000 20:42:42 -0500
> From: Guido van Rossum <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED] (Python mailing
> list),[EMAIL PROTECTED], [EMAIL PROTECTED]
> 
> To all Python users and developers:
> 
> Less than half a year ago, I moved with my team to BeOpen.com, in the
> hope of finding a new permanent home for Python development.  At
> BeOpen, we've done several good things for Python, such as moving the
> Python and Jython development process to SourceForge, and the
> successful release of Python 2.0.
> 
> Unfortunately, BeOpen.com's original plans for PythonLabs didn't work
> out as hoped, and we weren't able to reach mutual agreement on
> workable alternative plans -- despite trying for months.
> 
> I am proud to have found a new home for my entire team: starting
> today, Tim Peters, Barry Warsaw, Jeremy Hylton, Fred Drake and myself
> are working for Digital Creations.  We will be spending part of our
> time on core Python development (including Jython and Mailman) and
> part of our time on Python infrastructure improvements that also
> benefit Zope.
> 
> Python will remain Open Source; Digital Creations has no desire to
> monetize or brand the Python language or specific Python
> distributions.  All future work we do on Python as Digital Creations
> employees will be owned by a non-profit organization yet to be
> created.  We think of this new organization as the Python Software
> Foundation.  In the meantime (while the PSF is under construction) I
> will own such copyrights personally.
> 
> We're excited to be working for Digital Creations: they are one of the
> oldest companies active in the Python community, one of the companies
> most committed to Python, and they have a great product!  Plus, we
> know they have deep financial backing.  We trust that Digital
> Creations will provide a stable home for Python for many years.
> 
> Digital Creations has also offered to take over hosting of the
> python.org and starship sites.  On behalf of the Python community,
> we're grateful for this support of the two prime community sites for
> Python, and we expect to be implementing the transitions shortly.
> 
> These are exciting times for the PythonLabs team -- and also for
> Python and its community.  Mainstream successes for Python are showing
> up everywhere, and we're proud to be a part of such a smart and
> friendly community.  A great year lies ahead!
> 
> --Guido van Rossum (home page: http://www.python.org/~guido/)
> 
> -- 
> http://www.python.org/mailman/listinfo/python-list



___
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] case insensitive sorts

2000-12-06 Thread Andy McKay

Minor nit and patch: I've found that really for me what users want to see is
a case insensitive sort of objects, not the current python case sensitive
sort. So that the order of objects from dtml-in and tree is a, A, b, B as
apposed to A, B, a, b.

Anyway Ive patched dtml-in and dtml-tree to do this sort on a ignore_case
tag. Is this useful to anyone else? And Ive thought of patching my Zope so
this is the default behaviour what does anyone else think. The next
thing to patch is ZCatalog...


___
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] case insensitive sorts

2000-12-06 Thread Andy McKay

Oh yeah for the ZCatalog I have two indexes one upper case and one lower
case for some of my classes. No problemo. My area to attack though is the
standard views such as the management interface...

How's life in Lancaster? Went to school there and grew up in Garstang

--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Steve Alexander" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, December 06, 2000 11:03 AM
Subject: Re: [Zope-dev] case insensitive sorts


> Andy McKay wrote:
>
> > Minor nit and patch: I've found that really for me what users want to
see is
> > a case insensitive sort of objects, not the current python case
sensitive
> > sort. So that the order of objects from dtml-in and tree is a, A, b, B
as
> > apposed to A, B, a, b.
> >
> > Anyway Ive patched dtml-in and dtml-tree to do this sort on a
ignore_case
> > tag. Is this useful to anyone else? And Ive thought of patching my Zope
so
> > this is the default behaviour what does anyone else think. The next
> > thing to patch is ZCatalog...
>
>
> The way I approached this was to have a ZPatterns attribute provider, or
> a method, that provides a modified version of the value I want to sort on.
>
> For example, I have a load of documents and folders with titles like
>
>   Big Folder
>
>   brown document
>
>   "Berries for Cooking" list
>
> I wanted to present these sorted by non-case-sensitive first letter or
> number. So, I made a method "title_for_sorting" that stripped off any
> punctuation at the start, and returned the first 20 characters in all
> lower case.  In this case, as it was a ZPatterns application, the method
> was presented as an attribute of the object using some skin-script. I
> used this attribute as a field-index in my SiteIndex ZCatalog.
>
> The reason I mention this is that sometimes case-insensitivity is not
> enough for sensible sorting. In this case, I had to strip out
> punctuation too.
>
> --
> Steve Alexander
> Software Engineer
> Cat-Box limited
> http://www.cat-box.net
>


___
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] case insensitive sorts

2000-12-07 Thread Andy McKay

But thats a result of the sorting...

anyway I have in and tree patched, I'll post them tonight when I get home
and let people do what they want.

--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Dieter Maurer" <[EMAIL PROTECTED]>
To: "Chris Withers" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, December 07, 2000 12:00 PM
Subject: Re: [Zope-dev] case insensitive sorts


> Chris Withers writes:
>  > Dieter Maurer wrote:
>  > > Andy McKay writes:
>  > >  >  what does anyone else think
>  > >
>  > > I would not like it.
>  >
>  > Why not? ;-)
> I would not like to see this sort order in the management
> screens, because I use capitalization to ensure that
> essential objects are at the top of the object list.
>
>
> 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 )
>


___
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] case insensitive sorts

2000-12-07 Thread Andy McKay

 > 3. ZCatalog stores objects in a pre-sorted order. Changing the sort
> order of any object (not just strings) would break *all* existing
> ZCatalog instances that store mixed case strings. (and other
> applications too - the python language reference documents that this
> assmption is safe at least until python3k)

Looking at this and other reasons I won't try to hack ZCatalog. I'll stick
to making lower case string indexes Seems the safest all around.


___
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] python 2.0, windows and zope

2000-12-13 Thread Andy McKay

Has anyone got python 2.0 working with Zope on windows? Just curious if
anyone has any pointers before I start done this (potentially) painful
path...

--
  Andy McKay, Developer.
  ActiveState.


___
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] python 2.0, windows and zope

2000-12-13 Thread Andy McKay

using python 2.0 and not the default python installation?
--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Josh Zeidner" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, December 13, 2000 9:18 AM
Subject: RE: [Zope-dev] python 2.0, windows and zope


>
> Ive successfully installed the latest version of zope on windows and have
it
> running my website.  http://www.brooklynmedialabs.com .  Its actually
easier
> than running it on linux!
>
>  -josh
>
>
>
> Has anyone got python 2.0 working with Zope on windows? Just curious if
> anyone has any pointers before I start done this (potentially) painful
> path...
>
> --
>   Andy McKay, Developer.
>   ActiveState.
>
>
> ___
> 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 )
>


___
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] python 2.0, windows and zope

2000-12-13 Thread Andy McKay

Waffling on to my own posts... but it would seem I have to build Zope from
source to get it to use another version of python since the use of
python15.dll is entrenched in Zope... All the install scripts seem to be
based on unix.

Can DC give me a hand here on pointers to how they build it for Windows?

--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, December 13, 2000 9:21 AM
Subject: Re: [Zope-dev] python 2.0, windows and zope


> using python 2.0 and not the default python installation?
> --
>   Andy McKay, Developer.
>   ActiveState.
>
> - Original Message -
> From: "Josh Zeidner" <[EMAIL PROTECTED]>
> To: "Andy McKay" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
> Sent: Wednesday, December 13, 2000 9:18 AM
> Subject: RE: [Zope-dev] python 2.0, windows and zope
>
>
> >
> > Ive successfully installed the latest version of zope on windows and
have
> it
> > running my website.  http://www.brooklynmedialabs.com .  Its actually
> easier
> > than running it on linux!
> >
> >  -josh
> >
> >
> >
> > Has anyone got python 2.0 working with Zope on windows? Just curious if
> > anyone has any pointers before I start done this (potentially) painful
> > path...
> >
> > --
> >   Andy McKay, Developer.
> >   ActiveState.
> >
> >
> > ___
> > 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 )
> >
>
>
> ___
> 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] python 2.0, windows and zope

2000-12-13 Thread Andy McKay

I think thats just the fella I need! Thanks...
Will let you know progress
--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "Brian Lloyd" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Wednesday, December 13, 2000 11:14 AM
Subject: RE: [Zope-dev] python 2.0, windows and zope


> > Waffling on to my own posts... but it would seem I have to build Zope
from
> > source to get it to use another version of python since the use of
> > python15.dll is entrenched in Zope... All the install scripts seem to be
> > based on unix.
> >
> > Can DC give me a hand here on pointers to how they build it for Windows?
>
> Hi Andy -
>
> We have a little python script that creates NMAKE compatible
> makefiles out of the Setup files. I've attached it + the .bat
> file we use to run it. Hope this helps!
>
>
> Brian Lloyd[EMAIL PROTECTED]
> Software Engineer  540.371.6909
> Digital Creations  http://www.digicool.com
>
>
>


___
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] calling SQL from External Method and using acquisition

2000-12-20 Thread Andy McKay

This is just an annoying namespace issue:
- I'm calling SQL methods from External Methods by .
- I can then call a SQL method by calling self.sql_method()

But (there is always a but):
- I have to manually pass all the arguments, very annoying.

Work arounds that seem to work
- manually pass all the arugments, great except its my code rigid, Id like
to use acquistion
- call a "wrapper" DTML Method, which calls the ZSQL method, I still have to
pass manually but then get to use acquistion to pick up other stuff. Very
cool. But now I hace one wrapper class for every SQL method.

Is there a simpler way I have missed?

--
  Andy McKay, Developer.
  ActiveState.


___
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] case insensitive sorts

2001-01-03 Thread Andy McKay

My main point is that the user who visits my site does not care about
python, Unix, NT or any wierd metaphors about kettles.

They want information fast and most users expect case insensitive sorts. Its
simpler and easy. I think having the ignore_case option for a -tree and -in
helps Zope by increasing the ease of development and friendliness to the
user.

--
  Andy McKay, Developer.
  ActiveState.


- Original Message -
From: "Casey Duncan" <[EMAIL PROTECTED]>
To: "Andy Dawkins" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, January 03, 2001 8:17 AM
Subject: Re: [Zope-dev] case insensitive sorts


> Andy Dawkins wrote:
> >
> > > Your analogies imply that this behavior is a bug or an unintended flaw
> > > in the design. I would argue that it is intentional. Unix file systems
> > > work the same way. Try doing an "ls" with mixed case files and you'll
> > > see what I mean.
> > >
> >
> > It isn't a flaw.  It seems as though it was overlooked.
> >
> > The sort on text works by sorting the data by its ascii value.
> > Capital letters have a lower ascii value than lower case letters.
> > i.e.
> > A-Z = 65 - 90
> > a-z = 97 - 122
> >
> > The arguement is that the sort should probably go
> > AaBbCcDdEeFf.etc
> >
> > -Andy
> >
> My point is that the sorting is intentionally Unix-like and case
> sensitive on purpose. Not due to laziness. But, perhaps the reason Unix
> is like that to begin with is due to laziness anyhow 8^). We'll never
> know for sure.
>
> --
> | Casey Duncan
> | Kaivo, Inc.
> | [EMAIL PROTECTED]
> `-->
>
> ___
> 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] Allowed characters in Zope ids

2001-01-03 Thread Andy McKay

> I recently read RFC 2396 which defines the generic URI syntax
> and especially the URL syntax.
> I recognized, that
>
>  * Zope forbids many characters in ids (with the error message
>"not allowed in URLs"), that are legal characters
>in URL path segments:
>
>   generally allowed in URL's: -_.!~*'()
>  Zope accepted:_. ~

- as well (see regex below)
, is allowed in the id, sorry not sure what the term path segment means..

>   allowed in path segments:   :@&=+$,
>  Zope accepted: ,
>
>
>This, probably, is not a big problem.
>But, it would be easy to fix.

Except for the fact that Zope also checks that the first character is not a
_. Thats a big security headache. To be honest Im not so worried about Zope
being more restrictive.

>  * Zope allows space characters in (ObjectManager) id's.
>The space is not a valid URL character.
>
>Zope forbids spaces in property ids.

This one is much more important in my mind. Its a real pain. Is there a good
reason for this. It should be easy to fix, actually looking at the regex in
Object Manager, shouldn't that just be a case of taking the space out of the
end of the regex?

ObjectManager.py

line 112: bad_id=ts_regex.compile('[^a-zA-Z0-9-_~\,\.]').search]

On a more anal note could we also patch ObjectManager to tell the user what
characters aren't allowed eg:

line 224: 'The id "%s" contains characters illegal in URLs.' % id

should be

line 224: 'The id "%s" contains characters illegal in URLs. Only characters,
digits and the characters ~-_,. are allowed.' % id



___
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] case insensitive sorts

2001-01-03 Thread Andy McKay

Hmm im actually not so sure on that. Currently you can do a sort either way,
if you fix it so its only case sensitive we'll end up like Visual Basic :)
Fixing python is a question for the python list and I'd be scared to ask it
there...

--
  Andy McKay, Developer.
  ActiveState.


- Original Message -
From: "Chris Withers" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Cc: "Casey Duncan" <[EMAIL PROTECTED]>; "Andy Dawkins" <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Wednesday, January 03, 2001 8:46 AM
Subject: Re: [Zope-dev] case insensitive sorts


> Andy McKay wrote:
> >
> > They want information fast and most users expect case insensitive sorts.
Its
> > simpler and easy. I think having the ignore_case option for a -tree
and -in
> > helps Zope by increasing the ease of development and friendliness to the
> > user.
>
> And my point was that this is so universally true that the _pthyon_ sort
> function (which is at fault here) should be fixed :-)
>
> cheers,
>
> Chris
>


___
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] ZDESIGN IDEAS = How to improve 'manage' ?

2001-01-08 Thread Andy McKay

> For example some headings I see a real need for:
>
> NAME [default now], DATE[created, last modified] SIZE, TYPE[meta-type],
> USER[default=owner], DEPTH, COUNT, CHANGES, PROPERTY, DISPLAY

This is just more dtml, since most of the mangement interface is done using
dtml-in over a simple set of objects, this should be straightforward.

> SIZE
> How big is this thing?
> When I look at a graphic is it a thumbnail icon or a hires scan?
> What about PDF
> What about folders - how to calculate the size of folder?

That might be a little more tricky and slower if you want to try and
calculate the size of a Folder containing many objects. That I would say is
not terribly important.

> What woudl you like to see when you click on manage?

Id like to see this configurable so I can choose these options.


___
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] New UI for 2.3

2001-01-11 Thread Andy McKay

> I haven't seen this yet, but I have to agree. Two frames is bad enough
> btu addign another one with all the wasted border space, etc, sounds
> like a bad idea...
> 
> > This would leave extra screen space for doing work.

Hear, hear, could anyone post some screenshots?
 
--
  Andy McKay


___
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] Debugging Zope with Komodo

2001-01-11 Thread Andy McKay

Aaron has just helped me get Komodo debugging working for Zope. Both Neil
and I think this is absolutely fantastic, for the first time we can see the
interaction of Zope internals as they happen (its no longer a black box
anymore). This shed so much light on Zope, I think its great and so will any
Zope developer.

Many thanks to all involved in Komodo for making this happen.

--
  Andy McKay.




___
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] Debugging Zope with Komodo

2001-01-11 Thread Andy McKay

Aaron has just helped me get Komodo debugging working for Zope. Both Neil
and I think this is great, for the first time we can see the
interaction of Zope internals as they happen (its no longer a black box
anymore). This shed so much light on Zope, I think its great and so will any
Zope developer.

Many thanks to all involved in Komodo for making this happen.
--
  Andy McKay.




___
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] Debugging Zope with Komodo

2001-01-11 Thread Andy McKay

Sorry wrong mail list. Move along, nothing to see here.
--
  Andy McKay.


- Original Message -
From: "Andy McKay" <[EMAIL PROTECTED]>
To: "zope-dev" <[EMAIL PROTECTED]>
Sent: Thursday, January 11, 2001 11:03 AM
Subject: [Zope-dev] Debugging Zope with Komodo


> Aaron has just helped me get Komodo debugging working for Zope. Both Neil
> and I think this is absolutely fantastic, for the first time we can see
the
> interaction of Zope internals as they happen (its no longer a black box
> anymore). This shed so much light on Zope, I think its great and so will
any
> Zope developer.
>
> Many thanks to all involved in Komodo for making this happen.
>
> --
>   Andy McKay.
>
>
>
>
> ___
> 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] Debugging Zope with Komodo

2001-01-12 Thread Andy McKay

My lips are sealed.

Damn email client... oh well it wont be the first time and won't be the last
this has happened.

Yours embarrased.

--
  Andy McKay.


- Original Message -
From: "Chris Withers" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Cc: "zope-dev" <[EMAIL PROTECTED]>
Sent: Friday, January 12, 2001 2:32 AM
Subject: Re: [Zope-dev] Debugging Zope with Komodo


> Andy McKay wrote:
> >
> > Sorry wrong mail list. Move along, nothing to see here.
>
> Too late ;-)
>
> What's Komodo?
>
> > > Aaron has just helped me get Komodo debugging working for Zope. Both
Neil
> > > and I think this is absolutely fantastic, for the first time we can
see
> > the
> > > interaction of Zope internals as they happen (its no longer a black
box
> > > anymore). This shed so much light on Zope, I think its great and so
will
> > any
> > > Zope developer.
>
> Cool... that sounds really interesting, where can I get a copy?
>
> cheers,
>
> Chris
>
> ___
> 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] New UI for 2.3

2001-01-12 Thread Andy McKay

Come on, can someone post some sample screenshots?
--
  Andy McKay.


- Original Message -
From: "Andy Dawkins" <[EMAIL PROTECTED]>
To: "Brian Lloyd" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, January 12, 2001 12:39 AM
Subject: RE: [Zope-dev] New UI for 2.3


> Well just to be completely different to everyone else, I like the new
look.
>
> The bar at the top takes up a centimeter on my 20in monitor and it doesn't
> bother me in the slightest.
>
> I think Brain is right, People have been asking for DC to give Zope a face
> lift and now its got one you are all complaining about it.
>
> Don't get me wrong the points you raised are valid but you are complaining
> about 32 pixels.  Give it a week and you won't know what you were
> complaining about.
>
> Overall it gets the thumbs up from me. :)
>
> -Andy
> (P.S. Why hasn't the acl_users folder got the same style of
> shaded/non-shaded rows, Just a consistancy thang :)
>
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
> > Of Brian Lloyd
> > Sent: 12 January 2001 02:12
> > To: Steve Alexander; [EMAIL PROTECTED]
> > Subject: RE: [Zope-dev] New UI for 2.3
> >
> >
> > > I think the new UI for 2.3 is great improvement over 2.2.
> > >
> > > I'm already finding the sorted tables of folder contents useful, and
> > > having the add new items select at the top saves time.
> > >
> > >
> > > However, I do not like the 3-frame interface. I feel that the top
frame
> > > is wasted space. The Zope logo and "Logged in as username | Logout"
> > > could as easily go at the bottom of the tree-view frame on the left.
> > > This would leave extra screen space for doing work.
> > >
> > > I realize that I can make the frame smaller by dragging it with my
> > > mouse. I do a lot of TTW development, and I think I might find that
> > > cumbersome, so I guess I'll be hacking the top frame out of my
> > > management interface :-)
> >
> > Are you guys working on 486's with 13in. monitors at 640x480 or
> > something? :^)
> >
> > Seriously - Zope has been criticized for a very long time for
> > being, ah, aesthetically challenged :) It is a valid criticism
> > - we have been (and quite honestly, will continue to be) more
> > concerned with function over form. But is it really so bad to
> > make a 32 pixel-high concession to a small pittance of branding?
> >
> > I know that "branding" isn't important for those who are already
> > believers, but Zope has grown enough that its reasonable to put
> > some effort into "first impression factor". It doesn't help the
> > community for reviews to come out that waste words on the
> > visual appeal shortcomings of the UI and totally miss the
> > point. A better first impression is a Good Thing.
> >
> > The top frame is also a place where we might want to put more
> > "placeless" operations like logout in the future. You can only
> > jam so much into the tree pane without it looking very much
> > like way too much is being jammed into the tree pane :) FWIW,
> > one of the things we may put there later is a way to do "browser
> > preferences" via cookies to control things like default text
> > area sizes. That could also have a "hide top frame" option for
> > those who really can't spare the 32px. :^)
> >
> >
> >
> > Brian Lloyd[EMAIL PROTECTED]
> > Software Engineer  540.371.6909
> > Digital Creations  www.digicool.com
> >
> >
> > ___
> > 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 )
>


___
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] New UI for 2.3

2001-01-12 Thread Andy McKay

My 2 cents and thanks to people for letting me have a look!

-There are too many conflicting shades of blue
- blue links on blue background, black text on blue background, blue
underlines on tabs and so on.
- you guys like blue eh?
-I dont mind the idea of the bar at the top, branding is fine
-I do mind the idea that is 32 pixels in height being unused. stick the
copyright, refresh options, time of day up there, if the space is being used
more effectively, people wont mind as much. There's a ton of stuff you could
put up there and still view on a laptop..
-No chance of getting no case sensitive object listing (or at least
having it as an option?)
-the select/deselect all is great but changing the button is generally
considering confusing..
--
  Andy McKay.


- Original Message -
From: "Dieter Maurer" <[EMAIL PROTECTED]>
To: "Brian Lloyd" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Friday, January 12, 2001 12:37 PM
Subject: RE: [Zope-dev] New UI for 2.3


> Brian Lloyd writes:
>  > ...
>  > But is it really so bad
>  > to
>  > make a 32 pixel-high concession to a small pittance of
>  > branding?
> I can spare 32 pixels in height, but the current 32 pixels are worthless
> for me as I cannot read what is there.
>
> I do not know at what design schools one learns that
> black letters on dark blue background is a good thing.
> It seems to be quite widespread, as I see this quite
> often.
>
> Please keep in mind that colors do not look equal everywhere.
> My colors are usually dimmed as my eyes start burning when
> I have to look into bright light for a longer time
> (Zope's management screens are very difficult for me
> as they use bright white as background. I already looked
> whether I could change it, but unfortunately, the
> color is coded individually in each file.
> What about using a central style sheet instead?).
> Therefore, what might look good at your screen,
> is unrecognizable on mine (and probably others).
>
> Furthermore, you lost brand by placing the
> blue Zope button onto the blue stripe.
> You can now only guess, what is should be.
> While contrast is very high at most places in the
> new design, it is far too low in this place.
>
>
> 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 )
>


___
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] Massive scalability

2001-01-15 Thread Andy McKay

> I am currently planning two separate 'Archive' type
> projects/Products. In both cases, I need to make sure that
> my implementation will scale to hundreds of thousands or
> even millions of objects.

I would recommend using an RDMBS behind Zope then. Its faster, simpler and I
have always had better results.


___
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] Massive scalability

2001-01-16 Thread Andy McKay

> While that would work for the simple object case, I find the
> prospect of storing a bunch of BLOBs (for the image data of
> the Photos) in an RDBMS to be *most* un-appetizing. Storing
> them on the server's file-system seems in-elegant as well.

Okey dokey, just a suggestion. I have heard people talk about large ZOBD's
but once I go over a 10,000 object mark I just find a RDBMS easier myself.
Go for it good luck!

> Does anyone know of any hidden 'gotchas' when dealing with
> this many objects, regardless of the hit-load on the system?

Mostly starting and stopping Zope, the 2gb limit (which can be avoided),
pulling objects back out with complicated queries are my biggest gripes.


___
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] Massive scalability

2001-01-16 Thread Andy McKay

Does ZPatterns provide a nice interface / way for storing classes in a
RDBMS? I have to say using an RDBMS is not as transparent as I would like,
this may may improve it. Finally a reason for me to ZPatterns...

--
  Andy McKay.


- Original Message -
From: "John Eikenberry" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: "Michael Bernstein" <[EMAIL PROTECTED]>
Sent: Tuesday, January 16, 2001 3:22 PM
Subject: Re: [Zope-dev] Massive scalability


> Michael Bernstein wrote:
>
> > So, again: Has anyone run up against any performance or
> > other limitations regarding large numbers (hundreds of
> > thousands or more) of objects stored within the ZODB either
> > in a BTree Folder or a Rack?
>
> I was looking into the same issues recently, but for a much smaller set of
> data (5ish). In my tests ZPatterns/binary-trees scaled well for
storage
> and retrieval. But ZCatalog did not. It was basically useless for partial
> matching searches (taking many minutes for searches that retrieved more
> than 100 matches). I was also concerned about the indexing overhead. It
> doesn't scale well when changing/adding many things at a time (we might
> have bulk adds/changes).
>
> I ended up deciding to go with a RDBMS backend for data storage with a
> ZPatterns interface. SkinScripts work so well for this that I'm actually
> glad I switched. It simplified my design and implementation immensely.
>
> --
>
> John Eikenberry
> [[EMAIL PROTECTED] - http://zhar.net]
> __
> "A society that will trade a little liberty for a little order
>  will deserve neither and lose both."
>   --B. Franklin
>
> ___
> 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 )




[Zope-dev] 2.3 beta

2001-01-16 Thread Andy McKay

On a more minor note would it be possible to get rid of the old style dtml
syntax (

Re: [Zope-dev] Massive scalability

2001-01-17 Thread Andy McKay


> Are you saying that Zope's startup and shutdown time is
> affected by the size of the ZODB?

Yep. Over small ZODB's you wont notice the effect until it gets large. I
found it very annoying when doing a lot of work in python and so had two
databases, one with a small amount of data and one with a lot (two sets of
test). However in the end Shane Hathaway's excellent refresh product saved
the day.

--
  Andy McKay.



___
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] Massive scalability

2001-01-17 Thread Andy McKay

Wow, that sounds perfect. Yes that's exactly what I was asking.

I can create an abstract data storage (SkinScript) that stores the data
anywhere, lets say for my purposes an RDBMS (but it could be ZODB etc). I
can then get and access classes (DataSkins) with no cares about the data
storage and use all the advantages an OO approach gives.

I've got to play with this stuff, this could solve my data storage
problems...

Thanks!
--

  Andy McKay.


- Original Message -
From: "Steve Spicklemire" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Wednesday, January 17, 2001 3:43 AM
Subject: Re: [Zope-dev] Massive scalability


>
> Hi Andy,
>
>I'm not sure what you mean by 'interface/way', so.. I'm going to
> guess at two possible interpretations.
>
> 1) Basically ZPatterns allows you to define classes (DataSkins)
> instances of which can optionally be used to view/create/change/delete
> external data through methods of the class ( + a little SkinScript ).
>
> If your store your instance data in SQL you can use SQL queries,
> masked from the application behind some generic method (e.g.,
> getFooIdsWithText( textToFind )") to find the id(s) of the instance(s)
> you're after.  You can then get the instance from the ZPatterns
> machinery and, once gotten, display it, change it, call it's methods,
> and/or delete it. The way these actions on the object interact with
> the data in the external database is all defined in 'SkinScript' which is
> hidden away as a PlugIn of a Rack deep inside the ZPatterns guts. At
> the Zope application level you don't really *know* where/how the data
> is stored. Best of all you, or your Product's customers can easily
> customize that part *after* your product is plugged into *their*
> application, without changing the basic application level logic
> and design of your product.
>
> It's the coolest. ;-)
>
> 2) To get folks started with moving objects from ZODB to SQL I've
> found ZFormulator handy as a tool to get folks quickly up to speed
> in how SQL 'works'.
>
> http://www.zope.org/Members/faassen/ZFormulator
>
> If they already have ZClasses, they can use this to 'automatically'
> generate starting point queries to match their class propertysheets.
> Of course... it probably won't be normalized/optimized/etc.. but
> it's better than doing it all for them! ;-)
>
> -steve
>
> >>>>> "Andy" == Andy McKay <[EMAIL PROTECTED]> writes:
>
> Andy> Does ZPatterns provide a nice interface / way for storing
> Andy> classes in a RDBMS? I have to say using an RDBMS is not as
> Andy> transparent as I would like, this may may improve
> Andy> it. Finally a reason for me to ZPatterns...
>
> Andy> -- Andy McKay.
>
>
> Andy> - Original Message - From: "John Eikenberry"
> Andy> <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Cc: "Michael
> Andy> Bernstein" <[EMAIL PROTECTED]> Sent: Tuesday, January 16,
> Andy> 2001 3:22 PM Subject: Re: [Zope-dev] Massive scalability
>
>
> >> Michael Bernstein wrote:
> >>
> >> > So, again: Has anyone run up against any performance or >
> >> other limitations regarding large numbers (hundreds of >
> >> thousands or more) of objects stored within the ZODB either >
> >> in a BTree Folder or a Rack?
> >>
> >> I was looking into the same issues recently, but for a much
> >> smaller set of data (5ish). In my tests
> >> ZPatterns/binary-trees scaled well for
> Andy> storage
> >> and retrieval. But ZCatalog did not. It was basically useless
> >> for partial matching searches (taking many minutes for searches
> >> that retrieved more than 100 matches). I was also concerned
> >> about the indexing overhead. It doesn't scale well when
> >> changing/adding many things at a time (we might have bulk
> >> adds/changes).
> >>
> >> I ended up deciding to go with a RDBMS backend for data storage
> >> with a ZPatterns interface. SkinScripts work so well for this
> >> that I'm actually glad I switched. It simplified my design and
> >> implementation immensely.
> >>
> >> --
> >>
> >> John Eikenberry [[EMAIL PROTECTED] - http://zhar.net]
> >> ___

Re: [Zope-dev] No Restarts-cos-of-changed-python-product in 2.3?

2001-01-17 Thread Andy McKay

I haven't spotted any UI for it, if its there. Shane's Refresh didn't quite
work all the time for every product (something he recognized in his
readme's).  This would be a huge advantage for me with 2.3.
--
  Andy McKay.


- Original Message -
From: "Chris Withers" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Cc: "Michael Bernstein" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, January 17, 2001 10:24 AM
Subject: [Zope-dev] No Restarts-cos-of-changed-python-product in 2.3?


> Andy McKay wrote:
> >
> > Yep. Over small ZODB's you wont notice the effect until it gets large. I
> > found it very annoying when doing a lot of work in python and so had two
> > databases, one with a small amount of data and one with a lot (two sets
of
> > test). However in the end Shane Hathaway's excellent refresh product
saved
> > the day.
>
> I think this problem is fixed in 2.3... anyone know how?
>
> Is there a 'refresh this product' button or is it done simply by modifying
a
> python file on disk?
>
> cheers,
>
> Chris
>
> ___
> 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] Re: ZCatalog Scalability

2001-01-17 Thread Andy McKay

> Michael Bernstein wrote:
> >
> > Christopher Petrilli wrote:
> > >
> > > Unfortunately, it won't change in b1, it might change before the final
> > > release if I can find a better solution.  The problem is in the
Vocabulary,
> > > not in the Catalog itself.  One of the things I'm focusing on is
improving
> > > the algorithms that are used for doing globbing.
> >
> > Which problem is the algorithm improvement meant to address,
> > bulk adds or partial search performance?
>
> I'm guessing the partial search thing, but the bulk add thing really needs
to be
> sorted out too.
>
> NIP'd love to move the archives at
http://zope.nipltd.com/public/lists.html to a
> wholely Zope solution, but ZCatalog consistently exploded when we tried to
do
> this.
> For now, we're working on a Zope front end into MySQL (MySQL's new full
text
> searching stuff is pretty damn quick, maybe you could nick their
algorithms? ;-)

For a similar project (http://mailarchive.activestate.com) we too use a
MSSQL back end, for various reasons similar to Chris. I'm not worried about
it, once upon a time I tried to stick everying in the ZODB. To me one of
Zope's great strengths is it's portability and connectivity to other
databases and storage systems.

--
  Andy McKay.


___
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] Massive scalability

2001-01-17 Thread Andy McKay

On the plus side any corrupted objects are fixed or deleted when you start
up the ZODB. For that reason, somedays a restart is very useful :)
--
  Andy McKay.


- Original Message -
From: "ender" <[EMAIL PROTECTED]>
To: "Michael Bernstein" <[EMAIL PROTECTED]>; "Andy McKay"
<[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, January 17, 2001 12:05 PM
Subject: Re: [Zope-dev] Massive scalability


> On Tuesday 16 January 2001 20:42, Michael Bernstein wrote:
>
> > Are you saying that Zope's startup and shutdown time is
> > affected by the size of the ZODB?
>
> AFAIK on a filestorage zope loads up the indexes (oid, file_offset?) into
> memory on start to facilitate object retrieval which impacts start up
time. i
> don't think the other storages operate this way.
>
> kapil
>
> ___
> 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 )




[Zope-dev] Import/Export in 2.3beta2

2001-01-19 Thread Andy McKay

Is this a stupid question, or why cant i Import/Export into a folder in 2.3
b2 (Windows), there seems to be no tab...

--
  Andy McKay.




___
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] Old to new registerClass

2001-01-23 Thread Andy McKay

Im hacking around IEMethod and it uses an old style of class initialisation
in the __init__.py along the lines of:

  misc_ = { 'imagef':'foo','imageg':'goo', }
  lang_= { 'en':'lang_en','sv':'lang_sv', }

I want to put this into a modern style product initialisation
(context.registerClass). Looking at this functions API it didn't become
readily apparent how I can pass in these values. This would be nice to do so
I don't have any hacking of dtml to do. Has anyone done this / got any
advice?

Thanks.

--
  Andy McKay.




___
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] Old to new registerClass

2001-01-24 Thread Andy McKay

Lang is used in this line:

document.write("");

Kind of a bizarre line, but it looks like its setting the script source.
Thanks, just doing a quick ZWiki-IEMethod merge so that you can edit a ZWiki
standard style or using IEMethod.

Thanks for the code.

--
  Andy McKay.


- Original Message -
From: "Johan Carlsson" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 24, 2001 8:44 AM
Subject: Re: [Zope-dev] Old to new registerClass


> > Brian Lloyd
> > etc. I don't know what 'lang_' does, so I'm not sure what
> > to advise you there...
> >
>
> Hi Andy,
> As far as I can see the land_ directory doesn't seam to do anything.
> You could try to just remove it.
> (It wasn't me that put it there.)
>
> As for the most part of the Images defined in the misc_ structure,
> I suppose all of the except the IEMethod.gif (needed outside)
> could be defined in the IEMethod class instead of the module level.
> They are really not so useful outside the scope of the IEMethod object
itself.
> This should apply to the JavaScript-files and CSS-files as well.
> (Well it was me who put those files there, but that was a long time ago
;-)
>
> Regards,
> Johan Carlsson
>
> ___
> 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] Old to new registerClass

2001-01-24 Thread Andy McKay

I nuked it and everything is just fine, its defined in misc. Anyway works
fine, will post a "package" shortly after some testing.
--
  Andy McKay.


- Original Message -
From: "Johan Carlsson" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>
Sent: Wednesday, January 24, 2001 9:39 AM
Subject: Re: [Zope-dev] Old to new registerClass


> > Lang is used in this line:
> >
> > document.write(" > type=\"text/javascript\">");
>
> I think that:
> The "lang" Javascript variable is either set to "sv" or "en" so the script
include
> file should look for either "lang_sv" or "lang_en".
> The dictionary lang_ defined in __init__ isn't, as far as I can see, used
anywhere.
>
> So you don't need to worry about it much.
>
> > Kind of a bizarre line, but it looks like its setting the script source.
> > Thanks, just doing a quick ZWiki-IEMethod merge so that you can edit a
ZWiki
> > standard style or using IEMethod.
>
> Great, one less thing for me to do :-)
>
> Johan
>


___
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] Server seems to stop responding.

2001-01-25 Thread Andy McKay

OS: Win2K
Zope: 2.2.4b1, using ZServer direct
Site, large catalog roughly 20,000 items, database size 839 MB.

Problem:

Zope's running quite happily, and then all of a sudden will stop responding
to incoming requests. A restart and its fine. There is no memory leak
(memory usage is very low), no other resources consuming space. All log
files say nothing. There seems to be no obvious trigger or thing to cause
it, only time (or use).

Im at wits end to figure out:
a) where to start debugging (apart from log files, Control Panel debug etc)
and
b) solution...

Any help will get my undying gratitude...

--
  Andy McKay.




___
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] Server seems to stop responding.

2001-01-26 Thread Andy McKay

I think I've traced to a hack of ZCache, I nuked with much better results. I
guess I'll wait for zope 2.3

Cheers.
--
  Andy McKay.


- Original Message -
From: "Chris McDonough" <[EMAIL PROTECTED]>
To: "Andy McKay" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Thursday, January 25, 2001 3:40 PM
Subject: Re: [Zope-dev] Server seems to stop responding.


> Andy, look at the documentation in z2.py for the "-M" switch that writes
out
> a debug log of method accesses.
>
> Then visit http://www.zope.org/Members/mcdonc/HowTos/DEBUG-LOG
>
> It tells you how to track down hangs via stuff in your debug log.
>
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, January 25, 2001 5:08 PM
> Subject: [Zope-dev] Server seems to stop responding.
>
>
> > OS: Win2K
> > Zope: 2.2.4b1, using ZServer direct
> > Site, large catalog roughly 20,000 items, database size 839 MB.
> >
> > Problem:
> >
> > Zope's running quite happily, and then all of a sudden will stop
> responding
> > to incoming requests. A restart and its fine. There is no memory leak
> > (memory usage is very low), no other resources consuming space. All log
> > files say nothing. There seems to be no obvious trigger or thing to
cause
> > it, only time (or use).
> >
> > Im at wits end to figure out:
> > a) where to start debugging (apart from log files, Control Panel debug
> etc)
> > and
> > b) solution...
> >
> > Any help will get my undying gratitude...
> >
> > --
> >   Andy McKay.
> >
> >
> >
> >
> > ___
> > 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 )
>


___
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] ANNOUNCE: Zope 2.3.0 final released

2001-01-26 Thread Andy McKay

Congrats!
--
  Andy McKay.


- Original Message - 
From: "Brian Lloyd" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, January 26, 2001 1:06 PM
Subject: [Zope-dev] ANNOUNCE: Zope 2.3.0 final released


> Hello all,
> 
>   Zope 2.3.0 final has been released - you can download it from
>   Zope.org:
> 
>   http://www.zope.org/Products/Zope/2.3.0/
> 
>   Zope 2.3 is focused on improving productivity, ease of use and 
>   performance. New features in the 2.3 release supporting these 
>   goals include:
> 
> - Scripts to allow safe web management of logic, dramatically 
>   improving the ability to separate logic and presentation in 
>   site design
> 
> - Cache Managers to provide a powerful caching infrastructure 
>   for dramatically improving site responsiveness while retaining 
>   dynamicism
> 
> - Built-in infrastructure for complex virtual hosting of multiple 
>   sites on one server
> 
> - Significantly improved Zope Management Interface for web-based 
>   authoring and administration
> 
> - Other important changes, such as improvements in WebDAV support,
>   customizable object creation, running an optional server for 
>   browsing source documents, significant improvements in cataloging 
>   and indexing, and a new quick start document with references to 
>   the most important documentation for new users
> 
>   Zope 2.3 also marks the first feature release where a significant 
>   amount of the work was done "in the fishbowl" using our open 
>   development process on dev.zope.org. This release owes a lot to 
>   the hard work of many in the Zope community in addition to folks 
>   here at DC. The MVPs for Zope 2.3 include:
> 
> - Evan Simpson (Python scripting and SiteAccess)
> 
> - Shane Hathaway (CacheManager and many other things)
> 
> - Adam Davis (improvements to the Zope interface)
> 
> - Chris Petrilli (ZCatalog)
> 
> - Toby Dickenson (improved Python 2 support)
> 
> - Chris McDonough (improved UserFolders)
> 
> - John Odom (StructuredText NG)
> 
> - Michel Pelletier (Interfaces and new Quickstart)
> 
> - Casey Duncan (ZCatalog patches)
> 
> - Tres Seaver (FTP and DAV support in ZClasses)
> 
> - John Heintz (patch for ExtensionClass)
> 
> - Chris Withers (patches and bug hunting)
> 
> - Tom Vijlbrief (FTP rename support)
> 
> - Dieter Maurer (patches and bug hunting)
> 
>   My apologies to anyone I've missed - thanks also to the many 
>   who participated the alpha and beta cycles and provided 
>   feedback.
> 
>   For more information on what is new in this release, see the 
>   CHANGES.txt and HISTORY.txt files for the release:
> 
> - http://www.zope.org/Products/Zope/2.3.0/CHANGES.txt
> 
> - http://www.zope.org/Products/Zope/2.3.0/HISTORY.txt
> 
> 
> Brian Lloyd[EMAIL PROTECTED]
> Software Engineer  540.371.6909  
> Digital Creations  http://www.digicool.com
> 
> 
> ___
> 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 )




[Zope-dev] Storing session objects in a ZODB

2001-01-29 Thread Andy McKay

I want to store the session objects (from CoreSessionTracking) in the ZODB
so that users can save preferences (set in a Session) and call them back
later. Just thinking that the easiest way to something is to pickle it, but
pickling it in the ZODB which then pickles it, seems daft. Someone suggested
I could just _setObject into the ZODB, but don't I still need to make a
class wrapper around this?

Has anyone tried this? I couldn't spot anything in the CoreSessionTracking
API that obvious...

Cheers.

--
  Andy McKay.




___
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] Zope Service Won't Start

2001-01-30 Thread Andy McKay

Will start from MS-Dos? Starting it using the start.bat file will produce an
output of errors encoutered.
--
  Andy McKay.


- Original Message -
From: "Nai A. Tzeo" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, January 30, 2001 5:31 PM
Subject: [Zope-dev] Zope Service Won't Start


> Hello,
>
> I've encountered a slight problem.  My company is running Zope as an NT
> service and it's been running great for a few months but it stopped
working
> today.  I was installing ZmxODBCDA by copying the files from the zip to
> Zope.  After copying the files over, I restarted Zope via NT Service.
Keeps
> throwing start service due to logon failure.  I don't know what to do.
> Rebooted and deleted all the files I was installing and still can't get
the
> server started.  Anyone has any suggestion?  I'm a total newbie and am at
> lost.  There are going to be a lot of piss off people tomorrow if I don't
> get this working tonight.
>
> TIA,
> Nai
>
> ___
> 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-dev] Storing session objects in a ZODB

2001-01-31 Thread Andy McKay

Well my quick hack and wacky of doing it is as follows:

- I wrote a quick simple class "ZStore" that has as one of its properties a
pickle, which you can read and write to using cStringIO
- I make a ZStore object, throw in the session object, it pickles it as the
data property, I add a few more useful properties, like title, owner etc...
- To get it back I get that object, unpickle that property and I have the
session back.

Quick hack that works for me and allows me to change the content of a
session object, without having to change the storage. Im sure someone will
come up with a better solution.

--
  Andy McKay.


- Original Message -
From: "Chris McDonough" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 31, 2001 11:28 AM
Subject: [Zope-dev] Fw: [Zope-dev] Storing session objects in a ZODB


> This is a forwarding of an interesting session-related discussion between
> Andy and I... it covers the idea of storing session states as "snapshots"
at
> a particular time, later allowing users to select a session state.  This
is
> useful if you wish to allow users to make incremental changes to data in a
> session and "bookmark" a session state for later copying into the current
> session.  This is something that the "bare" session tracking stuff won't
do
> for you, although it can facilitate it tremendously.
>
> Input welcomed!
>
> - C
>
> - Original Message -
> From: "Andy McKay" <[EMAIL PROTECTED]>
> To: "Chris McDonough" <[EMAIL PROTECTED]>
> Sent: Wednesday, January 31, 2001 1:56 PM
> Subject: Re: [Zope-dev] Storing session objects in a ZODB
>
>
> > > I think you may be trying to use sessions to do something that
sessions
> > > don't do.  You can *use* the sessioning machinery as a base to build
the
> > > infrastructure to do such a thing, but it won't do it out of the box.
I
> > am
> > > currently trying to build an "onSessionStart" and "onSessionEnd" event
> > into
> > > session data objects.  If you had this capability, an arbitrary Python
> > > method (or DTML method or external method) could be called when a
> session
> > > data object is created and when it expires.  If you were to make use
of
> > > these hooks to copy the state of the session data object into another
> > > structure (related to the currently logged in user - a "checkpoint" if
> you
> > > will), you could build a catalog of session states that could be
> recopied
> > > into the current session namespace.
> > >
> > > Alternately, you could forego the use of events and just have a button
> > that
> > > says "save session state" somewhere, and copy the contents of the
> session
> > > namespace into something else.  Then when a user wanted to choose a
> > session
> > > state, copy it back into the current session namespace.  This is the
> same
> > > idea, it just lets the user be explicit about what session state he
> wants
> > to
> > > use instead of depending on the event hook to create a new state.
> >
> > Bingo, yes that's it!
> >
> > > Does this make sense?  Can I cc this to Zope-Dev so we can get some
> > > discussion about it?
> >
> > Absolutely!
> >
> > --
> >   Andy McKay.
> >
> > >
> > >
> > > > - Original Message -
> > > > From: "Chris McDonough" <[EMAIL PROTECTED]>
> > > > To: "Andy McKay" <[EMAIL PROTECTED]>
> > > > Sent: Tuesday, January 30, 2001 9:53 AM
> > > > Subject: Re: [Zope-dev] Storing session objects in a ZODB
> > > >
> > > >
> > > > > Andy,
> > > > >
> > > > > I'm still not sure why you wouldn't set up an external data
> > container..
> > > if
> > > > > you want, you can call me at 540-371-6909 if you think you can
> explain
> > > it
> > > > > better over the phone...
> > > > >
> > > > > - C
> > > > >
> > > > >
> > > > >
> > > > > - Original Message -
> > > > > From: "Andy McKay" <[EMAIL PROTECTED]>
> > > > > To: "Chris McDonough" <[EMAIL PROTECTED]>
> > > > > Sent: Tuesday, January 30, 2001 12:28 PM
> > > > > Subject: Re: [Zope-dev] Storing session objects in a ZODB
> > > > >
> > > > >
> > > > > >

Re: [Zope-dev] Fw: [Zope-dev] Storing session objects in a ZODB

2001-01-31 Thread Andy McKay

> Cool!  Note that the session data object implements the mapping interface,
> so you don't really need to pickle up a copy of it.  I'd recommend against
> this, although it seems to be working well for you.

Any special reason why I shouldn't pickle apart from the fact that the ZODB
will do it to save the object?

> Instead, to save a session state, I'd just grab the current session data
> object and iterate over its items, grabbing things out of it that are
> interesting to my application.  Then I'd copy these things into another
data
> structure, maybe by sticking them into an instance of a class that also
> implements the mapping interface and put that instance in a folder
somewhere
> which is related to the currently logged-in user.

Cool, I'll have to look at the mapping interface. I use a "fixed" version of
UserInfoFolder to maintain a folderish object on each person, Im throwing
this into there. Works nicely.

> Then when a user wanted to restore a saved session state, get a list of
> session state objects in his session state folder, present them to him,
have
> him select one.  When he does, copy the items out of it into the current
> session data object.
>
> The nice thing about this general strategy is that you can work with the
> current session data object in all of your app code that depends on
session
> state.  How the session state is saved and restored (and what the session
> data object values are) is completely independent of the app code.

Yep this is what I like. Im actually thinking this simple ZStore class is a
useful little object for throwing stuff into, if I get mapping working I'll
release the whole 50 lines of code it currently is...

Thanks for your help.

--
  Andy McKay.



___
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-dev] Storing session objects in a ZODB

2001-02-02 Thread Andy McKay

> Im storing session-like data pickled inside the URL. I end up with
> long, ugly-looking URLs, but it does mean that a browser's bookmarks
> and back button work as expected, effectively 'undoing' changes made
> to thier session state.
>
> This solution also avoids the problem of finding enough storage on the
> server to store multiple revisions of each session.

This solution is common and works great, but Ive never really liked it
myself since it involves munging URL's and making them look ugly. I like
nice short URL's I can email. In my more situation specific solution I give
access to the stored session snapshots along the lines of
?load_ssn=Default will load in the session named "Default" for that user
allowing them to be bookmarked...

--
  Andy McKay.


___
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] Changing Ownership

2001-02-02 Thread Andy McKay

I have a folder inside a user_info_folder that allows users to store data
(these fabled session snapshots of earlier posts). When I create it I want
to set the Ownership of that folder to the user. Since a user is created by
someone else (only admin can create users), the admin person is becoming the
owner. Simple I thought, in python when the object is created, set the
ownership

obj.changeOwnership(user)

where user is: user = self.acl_users.getUser(id)

The error I get back is

Error Type: AttributeError
Error Value: aq_inner


...

  File d:\Zope23\lib\python\AccessControl\Owned.py, line 168, in
changeOwnership
(Object: Traversable)
  File d:\Zope23\lib\python\AccessControl\Owned.py, line 302, in ownerInfo
AttributeError: (see above)

It would seem ownerInfo is looking for the User context to find the path to
the object. Anyway the end result is I can't seem to set the owner. Is there
a simpler way to do this. Is getUser actually returning the wrong thing?

Cheers.
--
  Andy McKay.




___
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] test, please ignore

2001-02-02 Thread Andy McKay

My golly are we back up?
--
  Andy McKay.


- Original Message - 
From: "Michael Bernstein" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 8:06 AM
Subject: [Zope-dev] test, please ignore


> test
> 
> ___
> 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 )



[Zope-dev] CoreSessionTracking stuff

2001-02-05 Thread Andy McKay

More questions on CoreSessionTracking. On on site I wish to persist the
information on a session indefinitely so a user can reconnect with those
previous session settings. I looked at "External Session Data Container"
(ESDC) and had some questions here I go:

-Why does an ESDC have a session timeout in 20 minutes, yet the cookie
lifespan can be 30 days. Surely there will be no way to tie a cookie back up
to a session since the ESDC will be have had that person nuked, I was sort
of hoping I coudl persist the data in the ESDC for a long time to provide
storage (I could always set the minutes to 9 or something silly). I
guess if I really want data to be persisted for ever some sort of Membership
product will be needed...
-Mounting a non-undoable db into Zope is not trivial unless there is
something Im missing. There's a non-undoable system every Zope installation
has called the file system, why dont we use that? I was thinking we could
modifiy LocalFS to provide that sort of functionality would be much
easier...

Cheers.

--
  Andy McKay.




___
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] Debugging Zope

2001-02-05 Thread Andy McKay

For all those who questioned my slip of an email a few weeks ago regarding
debugging Zope with Komodo, well its official now. A how to and some
screenshots are now available: http://www.zope.org/Members/andym/Komodo. I
hope you find it as useful as I do.

Cheers.

--
  Andy McKay.




___
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] CoreSessionTracking stuff

2001-02-05 Thread Andy McKay

> A session data object timeout of "0" as set in the session data container
> means "give me completely persistent session data objects, do not expire
> them".  Set it to this, and set a high cookie timeout.  But yes, a better
> way to do something like this is to use sessioning in combination with a
> membership product.

Ah ok, yes the more I thought about it, the more I thought a Membership
system is the way to go.

> Local filesystem access won't work across ZEO clients.  The primary
purpose
> of an external data container is to provide access to a shared namespace
> between ZEO clients.  This doesn't mean someone couldn't write an
alternate
> data container implementation that uses the filesystem, however.

True. But its another option that is quick and easy for many people. I'll
put it on my interesting things to do on a rainy day list somewhere

> As far as the difficulty of mounting goes, when I can find some time, I
want
> to write a mounting howto.

Thats always welcome.

Thanks.


___
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] manage_options in 2.3

2001-02-07 Thread Andy McKay

Thanks for the new management interface guys I happily wrote a product last
night and did a quick interface using the standard Folder interface and
fiddled with filtered_meta_types list and dontAllowCutandPaste and so on. A
quick How-To will be on its way. I got a wierd error trying to fiddle with
manage_options though, in the olden days something like this worked:

manage_options = (
( Folder.manage_options[0], ) +
( {'label':'View', 'action':'my_index_html', ) +
( Folder.manage_options[2:], )
)

But I kept getting this error in 2.3:

(Object: manage_tabs)
  File E:\Zope23\lib\python\App\special_dtml.py, line 236, in _exec
(Object: manage_tabs)
  File E:\Zope23\lib\python\DocumentTemplate\DT_With.py, line 133, in render
(Object: _(manage_options=filtered_manage_options()))
  File E:\Zope23\lib\python\DocumentTemplate\DT_Util.py, line 334, in eval
(Object: _(manage_options=filtered_manage_options()))
(Info: filtered_manage_options)
  File , line 0, in ?
  File E:\Zope23\lib\python\App\Management.py, line 119, in
filtered_manage_options
(Object: Traversable)
AttributeError: (see above)

Error Type: AttributeError
Error Value: 'tuple' object has no attribute 'get'

It seems its looking for a tuple of dicts? But looking at Folder on other
classes their manage_options hasn't changed. I then found this hack worked
(looking at this morning it could be improved):

_m = list(Folder.manage_options)
_m[1] = {'label':'View','action':'my_index_html'}
manage_options = (_m)

Whats going on?

--
  Andy McKay.




___
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] Python products

2001-02-07 Thread Andy McKay

Take a look at FSPoll which has sort of structure...

> You may have to do somethign funky if you want to limit the types of
object that
> appear in the 'Add' list of your new classes. I have no idea how to do
that :-S

I did that in FSPoll just last night. Basically overrode
filtered_meta_types, and iterated through the tuple of objects, discarding
ones I dont want, keeping the ones I do. I was hoping to do a how to in the
next day or so.

--
  Andy McKay.


___
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 )



  1   2   3   4   >