Re: [Zope-dev] local grants for z3c.rest not working.

2008-12-10 Thread Jayarajan Jn
Also, i have a PAU registered. Still it seems like the PAU is not being
contacted for authenticating REST requests. I can Authenticate the
principals in  principal.zcml only.

rgds,
Jayarajan J N (IRC nick - jayaraj)

On Thu, Dec 11, 2008 at 12:06 PM, Jayarajan Jn <[EMAIL PROTECTED]> wrote:

> Hi all,
>
> Recently i was looking for some zope3 based solutions for implementing
> RESTful public API. And i found z3c.rest. To begin with package I have
> installed it and enabled the the RESTviews for 'Folder' that is provided in
> the 'tests' sub-folder of z3c.rest. It works fine. Then i changed the
> Permission setting for GET view  from 'zope.View' to 'zope.ManageContent'
> and i expected this would make the GET view of the Folder to be unavailable
> to the Public. But it was still possible for me to call the GET view with an
> 'unauthorised' request.
>
> Similarly, i changed the permission for POST/PUT from 'zope.ManageContent'
> to 'zope.Public' and still I had to get authenticated to access it.
>
> Can any one please tell me how can i use local grants with z3c.rest? I
> expected it to work the same way as other zope:views do. Please help me on
> this.
>
> I have installed the package available in the svn trunk. Zope3 setup is
> zope3.4.0c1 + python 2.5
> I have tested the GET view using both web browser and a python script.
>
> Following is the original  configurations from z3c/rest/tests/folder.zcml
>
> 
>  for="zope.app.folder.interfaces.IFolder"
> name="GET"
> type="..interfaces.IRESTRequest"
> factory=".folder.FolderAPI"
> permission="zope.View"
> allowed_attributes="GET"
> />
>
>  for="zope.app.folder.interfaces.IFolder"
> name="POST"
> type="..interfaces.IRESTRequest"
> factory=".folder.FolderAPI"
> permission="zope.ManageContent"
> allowed_attributes="POST"
> />
>
>  for="zope.app.folder.interfaces.IFolder"
> name="PUT"
> type="..interfaces.IRESTRequest"
> factory=".folder.FolderAPI"
> permission="zope.ManageContent"
> allowed_attributes="PUT"
> />
> ##
>
> This is how i changed it
>
> --
>  for="zope.app.folder.interfaces.IFolder"
> name="GET"
> type="..interfaces.IRESTRequest"
> factory=".folder.FolderAPI"
> permission="zope.ManageContent"
> allowed_attributes="GET"
> />
>
>  for="zope.app.folder.interfaces.IFolder"
> name="POST"
> type="..interfaces.IRESTRequest"
> factory=".folder.FolderAPI"
> permission="zope.Public"
> allowed_attributes="POST"
> />
>
>  for="zope.app.folder.interfaces.IFolder"
> name="PUT"
> type="..interfaces.IRESTRequest"
> factory=".folder.FolderAPI"
> permission="zope.Public"
> allowed_attributes="PUT"
> />
> 
>
> Thanks in advance.
>
> rgds,
> Jayarajan J N (IRC nick - jayaraj)
>
>
___
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] local grants for z3c.rest not working.

2008-12-10 Thread Jayarajan Jn
Hi all,

Recently i was looking for some zope3 based solutions for implementing
RESTful public API. And i found z3c.rest. To begin with package I have
installed it and enabled the the RESTviews for 'Folder' that is provided in
the 'tests' sub-folder of z3c.rest. It works fine. Then i changed the
Permission setting for GET view  from 'zope.View' to 'zope.ManageContent'
and i expected this would make the GET view of the Folder to be unavailable
to the Public. But it was still possible for me to call the GET view with an
'unauthorised' request.

Similarly, i changed the permission for POST/PUT from 'zope.ManageContent'
to 'zope.Public' and still I had to get authenticated to access it.

Can any one please tell me how can i use local grants with z3c.rest? I
expected it to work the same way as other zope:views do. Please help me on
this.

I have installed the package available in the svn trunk. Zope3 setup is
zope3.4.0c1 + python 2.5
I have tested the GET view using both web browser and a python script.

Following is the original  configurations from z3c/rest/tests/folder.zcml







##

This is how i changed it

--







Thanks in advance.

rgds,
Jayarajan J N (IRC nick - jayaraj)
___
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] z3c.form 2.0 release

2008-12-10 Thread Brian Sutherland
On Wed, Dec 10, 2008 at 01:29:49PM -0500, Tres Seaver wrote:
> Note that the __file__ of the namespace package is not guaranteed to be
> in one or the other egg, which is why namespace packages must have
> nothing more in their __init__.py than the boilerplate which declares
> the namespace.

With system packaged the __init__.py is guaranteed to not even be
installed. Try this:

$ python setup.py install --single-version-externally-managed --root xxx

Also, if there are files alongside the __init__.py, they can cause
filesystem conflicts in system packagers. dpkg will refuse to install a
package if it would overwrite a file owned by another package.

> 
> 
> 
> Tres
> - --
> ===
> Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
> Palladion Software   "Excellence by Design"http://palladion.com
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
> 
> iD8DBQFJQAqd+gerLs4ltQ4RAvHgAKCgjeyLLFqZUmhmhsd81Wm6RXlXyQCg2r0D
> PNIFGNtvOwkYzsh9VSHEIy4=
> =pcdI
> -END 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 )


-- 
Brian Sutherland
___
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] z3c.form 2.0 release

2008-12-10 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Tres Seaver wrote:

> Brian Sutherland wrote:
>> On Wed, Dec 10, 2008 at 11:05:06AM +0100, Hermann Himmelbauer wrote:
>>> Someone recently suggested to rename it to z3c.schema.iban, which sounds a 
>>> good idea to me, however, in this case my package would use another 
>>> package, 
>>> namely z3c.schema, as namespace.
>>>
>>> So what's your suggestion in this case?
>> There's no problem as long as z3c.schema is truly empty, i.e. there are
>> no other packages that put any files in it.
> 
>> The problem with z3c.pt.compat is that z3c.pt is not empty (see
>> http://svn.zope.org/z3c.pt/trunk/src/z3c/pt/). That's what causes the
>> problems I've been seeing.
> 
> The issue comes not from having modules inside the namespace package
> (which is fine:  the __path__ of namespacee packages is extended to
> include all eggs which use it).  Rather, the problem is having a
> non-empty __init__.py in a namespace package (specifically, one which
> does anything else than declare that it is a namespace).  The problem
> arises because only one of the __init__.py files will be imported (the
> first one found).

A points I missed the first time:

- - If having modules inside a namespace package was somehow broken
  under setuptools, then having sub-pacakges would be too:  there
  isn't any magical difference between the two in how Python imports
  them.

Please see the setuptools docs for an explanation of what namespace
pacakges must do:



I created a pair of packages to demonstrate having a module inside a
namespace package (see attachment).  To play with them, run 'python
setup.py develop' in each of them using a setuptools-enabld Python
environment in whose site-packages you don't mind scribbling (a
virtualenv is perfect for this kind of stuff).  E.g.::

 $ /path/to/virtualenv --no-site-packages /tmp/nstest
 $ cd /tmp/nstest
 $ mkdir src
 $ cd src
 $ tar xzf /tmp/nstest.tar.gz
 $ cd foo
 $ ../../bin/python setup.py develop
 $ cd ../foo.bar
 $ ../../bin/python setup.py develop
 $ cd ../..
 $ bin/python
 ...
 >>> import foo
 >>> print foo.__file__
 '/tmp/nstest/src/foo.bar/foo/__init__.pyc'
 >>> import foo.qux
 >>> import foo.bar
 >>> foo.qux.quack
 >>> foo.bar.cheer

Note that the __file__ of the namespace package is not guaranteed to be
in one or the other egg, which is why namespace packages must have
nothing more in their __init__.py than the boilerplate which declares
the namespace.



Tres
- --
===
Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
Palladion Software   "Excellence by Design"http://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJQAqd+gerLs4ltQ4RAvHgAKCgjeyLLFqZUmhmhsd81Wm6RXlXyQCg2r0D
PNIFGNtvOwkYzsh9VSHEIy4=
=pcdI
-END PGP SIGNATURE-


nstest.tar.gz
Description: GNU Zip compressed data
___
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] z3c.form 2.0 release

2008-12-10 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Brian Sutherland wrote:
> On Wed, Dec 10, 2008 at 11:05:06AM +0100, Hermann Himmelbauer wrote:
>> Someone recently suggested to rename it to z3c.schema.iban, which sounds a 
>> good idea to me, however, in this case my package would use another package, 
>> namely z3c.schema, as namespace.
>>
>> So what's your suggestion in this case?
> 
> There's no problem as long as z3c.schema is truly empty, i.e. there are
> no other packages that put any files in it.
> 
> The problem with z3c.pt.compat is that z3c.pt is not empty (see
> http://svn.zope.org/z3c.pt/trunk/src/z3c/pt/). That's what causes the
> problems I've been seeing.

The issue comes not from having modules inside the namespace package
(which is fine:  the __path__ of namespacee packages is extended to
include all eggs which use it).  Rather, the problem is having a
non-empty __init__.py in a namespace package (specifically, one which
does anything else than declare that it is a namespace).  The problem
arises because only one of the __init__.py files will be imported (the
first one found).


Tres.
- --
===
Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
Palladion Software   "Excellence by Design"http://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJQAOO+gerLs4ltQ4RAq7iAJ9u2qd+iBHh3NMMGtO/pdPuNbcHAgCgqQxQ
3Sixt5Nslc7Lzw2CKjJrkaA=
=DQvL
-END 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] z3c.form 2.0 release

2008-12-10 Thread Hermann Himmelbauer
Am Mittwoch 10 Dezember 2008 13:02:02 schrieb Roger Ineichen:
> Hi Herman
>
> > Betreff: Re: [Zope-dev] z3c.form 2.0 release
> >
> > Am Dienstag 09 Dezember 2008 16:24:41 schrieb Roger Ineichen:
> > > Hi Brian
> > >
> > > > Betreff: Re: [Zope-dev] z3c.form 2.0 release
> > > >
> > > > On Sun, Dec 07, 2008 at 11:27:01PM -0800, Stephan Richter wrote:
> > > > > On Friday 05 December 2008, Martin Aspeli wrote:
> > > > > > Is there any indication on when we'll see a 2.0 release
> > > >
> > > > of z3c.form?
> > > >
> > > > > > We need a widget that's not in the 1.9 release, but is on
> > > >
> > > > trunk (for
> > > >
> > > > > > a list with textline value type), and are wondering
> > > >
> > > > whether to roll
> > > >
> > > > > > our own or wait for a new z3c.form release.
> > > > >
> > > > > I am considering the code feature complete. I would like to get
> > > > > confirmation from people that (a) the z3c.pt integration works
> > > > > well
> > > >
> > > > I have an issue with this. z3c.pt.compat creates a nasty
> >
> > issue when
> >
> > > > trying to package it as a Debian package.
> > > >
> > > > The root cause seems to be that z3c.pt.compat declares
> >
> > z3c.pt as a
> >
> > > > namespace package. These are defined in the setuptools
> >
> > documentation
> >
> > > > to be "merely a container for modules and subpackages."
> >
> > [1]. z3c.pt
> >
> > > > doesn't conform to that as it contains files. This doesn't matter
> > > > till you try to install it using the
> > > > --single-version-externally-managed option, at which
> >
> > point you get
> >
> > > > file conflicts.
> > > >
> > > > I've been thinking about it a while, and I think the only
> >
> > solution
> >
> > > > is to rename z3c.pt.compat to z3c.ptcompat, make a new release of
> > > > that and migrate z3c.form. I'm willing to implement that
> >
> > if there's
> >
> > > > enough support.
> > > >
> > > > [1]
> >
> > http://peak.telecommunity.com/DevCenter/setuptools#namespace-package
> >
> > > > s
> > >
> > > I agree
> > > A package should never use another package as it's namespace.
> > > Which means a package can not be both a package and namespace for
> > > other packages.
> >
> > Ah, that's interesting. Because I recently released a package
> > called "z3c.iban", which is basically about a schema about
> > the international bank account number.
> >
> > Someone recently suggested to rename it to z3c.schema.iban,
> > which sounds a good idea to me, however, in this case my
> > package would use another package, namely z3c.schema, as namespace.
> >
> > So what's your suggestion in this case?
>
> You should move the iban folder to the existing
> z3c.schema package. But only if the z3c.schema.iban
> doesn''t depend on any other package the z3c.schema
> already does.

Yes, that's exactly the problem - it depends on the "iban" module (a package, 
which I also wrote).

> Otherwise you should rename the package to z3c.iban
> or anything you like.
>
> Or we could do it the other way arround. We could
> split the z3c.schema package into different pacakges
> like z3c.schema.iban. This whould be nicer because
> we can share th z3c.schema package as a namespace.

That was what I was thinking about, as I estimate that there will be quite 
some packages over time which will rely on other packages and can hence not 
go into z3c.schema.

Best Regards,
Hermann

-- 
[EMAIL PROTECTED]
GPG key ID: 299893C7 (on keyservers)
FP: 0124 2584 8809 EF2A DBF9  4902 64B4 D16B 2998 93C7

___
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] z3c.form 2.0 release

2008-12-10 Thread Roger Ineichen
Hi Herman

> Betreff: Re: [Zope-dev] z3c.form 2.0 release
> 
> Am Dienstag 09 Dezember 2008 16:24:41 schrieb Roger Ineichen:
> > Hi Brian
> >
> > > Betreff: Re: [Zope-dev] z3c.form 2.0 release
> > >
> > > On Sun, Dec 07, 2008 at 11:27:01PM -0800, Stephan Richter wrote:
> > > > On Friday 05 December 2008, Martin Aspeli wrote:
> > > > > Is there any indication on when we'll see a 2.0 release
> > >
> > > of z3c.form?
> > >
> > > > > We need a widget that's not in the 1.9 release, but is on
> > >
> > > trunk (for
> > >
> > > > > a list with textline value type), and are wondering
> > >
> > > whether to roll
> > >
> > > > > our own or wait for a new z3c.form release.
> > > >
> > > > I am considering the code feature complete. I would like to get 
> > > > confirmation from people that (a) the z3c.pt integration works 
> > > > well
> > >
> > > I have an issue with this. z3c.pt.compat creates a nasty 
> issue when 
> > > trying to package it as a Debian package.
> > >
> > > The root cause seems to be that z3c.pt.compat declares 
> z3c.pt as a 
> > > namespace package. These are defined in the setuptools 
> documentation 
> > > to be "merely a container for modules and subpackages." 
> [1]. z3c.pt 
> > > doesn't conform to that as it contains files. This doesn't matter 
> > > till you try to install it using the 
> > > --single-version-externally-managed option, at which 
> point you get 
> > > file conflicts.
> > >
> > > I've been thinking about it a while, and I think the only 
> solution 
> > > is to rename z3c.pt.compat to z3c.ptcompat, make a new release of 
> > > that and migrate z3c.form. I'm willing to implement that 
> if there's 
> > > enough support.
> > >
> > > [1]
> > > 
> http://peak.telecommunity.com/DevCenter/setuptools#namespace-package
> > > s
> >
> > I agree
> > A package should never use another package as it's namespace.
> > Which means a package can not be both a package and namespace for 
> > other packages.
> 
> Ah, that's interesting. Because I recently released a package 
> called "z3c.iban", which is basically about a schema about 
> the international bank account number. 
> 
> Someone recently suggested to rename it to z3c.schema.iban, 
> which sounds a good idea to me, however, in this case my 
> package would use another package, namely z3c.schema, as namespace.
> 
> So what's your suggestion in this case?

You should move the iban folder to the existing 
z3c.schema package. But only if the z3c.schema.iban 
doesn''t depend on any other package the z3c.schema 
already does.

Otherwise you should rename the package to z3c.iban
or anything you like.

Or we could do it the other way arround. We could 
split the z3c.schema package into different pacakges
like z3c.schema.iban. This whould be nicer because 
we can share th z3c.schema package as a namespace.

I'm fine with everything as long as we don't use
real packages as namespace for packages.

Regards
Roger Ineichen

> Best Regards,
> Hermann
> 
> 
> 
> 
> --
> [EMAIL PROTECTED]
> GPG key ID: 299893C7 (on keyservers)
> FP: 0124 2584 8809 EF2A DBF9  4902 64B4 D16B 2998 93C7
> 

___
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: 4 OK, 2 Failed

2008-12-10 Thread Zope Tests Summarizer
Summary of messages to the zope-tests list.
Period Tue Dec  9 12:00:00 2008 UTC to Wed Dec 10 12:00:00 2008 UTC.
There were 6 messages: 6 from Zope Tests.


Test failures
-

Subject: FAILED (failures=2) : Zope-trunk Python-2.4.5 : Linux
From: Zope Tests
Date: Tue Dec  9 20:29:11 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-December/010625.html

Subject: FAILED (failures=2) : Zope-trunk Python-2.5.2 : Linux
From: Zope Tests
Date: Tue Dec  9 20:30:41 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-December/010626.html


Tests passed OK
---

Subject: OK : Zope-2.8 Python-2.3.7 : Linux
From: Zope Tests
Date: Tue Dec  9 20:23:10 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-December/010621.html

Subject: OK : Zope-2.9 Python-2.4.5 : Linux
From: Zope Tests
Date: Tue Dec  9 20:24:41 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-December/010622.html

Subject: OK : Zope-2.10 Python-2.4.5 : Linux
From: Zope Tests
Date: Tue Dec  9 20:26:11 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-December/010623.html

Subject: OK : Zope-2.11 Python-2.4.5 : Linux
From: Zope Tests
Date: Tue Dec  9 20:27:41 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-December/010624.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] z3c.form 2.0 release

2008-12-10 Thread Malthe Borch
2008/12/10 Brian Sutherland <[EMAIL PROTECTED]>:
> Below are the failures, Malthe, would you mind having a look at these?

I'll take a look at them; seems to be __repr__-related all around.

\malthe
___
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] z3c.form 2.0 release

2008-12-10 Thread Brian Sutherland
On Tue, Dec 09, 2008 at 09:09:26PM +0100, Brian Sutherland wrote:
> On Tue, Dec 09, 2008 at 04:31:33PM +0100, Malthe Borch wrote:
> > 2008/12/9 Roger Ineichen <[EMAIL PROTECTED]>:
> > > I agree
> > > A package should never use another package as it's namespace.
> > > Which means a package can not be both a package and namespace for
> > > other packages.
> > 
> > Seems to work fine for e.g. ``repoze.bfg``.
> 
> It works under most situations, but not the ones that are important to
> me. I've never tried to use repoze.bfg.
> 
> > > Malthe are you aware of this? Can you change it?
> > 
> > I do regret the package name and I would not be opposed to renaming it
> > to z3c.ptcompat.
> 
> Great, then sometime this week I'll:
> * rename the package

I've done this.

> * upload a release to pypi

I got caught on this, for 2 reasons:

* The z3c.pt.compat tests are broken and were broken before I
  started. I don't want to release a package with broken tests. [1]
* 93339 breaks the z3c.form tests [2]

Below are the failures, Malthe, would you mind having a look at these?

> * change the imports and dependencies in z3c.form

I've done this on a branch for now. I'll have a look at the other
z3c.* packages once this is all working.

The test failures:

[1]

Running zope.testing.testrunner.layer.UnitTests tests:
  Set up zope.testing.testrunner.layer.UnitTests in 0.000 seconds.


Failure in test /Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt
Traceback (most recent call last):
  File
"/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/unittest.py",
line 260, in run
testMethod()
  File
"/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/doctest.py",
line 2128, in runTest
raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for zcml.txt
  File "/Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt", line 0

--
File "/Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt", line 27,
in zcml.txt
Failed example:
factory.index
Expected:

Got:

--
File "/Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt", line 45,
in zcml.txt
Failed example:
factory.index
Expected:

Got:

--
File "/Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt", line 70,
in zcml.txt
Failed example:
factory.template
Expected:

Got:

--
File "/Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt", line 90,
in zcml.txt
Failed example:
factory.template
Expected:

Got:

--
File "/Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt", line
111, in zcml.txt
Failed example:
factory.index
Expected:

Got:

--
File "/Users/jinty/src/z3c.ptcompat/src/z3c/ptcompat/zcml.txt", line
131, in zcml.txt
Failed example:
factory.index
Expected:

Got:


[2]

Failure in test /Users/jinty/src/z3c.form/src/z3c/form/tests/../form.txt
Failed doctest test for form.txt
  File "/Users/jinty/src/z3c.form/src/z3c/form/tests/../form.txt", line
0

--
File "/Users/jinty/src/z3c.form/src/z3c/form/tests/../form.txt", line
478, in form.txt
Failed example:
print addForm.render() # doctest: +NOPARSE_MARKUP
Expected:
  http://www.w3.org/1999/xhtml";>

  There were some errors.
  

  The id and name cannot be the same.

  
  ...

  

Got:
  http://www.w3.org/1999/xhtml";>

  There were some errors.
  

  The id and name cannot be the same.

  
  

  ID
  


  Name
  


  Gender
  
no value
male
female
  
  


  Age
  


  

  

  

Diff:
  http://www.w3.org/1999/xhtml";>

  There were some errors.
  

  The id and name cannot be the same.

  
  
  -

  ID
  


  Name
  


  Gender
  
no value
male
female
  
  


  Age
  


  

  

  




> 
> Please let me know if there's a step I'm missing?
> 
> > 
> > \malthe
> > 
> 
> -- 
> Brian Sutherland
> ___
> Zope-Dev maillist  -  Zope-Dev@zope.org
> http://mail.zope.org/mailman/listinfo/zope

Re: [Zope-dev] z3c.form 2.0 release

2008-12-10 Thread Brian Sutherland
On Wed, Dec 10, 2008 at 11:05:06AM +0100, Hermann Himmelbauer wrote:
> Someone recently suggested to rename it to z3c.schema.iban, which sounds a 
> good idea to me, however, in this case my package would use another package, 
> namely z3c.schema, as namespace.
> 
> So what's your suggestion in this case?

There's no problem as long as z3c.schema is truly empty, i.e. there are
no other packages that put any files in it.

The problem with z3c.pt.compat is that z3c.pt is not empty (see
http://svn.zope.org/z3c.pt/trunk/src/z3c/pt/). That's what causes the
problems I've been seeing.

> 
> Best Regards,
> Hermann
> 
> 
> 
> 
> -- 
> [EMAIL PROTECTED]
> GPG key ID: 299893C7 (on keyservers)
> FP: 0124 2584 8809 EF2A DBF9  4902 64B4 D16B 2998 93C7
> 

-- 
Brian Sutherland
___
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] z3c.form 2.0 release

2008-12-10 Thread Hermann Himmelbauer
Am Dienstag 09 Dezember 2008 16:24:41 schrieb Roger Ineichen:
> Hi Brian
>
> > Betreff: Re: [Zope-dev] z3c.form 2.0 release
> >
> > On Sun, Dec 07, 2008 at 11:27:01PM -0800, Stephan Richter wrote:
> > > On Friday 05 December 2008, Martin Aspeli wrote:
> > > > Is there any indication on when we'll see a 2.0 release
> >
> > of z3c.form?
> >
> > > > We need a widget that's not in the 1.9 release, but is on
> >
> > trunk (for
> >
> > > > a list with textline value type), and are wondering
> >
> > whether to roll
> >
> > > > our own or wait for a new z3c.form release.
> > >
> > > I am considering the code feature complete. I would like to get
> > > confirmation from people that (a) the z3c.pt integration works well
> >
> > I have an issue with this. z3c.pt.compat creates a nasty
> > issue when trying to package it as a Debian package.
> >
> > The root cause seems to be that z3c.pt.compat declares z3c.pt
> > as a namespace package. These are defined in the setuptools
> > documentation to be "merely a container for modules and
> > subpackages." [1]. z3c.pt doesn't conform to that as it
> > contains files. This doesn't matter till you try to install
> > it using the --single-version-externally-managed option, at
> > which point you get file conflicts.
> >
> > I've been thinking about it a while, and I think the only
> > solution is to rename z3c.pt.compat to z3c.ptcompat, make a
> > new release of that and migrate z3c.form. I'm willing to
> > implement that if there's enough support.
> >
> > [1]
> > http://peak.telecommunity.com/DevCenter/setuptools#namespace-packages
>
> I agree
> A package should never use another package as it's namespace.
> Which means a package can not be both a package and namespace for
> other packages.

Ah, that's interesting. Because I recently released a package 
called "z3c.iban", which is basically about a schema about the international 
bank account number. 

Someone recently suggested to rename it to z3c.schema.iban, which sounds a 
good idea to me, however, in this case my package would use another package, 
namely z3c.schema, as namespace.

So what's your suggestion in this case?

Best Regards,
Hermann




-- 
[EMAIL PROTECTED]
GPG key ID: 299893C7 (on keyservers)
FP: 0124 2584 8809 EF2A DBF9  4902 64B4 D16B 2998 93C7
___
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 )