[Zope-dev] Re: Refresh trashes acquisition

Ross Boylan RossBoylan@stanfordalumni.org
Thu, 25 Jul 2002 14:53:24 -0700


On Thu, Jul 25, 2002 at 12:09:35PM -0700, Gary Speer wrote:
> Dear Ross - 
> I strongly encourage you to switch to the zope@zope.org mailing list as this one is dedicated to next-generation product enhancement as opposed to peer user assistance.

I thought this list was for developers, including product developers,
while the other was for zope users.  Isn't that the case?

> 
> The approach you are taking seems a bit convoluted and I, for one, do not understand the business/project objectives reason to construct the objects as you do and create the acquisition cvhallenge you hope to solve.  Perhaps you can elaborate on the goal you hope to accomplish so others can suggest the better tools and object containment structure to use.  It seems earlier design decisions have taken you to solving issues that might not exist with an alternative, more-naturally-zope-like approach.
> 
> Gary
> 

I suspect you are right that I may be going about this in an un-Zope
like way, so let me describe the goals at a slightly higher level.  My
immediate goal is to be able to do votes for a non-profit organization
I'm in.  Existing tools that I have found (include both non-Zope
things and the Zope Poll product) are not quite flexible enough.  For
example, I want to have several question in one poll (eliminatess most
of the non-Zope things) and I want to be able to have people rank
alternatives for some of the questions (Poll product doesn't have
this).

I'm trying to make something that has lots of little bits that can be
combined flexibly.  For example, one can combine a particular style of
question (yes/no vs ranking) with a way of tabulating the votes
(instant-run-off vs ranked pairs for ranked questions).

The part that's giving me trouble relates to how subitems are
handled.  Questions are subitems of a Ballot, and Response are
subitems of Questions.  There are two choices
1) what order should the items be presented in (e.g., original order
or a random order)?
2) how should they be labelled?  This in turn has two parts: do you
want arabic, roman, or letters for the labels, and what decoration
around that do you want--e.g., "Question xxx:" vs "Issue xxx)".

It seems natural to allow some of these options to be specified at a
high level of containment.  For example, one might have a preferred
numbering style for questions and another for responses that are set at
the level of the Ballot (or even higher, possibly).  Then, if you
wanted to, you could override these lower down.

Specifically, each question determines how to number its responses,
but the style it uses for numbering the responses will typically come
from a higher level.

This style of containment and optional overriding seemed to me exactly
what acquisition was all about, so I tried to do it with acquisition.
But it didn't work.  Based on previous responses, I've implemented a
containment hierarchy by hand.  This works.  Almost surely there is a
better way.