[Zope-Checkins] SVN: Zope/branches/Zope-2_8-branch/ Move to ZODB 3.4.1a6. This restores the LoopCallback.exit_status

2005-07-19 Thread Tim Peters
Log message for revision 37340:
  Move to ZODB 3.4.1a6.  This restores the LoopCallback.exit_status
  gimmick back to where it was.
  

Changed:
  _U  Zope/branches/Zope-2_8-branch/lib/python/
  _U  Zope/branches/Zope-2_8-branch/utilities/

-=-

Property changes on: Zope/branches/Zope-2_8-branch/lib/python
___
Name: svn:externals
   - zope   
svn://svn.zope.org/repos/main/Zope3/tags/ZopeX3-3.0.0-Zope-2.8-a4/src/zope
ZConfigsvn://svn.zope.org/repos/main/ZConfig/tags/ZConfig-2.3
BTrees svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/BTrees
Persistencesvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/Persistence
persistent svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/persistent
ThreadedAsync  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ThreadedAsync
transactionsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/transaction
ZEOsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ZEO
ZODB   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ZODB
ZopeUndo   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ZopeUndo
zdaemonsvn://svn.zope.org/repos/main/zdaemon/tags/zdaemon-1.1

   + zope   
svn://svn.zope.org/repos/main/Zope3/tags/ZopeX3-3.0.0-Zope-2.8-a4/src/zope
ZConfigsvn://svn.zope.org/repos/main/ZConfig/tags/ZConfig-2.3
BTrees svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/BTrees
Persistencesvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/Persistence
persistent svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/persistent
ThreadedAsync  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ThreadedAsync
transactionsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/transaction
ZEOsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ZEO
ZODB   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ZODB
ZopeUndo   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ZopeUndo
zdaemonsvn://svn.zope.org/repos/main/zdaemon/tags/zdaemon-1.1



Property changes on: Zope/branches/Zope-2_8-branch/utilities
___
Name: svn:externals
   - ZODBTools  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/scripts

   + ZODBTools  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/scripts


___
Zope-Checkins maillist  -  Zope-Checkins@zope.org
http://mail.zope.org/mailman/listinfo/zope-checkins


[Zope-Checkins] SVN: Zope/trunk/ Merge rev 37340 from Zope 2.8 branch.

2005-07-19 Thread Tim Peters
Log message for revision 37341:
  Merge rev 37340 from Zope 2.8 branch.
  
  Move to ZODB 3.4.1a6.  This restores the LoopCallback.exit_status
  gimmick back to where it was.
  

Changed:
  _U  Zope/trunk/lib/python/
  _U  Zope/trunk/utilities/

-=-

Property changes on: Zope/trunk/lib/python
___
Name: svn:externals
   - zope   
svn://svn.zope.org/repos/main/Zope3/tags/ZopeX3-3.0.0-Zope-2.8-a4/src/zope
ZConfigsvn://svn.zope.org/repos/main/ZConfig/tags/ZConfig-2.3
BTrees svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/BTrees
Persistencesvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/Persistence
persistent svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/persistent
ThreadedAsync  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ThreadedAsync
transactionsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/transaction
ZEOsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ZEO
ZODB   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ZODB
ZopeUndo   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/ZopeUndo
zdaemonsvn://svn.zope.org/repos/main/zdaemon/tags/zdaemon-1.1

   + zope   
svn://svn.zope.org/repos/main/Zope3/tags/ZopeX3-3.0.0-Zope-2.8-a4/src/zope
ZConfigsvn://svn.zope.org/repos/main/ZConfig/tags/ZConfig-2.3
BTrees svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/BTrees
Persistencesvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/Persistence
persistent svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/persistent
ThreadedAsync  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ThreadedAsync
transactionsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/transaction
ZEOsvn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ZEO
ZODB   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ZODB
ZopeUndo   svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/ZopeUndo
zdaemonsvn://svn.zope.org/repos/main/zdaemon/tags/zdaemon-1.1



Property changes on: Zope/trunk/utilities
___
Name: svn:externals
   - ZODBTools  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a5/src/scripts

   + ZODBTools  svn://svn.zope.org/repos/main/ZODB/tags/3.4.1a6/src/scripts


___
Zope-Checkins maillist  -  Zope-Checkins@zope.org
http://mail.zope.org/mailman/listinfo/zope-checkins


[Zope-Coders] Zope tests: 8 OK

2005-07-19 Thread Zope tests summarizer
Summary of messages to the zope-tests list.
Period Mon Jul 18 11:01:02 2005 UTC to Tue Jul 19 11:01:02 2005 UTC.
There were 8 messages: 8 from Zope Unit Tests.


Tests passed OK
---

Subject: OK : Zope-2_6-branch Python-2.1.3 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:25:47 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002623.html

Subject: OK : Zope-2_6-branch Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:27:17 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002624.html

Subject: OK : Zope-2_7-branch Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:28:47 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002625.html

Subject: OK : Zope-2_7-branch Python-2.4.1 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:30:17 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002626.html

Subject: OK : Zope-2_8-branch Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:31:47 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002627.html

Subject: OK : Zope-2_8-branch Python-2.4.1 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:33:17 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002628.html

Subject: OK : Zope-trunk Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:34:47 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002629.html

Subject: OK : Zope-trunk Python-2.4.1 : Linux
From: Zope Unit Tests
Date: Mon Jul 18 23:36:17 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-July/002630.html

___
Zope-Coders mailing list
Zope-Coders@zope.org
http://mail.zope.org/mailman/listinfo/zope-coders


[Zope-Coders] Rescheduling Zope 2.8.1 b1

2005-07-19 Thread Andreas Jung
Because of some traveling next week I will push back the release for one or 
two days (means Jul 28th or 29th). Hope this won't hurt anyone.


Andreas

pgpLTH5RalkWJ.pgp
Description: PGP signature
___
Zope-Coders mailing list
Zope-Coders@zope.org
http://mail.zope.org/mailman/listinfo/zope-coders


Re: [Zope-Coders] Upcoming 2.8.1 release

2005-07-19 Thread Tim Peters
[Andreas Jung]
 Just the usual reminder from the release management :-) Zope 2.8.1 b1
 will be released next Wednesday

[Tim Peters]
 Is this correct?  Please confirm.

 http://www.zope.org/Wikis/DevSite/Projects/Zope2.8/MilestonePlan

 still says

 2.8.1 b1: 2005/7/27
 2.8.1 final: 2005/08/10

[Andreas]
 Argh...you're right again...I wonder why my Ical has all release dates one
 week earlier. I was not my goal to annoy or anger you :-)

Good thing, too, since you accomplished neither -- I was simply in a
state of panic.  I'm much calmer now -- thanks wink.
___
Zope-Coders mailing list
Zope-Coders@zope.org
http://mail.zope.org/mailman/listinfo/zope-coders


[Zope-dev] Reg Zope Installation Problem

2005-07-19 Thread praba kar
Dear All,

I try to install zope 2.7.0.  After the
installation. I have create zope installation
directory using mkzopeinstance.py.  From that
zope installation directory I try to run
bin/runzope command.  But It will give
below type error.
***

--
2005-07-19T19:00:04 INFO(0) ZServer HTTP server
started at Tue Jul 19 19:00:04 2005
Hostname: localhost.localdomain
Port: 8080
--
2005-07-19T19:00:04 INFO(0) ZServer FTP server started
at Tue Jul 19 19:00:04 2005
Hostname: prabahar
Port: 8021
--
2005-07-19T19:00:04 INFO(0) Zope Set effective user to
enmail
Traceback (most recent call last):
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/run.py,
line 49, in ?
run()
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/run.py,
line 19, in run
start_zope(opts.configroot)
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/__init__.py,
line 51, in start_zope
starter.startZope()
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/__init__.py,
line 230, in startZope
Zope.startup()
  File
/Programs/Zope/2.7.0/lib/python/Zope/__init__.py,
line 45, in startup
from Zope.App.startup import startup as _startup
  File
/Programs/Zope/2.7.0/lib/python/Zope/App/startup.py,
line 30, in ?
import OFS.Application
  File
/Programs/Zope/2.7.0/lib/python/OFS/Application.py,
line 18, in ?
import Globals,Folder,os,sys,App.Product,
App.ProductRegistry, misc_
  File
/Programs/Zope/2.7.0/lib/python/App/Product.py, line
44, in ?
from HelpSys.HelpSys import ProductHelp
  File
/Programs/Zope/2.7.0/lib/python/HelpSys/__init__.py,
line 15, in ?
import HelpSys
  File
/Programs/Zope/2.7.0/lib/python/HelpSys/HelpSys.py,
line 18, in ?
from Products.ZCatalog.ZCatalog import ZCatalog
  File
/Programs/Zope/2.7.0/lib/python/Products/ZCatalog/__init__.py,
line 16, in ?
import ZCatalog, Catalog, CatalogAwareness,
CatalogPathAwareness, ZClasses
  File
/Programs/Zope/2.7.0/lib/python/Products/ZCatalog/ZCatalog.py,
line 39, in ?
from IZCatalog import IZCatalog
  File
/Programs/Zope/2.7.0/lib/python/Products/ZCatalog/IZCatalog.py,
line 236, in ?
__doc__ = IZCatalog.__doc__ + __doc__
TypeError: unsupported operand type(s) for +:
'NoneType' and 'NoneType'
*
Kindly let me know what is the problem ? I didn't know
how to update zope.conf file.  Kindly guide
me how to start zope service

regards
Prabahar.





___
Too much spam in your inbox? Yahoo! Mail gives you the best spam protection for 
FREE! http://in.mail.yahoo.com
___
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] Re: [Zope-Coders] Upcoming 2.8.1 release

2005-07-19 Thread Tim Peters
[Andreas Jung]
 Just the usual reminder from the release management :-) Zope 2.8.1 b1
 will be released next Wednesday

[Tim Peters]
 Is this correct?  Please confirm.

 http://www.zope.org/Wikis/DevSite/Projects/Zope2.8/MilestonePlan

 still says

 2.8.1 b1: 2005/7/27
 2.8.1 final: 2005/08/10

[Andreas]
 Argh...you're right again...I wonder why my Ical has all release dates one
 week earlier. I was not my goal to annoy or anger you :-)

Good thing, too, since you accomplished neither -- I was simply in a
state of panic.  I'm much calmer now -- thanks wink.
___
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] Forcing Zope transaction commit

2005-07-19 Thread Bakhtiar A Hamid
On 7/19/05, David H [EMAIL PROTECTED] wrote:
 Hi list,
 
 At times (it seems)  necessary to force a Zope transaction commit.  This
 might occur between two zSQL calls where the second depends on the
 first's *SQL* transaction's availability but the first has not yet been
 commited because the *Zope* transaction that includes both zSQL calls
 has not yet been commited.
 
 I handled this with a call to an external script as below, eg
 
 . zSql1()
 . pyCommit()
 zSql2()
 Publish new page
 
 Here's pyCommit()
 
 # ...
 # Extenstion/pyCommit.py
 # ...
 from ZODB import FileStorage,DB
 
 def commit( self ):
t = get_transaction() # ZODB builtin
if t:
   t.commit()
 # ...
 
 Thats it. And it solved my problem. Is there a reason why this is a bad
 idea, all things being equal?  A better way to do it, when needed?
 

you're playing with fire  ;)

let zope handle the transaction

use dtml-var sql_delimeter to separate two or more sql calls

this way, if one of the call fails, the transaction will be aborted

gurus, correct me if i'm wrong, please

hth

 Thanks,
 David
 
 ___
 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 )
 


-- 
http://myzope.kedai.com.my - my-zope org
___
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] Forcing Zope transaction commit

2005-07-19 Thread David H




Bakhtiar A Hamid wrote:

  On 7/19/05, David H [EMAIL PROTECTED] wrote:
  
  
Hi list,

At times (it seems)  necessary to force a Zope transaction commit.  This
might occur between two zSQL calls where the second depends on the
first's *SQL* transaction's availability but the first has not yet been
commited because the *Zope* transaction that includes both zSQL calls
has not yet been commited.

I handled this with a call to an external script as below, eg

. zSql1()
. pyCommit()
zSql2()
Publish new page

Here's pyCommit()

# ...
# Extenstion/pyCommit.py
# ...
from ZODB import FileStorage,DB

def commit( self ):
   t = get_transaction() # ZODB builtin
   if t:
  t.commit()
# ...

Thats it. And it solved my problem. Is there a reason why this is a bad
idea, all things being equal?  A better way to do it, when needed?


  
  
you're playing with fire  ;)

let zope handle the transaction

use dtml-var sql_delimeter to separate two or more sql calls

this way, if one of the call fails, the transaction will be aborted

gurus, correct me if i'm wrong, please

hth

  
  

Bakhtiar,

Thanks very much for responding.

Your idea is what I thought of at first - but my Interbase Adapter
doesn't like COMMIT statements (!) and I didn't test it out. But it
seems that would not solve the problem because both ZSQL methods are
embedded in the *same* zope transaction stream, e.g.

. Submit a page
. call ZSQL1 (part of Zope Tran 100)
. call ZSQL2 (part of Zope Tran 100) --- this depends on zSqL1
being executed but the transaction has not been executed yet, its
pending.
. Display a page
. *now* Zope commits (executes all calls - which is too late in this
case).

When ZSQL2 is called ZSQL1's results are not yet executed into my RDMS
and therefore ZSQL2 cannot see whatever ZSQL1 did. (COMMITs not
with-standing).

Its understandable that Zope might wait between page presentations to
transact all changes until
all succeed ( an exception aborts the transaction). Its just in some
cases they can't all succeed until some
are transacted.

David





(even with your recommended COMMIT) is not available at the time ZSQL2
is called.

>From what i've seen it appears that Zope commits transactions 

David





___
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] Forcing Zope transaction commit

2005-07-19 Thread m . bizzarri
It would be better if you explain what you're trying to obtain. Inside a
single *Zope* transaction, all the queries are inside the same *RDBMS*
transaction.

Therefore, the second sql method should see the effects of the first
one. If that is not the case, review what is actually happening (i.e.
the first query may be failing even though you did not detect it).

Regards
Marco




On Mon, Jul 18, 2005 at 09:14:26PM -0700, David H wrote:
 Hi list,
 
 At times (it seems)  necessary to force a Zope transaction commit.  This 
 might occur between two zSQL calls where the second depends on the 
 first's *SQL* transaction's availability but the first has not yet been 
 commited because the *Zope* transaction that includes both zSQL calls 
 has not yet been commited.
 
 I handled this with a call to an external script as below, eg
 
 . zSql1()
 . pyCommit() 
 zSql2()
 Publish new page
 
 Here's pyCommit()
 
 # ...
 # Extenstion/pyCommit.py
 # ...
 from ZODB import FileStorage,DB
 
 def commit( self ):
   t = get_transaction() # ZODB builtin
   if t:
  t.commit()
 # ...
 
 Thats it. And it solved my problem. Is there a reason why this is a bad 
 idea, all things being equal?  A better way to do it, when needed?
 
 Thanks,
 David
 
 ___
 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 )

-- 
Marco Bizzarri - Amministratore Delegato - Icube S.r.l.
Sede:   Via Ridolfi 15 - 56124 Pisa (PI), Italia 
E-mail: [EMAIL PROTECTED]   WWW: www.icube.it   
Tel:(+39) 050 97 02 07  Fax: (+39) 050 31 36 588


signature.asc
Description: Digital 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] Forcing Zope transaction commit

2005-07-19 Thread Tino Wildenhain
Am Dienstag, den 19.07.2005, 00:35 -0700 schrieb David H:
...
 Your idea is what I thought of at first - but my Interbase Adapter
 doesn't like COMMIT statements (!)  and I didn't test it out.  But it
 seems that would not  solve the problem because both ZSQL methods are
 embedded in the *same* zope transaction stream, e.g.
 
 .  Submit a page
 .  call ZSQL1 (part of Zope Tran 100)
 . call ZSQL2  (part of Zope Tran 100)  --- this depends on zSqL1
 being executed but the transaction has not been executed yet, its
 pending.
 .  Display a page
 .  *now* Zope commits (executes all calls - which is too late in this
 case).
 
 When ZSQL2 is called ZSQL1's results are not yet executed into my RDMS
 and therefore ZSQL2 cannot see whatever ZSQL1 did. (COMMITs not
 with-standing).


Stop. Should Interbase here behave different? Its actually required
that a database makes changes visible to all queries in the _same
transaction_. It depends on Transaction Isolation Level 
if you see further changes, e.g. if your Database supports read
committed - this means you would see data changed by _other
transactions_ that started _after your transaction_.

 Its understandable that Zope might wait between page presentations to
 transact all changes until all succeed ( an exception aborts the
 transaction).  Its just in some cases they can't all succeed until
 some are transacted.

Thats weird. I'd like to see the model you are referring to here.
Are you perhaps playing with after-commit triggers? 

___
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 in treating custom exception

2005-07-19 Thread Marco Bizzarri

Hi all.

It looks like I've hit something which is already known (I've found this 
reference:


http://mail.zope.org/pipermail/zope-collector-monitor/2004-October/004316.html

)

I've a custom standard_error_html page, made with a Zope Page Template. 
I'm trying to provide a custom __str__ for a custom exception. This 
works, most of the time, but in some cases I encounter the following error:


TypeError: unbound method __str__() must be called with InvalidFolderId 
instance as first argument (got nothing instead)


InvalidFolderId is the custom exception, of course.

This is the code of the exception:

class InvalidFolderId(Exception):

def __init__(self, folder_id):
self.folder_id = folder_id

def __str__(self):
return folder id %s could not be found in the database % 
self.folder_id



folder_id is a number. What could be done to avoid this problem?

Thank you in advance for the help.

Regards
Marco
begin:vcard
fn:Marco Bizzarri
n:Bizzarri;Marco
org:Icube S.r.l.
adr:;;via Ridolfi 15;Pisa;PI;56124;Italy
email;internet:[EMAIL PROTECTED]
title:Amministratore Delegato
tel;work:+39-050-970-207
tel;fax:+39-050-3136-588
tel;cell:+39-348-640-4861
x-mozilla-html:FALSE
url:http://notenotturne.blogspot.com/
version:2.1
end:vcard

___
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] ZPyIRC and Zope 2.7

2005-07-19 Thread David

Hi

I installed ZPyIRC version 0.1.3 in Zope 2.7.5 and I get Zope  
Template Errors on two of the frames when trying to start a chat  
client. I don't know ZTP very well. (Python is 2.3.5)


I was hoping that maybe somebody has fixed the templates for 2.7.

Any help very welcome!

DR

Here a traceback from cwindowlist:

Traceback (innermost last):

Module ZPublisher.Publish, line 101, in publish
Module ZPublisher.mapply, line 88, in mapply
Module ZPublisher.Publish, line 39, in call_object
Module Shared.DC.Scripts.Bindings, line 306, in __call__
Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
Module Products.PageTemplates.PageTemplateFile, line 106, in _exec
Module Products.PageTemplates.PageTemplate, line 88, in pt_render
PageTemplateFile at /site/chat/stratis/ 
4d9d10fad2a83777ee81bbbae6be3f44/cwindowlist

Warning: Compilation failed
Warning: TAL.HTMLTALParser.NestingError: Open tags html, head,  
script do not match close tag /div, at line 262, column 50

PTRuntimeError: Page Template has errors.

Here a traceback from cuserlist:

Traceback (innermost last):

Module ZPublisher.Publish, line 101, in publish
Module ZPublisher.mapply, line 88, in mapply
Module ZPublisher.Publish, line 39, in call_object
Module Shared.DC.Scripts.Bindings, line 306, in __call__
Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
Module Products.PageTemplates.PageTemplateFile, line 106, in _exec
Module Products.PageTemplates.PageTemplate, line 88, in pt_render
PageTemplateFile at /site/chat/stratis/ 
4d9d10fad2a83777ee81bbbae6be3f44/cuserlist

Warning: Compilation failed
Warning: TAL.HTMLTALParser.NestingError: Open tags html, head,  
script do not match close tag /td, at line 32, column 79

PTRuntimeError: Page Template has errors.
___
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] ZPyIRC and Zope 2.7

2005-07-19 Thread Andreas Jung



--On 19. Juli 2005 09:57:27 +0100 David [EMAIL PROTECTED] wrote:


Hi

I installed ZPyIRC version 0.1.3 in Zope 2.7.5 and I get Zope  Template
Errors on two of the frames when trying to start a chat  client. I don't
know ZTP very well. (Python is 2.3.5)

I was hoping that maybe somebody has fixed the templates for 2.7.


You could fix the templates yourself or ask the author of the product :-)

-aj




pgp6I2N7WYX1N.pgp
Description: 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 )


[Zope] Reg Zope Installation Problem

2005-07-19 Thread praba kar
Dear All,

I try to install zope 2.7.0.  After the
installation. I have create zope installation
directory using mkzopeinstance.py.  From that
zope installation directory I try to run
bin/runzope command.  But It will give
below type error.
***

--
2005-07-19T19:00:04 INFO(0) ZServer HTTP server
started at Tue Jul 19 19:00:04 2005
Hostname: localhost.localdomain
Port: 8080
--
2005-07-19T19:00:04 INFO(0) ZServer FTP server started
at Tue Jul 19 19:00:04 2005
Hostname: prabahar
Port: 8021
--
2005-07-19T19:00:04 INFO(0) Zope Set effective user to
enmail
Traceback (most recent call last):
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/run.py,
line 49, in ?
run()
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/run.py,
line 19, in run
start_zope(opts.configroot)
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/__init__.py,
line 51, in start_zope
starter.startZope()
  File
/Programs/Zope/2.7.0/lib/python/Zope/Startup/__init__.py,
line 230, in startZope
Zope.startup()
  File
/Programs/Zope/2.7.0/lib/python/Zope/__init__.py,
line 45, in startup
from Zope.App.startup import startup as _startup
  File
/Programs/Zope/2.7.0/lib/python/Zope/App/startup.py,
line 30, in ?
import OFS.Application
  File
/Programs/Zope/2.7.0/lib/python/OFS/Application.py,
line 18, in ?
import Globals,Folder,os,sys,App.Product,
App.ProductRegistry, misc_
  File
/Programs/Zope/2.7.0/lib/python/App/Product.py, line
44, in ?
from HelpSys.HelpSys import ProductHelp
  File
/Programs/Zope/2.7.0/lib/python/HelpSys/__init__.py,
line 15, in ?
import HelpSys
  File
/Programs/Zope/2.7.0/lib/python/HelpSys/HelpSys.py,
line 18, in ?
from Products.ZCatalog.ZCatalog import ZCatalog
  File
/Programs/Zope/2.7.0/lib/python/Products/ZCatalog/__init__.py,
line 16, in ?
import ZCatalog, Catalog, CatalogAwareness,
CatalogPathAwareness, ZClasses
  File
/Programs/Zope/2.7.0/lib/python/Products/ZCatalog/ZCatalog.py,
line 39, in ?
from IZCatalog import IZCatalog
  File
/Programs/Zope/2.7.0/lib/python/Products/ZCatalog/IZCatalog.py,
line 236, in ?
__doc__ = IZCatalog.__doc__ + __doc__
TypeError: unsupported operand type(s) for +:
'NoneType' and 'NoneType'
*
Kindly let me know what is the problem ? I didn't know
how to update zope.conf file.  Kindly guide
me how to start zope service

regards
Prabahar.








__
Free antispam, antivirus and 1GB to save all your messages
Only in Yahoo! Mail: http://in.mail.yahoo.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 )


Re: [Zope] Reg Zope Installation Problem

2005-07-19 Thread Andreas Jung



--On 19. Juli 2005 14:42:01 +0100 praba kar [EMAIL PROTECTED] wrote:


Dear All,

I try to install zope 2.7.0.  After the
installation. I have create zope installation
directory using mkzopeinstance.py.  From that
zope installation directory I try to run
bin/runzope command.  But It will give


2.7.0 is *ancient*. Try 2.7.7.

-aj



pgp92Xsf3l6ZD.pgp
Description: 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] Reg Zope Installation Problem

2005-07-19 Thread Florent Guillaume
praba kar  [EMAIL PROTECTED] wrote:
 I try to install zope 2.7.0.

Stop right here. Zope 2.7.0 is hopelessly outdated. Use Zope 2.7.6.

Florent

-- 
Florent Guillaume, Nuxeo (Paris, France)   CTO, Director of RD
+33 1 40 33 71 59   http://nuxeo.com   [EMAIL PROTECTED]
___
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] question on python script, dtml method and options

2005-07-19 Thread Erik Myllymaki
I use the following template often. When using a page template for my MAIN page, 
I access the error and message vars with:


p tal:content=options/errorError message/p
p tal:content=options/messageReg. Message/p

How would I access them when I use a dtml-method for my MAIN page?
dtml-var error and dtml-var message don't seem to work.

Python Script - index_html:

# Import a standard function, and get the HTML request and response objects.
from Products.PythonScripts.standard import html_quote
request = container.REQUEST
RESPONSE =  request.RESPONSE

error=''
message=''

if not request.has_key('next_state'):
  return container['MAIN'](context, request, error=error, message=message)

elif  request.get('next_state') == 'Do Something':
  try:
doSomething()
message = message + 'We did something'
  except:
error = error + 'Error in doSomething()'


elif  request.get('next_state') == 'Do Something Else':
  try:
doSomethingElse()
message = message + 'We did something else'
  except:
error = error + 'Error in doSomethingElse()'


return container['MAIN'](context, request, error=error, message=message)

___
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] question on python script, dtml method and options

2005-07-19 Thread Peter Bengtsson
On 7/19/05, Erik Myllymaki [EMAIL PROTECTED] wrote:
 I use the following template often. When using a page template for my MAIN 
 page,
 I access the error and message vars with:
 
 p tal:content=options/errorError message/p
 p tal:content=options/messageReg. Message/p
 
 How would I access them when I use a dtml-method for my MAIN page?
 dtml-var error and dtml-var message don't seem to work.
 

That _should_ work. 
In DTML, I think when you ask for something it does a options,
REQUEST, context, acquisition context lookup all in one loop. In TAL
you can't be lazy :( and you have to specify exactly where you expect
it to come from.

Bare in mind that keyword arguments only span across ONE template
where as variables in REQUEST span across ALL templates.

Doublecheck your template usage and/or send us your traceback.

 Python Script - index_html:
 
 # Import a standard function, and get the HTML request and response objects.
 from Products.PythonScripts.standard import html_quote
 request = container.REQUEST
 RESPONSE =  request.RESPONSE
 
 error=''
 message=''
 
 if not request.has_key('next_state'):
return container['MAIN'](context, request, error=error, message=message)
 
 elif  request.get('next_state') == 'Do Something':
try:
  doSomething()
  message = message + 'We did something'
except:
  error = error + 'Error in doSomething()'
 
 
 elif  request.get('next_state') == 'Do Something Else':
try:
  doSomethingElse()
  message = message + 'We did something else'
except:
  error = error + 'Error in doSomethingElse()'
 
 
 return container['MAIN'](context, request, error=error, message=message)
 
 ___
 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 )
 


-- 
Peter Bengtsson, 
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.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 )


Re: [Zope] question on python script, dtml method and options

2005-07-19 Thread Erik Myllymaki
I don't get a traceback, i just get error and message back as empty strings; 
their initiallized value.


very strange.



Peter Bengtsson wrote:

On 7/19/05, Erik Myllymaki [EMAIL PROTECTED] wrote:


I use the following template often. When using a page template for my MAIN page,
I access the error and message vars with:

p tal:content=options/errorError message/p
p tal:content=options/messageReg. Message/p

How would I access them when I use a dtml-method for my MAIN page?
dtml-var error and dtml-var message don't seem to work.




That _should_ work. 
In DTML, I think when you ask for something it does a options,

REQUEST, context, acquisition context lookup all in one loop. In TAL
you can't be lazy :( and you have to specify exactly where you expect
it to come from.

Bare in mind that keyword arguments only span across ONE template
where as variables in REQUEST span across ALL templates.

Doublecheck your template usage and/or send us your traceback.



Python Script - index_html:

# Import a standard function, and get the HTML request and response objects.
from Products.PythonScripts.standard import html_quote
request = container.REQUEST
RESPONSE =  request.RESPONSE

error=''
message=''

if not request.has_key('next_state'):
  return container['MAIN'](context, request, error=error, message=message)

elif  request.get('next_state') == 'Do Something':
  try:
doSomething()
message = message + 'We did something'
  except:
error = error + 'Error in doSomething()'


elif  request.get('next_state') == 'Do Something Else':
  try:
doSomethingElse()
message = message + 'We did something else'
  except:
error = error + 'Error in doSomethingElse()'


return container['MAIN'](context, request, error=error, message=message)

___
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] question on python script, dtml method and options

2005-07-19 Thread Peter Bengtsson
On 7/19/05, Erik Myllymaki [EMAIL PROTECTED] wrote:
 I don't get a traceback, i just get error and message back as empty strings;
 their initiallized value.
 

So you're not getting an error. 
What is the initialized value? Is 'error' and 'message' set in REQUEST?
(that you can find out from doing dtml-var REQUEST)


 
 
 Peter Bengtsson wrote:
  On 7/19/05, Erik Myllymaki [EMAIL PROTECTED] wrote:
 
 I use the following template often. When using a page template for my MAIN 
 page,
 I access the error and message vars with:
 
 p tal:content=options/errorError message/p
 p tal:content=options/messageReg. Message/p
 
 How would I access them when I use a dtml-method for my MAIN page?
 dtml-var error and dtml-var message don't seem to work.
 
 
 
  That _should_ work.
  In DTML, I think when you ask for something it does a options,
  REQUEST, context, acquisition context lookup all in one loop. In TAL
  you can't be lazy :( and you have to specify exactly where you expect
  it to come from.
 
  Bare in mind that keyword arguments only span across ONE template
  where as variables in REQUEST span across ALL templates.
 
  Doublecheck your template usage and/or send us your traceback.
 
 
 Python Script - index_html:
 
 # Import a standard function, and get the HTML request and response objects.
 from Products.PythonScripts.standard import html_quote
 request = container.REQUEST
 RESPONSE =  request.RESPONSE
 
 error=''
 message=''
 
 if not request.has_key('next_state'):
return container['MAIN'](context, request, error=error, message=message)
 
 elif  request.get('next_state') == 'Do Something':
try:
  doSomething()
  message = message + 'We did something'
except:
  error = error + 'Error in doSomething()'
 
 
 elif  request.get('next_state') == 'Do Something Else':
try:
  doSomethingElse()
  message = message + 'We did something else'
except:
  error = error + 'Error in doSomethingElse()'
 
 
 return container['MAIN'](context, request, error=error, message=message)
 
 ___
 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 )
 
 
 
 
 


-- 
Peter Bengtsson, 
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.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 )


Re: [Zope] question on python script, dtml method and options

2005-07-19 Thread Erik Myllymaki

I am using DTML only because I am using the excellent Calendar tag product.

sometimes, the links on the calendar tag get affected by from variables so as a 
hack i re-write the QUERY_STRING using:


request.RESPONSE.redirect(request['URL'] + '?mode-calendar=' + 
request['mode-calendar'] + 'date-calendar=' + request['date-calendar'] + 
'location=' + request['location'])


instead of:

return container['MAIN'](context, request, error=error, message=message)

I originally left that detail out to avoid unnecessary confusion, but I think it 
might be the cause...ideas?






Peter Bengtsson wrote:

On 7/19/05, Erik Myllymaki [EMAIL PROTECTED] wrote:


I use the following template often. When using a page template for my MAIN page,
I access the error and message vars with:

p tal:content=options/errorError message/p
p tal:content=options/messageReg. Message/p

How would I access them when I use a dtml-method for my MAIN page?
dtml-var error and dtml-var message don't seem to work.




That _should_ work. 
In DTML, I think when you ask for something it does a options,

REQUEST, context, acquisition context lookup all in one loop. In TAL
you can't be lazy :( and you have to specify exactly where you expect
it to come from.

Bare in mind that keyword arguments only span across ONE template
where as variables in REQUEST span across ALL templates.

Doublecheck your template usage and/or send us your traceback.



Python Script - index_html:

# Import a standard function, and get the HTML request and response objects.
from Products.PythonScripts.standard import html_quote
request = container.REQUEST
RESPONSE =  request.RESPONSE

error=''
message=''

if not request.has_key('next_state'):
  return container['MAIN'](context, request, error=error, message=message)

elif  request.get('next_state') == 'Do Something':
  try:
doSomething()
message = message + 'We did something'
  except:
error = error + 'Error in doSomething()'


elif  request.get('next_state') == 'Do Something Else':
  try:
doSomethingElse()
message = message + 'We did something else'
  except:
error = error + 'Error in doSomethingElse()'


return container['MAIN'](context, request, error=error, message=message)

___
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] question on python script, dtml method and options

2005-07-19 Thread Peter Bengtsson
How you get to the page is irrelevant. I don't care if you redirect
there or type in the url or click a link.

On 7/19/05, Erik Myllymaki [EMAIL PROTECTED] wrote:
 I am using DTML only because I am using the excellent Calendar tag product.
 
 sometimes, the links on the calendar tag get affected by from variables so as 
 a
 hack i re-write the QUERY_STRING using:
 
 request.RESPONSE.redirect(request['URL'] + '?mode-calendar=' +
 request['mode-calendar'] + 'date-calendar=' + request['date-calendar'] +
 'location=' + request['location'])
 
 instead of:
 
 return container['MAIN'](context, request, error=error, message=message)
 
 I originally left that detail out to avoid unnecessary confusion, but I think 
 it
 might be the cause...ideas?
 
 
 
 
 
 Peter Bengtsson wrote:
  On 7/19/05, Erik Myllymaki [EMAIL PROTECTED] wrote:
 
 I use the following template often. When using a page template for my MAIN 
 page,
 I access the error and message vars with:
 
 p tal:content=options/errorError message/p
 p tal:content=options/messageReg. Message/p
 
 How would I access them when I use a dtml-method for my MAIN page?
 dtml-var error and dtml-var message don't seem to work.
 
 
 
  That _should_ work.
  In DTML, I think when you ask for something it does a options,
  REQUEST, context, acquisition context lookup all in one loop. In TAL
  you can't be lazy :( and you have to specify exactly where you expect
  it to come from.
 
  Bare in mind that keyword arguments only span across ONE template
  where as variables in REQUEST span across ALL templates.
 
  Doublecheck your template usage and/or send us your traceback.
 
 
 Python Script - index_html:
 
 # Import a standard function, and get the HTML request and response objects.
 from Products.PythonScripts.standard import html_quote
 request = container.REQUEST
 RESPONSE =  request.RESPONSE
 
 error=''
 message=''
 
 if not request.has_key('next_state'):
return container['MAIN'](context, request, error=error, message=message)
 
 elif  request.get('next_state') == 'Do Something':
try:
  doSomething()
  message = message + 'We did something'
except:
  error = error + 'Error in doSomething()'
 
 
 elif  request.get('next_state') == 'Do Something Else':
try:
  doSomethingElse()
  message = message + 'We did something else'
except:
  error = error + 'Error in doSomethingElse()'
 
 
 return container['MAIN'](context, request, error=error, message=message)
 
 ___
 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 )
 
 
 
 
 


-- 
Peter Bengtsson, 
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.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: question on python script, dtml method and options

2005-07-19 Thread Josef Meile

Hi Erik,

I don't get a traceback, i just get error and message back as empty 
strings; their initiallized value.


very strange.

Looking at your python script I saw that initially you set error and
message to the empty string ''. I guess the script is not detecting a
'next_state' keyword in the request. So, it is excecuting the first if
of your code:

if not request.has_key('next_state'):
  return container['MAIN'](context, request, error=error, message=message)

Where are you initializing 'next_state'? Try printing the request
object to see if it really exists or perhaps you are doing some typo.

Regards,
Josef

___
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: question on python script, dtml method and options

2005-07-19 Thread Erik Myllymaki
next_state does get initialized - it is the name of the submit buttons on my 
various forms.



Josef Meile wrote:

Hi Erik,

I don't get a traceback, i just get error and message back as empty 
strings; their initiallized value.


very strange.


Looking at your python script I saw that initially you set error and
message to the empty string ''. I guess the script is not detecting a
'next_state' keyword in the request. So, it is excecuting the first if
of your code:

if not request.has_key('next_state'):
  return container['MAIN'](context, request, error=error, message=message)

Where are you initializing 'next_state'? Try printing the request
object to see if it really exists or perhaps you are doing some typo.

Regards,
Josef

___
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] ZTUtils.Iterator value in ZPT

2005-07-19 Thread David Pratt

I want to intialize the value of ZTUtils.Iterator and use the value
to increment tabindex attribute  in my ZPT for forms in CMF

Something like:

div tal:define iterator python:modules['ZTUtils'].Iterator; 
div
.. html form contents
   .. a field
   input tal:attributes=tabindex 
python:Iterator.next() ...

 ... etc, etc.  
/div
/div

The first part gives me an iterator object.  How do I get its value as 
an integer?

___
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] ZopeProfiler (python profiler) - strange results

2005-07-19 Thread Maciej Wisniowski

Hi!

I've just run ZopeProfiler few times to check which functions are
slowest in my site and during analysis of the results I've found
something that confuses me a bit.

When I'm showing results using print_stats and ordered by time
I get times:

calls   tottime  percall   cumtime   percallfunction

...total_x...cumulative_x   ...   X:1026(__call__)


for function X.

This seemed good till I've used print_callees format which
showed me that function X is calling function Y and Z and
their execution times are:

functions_time = Y_call_time + Z_call_time.


As far as I understand it tottime is the time without
subfunctions' call times and cumtime is with subfunctions'
call times, so I supposed that:

cumulative_x - functions_time = total_x

but this is not true... in almost every case I've checked it is
rather:

total_x + functions_time  cumulative_x

Why? I don't think these are concurrent threads...
but what makes this difference? It's possibly
something trivial but... ;)


--
Maciej Wisniowski
___
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] ZTUtils.Iterator value in ZPT

2005-07-19 Thread Peter Bengtsson
On 7/19/05, David Pratt [EMAIL PROTECTED] wrote:
 I want to intialize the value of ZTUtils.Iterator and use the value
 to increment tabindex attribute  in my ZPT for forms in CMF
 
 Something like:
 
 div tal:define iterator python:modules['ZTUtils'].Iterator; 
 div

Don't you need to create it with a sequence like
div tal:define iterator python:modules['ZTUtils'].Iterator(range(100)); 
-- 
Peter Bengtsson, 
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.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] performance of textindexng2 vs. zctextindex

2005-07-19 Thread Francis Kelly
I recently installed TextIndexNG2 2.1.1 on a system running Zope 2.7.6 
on Fedora Core 3. I've been running some comparison tests with 
ZCTextIndex, which is what our site currently uses. We're indexing 
around 50,000 objects at the moment. For TextIndexNG2, this is the 
configuration:


Indexed attributes   keywordSearchSource
Default encodingutf-8
Storage StandardStorage
Stemmer english
Splitter: casefolding   enabled
Splitter: index single characters   disabled
Splitter: max. length of splitted words 64
Splitter: separator characters  .+-_@
Default query parserPyQueryParser
Autoexpansion   disabled
Stopwords   english
Normalizer  European
Use converters  disabled
Near distance   
Left truncation disabled



I've been struck that if the number of search hits is high, TextIndexNG2 
is much slower than ZCTextIndex. For example, if I do a search on 
'podcast' (our site deals w/ podcasting) I get about 14,000 hits. 
ZCTextIndex returns the results in about 0.1 seconds; TextIndexNG2 takes 
31 seconds or 300 times longer. In general, the more hits there are, the 
bigger the difference between the two search indexes.


TextIndexNG2 is great: it has many features that we really want and 
perhaps the cost of those features is performance vis-a-vis ZCTextIndex. 
But I'm hoping that maybe I've overlooked an obvious or not-so-obvious 
configuration issue that will enable me to speed up TextIndexNG2.


Thanks for any advice.

Francis Kelly
www.loomia.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 )


Re: [Zope] ZTUtils.Iterator value in ZPT

2005-07-19 Thread David Pratt
Hi Peter. Thanks for your reply.  I think I am getting closer with this 
but still not quite right.
It appears I am calling Iterator right, because it gets an Iterator 
instance and now getting number 1

but that doesn't tell me much.


div tal:define = tabindex python:Iterator(range(100));

div
.. html form contents
   .. a field
   input tal:attributes=tabindex/next ...
 ... another field  
/div

is giving tabindex=1 all the way through my forms.  I thought next 
meant next, meaning you are asking the iterator for the next value. 
What am I missing?


Regards,
David

On Tuesday, July 19, 2005, at 07:18 PM, Peter Bengtsson wrote:


On 7/19/05, David Pratt [EMAIL PROTECTED] wrote:

I want to intialize the value of ZTUtils.Iterator and use the value
to increment tabindex attribute  in my ZPT for forms in CMF

Something like:

div tal:define iterator python:modules['ZTUtils'].Iterator; 
div


Don't you need to create it with a sequence like
div tal:define iterator 
python:modules['ZTUtils'].Iterator(range(100)); 

--
Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.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] Zope Foundation Update

2005-07-19 Thread Rob Page

Foundation Update


This note updates progress on forming of the Zope
Foundation. To remain transparent as possible, we are
communicating in as timely a manner as possible.

First, we have contacted the Software Freedom Law
Center (SFLC) which specializes in the formation and
maintenance of the legal structures that support open
source software. From our first conference call with
our primary POC there (who also helped with the Plone
Foundation), we took away some homework items
including:

   (1) draft trademark license agreement between Zope
   Corporation and the Zope Foundation

   (2) draft/initial set of ByLaws and related formation
   documents that capture the spirit of what we've
   been discussing for a while now (i.e., Eclipse
   Foundation-inspired membership and Apache
   Software Foundation-inspired operations).

We have made progress on (2) but stopped when we
discovered a trademark violation that needs to be
addressed before Zope Corporation can properly license
the trademarks to the Zope Foundation.

During my stay at EuroPython I learned that eighteen
months ago (and without Zope Corporation's knowledge or
consent) Zope Europe Association (ZEA) registered a
trademark consisting of the Cirlce-Z (the stylized Z
surrounded by a circle) followed by the word ZOPE
(hereinafter Circle-Z-Zope).  The mark they
registered is identical to the corporate logo used by
Zope Corporation.

In the three weeks since learning of ZEA's illegitimate
registration of our marks we have tried diligently (but
unsuccessfully) to get ZEA to unconditionally transfer
the rights of the registration.

We have offered to reimburse the registration fees paid
by the ZEA to the WIPO (World Intellectual Property
Organization) in order to facilitate the transfer. We
have further offered to preserve their license to use
the Zope mark in the conduct of their business as an
association of Zope companies.

ZEA's registration represents an abuse of registration
and management of international trademarks and the
misappropriation of a mark that is clearly the property
of Zope Corporation.  We are sorely disappointed that
ZEA is unwilling to transfer the marks quickly and
quietly so that we can proceed swiftly toward the
formation of the Zope Foundation.

We know that the establishment of a fair trademark
license for the entire Zope community is an _essential_
component of the Zope Foundation. It is possible that
we will come to a conclusion with the ZEA prior to the
conclusion of a trademark dispute process.

However, as a result (and unfortunately), until this
matter is resolved using the established
legal/trademark management processes, we are not able
to proceed with the Zope Foundation. We will keep the
community updated as milestones are reached, so that
you know what the new target dates are for the
formation of the Foundation at the same time that we
do.

We recognize that there are lingering questions about
the trademark and our management thereof.  We have
captured our position on these marks in an open letter
to the Zope Community.  You can find this letter at:

o http://www.zope.com/about_us/legal/ 
ZopeCorpTrademarkManagement_OpenLetter.html


As an aside, the ZEA has also registered the Plone logo
as a trademark.  It is not our business, but came as a
surprise to us, that the Plone Foundation is not the
owner of the Plone trademark.

--
Rob Page   V: 540 361 1710
Zope Corporation   F: 703 995 0412

___
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] performance of textindexng2 vs. zctextindex

2005-07-19 Thread Andreas Jung



--On 19. Juli 2005 17:15:25 -0700 Francis Kelly [EMAIL PROTECTED] wrote:


I recently installed TextIndexNG2 2.1.1


which is *pretty old*. Take a look at the v 2.2.0 which has been optimized 
over the time in different ways. Consider using StupidStorage as documented 
in the release notes.




I've been struck that if the number of search hits is high, TextIndexNG2
is much slower than ZCTextIndex. For example, if I do a search on
'podcast' (our site deals w/ podcasting) I get about 14,000 hits.
ZCTextIndex returns the results in about 0.1 seconds; TextIndexNG2 takes
31 seconds or 300 times longer. In general, the more hits there are, the
bigger the difference between the two search indexes.


Query speed depends on different things: the query, the implementation, the 
operations needed to be performed during the query. Because of some 
functionality TXNG needs to store much more information than ZCTextIndex.

It did this as said above sometimes in a not so efficient way (see above).
You might also look at TextIndexNG V3.

-aj


pgpFYdmOCOO1D.pgp
Description: 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] Zope Foundation Update

2005-07-19 Thread Andreas Jung



--On 19. Juli 2005 19:07:25 -0400 Rob Page [EMAIL PROTECTED] wrote:


During my stay at EuroPython I learned that eighteen
months ago (and without Zope Corporation's knowledge or
consent) Zope Europe Association (ZEA) registered a
trademark consisting of the Cirlce-Z (the stylized Z
surrounded by a circle) followed by the word ZOPE
(hereinafter Circle-Z-Zope).  The mark they
registered is identical to the corporate logo used by
Zope Corporation.

In the three weeks since learning of ZEA's illegitimate
registration of our marks we have tried diligently (but
unsuccessfully) to get ZEA to unconditionally transfer
the rights of the registration.



Isn't this really strange? How can ZEA register any ZC trademark?!
Either ZC is the owner of the trademarks including Europe or it isn't?!
So either ZEA is violating the ZC trademark rights knowingly or ZC maybe 
never had any registered trademarks in Europeyou someone please clarify 
this (Paul?).


-aj

pgpJmdraambLk.pgp
Description: 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] Cool monkey patch to make tracebacks more useful :-)

2005-07-19 Thread Chris Withers

Dieter Maurer wrote:


Do you get a traceback by pdb?


I meant when I type w in a pdb session.


   I only get information of the form
   *** TypeError: exceptions.TypeError instance at 0x405e0cac

This is even more stupid than Microsoft error messages.

Today, I have been so annoyed by this that I decided to
improve pdb in this respect and donate the patch
as a feature for the Python core...


Indeed, if you could post any patches you make here, I'd be happy to 
include them in my little patch product.


cheers,

Chris

--
Simplistix - Content Management, Zope  Python Consulting
   - http://www.simplistix.co.uk

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