Re: [Zope-dev] SVN: z3c.pt/trunk/TODO.txt

2008-09-10 Thread Martijn Faassen
Malthe Borch wrote:
> 2008/9/9 Philipp von Weitershausen <[EMAIL PROTECTED]>:
 +- Make e.g.  and 
 etc.
 +  work
>>> Are we sure we want this? It's (afaik) not correct XML;
>> It's not? How so?
> 
> If the element belongs to some namespace, then attributes from this
> namespace should be native to it. But I couldn't find any
> documentation to support that this is a strict requirement. Perhaps it
> should be allowed, then.

As far as I know in XML, attributes without an explicit namespace prefix 
are not in any namespace at all. Default namespaces don't apply to 
attributes.

ZPT seems to have a different interpretation, perhaps. Though in the end 
the processor determines what to do with attributes, of course. It's 
just that XML processors shouldn't place an attribute into a namespace 
unless there is an explicit prefix.

Regards,

Martijn

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] Zope Tests: 5 OK

2008-09-10 Thread Zope Tests Summarizer
Summary of messages to the zope-tests list.
Period Tue Sep  9 11:00:00 2008 UTC to Wed Sep 10 11:00:00 2008 UTC.
There were 5 messages: 5 from Zope Tests.


Tests passed OK
---

Subject: OK : Zope-2.8 Python-2.3.6 : Linux
From: Zope Tests
Date: Tue Sep  9 20:53:04 EDT 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-September/010140.html

Subject: OK : Zope-2.9 Python-2.4.4 : Linux
From: Zope Tests
Date: Tue Sep  9 20:54:35 EDT 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-September/010141.html

Subject: OK : Zope-2.10 Python-2.4.4 : Linux
From: Zope Tests
Date: Tue Sep  9 20:56:05 EDT 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-September/010142.html

Subject: OK : Zope-2.11 Python-2.4.4 : Linux
From: Zope Tests
Date: Tue Sep  9 20:57:35 EDT 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-September/010143.html

Subject: OK : Zope-trunk Python-2.4.4 : Linux
From: Zope Tests
Date: Tue Sep  9 20:59:05 EDT 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-September/010144.html

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] SVN: z3c.pt/trunk/TODO.txt

2008-09-10 Thread Laurence Rowe
Martijn Faassen wrote:
> Malthe Borch wrote:
>> 2008/9/9 Philipp von Weitershausen <[EMAIL PROTECTED]>:
> +- Make e.g.  and 
> etc.
> +  work
 Are we sure we want this? It's (afaik) not correct XML;
>>> It's not? How so?
>> If the element belongs to some namespace, then attributes from this
>> namespace should be native to it. But I couldn't find any
>> documentation to support that this is a strict requirement. Perhaps it
>> should be allowed, then.
> 
> As far as I know in XML, attributes without an explicit namespace prefix 
> are not in any namespace at all. Default namespaces don't apply to 
> attributes.

I don't think  this is correct, 
http://www.w3.org/TR/REC-xml-names/#scoping-defaulting

"""
A default namespace declaration applies to all unprefixed element names 
within its scope. Default namespace declarations do not apply directly 
to attribute names; the interpretation of unprefixed attributes is 
determined by the element on which they appear.
"""

Laurence

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] SVN: z3c.pt/trunk/TODO.txt

2008-09-10 Thread Dieter Maurer
Martijn Faassen wrote at 2008-9-10 11:32 +0200:
> ...
>As far as I know in XML, attributes without an explicit namespace prefix 
>are not in any namespace at all. Default namespaces don't apply to 
>attributes.

http://www.w3.org/TR/2006/REC-xml-names-20060816/#scoping-defaulting

specifies:

"the interpretation of unprefixed attributes is determined by the element on 
which they appear."

The "tal/metal:" elements have decided that unprefixed attributes
are interpreted as belonging to this namespace.



-- 
Dieter
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] explicit sys.path manipulation in test.py causing problems

2008-09-10 Thread Rob Miller
hi all,

in Zope's testrunner, the SOFTWARE_HOME is explicitly added to the front of
the python package lookup path, like so:

sys.path.insert(0, shome)

this doesn't happen in the same manner when you're actually starting a Zope
server.  as a result, the test runner will not work in certain environments
where Zope itself is purring happily along.

specifically, i've got a setup where Zope 2.10 is installed into a virtualenv
using the traditional Zope install mechanisms.  i want to use ZODB BLOB
storage, however, so i've got ZODB 3.8 eggs installed.  setuptools gives eggs
precedence over non-egg packages, so this works well, except when using
test.py, where the explicit insertion of SOFTWARE_HOME at the very
beginning of sys.path trumps the egg installation.

i'd like to put a check in there so that SOFTWARE_HOME is only added to the
package lookup if the Zope2 package isn't already available:

try:
 import Zope2
except ImportError:
 sys.path.insert(0, shome)

in other words, if the environment is already set up, don't mess with it.

anyone have a problem w/ me making this change on trunk and the 2.10 and 2.11 
branches?

-r

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] Events and interfaces for different request types

2008-09-10 Thread Roger Ineichen
Hi

Sidnei 

> Betreff: [Zope-dev] Events and interfaces for different request types
> 
> Hi all,
> 
> More than once I've found myself on a situation where I 
> needed to subscribe to a specific event but only if it 
> happens through a specific request type. One problem with 
> that is that commonly the request is not part of the event 
> information. Another problem might be that the request type 
> might not be properly flagged, but this is a different 
> subject and applies mostly to Zope 2.
> 
> Now, for solving this problem, I usually create a custom and 
> more specialized event that includes the request as part of 
> it's information. So, for example, I'm interested in 
> IObjectModifiedEvent but only for IWebDAVRequest, then I create:
> 
> class IObjectRequestModifiedEvent(IObjectModifiedEvent):
>request = Attribute(...)
> 
> def subscriber(object, event):
>if IWebDAVRequest.isProvidedBy(event.request):
>   # do something
> 
> Now, I wonder if someone has any suggestion on how to 
> simplify this further...

I personaly think the request which is almost only a user 
interaction should not be a part of the model. The 
basic event subscribers will act at the (MVC) model level
independent of what user will interact and independent from
the different user interfaces e.g. web browser web dav etc.

But I see your point. I think what is missing is some
kind of view events. Because the API which web dav uses
is implemented as views, right?

I also think this is probably special for FTP and Web Dav
but not required in web browser views.


Regards
Roger Ineichen
_
END OF MESSAGE


> --
> Sidnei da Silva
> Enfold Systems http://enfoldsystems.com
> Fax +1 832 201 8856 Office +1 713 942 2377 Ext 214 
> ___
> Zope-Dev maillist  -  Zope-Dev@zope.org
> http://mail.zope.org/mailman/listinfo/zope-dev
> **  No cross posts or HTML encoding!  ** (Related lists -  
> http://mail.zope.org/mailman/listinfo/zope-announce
>  http://mail.zope.org/mailman/listinfo/zope )
> 

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] Events and interfaces for different request types

2008-09-10 Thread Robert Marianski
On Wed, Sep 10, 2008 at 06:25:20PM -0200, Sidnei da Silva wrote:
> Hi all,
> 
> More than once I've found myself on a situation where I needed to
> subscribe to a specific event but only if it happens through a
> specific request type. One problem with that is that commonly the
> request is not part of the event information. Another problem might be
> that the request type might not be properly flagged, but this is a
> different subject and applies mostly to Zope 2.
> 
> Now, for solving this problem, I usually create a custom and more
> specialized event that includes the request as part of it's
> information. So, for example, I'm interested in IObjectModifiedEvent
> but only for IWebDAVRequest, then I create:
> 
> class IObjectRequestModifiedEvent(IObjectModifiedEvent):
>request = Attribute(...)
> 
> def subscriber(object, event):
>if IWebDAVRequest.isProvidedBy(event.request):
>   # do something
> 
> Now, I wonder if someone has any suggestion on how to simplify this further...
> -- 
> Sidnei da Silva
> Enfold Systems http://enfoldsystems.com
> Fax +1 832 201 8856 Office +1 713 942 2377 Ext 214

I haven't tried this, but you might be able to send out an event on an
additional channel in a general handler. Something like:

def subscriber(object, event):
notify(object, event, event.request)

And you should be able to register event handlers for the 3 channels now.

-- 
Robert


pgputeu7jhKg3.pgp
Description: PGP signature
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] Events and interfaces for different request types

2008-09-10 Thread Stephan Richter
On Wednesday 10 September 2008, Robert Marianski wrote:
> And you should be able to register event handlers for the 3 channels now.

Of course that works. :-) It's just a multi-adapter lookup. ;-)

Regards,
Stephan
-- 
Stephan Richter
Web Software Design, Development and Training
Google me. "Zope Stephan Richter"
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] How to use UserTrack product?

2008-09-10 Thread Rupesh P Raj
Thanks a lot Dieter for the guidance. It worked well.

Thanks,
Roopesh
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )