Alt-TAL (Re: [Zope-dev] i18n for CMF And Plone, backporting i18n to Zope 2.x)

2002-07-01 Thread Lalo Martins

On Mon, Jul 01, 2002 at 03:49:07PM -0300, Sidnei da Silva wrote:
 On Seg 01 Jul 2002 15:26, Jim Fulton wrote:
 | I'll add that the current ZPT implementation is too slow
 | (thanks to recent DTML speedups ;).
 |
 | ZPT needs to be as fast as or faster than DTML.  It would be
 | great if it was cleaner and more pluggable.
 
 I remember that i had the same concern when discussing this with lalo, and he 
 told me that this should be faster, as TAL-Current stores a binary 
 representation of the XML Parsed source, and his version is based on PAX, and 
 this would not need to be pre-compiled and stored. Unfortunately I cannot 
 give more information as this explanation seemed fine to me at that time.


Our original prototypes of ZPT stored a DOM tree in the ZODB, so they only
really parsed the source when it was updated.

When the stuff was rewritten for optimization, DOM was done away with in
favour of TAL bytecode which, for some reason, isn't stored persistently.
I asked once, and I seem to remember the answer was it doesn't pickle well.


Well, Alt-TAL is an experiment to see how fast a pluggable and readable
version of TAL could be.

My first step was to construct a bytecode that is pickleable and is not
TAL-specific. This is PAX. I didn't yet announce PAX anywhere as it is
evolving fast to meet the needs of Alt-TAL, but I plan to make it a package
in its own right in the near future.

In Alt-TAL, rendering TAL is a PAX Transform. This dawned on me as a
result of a comment by Leo Almeida that TAL could probably be implemented as
a XSLT sheet.

Alt-TAL currently only implements the tal: namespace, and tal:on-error is
missing because it implies an exception-handling infrastructure which I
didn't yet even design. So, the reason I didn't announce Alt-TAL was that it
was so incomplete.

But in my tests (and I run tests on a very old ppc machine, so that I may
get a visual feel for the speed differences), the few input templates that
already pass, pass faster than with the original TAL.

Of course this experience has a long way to go. I need tal:on-error, then
all metal: stuff, then make a version of PageTemplate that uses Alt-TAL
(originally I planned Alt-TAL to be a drop-in replacement, but that would
impact performance very badly so I gave up), then benchmark and optimize and
benchmark and rinse and repeat.

In a very extreme case, PAX (or perhaps PAX transform) can be optimized into
C or Pyrex. As it has a lot of for loops, I assume this would be a gain.

Of course, as my design skills are stronger than my coding skills, and as my
optimizing skills are very very weak [;-)], I invite anyone interested in
this experience to join in.


[]s,
   |alo
   +
--
  It doesn't bother me that people say things like
   you'll never get anywhere with this attitude.
   In a few decades, it will make a good paragraph
  in my biography. You know, for a laugh.
--
http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Eu jogo RPG! (I play RPG) http://www.eujogorpg.com.br/
Python Foundry Guide http://www.sf.net/foundry/python-foundry/


___
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: [Zope3-dev] Are there Graphic Designers?

2002-04-07 Thread Lalo Martins

On Sat, Apr 06, 2002 at 10:52:27AM +0100, Adrian Hungate wrote:
 
 My question is this: Everyone is saying The ZMI is bad, it's confusing,
 users don't like it.

Which everyone? Not me.

 Could anyone show me evidence of this? Personally I
 love the ZMI in the current versions. I have also found there is a
 negligable learning curve for users who already know how to use Windows
 Explorer and similar products. I just don't see the need to throw out the
 ZMI - Are we in a baby/bathwater situation here?

We're not throwing out the ZMI. We're writing something similar for Zope3.
The name is ZopeTop.

[]s,
   |alo
   +
--
  It doesn't bother me that people say things like
   you'll never get anywhere with this attitude.
   In a few decades, it will make a good paragraph
  in my biography. You know, for a laugh.
--
http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.org/
Python Foundry Guide http://www.sf.net/foundry/python-foundry/


___
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: [Zope3-dev] Are there Graphic Designers?

2002-04-04 Thread Lalo Martins

On Thu, Apr 04, 2002 at 03:05:39PM -0600, Stephan Richter wrote:
 Hello everyone,
 
 as we are moving forward developing Zope 3 with large steps, it becomes 
 more and more desirable to think about a nice frontend (ZMI) for Zope 3.
 
 However the skill set of the developers currently working on Zope 3 does 
 not include good graphics design skills. For this reason the development 
 team is looking for one to two good graphic artists who would like to work 
 on the look and feel of the new Zope version. Since it is fully developed 
 from scratch, there are almost no restrictions, other than: It has to be 
 functional.
 
 Are there any takers?

I propose to base the Zope3 ZMI on the Plone CMF skin (designed primarily by
the talented Alexander Limi and Vidar Andersen with important coding by Alan
Runyan), which can be seen at http://plone.org.

I don't know if Limi  group are available to do the work themselves, unless
ZC hires them for the job, but I don't think they would object either. I
know at least Alan has a lot of interest in Z3.

As I'm skinning Plone/CMF for my primary job, I'd be willing to do (or
coordinate if other people want to help) the work of adapting the skin to
Zope3 needs.

[]s,
   |alo
   +
--
  It doesn't bother me that people say things like
   you'll never get anywhere with this attitude.
   In a few decades, it will make a good paragraph
  in my biography. You know, for a laugh.
--
http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.org/
Python Foundry Guide http://www.sf.net/foundry/python-foundry/


___
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] masquerading python products as functions

2001-07-11 Thread Lalo Martins

On Wed, Jul 11, 2001 at 11:38:20PM +1200, Mick wrote:
 Hi,
 
 I am trying to make a product act like an external method, or dtmlmethod.
 Basically I have taken the minimal product and added a __call__ function.
 It works fine, and can be called as a function of the object that contains
 it.  The problem is that the minimal objects namespace is also pushed onto
 the stack, and to get out of it I need to go through self.aq_parent.

You may want to try out Shared.DC.Scripts.Script.

I have a (preliminary) HOWTO at
http://www.zope.org/Members/lalo/scriptclass-dev

[]s,
   |alo
   +
--
http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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] RFC: How-To on subclassing Shared.DC.Scripts.Script.Script

2001-06-25 Thread Lalo Martins

I'm thinking here that subclassing Script is the way to go for
any object that needs finer control on how it is called - and
I'll say that of any class that doesn't just do

  index_html = HTMLFile(foo, globals())

So, I wrote a How-To. It's definitely not ready for prime-time,
as I haven't actually used it to implement a class, but I think
it's correct. I'd appreciate if people took a look at it and
commented both on correctness and clarity/usefulness.

It is at http://www.zope.org/Members/lalo/scriptclass-dev now;
this is a ZWikiPage, so you can comment right there. The real
address will be http://www.zope.org/Members/lalo/scriptclass
when it's ready.

[]s,
   |alo
   +
--
http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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 )



Re: [Zope-dev] RFC: How-To on subclassing Shared.DC.Scripts.Script.Script

2001-06-25 Thread Lalo Martins

On Mon, Jun 25, 2001 at 06:36:30PM -0500, Stephan Richter wrote:
 
 But when I started reading it, I wanted to learn more of how I could 
 implement a new scripting language into Zope, such as a ZOQL (as mentioned 
 on the SmartObjects mailing list: 
 http://imail.iuveno-net.de/pipermail/smartobjects/), Tcl, XQuery or XPath. 
 Even though your usage of the Script-class is unique and obviously useful, 
 I think you should make a note, that will not describe how to implement 
 another scripting language. But other than that, I learned something new.

Thank you :-)

I don't think I could teach something as generic as this; the
process would be completely different for each language, and
depend on your interpreter. For starters, PythonScript and
ZopePageTemplates are completely different.

The classes to add new scripting languages would be similar up
to the point I described in my How-To, I'm afraid. Up from
there, it's you and your interpreter.

[]s,
   |alo
   +
--
Esvazie sua mente, pequeno gafanhoto.
   Nós temos muito o que aprender... mas primeiro...
   Primeiro você terá que desaprender o que acha que já sabe.
--
http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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 )



Re: [Zope-dev] ANNOUNCE: Zope 2.4.0 alpha 1 released

2001-06-01 Thread Lalo Martins

On Fri, Jun 01, 2001 at 07:33:43AM +1000, Albert Langer wrote:
 
 A note to component developers - as of Zope 2.4 ExtensionClass has not been
 updated to support all of the new magic protocols that Python classes
 support (we're hoping that EC will go away soon).
 
 What does hoping that EC will go away soon mean? I thought that
 ExtensionClass was pretty
 fundamental to Zope?? Does this just mean that the limitation on magic
 protocols will go away soon, or is there some URL I should look at re
 replacement for EC?

EC are a fix for a problem that shouldn't exist in Python
(inability to inherit from classes defined in C/C++).

By hoping that EC will go away soon, I assume they mean the
PythonLabs folks are working on fixing this for once in Python
itself. Right?

[]s,
   |alo
   +
--
   I say a prayer now our love's departed
That you'll come back to stay
  Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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] What would *you* like to have in PropertyManager and friends?

2001-05-27 Thread Lalo Martins

raise ZopeProject('http://dev.zope.org/Wikis/DevSite/Proposals/PropertyRevamp')

We at Hiperlogica realize a lot of you people prefer to write
your code in Python in the filesystem. However, we also believe
the power of Zope's trough-the-web RAD framework is one of the
reasons for its success; more importantly, it's a good part of
the reason it works for *us*.

In this spirit, we fired up HiperDom a few months ago, and
we're now working on ZUnitTTW to allow developers to unit test
their ZClasses and even their very sites.

Now, we've been taking note of a lot of peeves we have with
Properties, in the past one year or so. After all this time,
and dealing with some Zope internals, we feel confident enough
to propose to fix them.

So we're raising a Project in the fishbowl to implement these
changes. But before we dive in the mud, we'd like to hear from
people that really use Properties (and/or ZClasses), or that
would use them if they were more powerful. Please go to the
Proposal page, linked above, and tell us what you think.

[]s,
   |alo
   +
--
   I say a prayer now our love's departed
That you'll come back to stay
  Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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 )



Re: [Zope-dev] zunit 0.2 comments

2001-05-01 Thread Lalo Martins

On Mon, Apr 30, 2001 at 09:34:53PM -0700, Simon Michael wrote:
 
 Zope or the codeit setup didn't seem to see things in
 INSTANCE_HOME/Shared and I don't have access to SOFTWARE_HOME/Shared.

Hmm. Rolled newspaper for them. :-)


 What's the reason for this new level of indirection, the
 ExternalTestCase object ? And do you think this name is appropriate ?
 (I am confused about tests vs test cases vs test suites)

It's a refactoring to prepare for 0.3, where we'll have the
actual TestCase object. This object will allow you to write
tests TTW.

Yes, we know a lot of you don't want to do that. Don't worry,
ExternalTestCase will always be there ;-) But you have to
realize that there are also a lot of people who just won't
touch Python code in the filesystem whenever possible. If
you're testing a ZClass-based Product, it would be completely
cumbersome to use PyUnit.

 Also, any ideas about the following which I get when running either my
 own tests or the samples:
(...)
 AttributeError: id

Mumble mumble. Probably API incompatibility between Zope
versions? We'll look further into it.

(Recent versions are deprecating direct access to the 'id'
attribute, specially because you don't know when it's a string
and when it's a method... we should have used getId())

We now have a SourceForge project, feel free to report bugs and
browse our open tasks to see where we're going :-)

[]s,
   |alo
   +
--
   I say a prayer now our love's departed
That you'll come back to stay
  Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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 )



Re: [Zope-dev] zunit 0.2 comments

2001-04-26 Thread Lalo Martins

On Thu, Apr 26, 2001 at 01:21:01AM -0700, Simon Michael wrote:
  Hi Lalo,
 
  thanks for your work on ZUnit. I have just been playing with 0.2.

Thank you for your feedback.

  To get it working in my zope account at Codeit, I moved Hiper from
  Shared/ to Products/ and changed the import statements.

Why?

  I also needed to make some changes of this kind:
 
   #manage_RunTestsForm = 
Globals.HTMLFile('Products/ZUnit/dtml/TestRunner/RunTests')
   manage_RunTestsForm = 
Globals.HTMLFile('dtml/TestRunner/RunTests',globals())

Ooops :-) this proves that Pair Programming doesn't catch them *all*.

  I'm having trouble figuring out the syntax of the test_ids
  property. Can you help ?

Each line is the Id of an ExternalTestCase object. You can use
RestrictedTraversal, as in MyFolder/tests/MyTestCase.

[]s,
|alo
+
--
I say a prayer now our love's departed
 That you'll come back to stay
   Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
  pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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] WebDAV etc permissions (Re: zope nautilus cabal)

2001-04-18 Thread Lalo Martins

On Fri, Apr 13, 2001 at 11:48:39PM +0100, Chris Withers wrote:
  The WebDAV (and XMLRPC) stuff either needs to be decomposed to run on its
  own port (and only that port) or more explicit permissions need to be
  associated with WebDAV/XMLRPC operations if we take for granted that being
  able to browse the root folder structure is a bad thing.
(...)
 Basically, 'access contents information' isn't a great permission. If you
 turn if off, life gets horrible, if you leave it on, bits hang out. I'd
 prefer to see something like:
 - Access Contents Information via HTTP
 - Access Contents Information via FTP
 ..etc...

When I crawled out of bed today it ocurred to me that there is
a very reasonable sollution already.

We've had a "FTP access" permission for ages. So, either:

- make WebDAV, XMLRPC etc protected by "View Management Screens"

- make WebDAV, XMLRPC etc protected by "FTP access"

- make WebDAV, XMLRPC etc protected by "DAV/RPC access"
  (a new permission)

yes? 

[]s,
   |alo
   +
--
   I say a prayer now our love's departed
That you'll come back to stay
  Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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 )



Re: [Zope-dev] Confused by accuisition, need help

2001-04-08 Thread Lalo Martins

On Sun, Apr 08, 2001 at 11:14:51PM +0200, Robert Rottermann wrote:
 Hi there,
 
 I need the help with the following situation:

The easiest way is to make more use of DTML and not try to bend
it so much:


   dtml-in expr="PARENTS[0].data()"
 OPTION selected value="dtml-var sequence-index"
   dtml-var sequence-item
 /OPTION
   /dtml-in

Instead, try just dtml-in data.


 Now my problem:
 in index_html I only would like to splice the various parts togezher. 
 
 Like so:
 some glue
 dtml-var expr="PARENTS[0].data.projects.show()"
 dtml-var expr="PARENTS[0].data.documents.show()"
 /some glue

Try this:

 some glue
 dtml-with data
 dtml-with projects
 dtml-var show
 /dtml-with
 dtml-with documents
 dtml-var show
 /dtml-with
 /dtml-with
 /some glue

Or something like that.

When you call stuff with "name=" instead of "expr=", you let
DocumentTemplate do the calling for you, and then your methods
will be called with the correct parameters.

[]s,
   |alo
   +
--
   I say a prayer now our love's departed
That you'll come back to stay
  Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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 )



Re: [Zope-dev] Confused by accuisition, need help

2001-04-08 Thread Lalo Martins

BTW - you're not confused by Acquisition, you're confused by
DocumentTemplate's calling conventions (you can't call it with
zero parameters, not if you want it to work anyway)

[]s,
   |alo
   +
--
   I say a prayer now our love's departed
That you'll come back to stay
  Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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] Can't _setObject???

2001-04-02 Thread Lalo Martins

Hi there

I just found out (while coding ZUnit 0.2) that ZUnit 0.1
doesn't work on Zope 2.3.x for some reason.

The method manage_startTests of the TestRunner class creates an
instance of TestResults, runs the tests with it (using
RESPONSE.write(), if this makes a difference), then adds it to
itself using self._setObject().

On Zope 2.2.x this works like a charm. On 2.3.x it doesn't
bomb, doesn't raise an exception and doesn't set my house on
fire, but the TestResults object simply isn't persisted.

We tried all kinds of desperate things, like setting _p_changed
on both TestRunner and TestResults, and doing a
get_transaction().commit() - nothing changes.

Out of curiosity, we enabled the addlist in TestRunner and sure
enough, you can add objects via the addlist and they persist
normally.

Anyone has a clue? Of all things that changed between 2.2 and
2.3, which one can be killing us like that?

[]s,
   |alo
   +
--
   I say a prayer now our love's departed
That you'll come back to stay
  Bring back the perfect day

http://www.laranja.org/mailto:[EMAIL PROTECTED]
 pgp key: http://www.laranja.org/pessoal/pgp

Brazil of Darkness (RPG)  ---   http://www.BroDar.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 )



Re: [Zope] hiperdom

2001-01-18 Thread Lalo Martins

On Thu, Jan 18, 2001 at 12:38:29PM +0800, Bak@kedai wrote:
 hello all
 scuse my ignorance.  i have this[1] in a hiperdom instance (partial text from 
 hiperdom howto).  but i got this[2] error when i clicked change.
 
 i know it's me not understanding XML well enough.

There's no HiperDom HOWTO, and what little documentation there
is, is outdated.

Martijn upgraded HiperDom to work with the newer PyXML package,
but for that you'll need proper XML namespace handling, as in
(in your case) html xmlns:hdom="uri:hiperdom".../html.

The default text already gives you an example; if you create a
template, it's filled with EmptyTemplate xmlns:hdom="uri:hiperdom" /

 p/s - maybe, the default text in a newly created hiperdom instance should be 
 something similar to what a new dtml method/document gives now?

Hadn't thought of this, sounds like a good idea.

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] Industry customer lists

2001-01-04 Thread Lalo Martins

In the future, if you choose to respond to spam, don't CC the
list, please.

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Re: [Zope] ANNOUNCE: Zope 2.3.0 alpha 1 released...

2000-12-13 Thread Lalo Martins

Found a bug, I think... when I try to add a property to a
PropertyManager (but not a PropertySheet?) I get:

Error Type: ImportError
Error Value: cannot import name checkValidId

Traceback (innermost last):
  File /opt/Zope-2.3.0a1-src/lib/python/ZPublisher/Publish.py,
line 222, in publish_module
  File /opt/Zope-2.3.0a1-src/lib/python/ZPublisher/Publish.py,
line 187, in publish
  File /opt/Zope-2.3.0a1-src/lib/python/Zope/__init__.py, line
221, in zpublisher_exception_hook
(Object: Traversable)
  File /opt/Zope-2.3.0a1-src/lib/python/ZPublisher/Publish.py,
line 171, in publish
  File /opt/Zope-2.3.0a1-src/lib/python/ZPublisher/mapply.py,
line 160, in mapply
(Object: manage_addProperty)
  File /opt/Zope-2.3.0a1-src/lib/python/ZPublisher/Publish.py,
line 112, in call_object
(Object: manage_addProperty)
  File /opt/Zope-2.3.0a1-src/lib/python/OFS/PropertyManager.py,
line 318, in manage_addProperty
(Object: Traversable)
  File /opt/Zope-2.3.0a1-src/lib/python/OFS/PropertyManager.py,
line 247, in _setProperty
(Object: Traversable)
ImportError: (see above)


[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar


___
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] New version of book uploaded

2000-12-07 Thread Lalo Martins

Okey, so I decided to start by the last chapter (Appendix B)
;-) in lynx, /method hilighted:

From Python

Products, External Methods, and PythonMethods can call a
DTML Document in the same way as calling a DTML Document
from a Python expression in DTML; as shown in the previous
example.

This paragraph appears twice.

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] New version of book uploaded

2000-12-07 Thread Lalo Martins

Okay, one more to raise my chances ;-) (I really want this book!)

   First create a new Folder named exhibitTemplate in your
 Product. This will serve as a template for exhibits. Also in
 the Product folder create a DTML Method named addForm, and
 restricted Python Method named add. These methods will
 create new exhibit instances. Now go back to your Factory
 and change it so that the Add list name is Zoo Exhibit and
 the method is addForm.

The next paragraph also refers to an "add method" (should
probably be an "add script").

Then later, in section "Creating Methods on your ZClass":

   You can create any kind of Zope object on the Methods view,
 but generally only Method-like objects (DTML, Python, and
 Perl Method, for example) are added.

Later on this section there are some mentions of "this method"
refering to a Python Script, but this is dubious since in this
case the Script is really a "method" of the ZClass in the
literal OOP meaning.

Later in "Using Python Base Classes":

   ... A Python base class is pretty much the same thing as a
 collection of unrestricted Python methods.

And the last paragraph of the chapter also refers to
"restricted Python Methods".

I could hunt out all of them, but I'll leave some books for the
rest of the world ;-)

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope-dev] ZUnit - feedback convocation

2000-12-06 Thread Lalo Martins

On Mon, Dec 04, 2000 at 02:56:26PM -0800, Michel Pelletier wrote:
 On Mon, 4 Dec 2000, Lalo Martins wrote:
 
  The first section is the advocacy section; it will begin with
  "if you already do unit tests, you may want to skip this
  section". I'm not sure if the history lesson is out of scope,
  but "Why do you want to use it" is probably better.
 
 Hmm... actually in that case you may want to axe both "why" and the history.

I agree. At most, one paragraph about each could go in "What
is Unit Testing".

   What does "refactor mercilessly!" mean?
  
  I'll explain that one of the benefits of unit testing
  extensively is that you can modify your code without fear
  (you'll know when it breaks). This section is more advocacy
  than technical.
 
 Ah, ok I like it.  I wonder if "refactor" is the right word; it's very
 specific and it sounds like any kind of changing can be done.

"Refactor Mercilessly!" is one of the "practices" of XP, and an
expression (XPression?) they like to throw around.

Also, yes, any kind of changing can be done, if the tests cover
it :-) (except that if you develop new functionality, you must
write new tests too)


  I allocated a subsection for this because just explaining the
  problem is already somewhat convoluted, as you see above ;-) in
  a printed book, I'd make it a sidebar or something, but...
 
 Hmm.  I guess my concern was because it was the only subsection of
 'Fixtures'.  Do fixtures need a more topical breakdown or are they
 simple enough to sum up in one section?  Maybe we can think of some
 'fixture use cases'.

I don't think so. I think I just broke the rules. When I added
this subsection I was thinking more about some kind of sidebar,
not a real subsection - fixtures definitely don't need their
own topical breakdown.

As there is no provision for "sidebars" or "boxes" in the
informal standard format we've been using for these docs,
I'll move the note about this issue one level up.

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] OracleStorage, and possibly others

2000-11-30 Thread Lalo Martins

On Thu, Nov 30, 2000 at 08:10:15AM -0500, Jim Fulton wrote:
 Lalo Martins wrote:
  
  Please help stamp out Data.fs! :-)
 
 I don't think Data.fs will go away.  I do expect it to be relagated to
 initial evaluation and development projects. Use of Berkely DB in
 transactional mode requires a significant andminstration commitment.
 Log files need to be purged. Backup and recovery processes need to be in 
 place. A similar cost is associated with using Oracle and many other databases,
 I expect. People aren't going to want to deal with these issues when 
 initially trying and learning Zope (or ZODB).

Sometime it will, I hope. Or at least, be relegated to non-Zope
ZODBs where the data volume is very small. But FileStorage will
not be replaced by any of the current alternatives, I agree.

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] ZUnit - feedback convocation

2000-11-30 Thread Lalo Martins

Hi all

I'trying to write a document on ZUnit and Unit Testing in
general, following Michel's and Amos' documentation process. I
wrote an outline, and now I'm stuck :-) anyone with a few free
moments is welcome to take a look and send me some words. Also,
anyone very interested in the subject is welcome to volunteer
for editorial help (read the Process to know what this means).

Thank you.

(BTW, if you can't understand what an "outline" is, read the
process too. Oh what the heck. If you haven't read it, then
read it, it's very cool reading anyway.)

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar


Unit testing Zope Products with ZUnit

  by Lalo Martins

  Unit Testing

What is Unit Testing

Where does it come from

How should it be done

Refactor mercilessly!

  Writing Tests
  
Importing ZUnit

The TestCase class

Interfacing with the Zope environment

Fixtures

  The persistence problem - leaving traces behind

Grouping tests in TestSuites

Wrapping it all up in a creator function
  
  Running the tests
  
The TestRunner object

TestResults objects

Leaving objects behind for debugging



Re: [Zope-dev] OracleStorage, and possibly others

2000-11-29 Thread Lalo Martins

On Wed, Nov 29, 2000 at 07:02:50AM -0500, Chris McDonough wrote:
  Of course it would, for the same reasons as OracleStorage (eg
  FileStorage/Data.fs is inefficient)
 
 Actually, it's the other way around.  OracleStorage is 30-to-50 times slower
 than FileStorage on writes.  Reads are slow too but the slowness is somewhat
 negated by caching.

Chris, that's only true for small databases. At about 100M of
Data.fs, OracleStorage starts being faster. It depends on
hardware too. We made some benchmarks on a major Brazilian
portal, and well, it's currently running OracleStorage.

Anyway, I said "inefficient", not "slow".

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] OracleStorage, and possibly others

2000-11-29 Thread Lalo Martins

On Wed, Nov 29, 2000 at 10:13:15AM -0500, Chris McDonough wrote:
 It sounds like you've done more comprehensive speed testing than we have.
 Can you share some numbers?

Unfortunately no, I can't. We made measurements during a
consulting job I did for another company, and it was made by
them, not me, *plus* I wasn't smart enough to save a copy of
the numbers :-/

Anyway, the biggest problem they had was stability, their ZODB
grows and shrinks insickening speeds, and Data.fs would break
for some reasons I don't remember anymore, and OracleFS solved
that. I'll try to convince them to write a report to the list.

 - Original Message -
 From: "Lalo Martins" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Wednesday, November 29, 2000 8:42 AM
 Subject: Re: [Zope-dev] OracleStorage, and possibly others
 
 
  On Wed, Nov 29, 2000 at 07:02:50AM -0500, Chris McDonough wrote:
Of course it would, for the same reasons as OracleStorage (eg
FileStorage/Data.fs is inefficient)
  
   Actually, it's the other way around.  OracleStorage is 30-to-50 times
 slower
   than FileStorage on writes.  Reads are slow too but the slowness is
 somewhat
   negated by caching.
 
  Chris, that's only true for small databases. At about 100M of
  Data.fs, OracleStorage starts being faster. It depends on
  hardware too. We made some benchmarks on a major Brazilian
  portal, and well, it's currently running OracleStorage.
 
  Anyway, I said "inefficient", not "slow".


[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] BerkeleyStorage (Re: [Zope-dev] OracleStorage, and possibly others)

2000-11-29 Thread Lalo Martins

On Wed, Nov 29, 2000 at 04:28:26PM +, Ty Sarna wrote:
 Lalo Martins wrote:
  
  What about the other Storage projects? BerkeleyStorage has been
  dead for an year.
 
 It's not dead, it's just pining for the fjords!
 
 Seriously, AFAIK it still works, and it's mainly just stalled waiting
 for some interest.  It could stand to be updated to BerkeleyDB 3, but
 that was blocked on having an updated Python BerkeleyDB module for a
 while.  Now there is an updated version, so it should be easy to update
 the storage. 
 
 The main thing BerkeleyStorage is lacking is interest -- I don't need it
 currently for the purpose for which it was developed, and nobody else seems
 to need it much either.  It looked for a while like it might get a boost
 from the Sessions project, but that's stalled for the moment as well. 

I think a BerkeleyDB3-based Storage would be a very cool option
if versioning was optional instead of missing. (Then again,
this is almost getting to my dreamed XDeltaStorage...)

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] OracleStorage, and possibly others

2000-11-28 Thread Lalo Martins

On Tue, Nov 28, 2000 at 06:01:15PM -0800, Ender wrote:
 Lalo Martins wrote:
  
  Well, two betas of OracleStorage in one day, then a month and a
  half of silence. What's the status?
  
  What about the other Storage projects? BerkeleyStorage has been
  dead for an year, and I heard pretty nasty words about
  InterbaseStorage. What about someone who wanted to try to port
  OracleStorage to Postgres or some other RDBMS?
  
  Please help stamp out Data.fs! :-)
 
 i've been interested in doing a postgres storage, but i haven't been
 able to convince myself that it would be useful in practice at all. any
 suggestions?

Of course it would, for the same reasons as OracleStorage (eg
FileStorage/Data.fs is inefficient), plus PostgreSQL is free
and Oracle costs thousands of dollars. What's the doubt? :-)

[]s,
   |alo
   +
--
  Hack and Roll ( http://www.hackandroll.org )
The biggest site for whatever-it-is-that-we-are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Factory location and Add box pollution

2000-11-27 Thread Lalo Martins

Create all your ZClasses normally, and make projectfolder a
subclass of Folder. Then, move all the Factories (except the
projectfolderFactory) to inside the projectfolder ZClass. This
should do the same trick as LocalFactory.


On Mon, Nov 27, 2000 at 02:38:42PM +0100, Stefan H. Holek wrote:
 I want to create a folderish ZClass to contain all my
 project specific ZClasses. The idea is to only have them show up
 when inside my projectfolder. Just like the ZClass object only
 shows up inside a product's folder.
 
 Well, when I derive from OFS:Folder I do get all the global stuff, but
 _not_ my included ZClasses in the Add box. OTOH, deriving from
 ZClasses:ObjectManager gives me my ZClasses, but _not_ the global
 objects (DTML Methods, ...)
 
 Deriving from _both_ gives me the behavior of whichever was named first.
 
 I have seen the LocalFactory product, but this would force me to move
 the factories and constructors out of my ZClasses. Its very existance
 though might mean what I want is impossible :( 



[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] New release of HiperDom and ZUnit

2000-11-15 Thread Lalo Martins

I made releases of both HiperDom and ZUnit yesterday. (Yes,
yesterday, Tuesday. I just forgot to make the announcement. Duh.)

The big news is that HiperDom is fully ZUnit-tested (which
gives you an idea of its API if you check the source of
HiperDomTests.py) and some buglets were fixed in the process;
ZUnit benefited a lot from some practical use (writing the
tests for HiperDom) and is now a lot more usable.

You don't need ZUnit to run HiperDom, but if you want to run
the tests, you do need the newest release of ZUnit (plus PyUnit
on your Python path).

Also:

HiperDom represents the presentation layer. Python Methods are
the ideal logic layer. So we figured we'd want an object for
the data layer. Actually, the data layer usually resides on
ZClasses or Python classes, but we wanted to have a
"lightweight" data layer object, so we coded one up and
included it (for now) in the HiperDom Product. Try it out.
There's not a lot of documentation yet, but the addform tells
you most of what you want to know.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope-dev] License issues

2000-11-13 Thread Lalo Martins

On Mon, Nov 13, 2000 at 06:40:31PM +0100, Juan David Ibáñez Palomar wrote:
 
 has come to my ears that there's people who doesn't use Zope because
 its license is GPL-incompatible, more info here:
 
  http://www.fsf.org/philosophy/license-list.html#GPLIncompatibleLicenses

They say it's an instance of "the obnoxious advertising
clause". I tend to agree, this clause should be removed. All my
non-Zope software is GPLed, all my Zope software has a very
permissive X11-like license without the obnoxious adv. clause.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] OracleStorage, and possibly others

2000-11-13 Thread Lalo Martins

Well, two betas of OracleStorage in one day, then a month and a
half of silence. What's the status?

What about the other Storage projects? BerkeleyStorage has been
dead for an year, and I heard pretty nasty words about
InterbaseStorage. What about someone who wanted to try to port
OracleStorage to Postgres or some other RDBMS?

Please help stamp out Data.fs! :-)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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

2000-11-13 Thread Lalo Martins

On Mon, Nov 13, 2000 at 01:14:51PM +0100, Rik Hoekstra wrote:
 
 On the other hand: I did that, and Hiperdom would neither expand nor
 display, in both giving some xml Node exception. So in fact I thought it
 was still under construction. The 'patching' was on win32 and manual, so
 I probably did something wrong ;-(. However, in a python test setup the
 module did work (?)

Which version of the XML-utils are you using? Please send me
the traceback (privately), I'd like to see that.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] HiperDom

2000-11-13 Thread Lalo Martins

On Mon, Nov 13, 2000 at 10:03:06AM +, Chris Withers wrote:
 Lalo Martins wrote:
  
  HiperDom is usable right now; we've been quite quiet because
  we're working on documentation and unit testing (and to have
  unit testing, we had to have ZUnit).
 
  Right now, we would "raally" encourage you to use HiperDom
  in your project, specially if the deployment schedule = 2
  months, and then please send us that feedback :-)
 
 I'd love to, but it'd be 'raally' helpful to have some documentation
 and a download with some explanation/help for someone as brain dead as
 me on a Monday morning ;-)
 
 Is that available yet?

As I said, we're currently focusing on documentation and unit
testing; there is some quite basic documentation in the HelpSys
which explains the syntax, and there is an example in the
webpage at zope.org, plus one more (more or less the same
example, but with the text in Portuguese) in exemplo_pt.html in
the distribution.

Better documentation is in the works, you can check the
"Projects" wiki on dev.zope.org.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Status of HiperDom (Re: XML Document DTML's tree, HiperDOM)

2000-11-10 Thread Lalo Martins

On Fri, Nov 10, 2000 at 10:28:44AM +, Chris Withers wrote:
 
 Oh yeah, while I'm here, how's the HiperDOM project getting on? That
 stuff would be raally useful for a project here...

HiperDom is usable right now; we've been quite quiet because
we're working on documentation and unit testing (and to have
unit testing, we had to have ZUnit).

The low version number is because we're not very sure about the
syntax and we wanted feedback on it from the community.

However, that just isn't happening, and we're tempted to call
the results of documentation and testing 1.0, then after
feedback and possible syntax modifications work on a 2.0.

Right now, we would "raally" encourage you to use HiperDom
in your project, specially if the deployment schedule = 2
months, and then please send us that feedback :-)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] [Ann] ZUnit released

2000-11-01 Thread Lalo Martins

Okay, the cat is out of the bag (in fact, going to Rio for the
weekend) and the worms are out of the can (better worms than
bugs, anyway). ZUnit, the Product all lazy programmers were so
afraid of, is available for review and download from your usual
shop at http://www.zope.org/Members/lalo/ZUnit completely FREE,
from the hands of your friends Lalo and Hiperlógica!

In comemoration of the release, we're holding the "meta-testing
contest": Whoever contributes some unit tests for ZUnit itself,
will win her name in the credits, plus a better and more stable
Product in the future, and an exclusive Warm Fuzzy Feeling (TM)!

Don't miss this oportunity! Check it out right now!

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Streaming?

2000-10-29 Thread Lalo Martins

Is it possible to "stream" (send data to the client via HTTP
incrementally) from Python code, or does ZPublisher only send
the data as a single wad when the method returns?

Assuming it is possible, obviously it requires using some other
API rather than just 'return'ing a string... where can I find
documentation and/or examples on that? If there is no existing
documentation or examples, source code would do.

(Context: when the tests are running on ZUnit, I'd like to give
some visual feedback, if possible by sending the dots returning
by PyUnit in real-time)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Streaming?

2000-10-29 Thread Lalo Martins

On Mon, Oct 30, 2000 at 12:23:36PM +1100, Terry Kerr wrote:
 Isn't that dependant on the protocol u are using to transfer the data?
 HTTP can't do streaming.  You can sort of do streaming using the
 experimental multipart content type, but IE browers don't recognise it,
 so it is pretty useless.

What are you talking about? Try to load any standard html page
with a very slow connection. If you just send the data slowly,
the browser will show it as it is received. That's streaming.

You can point an mp3 or realaudio player at an URL and it will
download the file and play it as it arrives.

That's the kind of streaming I want to do.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Streaming?

2000-10-29 Thread Lalo Martins

On Mon, Oct 30, 2000 at 12:48:53PM +1100, Terry Kerr wrote:
 That is not streaming.  That is just as you said..lack of bandwidth delaying
 the entire page arriving at once at you browser.  That is not contolled.  The
 server doesn't send it 'bit by bit' in a controlled manner.

But if it did, the results would be exactly the same. Actually,
that's exactly what most people refer to when they say
"streaming".

This is getting way off-topic. I want to know if there is an
API for that, not to discuss the meaning of the word.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Unit testing, ZUnit - It is in the fishbowl, please comment

2000-10-26 Thread Lalo Martins

The proposal below is in the fishbowl, at
http://dev.zope.org/Wikis/DevSite/Proposals/UnitTestingProducts

The approach will be, developing the standalone ZUnit Product
while the proposal is in the fishbowl, then push for the
proposal (integrating it with App/Product*.py). Expect a first
release of ZUnit next week or in the other.

In the meanwhile, please comment in the proposal's discussion
page :-) (or here)


On Mon, Oct 23, 2000 at 10:56:31PM -0200, Lalo Martins wrote:
 We (I and Hiperlógica) started to develop a Product we called
 ZUnit, intended for XP-style unit-testing Python-based
 Products in a full Zope environment (with a real ZODB, REQUEST,
 RESPONSE, etc).
 
 We first conceived it as a kind of Zope-based version of
 unittestgui.py - you create a "TestRunner" object giving it the
 package, module and name of a TestSuite object generator (see
 the PyUnit documentation) and inside it you may click on some
 widget to run the tests and produce a "TestResult" object which
 you can inspect later. Does this sound like a good design?
 
 Then I figured in the long run a Product isn't the best
 sollution; instead, fiddling with App/Product* sounds more like
 it, to allow developers to register tests just like they
 register classes, ZClass superclasses, _misc and help. Of
 course, just like the current registerHelp and others, it
 wouldn't be mandatory and not using it wouldn't break anything.
 
 Then, in the Product's page in the Control Panel, there would
 be a tab "Test", where you'd be allowed to run the unit tests.
 
 What do people think of this? What does DC think of this? Can I
 go ahead and develop it in this direction?



[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Unit testing, ZUnit

2000-10-23 Thread Lalo Martins

We (I and Hiperlógica) started to develop a Product we called
ZUnit, intended for XP-style unit-testing Python-based
Products in a full Zope environment (with a real ZODB, REQUEST,
RESPONSE, etc).

We first conceived it as a kind of Zope-based version of
unittestgui.py - you create a "TestRunner" object giving it the
package, module and name of a TestSuite object generator (see
the PyUnit documentation) and inside it you may click on some
widget to run the tests and produce a "TestResult" object which
you can inspect later. Does this sound like a good design?

Then I figured in the long run a Product isn't the best
sollution; instead, fiddling with App/Product* sounds more like
it, to allow developers to register tests just like they
register classes, ZClass superclasses, _misc and help. Of
course, just like the current registerHelp and others, it
wouldn't be mandatory and not using it wouldn't break anything.

Then, in the Product's page in the Control Panel, there would
be a tab "Test", where you'd be allowed to run the unit tests.

What do people think of this? What does DC think of this? Can I
go ahead and develop it in this direction?

(I will create a proposal in dev.zope.org, but I want to get
some feedback here first to flesh out the proposal a little
more.)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Namespace within a product... (argh...)

2000-10-10 Thread Lalo Martins

On Tue, Oct 10, 2000 at 11:56:11AM +0200, Pierre-Julien Grizel wrote:
 
 So - I had a look at DTMLDocument.py and saw the following method :
 
 def __call__ (self, client = None, REQUEST = {}, **kw):
   ...
 
 SO - I try to create this method for my product :
 
 def __call__ (self, client = None, REQUEST = {}, **kw):
   print client
   print REQUEST
 
 
 and it prints :
 None
 {}
 
 
 It seems that in fact the DTML document doesn't actually pass _.None and
 _ to my object. WHY ??

Evan already answered, but the short story is:

your object needs to have an attribute (it may be a class
attribute and usually is) named "isDocTemp", and this attribute
must evaluate to true. Otherwise, your object is called with no
parameters.

The relevant code is:

if hasattr(v,'isDocTemp') and v.isDocTemp:
v=v(None, self)
else:
try: v=v()
except (AttributeError,TypeError): pass

(from DocumentTemplate/DT_Util.py:277)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope-dev] Strange Error - in collector yet?

2000-10-07 Thread Lalo Martins

On Thu, Oct 05, 2000 at 10:01:15AM +0100, Chris Withers wrote:
 Lalo Martins wrote:
  
  This is on Zope 2.2.1. I'd really appreciate some clues on how
  to bust these ghosts.
 
 Have you put a full description in the bug collector yet?

Now it is. It was assigned number 1676.

I also busted my ghosts - by manually manipulating the ZODB via
Python. Felt kind like a brain surgery - on myself, using a
paperclip, a pencil and a pocket mirror. But it worked.

(To the tune of the Ghostbusters Theme by Ray Parker Jr.)

"An invisible ZClass sleeping in your bed? Who you're gonna
call? Py-thon!"

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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

2000-10-04 Thread Lalo Martins

For the third time, I have a similar problem. I deleted a
ZClass-based Product, but the objects of those ZClasses still
work - except for not having an icon or constructor, so I'm not
able to create or cut/copy/paste them.

Then, when I tried to import the newer version of the Product,
Zope gave me "Duplicate class Id", which means the old classes
still exist somewhere in its Dream realm.

This is on Zope 2.2.1. I'd really appreciate some clues on how
to bust these ghosts.

On Wed, Oct 04, 2000 at 06:51:21PM +0200, Roch'e Compaan wrote:
 I am getting really funny problems with my Zope installation and I have no
 idea where to start looking.
 
 I for instance deleted a python product from the Products directory and when
 I start Zope the product is still listed in the Product list.  I then packed
 the ZODB, cleared my Browser's cache, and refreshed the Product List but
 still the product is visible.  I can however delete the python product
 (which is by the way not in my Products directory) from the Control Panel.
 
 Somewhere something is cached and I don't know where.  It seems to cache
 errors as well and they stick.  A reinstallation fixed this problem, but now
 it seems more fundamental.  I've come accross this odd caching behaviour
 again after reinstall and can't reinstall every time this happens.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] HiperDom 0.1 is out

2000-10-02 Thread Lalo Martins

We released HiperDom 0.1 Saturday (this message is dated Monday
because it's when the objects got cataloged).

This version is Python-based, fully functional to the last
letter of the spec (except for hdom:method where we cleaned up
the interface a bit), fully HelpSys'ed, heck, it even has an
icon.

Oh, it has an undocumented feature too. Actually lots of 'em;
I have to write about manage_getTemplate somewhere for the next
version... but what I'm talking about right now is the hdom:id
directive used for creating "assets" like we discussed
previously in the "HiperDOM and xmlc" thread.

When you expand a section marked with hdom:text, before
discarding the contents, the engine hunts for elements marked
with hdom:id in it. Those found are added to the namespace.

...
p hdom:text="greeting"This paragraph will be replaced by a
greeting to span hdom:id="person"Lalo/span and span
hdom:id="company"Hiperlógica/span./p
...

The method "greeting" will be executed with a namespace as **kw
(I don't know how flexible is this, but it's how DTML does it).
In this namespace there will be at least
{'person': 'spanLalo/span', 'company': 'spanHiperlógica/span'}.

This feature isn't documented on purpose, since this subject is
far from settled and it is very possible that this isn't the
best sollution. But it's _a_ sollution and it's there to be
tested - "running code" :-)


We'll be away from this code for about two weeks, as we have an
urgent job to deliver to a big customer whose identity is so
ironic that I'll have to tell you folks as soon as I'm sure I'm
allowed to.

Anyway, I'd like everyone interested to try it out in this
meantime, send us your feedback, and discuss it here and/or on
the HiperDomWiki. I'll have an eye (and a few fingers) on this
discussion.

Thank you for your time, have a nice day. :-)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Fw: [cms-list] eMedicine, Inc. Receives Patent for Internet Publishing Software

2000-10-02 Thread Lalo Martins

On Mon, Oct 02, 2000 at 10:14:41PM -0500, Tim Cook wrote:
 "Dario Lopez-Kästen" wrote:
  
  as seen on cms list. Would this affect Zope in any way?
 
 Standard IANAL disclaimer. But, I read the patent. It looks like
 Zope is okay. You just can't build an application on it (or
 anything else where multiple people edit the same document
 online). Watch ZWiki

So wouldn't the original WikiWikiWeb be prior art?

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] ZPL HowTo?

2000-09-29 Thread Lalo Martins

We wished to release the new development version of HiperDom
under the ZPL, but we figured it wouldn't be that simple, as
the license text is all littered with "Digital Creations".

Is it just a matter of s/Digital Creations/Hiperlógica/g? Is
this even legal?

(This message is mostly rethorical, because we already decided
to just release it under the MIT-X11 license anyway, but I feel
this question should be discussed if people want to release
stuff under the ZPL in the future.)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Import Problems

2000-09-19 Thread Lalo Martins

On Tue, Sep 19, 2000 at 11:19:22AM -0600, Joshua Brauer wrote:

 Here's another try at getting this question addressed I
 have 2 Zope installs. On the newer one (2.2.1) when I try to
 import KM Net News (to install in the products list) I get the
 following error. Note I previously deleted KM Net News (the
 earlier version) but think that Zope might have gotten killed
 right in the middle of the delete and not completely deleted
 the product.
...
 Duplicate Class Ids: (see above)

This looks like the "floating ZClasses" problem I have with
2.2.1... when I installed it, BannerFolder was broken for some
reason, then I deleted it and when I tried to install the new
one I had the same exception you did (Duplicate Class Ids).

The weirdest part is that BannerFolder is now _working_
(without its Product). Please check your installation and see
if the old version of KM|Net still works (you won't be able to
create new objects, so you have to have old ones around to make
this test).

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope-dev] HiperDOM xmlc

2000-09-18 Thread Lalo Martins

On Mon, Sep 18, 2000 at 03:12:14PM -0400, Shane Hathaway wrote:
 [EMAIL PROTECTED] wrote:
   So the standard_page_template default wrapping is an attempt at a
   compromise.
  
  It's wrong.
 
 Please elaborate your position. :-)
 
 Why is it wrong?

Because, as we said, the HiperDOM/xHTMLTemplate template is
already a "view", already part of the presentation layer. The
standard_page_template default wrapping is an attempt to
conjure a new "meta-presentation" layer out of nothing.

It solves a problem but creates more, because most people will
_not_ want the wrappers at all. Wrappers re-create the infamous
"source vs. rendered issue" and there's no easy way out of
that; they may be an useful functionality, but they're an UI
nightmare.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] User objects on 2.2

2000-09-18 Thread Lalo Martins

On Sun, Sep 17, 2000 at 11:22:49PM -0300, Lalo Martins wrote:
 Why doesn't Anonymous have permission to call has_permission on
 itself? This is counter-intuitive to say the least...

Ooops... they have, kind of. The Anonymous user object inherits
the permissions from the top-level User Folder (/acl_users).
This is kind of weird and should be documented, but is usable.

(So, to allow Anonymous to call has_permission on itself you
have to enable "Access content information" for Anonymous on
/acl_users)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] CatalogAwareness is broken on 2.2

2000-09-18 Thread Lalo Martins

On Mon, Sep 18, 2000 at 10:47:35PM -0300, Lalo Martins wrote:
 CatalogAwareness in 2.2.x doesn't follow the new ZCatalog
 traversal standard - it uses absolute_url() to get the url it
 will give to the ZCatalog, and ZCatalog now wants an absolute
 (non-virtual) path. In practice, this means CatalogAware stuff
 won't work in conjunction with SiteAccess-based virtual
 hosting.

Just occurred to me to check the Collector; this is bug 1580
there. I sent a one-line patch (which will appear as 1629 if I
did everything right); I don't know if it's 100% right, but it
Works For Me (TM) ;-)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar


--- Products/ZCatalog/CatalogAwareness.py.orig  Thu Aug 24 11:09:21 2000
+++ Products/ZCatalog/CatalogAwareness.py   Mon Sep 18 23:07:18 2000
@@ -154,7 +154,7 @@
 if hasattr(self, 'DestinationURL') and \
callable(self.DestinationURL):
 url='%s/%s' % (self.DestinationURL(), self.id)
-else: url=self.absolute_url()
+else: url=string.join(self.getPhysicalPath(), '/')
 type, uri=ftype(url)
 host, uri=fhost(uri)
 script_name=self.REQUEST['SCRIPT_NAME']



Re: [Zope-dev] HiperDOM xmlc

2000-09-17 Thread Lalo Martins

On Sun, Sep 17, 2000 at 12:42:00PM -0400, Paul Everitt wrote:
 [EMAIL PROTECTED] wrote:
  BTW, please don't call the solution "xHTML Template"; it's not
  xHTML, it's generic XML - it can easily be used for RSS or WML
  or MathML or NewsML for example.
 
 While it *can* be used that way (just as DTML can be used to send mail
 messages), that's not the real intent of this proposal nor is that the
 real audience.  Our proposal it focused on letting HTML-oriented people
 with HTML-oriented tools create compliant stuff for the presentation
 job.

Why? WML-oriented people with WML-oriented tools would benefit
from it just as much, for example. (Are there WML-oriented
tools already?)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] HiperDOM xmlc

2000-09-17 Thread Lalo Martins

On Sun, Sep 17, 2000 at 04:07:18PM -0400, Shane Hathaway wrote:
 
  One sollution that could possibly work:
  (snip)
 
 We think alike.  A few of us tried to present this very solution (with a
 different spelling) to several people here at DC.  They found it quite
 confusing.  I honestly don't know why. :-/

Tell them that "It is confusing" without a reason doesn't help
us come up with a better sollution :-)

 But assuming someone can properly document this without making heads
 hurt and without sounding alarms in the minds of OO folks, maybe the
 right solution is an optional attribute on the opening tag that
 specifies the wrapping template.  If not specified, it would default to
 "standard_page_template".

Nonono. If the attribute is not specified, the page is a
standalone template and is not wrapped at all. This is important.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] HiperDOM xmlc

2000-09-17 Thread Lalo Martins

On Sun, Sep 17, 2000 at 03:51:35PM -0400, Shane Hathaway wrote:
 [EMAIL PROTECTED] wrote:
  
  Why? WML-oriented people with WML-oriented tools would benefit
  from it just as much, for example. (Are there WML-oriented
  tools already?)
 
 What Paul is saying is that we need to make it work for XHTML first.  It
 makes it easier to talk about with those less familiar with XML
 (especially XML namespaces.)  Then with a very small amount of work we
 can expand it to all XML schemas.

I can see how this makes sense as a strategy, but technically
it just doesn't... we're not using any features specific to
xHTML, and by all means we shouldn't. So, the way it is today
it already works with any XML schema.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] User objects on 2.2

2000-09-17 Thread Lalo Martins

Why doesn't Anonymous have permission to call has_permission on
itself? This is counter-intuitive to say the least...

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Bizarre bug - floating ZClasses

2000-09-17 Thread Lalo Martins

I finally went to upgrade our production machine (the one which
runs cosmetica.com.br and hackandroll.org) to Zope 2.2.

When I did (and after upgrading SiteAccess and updating its
objects with the provided script), BannerFolders and BannerAds
stopped working.

So, I went to the Control Panel and deleted the product, to
install the newer version. Before that, Zope was restarted, and
suddenly the Banner objects started functioning normally - with
their Product missing!

On top of that, I tried to install the Product and it gives me
a "Duplicate Class Ids" error...

It's been a while since I've been so puzzled and impressed by a
bug :-)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope-dev] HiperDOM xmlc

2000-09-15 Thread Lalo Martins

On Fri, Sep 15, 2000 at 08:21:21AM -0400, Paul Everitt wrote:
 
 I'm surprised that no one responded to this.  (Or maybe people did and
 our continual email server problems have lost it.)

Me too.

 I'd like to congratulate Hiperlogica, because they have (ding ding ding)
 the _right answer_! :^)

Thank you :-) We feel good about this answer too.

 Seriously, we at Digital Creations have been quietly formulating a
 proposal on this since Amos put up the template proposal in
 dev.zope.org.  I floated some trial balloons at EuroZope and it's clear
 there's some consensus.

Glad to know that.

 Our "XHTML Templates Proposal" is at:
 
   http://dev.zope.org/Wikis/DevSite/Proposals/XHTMLTemplatesProposal

It is not linked on the Proposals FrontPage...

--

Anyway, at least for HiperDOM I feel comfortable with the word
"template" because that's what it is about. The two primary
motivations for the design are:

* You can create the layout with any XML-compliant editor; if
the template is xHTML, you can use a XHTML-compliant WYSIWYG
tool. Or, thanks to the modern XML technology, you can use a
WYSIWYG HTML tool and pass it trough a SGML-XML filter to get
xHTML.

  Using specialized webdesigners with Zope project has been one
of the biggest pains in Zope development; we have to take the
sometimes ugly code generated by the tools they use, usually
clean it up, then insert the DTML tags in it. Making changes to
the design is a nightmare.

* The template looks like the rendered page; if you don't want
to fire up Zope, or if the application logic is not yet
finished, you can preview the layout by simply loading the
template in a browser.

These goals are similar, but not identical to the ones in the
proposal. Still, some parts of the proposal felt like extracted
rigth out of my mind :-)

I don't feel good about calling the layers "document" and
"view" or "presentation" and "data" because the "view" is not
strictly presentation code; invariant (static) parts shared by
all pages rendered with that template can be in the template.
As much as we all like to talk about "Web Applications", this
is not exactly like "normal" application design, where you can
draw a clear line between presentation and data (or model/view).

--

The only thing I _don't_ feel good about this kind of template
is that, in practice, we will probably lose the benefits of
things like dtml-var standard_html_header - meaning, when you
want to change the header of your site, you'll have to edit all
your templates.

Of course a site where this is a problem still _can_ use
"includes" like standard_html_header, but I believe most won't.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] HiperDOM xmlc

2000-09-15 Thread Lalo Martins

On Fri, Sep 15, 2000 at 03:17:00PM -0400, Shane Hathaway wrote:
 [EMAIL PROTECTED] wrote:
  The only thing I _don't_ feel good about this kind of template
  is that, in practice, we will probably lose the benefits of
  things like dtml-var standard_html_header - meaning, when you
  want to change the header of your site, you'll have to edit all
  your templates.
 
 I agree this is a problem, and speaking from experience, changing all
 templates is not an acceptable compromise.  For www.zope.org that would
 mean including the standard template in nearly every page, everywhere,
 because the pages on www.zope.org are nearly all "templates"
 themselves.  We would lose one of the primary benefits of Zope.

But using external fragments ("includes") is not a natural idea
for web designers. One of the main points of this fuss is to
allow them to create the templates in something like Dreamweaver.

 Another unacceptable compromise is including a variant of
 standard_html_header and _footer on every page (as is done now).  One
 reason is because it is not possible to write
 standard_html_header/_footer using well-formed XML.  The header begins
 the "html" tag, while the footer ends it.  In fact, most sites these
 days put the beginning of a table in _header and the end of the table in
 _footer.  Objects containing non-well-formed XML aren't compatible with
 a DOM-based solution.

I hadn't thought of this.

Of course you can already use "includes" which are valid XML,
such as a single row or cell of a table (for example, the
navbar of a complex site).

 This has been one of the points of discussion here at DC.  The only
 reasonable solution we've come up with is automatically wrapping the
 results of the rendering in an acquired object with a fixed name such as
 standard_page_template.

I don't like fixed names :-) what if I don't want to wrap a
particular template?

One sollution that could possibly work:

HiperDOMDocument at /foo/bar/somepage:

html hdom:wrapper="site_template"head
titleThis will be overridden by the wrapper template/title
/headbody
This will not appear in the document.
div hdom:id="someVariableName"
This will appear in the document.
/div
/body
/html



HiperDOMDocument at /site_template:

htmlhead
title hdom:text="title"Document title goes here via
aquisition/title
link rel=stylesheet href="http://yoursite.com/site_css"
type="text/css"/
/head
body bgcolor="white"
table border="0" cellpadding="0" cellspacing="0"
tr
td bgcolor="#6699cc" hdom:text="navbar"
  Here goes the site navbar, which can be replaced by a
  subsite-specific navbar thanks to aquisition/td
td hdom:text="someVariableName"
  Here goes the actual body of the template, acquired from the
  calling (wrapped) template via the hdom:id attribute/td
/tr
/table
/body
/html



To add even more sugar, there could be a button in the
management interface of the "somepage" document to
automagically merge it with the (current) wrapper so that it
reads:

html hdom:wrapper="site_template"head
title hdom:text="title"Document title goes here via
aquisition/title
link rel=stylesheet href="http://yoursite.com/site_css"
type="text/css"/
/head
body bgcolor="white"
table border="0" cellpadding="0" cellspacing="0"
tr
td bgcolor="#6699cc" hdom:text="navbar"
  Here goes the site navbar, which can be replaced by a
  subsite-specific navbar thanks to aquisition/td
td hdom:text="someVariableName" hdom:id="someVariableName"
This will appear in the document.
/td
/tr
/table
/body
/html

This would make the Dreamweaver freaks happy, I think.


BTW, please don't call the solution "xHTML Template"; it's not
xHTML, it's generic XML - it can easily be used for RSS or WML
or MathML or NewsML for example.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] And now for a good laugh (Re: [Zope] Zope and the GPL poison pill)

2000-09-14 Thread Lalo Martins

On Thu, Sep 14, 2000 at 10:23:21AM +0200, Nils Kassube wrote:
 [EMAIL PROTECTED] (Lalo Martins) wrote:
 
  Renderable wasn't even GPL'ed to begin with. And this isn't a
  mistake; now that I think if it, I clearly remember having
  chosen the ZPL so that DC folks could easily take the changes
  and merge them into Zope if they wished.
 
 My copy of Renderable ZClass 0.2 says:
 
 # Copyright (C) 1999 by Lalo Martins
 # Distributed under the terms of the GNU GPL, version 2 or later

Ah, thanks. Now _that_ is a mistake. Habit is a powerful thing
:-)

I'll make a new release (it's been stable for almost an year,
so I'll add some documentation and call it a beta), but in the
meanwhile consider it ZPL'ed; the license in the site is the
correct one.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] HiperDOM xmlc

2000-09-13 Thread Lalo Martins

We (I and Hiperlogica, a company I consult with) have been
developing a template renderer with similar intent to xmlc
(be based on XML/DOM, allow the template to be previewed and
edited using tools not aware of the format, such as xHTML
editors, and enforce presentation/logic separation).

As the project is somewhat on hold while we have more pressing
issues, I decided to share the current (rather kludgy)
prototype with the community. It is at
http://www.zope.org/Members/lalo/HiperDOM/

On Mon, Sep 11, 2000 at 02:06:08PM +, Jason Spisak wrote:
 Zope Devers,
 
 THis is going to seem strange coming from someone who hasn't been on the
 list in a long time, but I was at the Linux Expo in San Jose, and sat in on
 a Web app talk.  Lutris was in charge of the panel, and they talked about
 xmlc.  I went to their booth and asked about it. I think it could be the
 best way to get hard-core python people to jump on zope's band-wagon, and
 stop the dtml frowning.
 
 If you who are in the know about zope have time, please read a quick bit on
 what it is.
 
 http://xmlc.enhydra.org
 
 Especially the tutorial:
 
 http://staff.plugged.net.au/dwood/xmlc/index.html
 
 Is there any obvious reason why Zope wouldn't benefit tremendously from
 this design and programming separation and pure python boost?

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] And now for a good laugh (Re: [Zope] Zope and the GPL poison pill)

2000-09-13 Thread Lalo Martins

I replied to the message below promising to edit Renderable's
README to explicitly declare that I don't consider ZClass
subclassing to be a derivative work for the purposes of the
GPL.

Somehow, I didn't get my reply from the list. But never mind.

I went to my folder on Zope.org to edit the README and, surprise!

  License: ZPL

Renderable wasn't even GPL'ed to begin with. And this isn't a
mistake; now that I think if it, I clearly remember having
chosen the ZPL so that DC folks could easily take the changes
and merge them into Zope if they wished.

I don't know about you, but after this thread has degenerated
into a wholesale flamewar, I find this fact rather amusing.


On Tue, Sep 12, 2000 at 03:30:16PM +0200, Nils Kassube wrote:
 
 but the use of GPL'ed source code like e.g. Renderable ZClass
 in your web site probably means that you're now forced to publish
 every single bit of source built using the GPL'ed module --
 including commercial intranet projects. This can be impossible
 if you don't own the rights to every single piece of code used
 in a project. 

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] Zope and the GPL poison pill

2000-09-12 Thread Lalo Martins

On Tue, Sep 12, 2000 at 06:02:15PM +0200, Nils Kassube wrote:
 [EMAIL PROTECTED] (Oleg Broytmann) wrote:
 
 No, you are not forced to publish anything. GPL "virus" applied only if
  you want to *distribute* combined (your code + my GPL'd code).
 
 Like in "distributing to clients"? So that I have to publish
 source code to the whole world (not only clients) then? 

No. If you give binaries to someone, you have to also give
sources. You're not obliged to give the binaries to anyone. You
can charge big bucks for the binaries, but if someone has them
they're free to redistribute it.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] How to update DTML built from Python level?

2000-06-29 Thread Lalo Martins

Well, I edited the file I mention below (documentEdit.dtml) and
my changes aren't taking effect, no matter what (either on
2.2b3 and 2.1.6).


(Reason: if Mozilla sees textarea inside a td align=center,
the text inside the textarea is centered in the textarea, which
makes things quite unpalatable to work with. ;-) As Mozilla is
already a lot nicer to work with Zope, I'm willing to use this
temporary workaround for a while...)


On Wed, Jun 28, 2000 at 04:48:38PM -0700, Andy McKay wrote:
 Restarting will work (although it is not technically necessary for .dtml).
 Perhaps there is another reason...
 
  If I, for example, edit .../lib/python/OFS/documentEdit.dtml,
  what kind of black magic do I have to do to make my changes
  take effect? I'd think it is only a matter of restarting Zope,
  but that doesn't work :-/

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] ZODB or not ZODB?

2000-06-28 Thread Lalo Martins

On Wed, Jun 28, 2000 at 10:07:25AM -0400, Jim Fulton wrote:
 Casey Duncan wrote:
  
  Is ZODB up to the task of storing this quantity of objects? What problems
  might I run into? Is it a wise idea, could a data.fs file of this size
  (~3-400MB) become too easily corrupted?
 
 No. Zope.Org varies from 300MB to close to 2GB.

What about adding a box somewhere in zope.org telling us the
current size of the ZODB and perhaps some other stats (dunno,
RAM, number of processes)?

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] How to update DTML built from Python level?

2000-06-28 Thread Lalo Martins

If I, for example, edit .../lib/python/OFS/documentEdit.dtml,
what kind of black magic do I have to do to make my changes
take effect? I'd think it is only a matter of restarting Zope,
but that doesn't work :-/

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] Re: [Zope-Moz] mozilla and zope play nicely again!

2000-06-28 Thread Lalo Martins

On Wed, Jun 28, 2000 at 10:40:53AM +0200, Martijn Pieters wrote:
 On Wed, Jun 28, 2000 at 06:31:36PM +1000, Anthony Baxter wrote:
  
  *grumble* I'm sure I saw a post to slashdot saying M17 was out...
  yep, I did, 
  http://slashdot.org/article.pl?sid=00/06/26/1655250mode=nested
  
  "net of a million lies", indeed.
 
 Slashdot has the journalistic integrity of a cod fish. One of the replies on
 the page scolds the writer for _another_ mistake about this. Personally, I
 have given up on slashdot.

That's the kind of situation from which HackRoll was conceived
:-)

(Ok, that's half the reason... the more important half is that
it lost contact with Free Software philosophy - with both
articles about proprietary software that don't mean a thing for
a Free-Software-head, and clueless "you spoiled commie kids"
comments moderated up to the skies, but that's rather off-topic
here and now...)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Re: [Zope] :xxx syntax (was: HTML Editors that recognize DTML)

2000-06-27 Thread Lalo Martins

On Fri, Jun 23, 2000 at 07:49:21PM -0400, Jon Franz wrote:
 
 Also, its not XML compliant either, but I have a shorter dtml syntax patch
 available for download at:
 
 http://www.zope.org/Members/Coventry/dtml_shortcut
 
 it is a really small patch, and just allows : to replace dtml- or !--#
 inside your documents, such as in the snippet below:
 
 :var foo
 :if expr="la=lala"
 So you think la and lala are the same!?
 :else
 Ah, so you see a diffrence!
 /:if

I like this syntax; I'm in favour of adding it to a future
version of Zope (2.2.1?).

Except that your patch says it's GPLed, and GPL code cannot be
added to a ZPL product; please re-release as ZPL (I'm all in
favour of GPL, but this is not a good case for it :-) )

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Zope 2.2.0b2 - Undo

2000-06-24 Thread Lalo Martins

On Sat, Jun 24, 2000 at 11:18:27AM +, Oleg Broytmann wrote:
 Hi!
 
Do I understand it right, that on every object Undo displays only those
 action that applied to that object? And all Undo action are listed only in
 root? (that's looks pretty good for me!)

The way I see it, each Folder's Undo tab displays all actions
from there below, for which the current user has permission to
undo. (So still the root folder's Undo tab displays _all_
actions, assuming the current user has all permissions.)

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope-dev] Basic LoginManager HowTo

2000-06-02 Thread Lalo Martins

On Fri, Jun 02, 2000 at 07:29:18PM -0600, Bill Anderson wrote:
 Has anyone out there actually sarted _using_ LoginManager with ZODB
 storage? IOW, one that is not dependant on LDAP/SQL/etc., but that is
 functioning in place of a non-PTK acl_users folder? 

I tried. It's quite easy, except that you have to store the
user's password in a property, and access control is somewhat
broken WRT passwords, so anyone can read anyone's passwords if
they can write DTML.

Now I don't plan to just let anyone write DTML, but I don't
want to leave this hole open because I know I will forget it
sooner or later and open up an exploit.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
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] Proposal for mail-in to Zope

2000-05-31 Thread Lalo Martins

On Wed, May 31, 2000 at 04:54:24PM +0100, Simon Coles wrote:
 
 The problem we are trying to solve is basically being to email 
 "[EMAIL PROTECTED]" and that email ends up in the Zope ZODB 
 processed in whatever way is appropriate.

I've been thinking about this too, reached more or less the
same conclusions, and decided not to work on it because I'm
already lame enought on keeping up with the hundreds of stuff I
_am_ working on :-) Anyway:


 Most MTAs can be setup to pass an email to the stdin of a program. 
 Sendmail will do this, and Exim (http://www.exim.org/) will also pay 
 attention to what that program returns and queue the message for 
 re-try later if it fails. So using Exim, we don't have to get into 
 any messy stuff about queuing mails if the Zope server is down.

This is probably the best solution, but don't forget virtual
hosting: the method for deciding which method to call should
include the whole address (not only the username) and turn up
something similar to the rules used by zmailer or qmail.

The problem here is that most MTAs don't pass the whole
envelope address to such a "piped" program. As zmailer is
mostly scripted, I figured it would probably be the best/easier
solution, check it out. (Plus, it starts with Z ;-) hehehe)


 Some alternatives we considered and didn't go for:
   - write something in Zope to listen for SMTP connections, effectively
 large portions of an MTA. This would be cool but painful.

Agreed on both cool and painful. Perhaps the best solution in
the long run, but we need a ZODB more friendly to high-writing
first, I think.


   - pull mail from a POP or IMAP server. This had the downside that it
 introduced polling into the system (slow) and also required something
 to happen on a schedule, which doesn't happen in Zope yet.

I don't see advantages to this approach.


   - This program takes the email message and puts it into Zope, probably
 by calling a DTML Method or something. This would probably be
 configured by objects in the Zope ZODB which say effectively "When
 you get email for this address, then call this Method".

You don't even have to know what kind of method it is, and in
theory it doesn't have to be in the same server even. For each
mail address (or domain, in case of fallbacks, if you want to
implement that) you assign an URL, username and perhaps
password, and submit the message via POST somehow.

This tool would end up so easy to write (in principle) and
generic that it wouldn't even be tied to Zope. (Yes, you could
use ZPublisher.Client or XML-RPC or something more
Zope-specific - but why? What would you gain by that?)


 We haven't yet figured out how to make sure the above mail handling 
 program can find all the relevant configuration documents. Is there 
 some way of efficiently finding all instances of a particular ZClass?

There is a Design Pattern covering this. Essentially, the class
registers all instances somewhere when they're built - you can
do that in the constructor.

But there are two different things here... either you store the
configuration outside the ZODB and send to a different method
depending on this configuration, _or_ you send everything to a
single method and use a configuration in the ZODB to forward
the message to the correct handling method. Mixing the
approachs is not a good idea IMHO.


[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] Use of lambda expression in DTML

2000-05-30 Thread Lalo Martins

On Tue, May 30, 2000 at 10:28:42PM +0200, you wrote:
 Minor note:
 
   "lambda" is not a builtin but part of the syntax (a keyword).
   I am sure, they will work in expressions.

Uh. Of course that is correct.

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] Use of lambda expression in DTML

2000-05-29 Thread Lalo Martins

On Fri, May 26, 2000 at 03:05:14PM -0700, Jonothan Farr wrote:
  In brief: I get a NameError when invoking "filter(...)" from DTML.  I thought
  this was a built-in python method, so I'm a bit puzzled.
 
 Certain built-ins are not available in dtml for security and other reasons,
 filter and lambda are among them. As far as I know, you'll need to use an
 external method to do this or think of another way to do it in dtml.

One big question is: what's wrong with filter, map and lambda?
They can make a lot of code a lot simpler, specially for people
who have a background in functional programming.

IIRC there is nothing wrong with them - only that all builtins
were disabled and some specific few were re-enabled, and then
those three were overlooked.

Count one vote for getting them back (_.lambda, _.filter, _.map
is fine enough, of course).

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] ANN: Perl For Zope

2000-05-29 Thread Lalo Martins

I'd happilly pay a few hundred bucks to be able to use Scheme
(more specifically Guile with GOOPS and perhaps CMH could use
this as an excuse to get finished).

[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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




Re: [Zope] Use of lambda expression in DTML

2000-05-29 Thread Lalo Martins

On Mon, May 29, 2000 at 09:40:59PM +0200, Martijn Pieters wrote:
 
 I can't comment with authority on why these methods are not accessible, but I
 imagine that they are banned because they'll probably let you lock up Zope in
 one way or another, creating a convenient denial-of-service attack.

If someone can edit arbitrary DTML, there are already easier
ways to cause infinite loops. And these loops don't lock up
Zope, they only eventually raise an exception (granted,
consuming lots of resources in the proccess).

 What I would like to say is that if your application needs lambda, filter or
 map, your code is getting bejond report or presentation generation (for which
 DTML is intended) and in the realm of data manipulation and business rules. In
 this case your code would be much better placed in some form of Method object,
 be that an External, Python, or when ready, Perl Method, or even as a disk
 based Product.

1: This is simply not true, and a very poor excuse for
handicapping the language.

A common example is:

dtml-in "_.map (lambda item: Catalog.getobject (item.data_record_id_),
Catalog (REQUEST)"


I know fetching the actual records from a ZCatalog introduces a
performance penalty, but sometimes it's necessary; there are
times you need to be absolutely sure everything is pushed on
the namespace, including user-defined properties and
sub-objects. This is the case in HackRoll, and I have to use a
very ugly Python Method there (and as PythonMethods don't have
map either, I have to build a list from scratch using for,
which introduces additional penalties as I'm basically
bypassing Python's optimizations).

And _.filter can be a mini-catalog:

dtml-in "_.filter (lambda item: AUTHENTICATED_USER.has_permission ('some_permission', 
item),
objectValues (['Folder'])"


2: If I should be using a Python Method, then Python Methods
should have these forms, and they don't.


3: In short, these excuses are just the fallback (or should I
say Acquired?) excuses used mostly by people who don't know how
to use these very cool features of Python.


[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

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