Re: [Zope] error with repozo.py

2006-03-19 Thread Bernd Dorn
On 20.03.2006, at 07:45, Martin Koekenberg wrote:  Hello, I get an error when I want to create a backup with repozo.py.  Traceback (most recent call last):  File "./repozo.py", line 74, in ?    from ZODB.FileStorage import FileStorageImportError: No module named ZODB.FileStorage I already searched with google for a solution. I found that it could be a problem with PYTHONPATH, but I’ve set this path already.are you sure, looks as if the path is not correctyou have to set it to /lib/pythonjust startup the python interpreter and typeimport sys; sys.paththen it should print the path defined above, if not something is wrong What else can be wrong ? Regards, Martin Koekenberg   ___Zope maillist  -  Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope**   No cross posts or HTML encoding!  **(Related lists -  http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev ) ___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: zope 2.8.6 on Mac Intel

2006-03-19 Thread Bernd Dorn


On 19.03.2006, at 20:30, manuel spuhler wrote:


Hello,

Thank you for your hints. I successfully compiled python2.3.5 for OS
10.4, as described in Florent Guillaume's blog, but when I try to
compile Zope, I get the same error:

$ ./configure --prefix=/opt/Zope2.8 --with-python=/usr/local/bin/ 
python2.3


Using Python interpreter at /usr/local/bin/python2.3

Configuring Zope installation

  - Zope top-level binary directory will be /opt/Zope2.8.
  - Makefile written.

  Next, run make.

$ make
"/usr/local/bin/python2.3" "/Users/spuhlema/Desktop/Zope-2.8.6- 
final/setup.py" \

build
--build-base="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/ 
python-2.3"
--build-lib="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/ 
python-2.3/build-lib"
--build-scripts="/Users/spuhlema/Desktop/Zope-2.8.6-final/build- 
base/python-2.3/build-scripts"
--build-temp="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/ 
python-2.3/build-temp"

running build
running build_py
error: package directory
'build/lib/darwin-8/5/2-i386-2/4/zope/app/traversing/ftests' does not
exist
make: *** [build] Error 1

I guess Python doesn't compile equally on PowerPc and Intel.
Any idea?


you need zlib support compiled into python, this is only done, if the  
zlib header files are found at configure time


do you have it?




2006/3/19, Jens Vagelpohl <[EMAIL PROTECTED]>:

$ make
"/usr/bin/python" "/Users/spuhlema/Desktop/Zope-2.8.6-final/
setup.py" \
build
--build-base="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/
python-2.3"
--build-lib="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/
python-2.3/build-lib"
--build-scripts="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-
base/python-2.3/build-scripts"
--build-temp="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/
python-2.3/build-temp"


This line shows you are using the system Python at /usr/bin/python.
Don't. It's no good at all for compiling anything. Run "configure"
with the --with-python=/path/to/python flag to use a self-compiled
Python.

I have never used the Fink Python. It is child's play to compile
Python yourself (with the exception of Python 2.3.5 on OS X 10.4), so
that's the way to go. Here's the instructions I work from:

http://www.zope.org/Members/jens/docs/Document.2003-12-27.2431

These are not written for OS X/i386, but I'd be surprised if they
didn't work on both platforms.

jens

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


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


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

http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] error with repozo.py

2006-03-19 Thread Martin Koekenberg








Hello,

 

I get an error when I want to create a backup with
repozo.py. 

 

Traceback (most recent call last):

  File "./repozo.py", line 74, in ?

    from ZODB.FileStorage import FileStorage

ImportError: No module named ZODB.FileStorage

 

I already searched with google for a solution. I
found that it could be a problem with PYTHONPATH, but I’ve set this path already.

 

What else can be wrong ?

 

Regards,

 

Martin
 Koekenberg

 






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


Re: [Zope] Using tal:attributes in XML with non-ASCII characters

2006-03-19 Thread Andrew Veitch

On 19 Mar 2006, at 19:11, Dieter Maurer wrote:

This means that almost surely your "non-ascii" was not encoded
in UTF-8. Encode them this way and it will work.


Here's a test template that I created through the ZMI:


http://xml.zope.org/namespaces/tal";
  tal:define="dummy python:request.RESPONSE.setHeader('content- 
type', 'text/html;;charset=UTF-8')">

  




  


This gives:

Error Type: UnicodeDecodeError
Error Value: 'ascii' codec can't decode byte 0x80 in position 0:  
ordinal not in range(128)


If I change the input line to:



Then this will work in HTML mode but will fail in XML mode.


Finally, I tried tal:attributes with my function and the structure
keyword but 'structure' isn't supported with tal:attributes.


I have extended our local Zope to support "structure" for
attributes as well.


I had a look in TAL, and at the bottom of TALDefs.py is a function  
called attrEscape(s) which correctly escapes attributes but  
unfortunately this function doesn't seem to be used.



I could provide patches, if useful.


I would be very interested to see you patches.

Thanks in advance

Andrew

--
Logicalware Ltd
Stuart House, Eskmills, Musselburgh, EH21 7PQ, UK
Tel: +44(0)131 273 5130 http://www.logicalware.com


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

http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] Re: Ape

2006-03-19 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Dieter Maurer wrote:
> Chris Withers wrote at 2006-3-17 19:54 +:
> 
>>Chris Kratz wrote:
>>
>>>How does the refresh interval work for DirectoryView?  
>>
>>When zope is in dev mode, each time an fs-based object is rendered, it 
>>checks to see if it has changed on disk. This is pretty quick on linux, 
>>but can have issues on windows.
> 
> 
> Until the stupid special handling for Windows is removed...
> This should have happened ages ago -- but probably is still there...

It needs special handling, just *smart* special handling, because
Windows filesystems lie about the mtime of their directories.  Mark
Hammond had a notion of how do make that happen, and I created an issue
for it in the CMF collector:

  http://www.zope.org/Collectors/CMF/366


Tres.
- --
===
Tres Seaver  +1 202-558-7113  [EMAIL PROTECTED]
Palladion Software   "Excellence by Design"http://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFEHgCp+gerLs4ltQ4RAhJnAJ9kaMHIcA1PYNjz8vcnRvrAhEPx1QCgsd2I
zzZ7ElIGps59r7uqIfhUwyg=
=UVlU
-END PGP SIGNATURE-

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


Re: [Zope] Virtual Host Monster

2006-03-19 Thread Jens Vagelpohl


On 19 Mar 2006, at 21:34, Dan Gaibel wrote:


Hi Folks,

I want to use Zope for web hosting, and I wonder about the Virtual  
Host Monster. Is it reasonable to think that I could host say,  
200-300 small sites (different domains, low traffic) in one  
instance of zope 2.8? I'm planning on a dedicated server with 2GB  
of RAM. Does this seem feasible? Any advice on how to test  
something like this?


Not sure what your doubts about the VHM are, I don't see any problem  
there. This sounds feasible, but if you can get more RAM I'd go for it.


Testing a setup like that will require programming work on your part.  
You will want to create a script that creates all these sites and  
hopefully some content in them, and then a script that can run  
requests against them.


jens

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

http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] Virtual Host Monster

2006-03-19 Thread Dan Gaibel

Hi Folks,

I want to use Zope for web hosting, and I wonder about the Virtual  
Host Monster. Is it reasonable to think that I could host say,  
200-300 small sites (different domains, low traffic) in one instance  
of zope 2.8? I'm planning on a dedicated server with 2GB of RAM. Does  
this seem feasible? Any advice on how to test something like this?


Thanks,

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

http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: zope 2.8.6 on Mac Intel

2006-03-19 Thread Jens Vagelpohl


On 19 Mar 2006, at 19:30, manuel spuhler wrote:


Hello,

Thank you for your hints. I successfully compiled python2.3.5 for OS
10.4, as described in Florent Guillaume's blog, but when I try to
compile Zope, I get the same error:


There must be some odd difference then. It all works just fine on  
PPC... I'll ask a friend of mine who has a MacBook.


jens

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

http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: Ape

2006-03-19 Thread Dieter Maurer
Chris Withers wrote at 2006-3-17 19:54 +:
>Chris Kratz wrote:
>> How does the refresh interval work for DirectoryView?  
>
>When zope is in dev mode, each time an fs-based object is rendered, it 
>checks to see if it has changed on disk. This is pretty quick on linux, 
>but can have issues on windows.

Until the stupid special handling for Windows is removed...
This should have happened ages ago -- but probably is still there...

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


Re: [Zope] Using tal:attributes in XML with non-ASCII characters

2006-03-19 Thread Dieter Maurer
Andrew Veitch wrote at 2006-3-18 15:56 +:
>I'm just trying to think of a way of using tal:attributes with non- 
>ASCII characters using the XML parser.
>
>At first, I just used a straight tal:attributes with the encoding of  
>the template set to UTF-8 but that threw an expat error.

This means that almost surely your "non-ascii" was not encoded
in UTF-8. Encode them this way and it will work.

>My second attempt was to write a function which replaced all the non- 
>ASCII characters with entities such as Ā
>
>Unfortunately his also doesn't work because tal:attributes escapes it  
>into Ā which then fails.

I have extended our local Zope version to support (beside "text"
and "structure") also "mtext" (for markup text). It does not
escape entity references but still escapes other markup.

>Finally, I tried tal:attributes with my function and the structure  
>keyword but 'structure' isn't supported with tal:attributes.

I have extended our local Zope to support "structure" for
attributes as well.


I could provide patches, if useful.

> ...
>Any ideas would be appreciated.


The correct (recommended) way it to encode your non-ascii
in the encoding you claim to be using. Then the "expat" error
will go away.

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


Re: [Zope] Re: zope 2.8.6 on Mac Intel

2006-03-19 Thread manuel spuhler
Hello,

Thank you for your hints. I successfully compiled python2.3.5 for OS
10.4, as described in Florent Guillaume's blog, but when I try to
compile Zope, I get the same error:

$ ./configure --prefix=/opt/Zope2.8 --with-python=/usr/local/bin/python2.3

Using Python interpreter at /usr/local/bin/python2.3

Configuring Zope installation

  - Zope top-level binary directory will be /opt/Zope2.8.
  - Makefile written.

  Next, run make.

$ make
"/usr/local/bin/python2.3" "/Users/spuhlema/Desktop/Zope-2.8.6-final/setup.py" \
build
--build-base="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/python-2.3"
--build-lib="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/python-2.3/build-lib"
--build-scripts="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/python-2.3/build-scripts"
--build-temp="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/python-2.3/build-temp"
running build
running build_py
error: package directory
'build/lib/darwin-8/5/2-i386-2/4/zope/app/traversing/ftests' does not
exist
make: *** [build] Error 1

I guess Python doesn't compile equally on PowerPc and Intel.
Any idea?


2006/3/19, Jens Vagelpohl <[EMAIL PROTECTED]>:
> > $ make
> > "/usr/bin/python" "/Users/spuhlema/Desktop/Zope-2.8.6-final/
> > setup.py" \
> > build
> > --build-base="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/
> > python-2.3"
> > --build-lib="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/
> > python-2.3/build-lib"
> > --build-scripts="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-
> > base/python-2.3/build-scripts"
> > --build-temp="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/
> > python-2.3/build-temp"
>
> This line shows you are using the system Python at /usr/bin/python.
> Don't. It's no good at all for compiling anything. Run "configure"
> with the --with-python=/path/to/python flag to use a self-compiled
> Python.
>
> I have never used the Fink Python. It is child's play to compile
> Python yourself (with the exception of Python 2.3.5 on OS X 10.4), so
> that's the way to go. Here's the instructions I work from:
>
> http://www.zope.org/Members/jens/docs/Document.2003-12-27.2431
>
> These are not written for OS X/i386, but I'd be surprised if they
> didn't work on both platforms.
>
> jens
>
> ___
> Zope maillist  -  Zope@zope.org
> http://mail.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://mail.zope.org/mailman/listinfo/zope-announce
>  http://mail.zope.org/mailman/listinfo/zope-dev )
>
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: zope 2.8.6 on Mac Intel

2006-03-19 Thread Jens Vagelpohl

$ make
"/usr/bin/python" "/Users/spuhlema/Desktop/Zope-2.8.6-final/ 
setup.py" \

build
--build-base="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/ 
python-2.3"
--build-lib="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/ 
python-2.3/build-lib"
--build-scripts="/Users/spuhlema/Desktop/Zope-2.8.6-final/build- 
base/python-2.3/build-scripts"
--build-temp="/Users/spuhlema/Desktop/Zope-2.8.6-final/build-base/ 
python-2.3/build-temp"


This line shows you are using the system Python at /usr/bin/python.  
Don't. It's no good at all for compiling anything. Run "configure"  
with the --with-python=/path/to/python flag to use a self-compiled  
Python.


I have never used the Fink Python. It is child's play to compile  
Python yourself (with the exception of Python 2.3.5 on OS X 10.4), so  
that's the way to go. Here's the instructions I work from:


http://www.zope.org/Members/jens/docs/Document.2003-12-27.2431

These are not written for OS X/i386, but I'd be surprised if they  
didn't work on both platforms.


jens

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

http://mail.zope.org/mailman/listinfo/zope-dev )