[Zope-Coders] Zope tests: 8 OK

2005-10-10 Thread Zope tests summarizer
Summary of messages to the zope-tests list.
Period Sun Oct  9 11:01:01 2005 UTC to Mon Oct 10 11:01:01 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: Sun Oct  9 22:28:54 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003287.html

Subject: OK : Zope-2_6-branch Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Sun Oct  9 22:30:24 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003288.html

Subject: OK : Zope-2_7-branch Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Sun Oct  9 22:31:54 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003289.html

Subject: OK : Zope-2_7-branch Python-2.4.1 : Linux
From: Zope Unit Tests
Date: Sun Oct  9 22:33:24 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003290.html

Subject: OK : Zope-2_8-branch Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Sun Oct  9 22:34:54 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003291.html

Subject: OK : Zope-2_8-branch Python-2.4.1 : Linux
From: Zope Unit Tests
Date: Sun Oct  9 22:36:24 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003292.html

Subject: OK : Zope-trunk Python-2.3.5 : Linux
From: Zope Unit Tests
Date: Sun Oct  9 22:37:54 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003293.html

Subject: OK : Zope-trunk Python-2.4.1 : Linux
From: Zope Unit Tests
Date: Sun Oct  9 22:39:24 EDT 2005
URL: http://mail.zope.org/pipermail/zope-tests/2005-October/003294.html

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


[Zope-dev] Allowing python logging from restricted code

2005-10-10 Thread Chris Withers

Hi All,

Would anyone have a problem if I added the necessary security 
declarations to allow the python logging module to be used from 
restricted code?


I'd like do this both for the trunk and the 2.8 branch, unless anyone 
has huge objections...


Furthermore, I'd like to change zope.conf to allow the flexibility of 
defining loggers that ZConfig normally provides out of the box, rather 
than being limited to just the event log and the access log. I'd like to 
just do this for the trunk...


Anyway, please let me know what you think!

cheers,

Chris

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

___
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] Re: [Zope-Checkins] SVN: Zope/trunk/lib/python/Shared/DC/ZRDB/ Collector #556: sqlvar now returns 'null' rather than 'None'.

2005-10-10 Thread Chris Withers

Andreas Jung wrote:
Argh...there is also a gadfly package coming from Zope 3. So when we 
remove it from the Zope 2 core we get it back with Zope 3 :-)


Well, having a lightweight semi-functional rdb engine in the distro has 
always seemed handy for me, mainly for testing rdb-related components 
with the certainty that the rdb engine you're testing with will always 
be there...


Maybe we should move it to the testing package?

cheers,

Chris

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

___
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: Gadfly (was: Collector #556: sqlvar now returns 'null' rather than 'None'.)

2005-10-10 Thread Jens Vagelpohl


On 10 Oct 2005, at 08:58, Chris Withers wrote:


Andreas Jung wrote:

Argh...there is also a gadfly package coming from Zope 3. So when  
we remove it from the Zope 2 core we get it back with Zope 3 :-)




Well, having a lightweight semi-functional rdb engine in the distro  
has always seemed handy for me, mainly for testing rdb-related  
components with the certainty that the rdb engine you're testing  
with will always be there...


Maybe we should move it to the testing package?


You're just moving the problem around with that. What's the point?

jens

___
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] Allowing python logging from restricted code

2005-10-10 Thread Jim Fulton

Chris Withers wrote:

Hi All,

Would anyone have a problem if I added the necessary security 
declarations to allow the python logging module to be used from 
restricted code?


I'd like do this both for the trunk and the 2.8 branch, unless anyone 
has huge objections...


I think you need to be very careful with this. IMO, this is something
that should not be turned on by default. OTOH, I have no problem with
making this possible to turn on.

Jim

--
Jim Fulton   mailto:[EMAIL PROTECTED]   Python Powered!
CTO  (540) 361-1714http://www.python.org
Zope Corporation http://www.zope.com   http://www.zope.org
___
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] Re: [Zope-Checkins] SVN: Zope/trunk/lib/python/Shared/DC/ZRDB/ Collector #556: sqlvar now returns 'null' rather than 'None'.

2005-10-10 Thread Sidnei da Silva
On Mon, Oct 10, 2005 at 08:58:53AM +0100, Chris Withers wrote:
| Andreas Jung wrote:
| Argh...there is also a gadfly package coming from Zope 3. So when we 
| remove it from the Zope 2 core we get it back with Zope 3 :-)
| 
| Well, having a lightweight semi-functional rdb engine in the distro has 
| always seemed handy for me, mainly for testing rdb-related components 
| with the certainty that the rdb engine you're testing with will always 
| be there...
| 
| Maybe we should move it to the testing package?

If I'm allowed to say anything, I would like to see gadfly being
replaced by sqlite. It's available mostly everywhere except in Windows
by default, as many products already use it. sqlite itself is 'public
domain' and the python da has the same license as zlib if i recall,
which is very permissive as well.

-- 
Sidnei da Silva
Enfold Systems, LLC.
http://enfoldsystems.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 )


Re: [Zope-dev] Re: [Zope-Checkins] SVN: Zope/trunk/lib/python/Shared/DC/ZRDB/ Collector #556: sqlvar now returns 'null' rather than 'None'.

2005-10-10 Thread Andrew Veitch
SQLite implements enough of a subset of SQL to be genuinely useful  
and it's performance isn't too bad either. There is a Zope DA for it  
somewhere too.


We've never been able to use Gadfly for testing as it's so far from  
standard SQL that it just causes more problems than it solves - as we  
saw at the beginning of this thread.


A

On 10 Oct 2005, at 15:03, Sidnei da Silva wrote:


On Mon, Oct 10, 2005 at 08:58:53AM +0100, Chris Withers wrote:
| Andreas Jung wrote:
| Argh...there is also a gadfly package coming from Zope 3. So  
when we

| remove it from the Zope 2 core we get it back with Zope 3 :-)
|
| Well, having a lightweight semi-functional rdb engine in the  
distro has
| always seemed handy for me, mainly for testing rdb-related  
components
| with the certainty that the rdb engine you're testing with will  
always

| be there...
|
| Maybe we should move it to the testing package?

If I'm allowed to say anything, I would like to see gadfly being
replaced by sqlite. It's available mostly everywhere except in Windows
by default, as many products already use it. sqlite itself is 'public
domain' and the python da has the same license as zlib if i recall,
which is very permissive as well.

--
Sidnei da Silva
Enfold Systems, LLC.
http://enfoldsystems.com


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



--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

___
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] Re: [Zope-Checkins] SVN: Zope/trunk/lib/python/Shared/DC/ZRDB/ Collector #556: sqlvar now returns 'null' rather than 'None'.

2005-10-10 Thread Andreas Jung



--On 10. Oktober 2005 11:03:54 -0300 Sidnei da Silva 
[EMAIL PROTECTED] wrote:





If I'm allowed to say anything, I would like to see gadfly being
replaced by sqlite. It's available mostly everywhere except in Windows
by default, as many products already use it. sqlite itself is 'public
domain' and the python da has the same license as zlib if i recall,
which is very permissive as well.



IMO there is no need to ship the Zope core  with *any* DB package except 
the ZODB. From the maintenance point of view  we should basically ship with 
packages that  we really need and that provide value to the core 
distribution. In Zope 2.6 we included Docutils with provided 
reStructuredText functionality. Updating and maintaining the package has 
been a minor pain in the past. Dealing with exploits in 3rd-party-packages 
(as it happened yesterday
with Docutils) is another issue. The core distribution should only ship 
with packages where we have a certain amount of expertise to deal with such 
issues. I assume nobody of us is a sqlite core developer and knows the 
sources. Otherwise we end up like Plone and ship with more 3rd-party 
packages from release to release.


-aj



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


[Zope-dev] RestrictedPython, TALES Expressions and CMF

2005-10-10 Thread Sidnei da Silva
(sorry for the cross-post)

I'm currently facing an issue that seems to be a result of a bad
interaction between CMF, TALES and Restricted Python.

The issue currently happens when:

  1. A TALES 'Path Expression' in 'Caching Policy Manager' is evaluated
  2. The result of evaluating a sub-expression is a Python Script (eg:
 object/modified where 'modified' is a Python Script)
  3. The context as built by CMF doesn't define 'here'

What happens in this case is that the call will end up in
PageTemplates/ZRPythonExpr.py:call_with_ns, which is reproduced here
for your pleasure:

  def call_with_ns(f, ns, arg=1):
  td = Rtd()
  td.this = ns['here']
  td._push(ns['request'])
  td._push(InstanceDict(td.this, td))
  td._push(ns)
  try:
  if arg==2:
  return f(None, td)
  else:
  return f(td)
  finally:
  td._pop(3)

Now, given that there has been a decision of deprecating 'here' in
favor of 'context', I'm not exactly sure about the fix.

CMF seems to create expression contexts in two places off the top of
my head: In 'CMFCore/Expression.py' and
'CMFCore/CachingPolicyManager.py'. None of those define 'here' or
'context' but instead just 'object'.

In 'Products/PageTemplates/TALES.py', in the 'translate' function,
'here' is also hardcoded, but that should be less of an issue as code
reaching into that function *should* have a proper expression context.

The question then is, which code is wrong? PageTemplates for relying
on 'here' being defined, or CMF for not defining 'here'? I volunteer
to provide a fix with tests as soon as someone clarifies which one
needs to be fixed.

As a reminder, 'actions' as defined by 'portal_actions' tool and
anything that derives from 'ActionProviderBase' suffer from the same
issue.

-- 
Sidnei da Silva
Enfold Systems, LLC.
http://enfoldsystems.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 )


Re: [Zope-PAS] Re: Moving PAS and PluginRegistry to SVN?

2005-10-10 Thread Lennart Regebro
On 10/9/05, Jens Vagelpohl [EMAIL PROTECTED] wrote:

 On 9 Oct 2005, at 19:46, Rocky Burt wrote:

  What is the timeframe on this being done?  Just so I know when to
  update my development versions of PAS.
 
  - Rocky
 
 
  Jens Vagelpohl wrote:
 
  I would volunteer to move both the PluggableAuthService and
  PluginRegistry products to svn.zope.org. Anyone have any thoughts
  about that?

 There is no time frame. Only Zac has responded and I'm not sure if
 that constitutes enough assent.

well, +1, then.
___
Zope-PAS mailing list
Zope-PAS@zope.org
http://mail.zope.org/mailman/listinfo/zope-pas


Re: [Zope] [Ann] Zope Hotfix 2005-10-09

2005-10-10 Thread Tino Wildenhain

Andreas Jung schrieb:

Hello,

a security issue with the Docutils package coming with Zope 2.6 or 
higher has been discovered. Sites that expose reStructuredText 
functionality to
untrusted users (typically portal sites allowing registered users to 
edit content) are possibly affected.


Download location and installation are available from

  http://www.zope.org/Products/Zope/Hotfix_2005-10-09/security_alert

The hotfix is supposed to work with any Zope 2.7 and 2.8 version.
It might work for Zope 2.6 and Python 2.1 but we can not give a 
guarantee since Zope 2.6 is no longer maintained. Plone sites do not 
seem to be affected (there seems to be some additional code on top of 
Zope's

reST implementation avoiding the failure) however this not a guarantee.
The upcoming Zope 2.8.2 and 2.7.8 releases will also ship with the hotfix.



Where are the details on the nature of the security problem?
___
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] LocalFS problems with @import-ing stylesheets

2005-10-10 Thread Peter Bengtsson
2005/10/10, Samuel Souk-aloun [EMAIL PROTECTED]:
 I can confirm the problem, the stylesheet is not rendered from localfs
 with firefox

 the problem is caused by an incorect http header text/plain instead of
 text/css
 I've tried to add a type_map to the LocalFS but the content-type does
 not change
 so, for me, it is clearly a LocalFS issue

 anyone knows how to hardcode this content-type in LocalFS.py ?

How about setting the content-type in the stylesheet file? That's what
I always do.
dtml-call RESPONSE.setHeader('Content-Type','text/css')

--
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: Presentations Available

2005-10-10 Thread Nick Davis

Rob, Tres,
  Thanks a lot for your helpful responses. I take Tres's point of the 
difficulty of making templates that work for the different interests of 
designers and programmers, and that migration headaches are often a 
consequence of this. Hadn't thought of it like that before.
  Also its good to hear that so much has been addressed in Zope 3 to 
make things modular. I will take more of a look at the Zope 3 book.
  I've not yet had the opportunity to go to any conferences and it is 
hard to know just how much has been addressed already and what problems 
are already being solved. One can easily live in ignorance and getting 
replies like this is very helpful.
  BTW Both Chris and I come from the UK where complaining about things 
is a national sport so please no-one take offence. ;-)

Nick

___
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] Write log file from script

2005-10-10 Thread Chris Withers

Dave Kuhlman wrote:


Why not zLOG?  Look at:

Zope-2.8.1-home/lib/python/zLOG/__init__.py


Well, zLOG is hopefully going away some time soon ;-)

You should really be using the python logging module, for which zLOG is 
now just a facade:


import logging
logger = logging.getLogger('event.whatever')

logger.info('Argh! Help, the world with end in %i seconds',end_of_time)

I'm just writing a proposal to make this available in untrusted code 
such as Script (Python)'s, but in the meantime, you can use an external 
method:


import logging

logger = logging.getLogger('event.myapplogger')

def log(self,level,message,*args,exc_info=False):

logger.log(getattr(logging,level),
   message,
   *args,
   exc_info = exc_info

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 )


[Zope] ODBC database adapter for zope2.8.1 on windows

2005-10-10 Thread Sreekanth S Rameshaiah
Dear Friends,
Is there any good ODBC database adapter for zope2.8.1 on windows?
Thanks and Regards,
 - sree
-- 


Sreekanth S Rameshaiah
Executive Director
Mahiti Infotech Pvt. Ltd.
Ph: +91 98455 12611
www.mahiti.org
www.mahiti.org/Team/Sreekanth

First they ignore you, then they laugh at you, then they fight you, 
then you win. -- Mahathma Gandhi

___
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] ODBC database adapter for zope2.8.1 on windows

2005-10-10 Thread Andreas Jung

google for mxodbc

--On 10. Oktober 2005 16:37:45 +0530 Sreekanth S Rameshaiah 
[EMAIL PROTECTED] wrote:



Dear Friends,
Is there any good ODBC database adapter for zope2.8.1 on windows?
Thanks and Regards,
 - sree
--


Sreekanth S Rameshaiah
Executive Director
Mahiti Infotech Pvt. Ltd.
Ph: +91 98455 12611
www.mahiti.org
www.mahiti.org/Team/Sreekanth

First they ignore you, then they laugh at you, then they fight you,
then you win. -- Mahathma Gandhi

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






pgpnIRtEjLrve.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] MailTemplates 1.0.0 Released!

2005-10-10 Thread Chris Withers
These allow you to use the full power of the the python email package 
along with Zope's Page Template technology to easily build and send 
fully standards compliant emails.


The key feaures are:

- Use familiar ZPT syntax to generate both plain text and html email

- Easily create multi-part messages including the attachment of files

- Flexible and powerful ways to specify addresses and headers for email
  to be sent

- Full access to Python's email package from restricted python code such
  as python scripts

- Fully integrated with CMF-based products by way of Filesystem-based
  MailTemplates

This is the first public release of MailTemplates following several 
months of testing and development.


For more information, please see: 
http://www.simplistix.co.uk/software/zope/mailtemplates


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 )


Re: [Zope] reading zope.config file for ClientStorage

2005-10-10 Thread Chris Withers

Mika, David P (Research) wrote:
To initialize ZEO clients with ClientStorage I need info such as host, port, etc.  All the needed stuff is tucked away nicely in the zope.config file and I would like to be using the zope machinery access it.  I know that what I need is in there somewhere, but when I try to follow how it happens in say the Zope startup, I get lost in all the dependencies and my head starts swirling.  


I would like to be able to use something like is in ZODB/config.py:

class ZEOClient(BaseConfig):

def open(self):
from ZEO.ClientStorage import ClientStorage
# config.server is a multikey of socket-address values
# where the value is a socket family, address tuple.
L = [server.address for server in self.config.server]
return ClientStorage(
L,
storage=self.config.storage,
cache_size=self.config.cache_size,
name=self.config.name,
client=self.config.client,
var=self.config.var,
min_disconnect_poll=self.config.min_disconnect_poll,
max_disconnect_poll=self.config.max_disconnect_poll,
wait=self.config.wait,
read_only=self.config.read_only,
read_only_fallback=self.config.read_only_fallback,
username=self.config.username,
password=self.config.password,
realm=self.config.realm)

here BaseConfig has that bit of magic that has self.config.

I guess I need to know how to instantiate this class.  Any ideas?


Have a look at the run.py file in Stepper:

http://www.simplistix.co.uk/software/zope/stepper

It shows you how to parse zope.conf without having to start Zope up...

You may wish to wait for Stepper 1.3.0, though, which shows you how to 
do this for both Zope 2.7 and Zope 2.8...


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 )


Re: [Zope] Re: ZAjax anyone?

2005-10-10 Thread Bakhtiar A Hamid
On 10/10/05, Greg Fischer [EMAIL PROTECTED] wrote:
Ok, after further investigation, Tim Morgan's React is not exactly what
I am looking for. That said, his work is outstanding, and I think
it's awesome! It's like Ruby On Rails implemented (better IMHO)
in Zope! Very cool!

However, I think what I want to work with is just a Zope product without the MVC stuff. 

here's how i look at it

we have zope (dtml/script/zsql-method) that do specific calls that spits out results via xmlrpc.

on the browser side, we have all these ajax libs - openrico, dojo,
mochikits, azax, DataRequestor, jsolait, tim morgan's mini, etc

we just need to connect the dots. the ajax lib + our java
functions/etc will call dtml/script/sql-method via xmlrpc(builtin) or
jasonrpc(with the jsonrpc product) and page will be updated inline(?)

not much voodo involved. everything is there already.

a simple demo is at http://myzope.kedai.com.my/blogs/kedai/demo/; a
script python that just spits out DateTime().pCommon(), and the other,
a script python tah calls html file randomly. replace that with
anythin we want.

zope rox! but i guess we all know that



Thanks again everyone!

GregOn 10/9/05, Greg Fischer 
[EMAIL PROTECTED] wrote:
Thank you everyone! I really appreciate all the input. It's
amazing what you find by doing a little more thorough
searching... here's more of what I am looking for: 
http://timmorgan.org/wiki/ReactFrameworkForZope

Tim Morgan has put together what I would call Zajax from the looks of
it. I am going to start playing around with it, and see how it
fits my needs.

On a side note, I have put together a quick 'n' dirty blog about the
things I am finding, particularly for XMLHTTP, not JSON or
XML-RPC. www.zajax.net - (I liked the name so much, I had
to register the domain! :)On 10/9/05, Michael Haubenwallner 

[EMAIL PROTECTED] wrote:
Chris McDonough wrote: On Oct 8, 2005, at 6:54 AM, Greg Fischer wrote: I would love to have a product (called ZAjax :) that simplyreceives a request from the client and spits out xml.To be morespecific, a
 set of classes that call ZSQL methods and retrieverecords, then send that back in xml format. We've had this built in to Zope for a long time in the form of XML- RPC.There are several _javascript_ libraries that implement an XML- RPC
 client, the best in my recollection being vcXMLRPC.http://myzope.kedai.com.my/blogs/kedai/49
shows a few different ways to do Ajax and Zope.
Michael--http://zope.org/Members/d2m

http://planetzope.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
 )-- Greg Fischer1st Byte Solutions

http://www.1stbyte.com

-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.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-announcehttp://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] NameError in Zope Tutorial Lesson 8

2005-10-10 Thread Bakhtiar A Hamid
On 10/9/05, Norbert Kaufmann [EMAIL PROTECTED] wrote:
Hello listmembers,I am fairly new to Zope and turning debugging on and googling a lot doesnot lead me to the solution of the problem.Learning Zope I got this error trying out lesson 8(cont.):--snip--
Error Type: NameErrorError Value: global name 'title' is not defined--snap--
there's some more traceback that may help us determine where it b0rked. 

Zope version: 2.7.7Python: 2.3.5OS: FreeBSD 4.11-STABLEPlease can anybody give me a hint. I simply can't await to get my Elvis
Photo Archive up and running.TIANorbert___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] reading zope.config file for ClientStorage

2005-10-10 Thread Mika, David P (Research)
I've taken a look at stepper and dug into the zope source again.  It looks like 
both are relying on a startup script akin to zopectl to marshal everything 
correctly.  I would rather not be using a startup script (besides I couldn't 
sort it out); this is what I have so far:

from Zope.Startup import options, handlers
opts = options.ZopeOptions()
opts.configfile='c:\Zope-Instance-Test\etc\zope-with-zeo.conf'
opts.load_schema()
opts.load_configfile()

unfortunately in the resulting options object, I'm not getting the stuff I need 
from the conf file, namely the ZODB storage stuff needed for ClientStorage.

The schema file that is being used by ZopeOptions is 
Zope/Startup/zopeschema.xml.  This only has a skeleton zodb_db section.  It 
looks like the meat  potatoes are in ZODB/component.xml, but I don't see how 
that is actually pulled in.

Any more ideas?
Dave


-Original Message-
From: Chris Withers [mailto:[EMAIL PROTECTED]
Sent: Monday, October 10, 2005 8:57 AM
To: Mika, David P (Research)
Cc: zope@zope.org
Subject: Re: [Zope] reading zope.config file for ClientStorage


Mika, David P (Research) wrote:
 To initialize ZEO clients with ClientStorage I need info such as host, port, 
 etc.  All the needed stuff is tucked away nicely in the zope.config file and 
 I would like to be using the zope machinery access it.  I know that what I 
 need is in there somewhere, but when I try to follow how it happens in say 
 the Zope startup, I get lost in all the dependencies and my head starts 
 swirling. 

 I would like to be able to use something like is in ZODB/config.py:

   class ZEOClient(BaseConfig):

   def open(self):
   from ZEO.ClientStorage import ClientStorage
   # config.server is a multikey of socket-address values
   # where the value is a socket family, address tuple.
   L = [server.address for server in self.config.server]
   return ClientStorage(
   L,
   storage=self.config.storage,
   cache_size=self.config.cache_size,
   name=self.config.name,
   client=self.config.client,
   var=self.config.var,
   min_disconnect_poll=self.config.min_disconnect_poll,
   max_disconnect_poll=self.config.max_disconnect_poll,
   wait=self.config.wait,
   read_only=self.config.read_only,
   read_only_fallback=self.config.read_only_fallback,
   username=self.config.username,
   password=self.config.password,
   realm=self.config.realm)

 here BaseConfig has that bit of magic that has self.config.

 I guess I need to know how to instantiate this class.  Any ideas?

Have a look at the run.py file in Stepper:

http://www.simplistix.co.uk/software/zope/stepper

It shows you how to parse zope.conf without having to start Zope up...

You may wish to wait for Stepper 1.3.0, though, which shows you how to
do this for both Zope 2.7 and Zope 2.8...

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 )


[Zope] proxy role for an external method

2005-10-10 Thread Reinoud van Leeuwen
Hi,

I have a working pyhton script in the ZODB that searches for members and 
is called by a xmlrpc client. Security is only needed based on source IP 
address, so Anonymous can execute it, but the script has an Authenticated 
proxy role.

I would like to convert this script to an Exteral Method in 
$INSTANCE_HOME/Extensions. This basically works, but I cannot see any way 
to specify the proxy role. And when it is not specified the script 
obviously does not work.

After some googling, I tried to make a scriptname.metadata file with:
[default]
proxy=Authenticicated

But that does not seem to work...

- Is the .metadata supported for external methods?
- Is there another way to set proxy roles in external methods?

TIA,

-- 
__
Nothing is as subjective as reality
Reinoud van Leeuwen[EMAIL PROTECTED]
http://www.xs4all.nl/~reinoud
__
___
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] How to make a table with sortable colmns?

2005-10-10 Thread Thomas Apostolou
Thank you all.
You have helped ance again.
after reading the article above i understood that apart from writing 

table id="sortable" class="listing" summary="Content listing" cellpadding="0" cellspacing="0"

i sould also import this 2 js files wich makes my page understand what class="listing" means in order to behave like i would expect it to.

script type="text/_javascript_" src=""script type="text/_javascript_" src=""
Andreas Jung [EMAIL PROTECTED] wrote:
--On 7. Oktober 2005 14:35:00 +0100 Thomas Apostolou <[EMAIL PROTECTED]>wrote: But how can i tell the table to sort the column i click on just like plone does with the members list?I think he was asking for a client-side-only solution. Googlefor "sortable table". This will link you to some JS based solutions.The solution from is working for us. Especially you can hook your own comparison methodswhen you are dealing with custom types to be sorted (european dates, etc.)-aj
		 
Χρησιμοποιείτε Yahoo! 
Βαρεθήκατε τα ενοχλητικά μηνύ ματα (spam); Το Yahoo! Mail διαθέτει την καλύτερη δυνατή προστασία κατά των ενοχλητικών μηνυμάτων  
http://login.yahoo.com/config/mail?.intl=gr ___
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] proxy role for an external method

2005-10-10 Thread Jens Vagelpohl


On 10 Oct 2005, at 16:49, Reinoud van Leeuwen wrote:

I would like to convert this script to an Exteral Method in
$INSTANCE_HOME/Extensions. This basically works, but I cannot see  
any way

to specify the proxy role. And when it is not specified the script
obviously does not work.


Have you *tried* that? External methods don't need proxy roles. They  
are trusted code.


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] proxy role for an external method

2005-10-10 Thread Andreas Jung



--On 10. Oktober 2005 17:49:20 +0200 Reinoud van Leeuwen 
[EMAIL PROTECTED] wrote:





I would like to convert this script to an Exteral Method in
$INSTANCE_HOME/Extensions. This basically works, but I cannot see any way
to specify the proxy role. And when it is not specified the script
obviously does not work.



ExternaMethod run without restriction so there is usually to need for proxy 
roles (there are no proxy roles) for ExternalMethods.


-aj




pgpwB668eu9Pm.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] NameError in Zope Tutorial Lesson 8

2005-10-10 Thread Norbert Kaufmann
Bakhtiar A Hamid wrote:
[...]
 there's some more traceback that may help us determine where it b0rked. 
 

Sorry to bother you. Those who can read have a big advantage ;)
I did not set the 'title' parameter in the scripts parameter list.

But I have learned a lot about Zope debugging. So this time is not
totally lost.

THX

Norbert
___
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] proxy role for an external method

2005-10-10 Thread Reinoud van Leeuwen
On Mon, Oct 10, 2005 at 05:06:22PM +0100, Jens Vagelpohl wrote:
 
 On 10 Oct 2005, at 16:49, Reinoud van Leeuwen wrote:
 I would like to convert this script to an Exteral Method in
 $INSTANCE_HOME/Extensions. This basically works, but I cannot see  
 any way
 to specify the proxy role. And when it is not specified the script
 obviously does not work.
 
 Have you *tried* that? External methods don't need proxy roles. They  
 are trusted code.

yes. I I run the script from the ZMI logged in as admin it finds members, 
but if I try it from an XMLRPC client it does not

-- 
__
Nothing is as subjective as reality
Reinoud van Leeuwen[EMAIL PROTECTED]
http://www.xs4all.nl/~reinoud
__
___
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] proxy role for an external method

2005-10-10 Thread Andreas Jung

Are you using CMF/Plone?

-aj

--On 10. Oktober 2005 19:18:00 +0200 Reinoud van Leeuwen 
[EMAIL PROTECTED] wrote:



On Mon, Oct 10, 2005 at 05:06:22PM +0100, Jens Vagelpohl wrote:


On 10 Oct 2005, at 16:49, Reinoud van Leeuwen wrote:
 I would like to convert this script to an Exteral Method in
 $INSTANCE_HOME/Extensions. This basically works, but I cannot see
 any way
 to specify the proxy role. And when it is not specified the script
 obviously does not work.

Have you *tried* that? External methods don't need proxy roles. They
are trusted code.


yes. I I run the script from the ZMI logged in as admin it finds members,
but if I try it from an XMLRPC client it does not

--
__
Nothing is as subjective as reality
Reinoud van Leeuwen[EMAIL PROTECTED]
http://www.xs4all.nl/~reinoud
__
___
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 )






pgpzAkMrzjRxx.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] proxy role for an external method

2005-10-10 Thread Reinoud van Leeuwen
On Mon, Oct 10, 2005 at 07:27:11PM +0200, Andreas Jung wrote:
 Are you using CMF/Plone?

yes. the main part of the function is:

   for brain in self.portal_catalog(portal_type='User',
SearchableText=SearchableText):
user = brain.getObject()
if user is None:
continue
results.append(getUserInfo(user))

This works in a pyhton script but not in an external one

-- 
__
Nothing is as subjective as reality
Reinoud van Leeuwen[EMAIL PROTECTED]
http://www.xs4all.nl/~reinoud
__
___
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] proxy role for an external method

2005-10-10 Thread Reinoud van Leeuwen
On Tue, Oct 11, 2005 at 03:42:44AM +1000, Alan Milligan wrote:

  yes. I I run the script from the ZMI logged in as admin it finds members, 
  but if I try it from an XMLRPC client it does not
  
 You're sure you haven't got an access control problem and that your
 xml-rpc client is not running up as Anonymous?

Yes the client is not loggin in. (and since it will be a commandline 
script it is not supposed to do).

If I hardcode some bogus data to be returned it works fine. But as soon 
as something in the catalog is searched it does not work. So the xmlrpc 
works.
If I run the script from the browser (with default parameters) logged in 
as Manager it works. So the functionality works.

But really searching for something through xmlrpc does not work. If I copy 
 paste the code in an (ZODB) Python script which I give the Authenticated 
proxy role it works perfect.

So I suspect the conclusion is that the external method lacks that proxy 
role

-- 
__
Nothing is as subjective as reality
Reinoud van Leeuwen[EMAIL PROTECTED]
http://www.xs4all.nl/~reinoud
__
___
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] proxy role for an external method

2005-10-10 Thread Andreas Jung



--On 10. Oktober 2005 20:00:23 +0200 Reinoud van Leeuwen 
[EMAIL PROTECTED] wrote:



But really searching for something through xmlrpc does not work. If I
copy   paste the code in an (ZODB) Python script which I give the
Authenticated  proxy role it works perfect.



Nonsense. Your problem has nothing to do with proxy roles since Plone 
modifies your query. You can also try to send and XMLRPC using basic 
authentication.


-aj

pgplG8joVeEUo.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] proxy role for an external method

2005-10-10 Thread Peter Bengtsson
2005/10/10, Reinoud van Leeuwen [EMAIL PROTECTED]:
 On Mon, Oct 10, 2005 at 07:27:11PM +0200, Andreas Jung wrote:
  Are you using CMF/Plone?

 yes. the main part of the function is:

for brain in self.portal_catalog(portal_type='User',
 SearchableText=SearchableText):
 user = brain.getObject()
 if user is None:
 continue
 results.append(getUserInfo(user))

 This works in a pyhton script but not in an external one


I find this hard to believe. But, for the External Method you might
need to allow Anonymous to View it if it's at all protected.
What's the output when you do it via xmlrpc? Is it [] or error?


--
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] proxy role for an external method

2005-10-10 Thread Reinoud van Leeuwen
On Mon, Oct 10, 2005 at 10:57:25PM +0100, Peter Bengtsson wrote:
 2005/10/10, Reinoud van Leeuwen [EMAIL PROTECTED]:
  On Mon, Oct 10, 2005 at 07:27:11PM +0200, Andreas Jung wrote:
   Are you using CMF/Plone?
 
  yes. the main part of the function is:
 
 for brain in self.portal_catalog(portal_type='User',
  SearchableText=SearchableText):
  user = brain.getObject()
  if user is None:
  continue
  results.append(getUserInfo(user))
 
  This works in a pyhton script but not in an external one
 
 
 I find this hard to believe. But, for the External Method you might
 need to allow Anonymous to View it if it's at all protected.

Done that 
 What's the output when you do it via xmlrpc? Is it [] or error?
[]

I understood that Plone does some extra magic, so I have to setup a 
securoty context... I'll post it here if I have a working solution

-- 
__
Nothing is as subjective as reality
Reinoud van Leeuwen[EMAIL PROTECTED]
http://www.xs4all.nl/~reinoud
__
___
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] proxy role for an external method

2005-10-10 Thread Peter Bengtsson
2005/10/10, Reinoud van Leeuwen [EMAIL PROTECTED]:
 On Mon, Oct 10, 2005 at 10:57:25PM +0100, Peter Bengtsson wrote:
  2005/10/10, Reinoud van Leeuwen [EMAIL PROTECTED]:
   On Mon, Oct 10, 2005 at 07:27:11PM +0200, Andreas Jung wrote:
Are you using CMF/Plone?
  
   yes. the main part of the function is:
  
  for brain in self.portal_catalog(portal_type='User',
   SearchableText=SearchableText):
   user = brain.getObject()
   if user is None:
   continue
   results.append(getUserInfo(user))
  
   This works in a pyhton script but not in an external one
  
 
  I find this hard to believe. But, for the External Method you might
  need to allow Anonymous to View it if it's at all protected.

 Done that
  What's the output when you do it via xmlrpc? Is it [] or error?
 []

Can you then debug wether it that's because portal_catalog(**kws)
doesn't return anything or because brain.getObject() constantly
returns None?


 I understood that Plone does some extra magic, so I have to setup a
 securoty context... I'll post it here if I have a working solution

Shouldn't really be the problem. Isn't portal_catalog just another
ZCatalog that has nothing to do with Plone except it's located inside
a Plone instance.

 --
 __
 Nothing is as subjective as reality
 Reinoud van Leeuwen[EMAIL PROTECTED]
 http://www.xs4all.nl/~reinoud
 __
 ___
 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] POSKeyError nightmare

2005-10-10 Thread Kevin Carlson

Dieter,

I'm not sure I understand what you mean by fixing them all as shown 
above.  You mention loading the object from the ZODB and deleting the 
broken references, but I'm not sure how to do that.  I have looked 
around for info on loading objects by oid but cannot find anything 
helpful.  Can you help me out?


Thanks,

Kevin

Dieter Maurer wrote:


Kevin Carlson wrote at 2005-9-24 22:28 -0400:
 


...
File /opt/Zope-2.7/lib/python/Products/ZCatalog/Lazy.py, line 138, 
in __init__

  else: self._len = len(seq)
File /opt/Zope-2.7/lib/python/ZODB/Connection.py, line 559, in setstate
  p, serial = self._storage.load(oid, self._version)
File /opt/Zope-2.7/lib/python/ZODB/FileStorage.py, line 689, in load
  return self._load(oid, version, self._index, self._file)
File /opt/Zope-2.7/lib/python/ZODB/FileStorage.py, line 657, in _load
  raise POSKeyError(oid)
ZODB.POSException.POSKeyError: 000e5fec
   



Your catalog contains the missing object

 


oid 0x25506L BTrees.OOBTree.OOBucket
last updated: 2005-09-19 10:00:59.079910, tid=0x3601B18FC130433L
refers to invalid objects:
  oid 0xE5FEBL missing: 'Products.CMFDefault.File.File'
  oid 0xE5FECL missing: 'BTrees.OOBTree.OOBucket'
   



The second is the one shown in your traceback above.

This means: the OOBucket with oid 0x25506 contains
two broken references.

Load it from the ZODB. Determine which keys belong to
the broken references and delete these keys.

 


...
All of the objects that are causing the POSKeyError I believe to be 
coming from a single instance of a very large BTreeFolder2 instance.  
Can anyone offer any remedy to remove or repair the offending objects?
   



You can fix them all as shown above.

While the POSKeyErrors will go away, you have (of course)
lost information.

 



___
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] proxy role for an external method

2005-10-10 Thread Jens Vagelpohl


On 10 Oct 2005, at 23:14, Peter Bengtsson wrote:

I understood that Plone does some extra magic, so I have to setup a
securoty context... I'll post it here if I have a working solution



Shouldn't really be the problem. Isn't portal_catalog just another
ZCatalog that has nothing to do with Plone except it's located inside
a Plone instance.


It *is* a problem. The reason is most likiely all the extra stuff the  
catalog tool adds to the query before it reaches the actual catalog.  
The workaround is something like this:


from Products.ZCatalog.ZCatalog import ZCatalog
results = ZCatalog.searchResults(portal_catalog, **kws)

That way you circumvent any query munging done in the catalog tool  
searchResults method, specifically the effective/expires and  
allowedRolesAndUsers filtering.


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] Re: Zope Hotfix 2005-10-09 broke my zope 2.7.5

2005-10-10 Thread John Schinnerer
Aloha,

I just applied the below hotfix as directed to a zope 2.7.5
installation on my development machine.

It broke something bad, now the browser just says

The connection was refused when attempting to contact localhost:9673

I cannot access the ZMI nor any site pages, not on localhost:9673 nor
on 127.0.0.1:9673

That is the port it was installed and had been working on.
I did nothing but install the hotfix as directed on the linked page
below.

I have completely restarted the machine.
At boot time the messages indicate that zope started fine, as usual.

Any help appreciated, the sooner the better.

thanks,
John S.

--- Andreas Jung [EMAIL PROTECTED] wrote:

 Hello,
 
 a security issue with the Docutils package coming with Zope 2.6 or
 higher 
 has been discovered. Sites that expose reStructuredText functionality
 to
 untrusted users (typically portal sites allowing registered users to
 edit 
 content) are possibly affected.
 
 Download location and installation are available from
 
http://www.zope.org/Products/Zope/Hotfix_2005-10-09/security_alert
 
 The hotfix is supposed to work with any Zope 2.7 and 2.8 version.
 It might work for Zope 2.6 and Python 2.1 but we can not give a
 guarantee 
 since Zope 2.6 is no longer maintained. Plone sites do not seem to be
 
 affected (there seems to be some additional code on top of Zope's
 reST implementation avoiding the failure) however this not a
 guarantee.
 The upcoming Zope 2.8.2 and 2.7.8 releases will also ship with the
 hotfix.
 
 
 Andreas Jung
 
  ___
 Zope-Announce maillist  -  Zope-Announce@zope.org
 http://mail.zope.org/mailman/listinfo/zope-announce
 
   Zope-Announce for Announcements only - no discussions
 
 (Related lists - 
  Users: http://mail.zope.org/mailman/listinfo/zope
  Developers: http://mail.zope.org/mailman/listinfo/zope-dev )
 




__ 
Yahoo! Music Unlimited 
Access over 1 million songs. Try it free.
http://music.yahoo.com/unlimited/
___
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 Hotfix 2005-10-09 broke my zope 2.7.5

2005-10-10 Thread Andreas Jung

r

--On 10. Oktober 2005 20:21:10 -0700 John Schinnerer 
[EMAIL PROTECTED] wrote:



Aloha,

I just applied the below hotfix as directed to a zope 2.7.5
installation on my development machine.

It broke something bad, now the browser just says

The connection was refused when attempting to contact localhost:9673

I cannot access the ZMI nor any site pages, not on localhost:9673 nor
on 127.0.0.1:9673

That is the port it was installed and had been working on.
I did nothing but install the hotfix as directed on the linked page
below.

I have completely restarted the machine.
At boot time the messages indicate that zope started fine, as usual.


When Zope does not respond to requests as stated then there has been 
something during the startup phase of phase. I do not believe that the patch
causes a startup problem. If it does then you applied it the wrong way or 
you are not telling us all details in terms of error messages happening 
during startup.


-aj




pgpJTUaOuo2od.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] Re: LocalFS problems with @import-ing stylesheets

2005-10-10 Thread Chris Beaven

Samuel Souk-aloun wrote:

I can confirm the problem, the stylesheet is not rendered from localfs
with firefox

the problem is caused by an incorect http header text/plain instead of
text/css
I've tried to add a type_map to the LocalFS but the content-type does
not change
so, for me, it is clearly a LocalFS issue

anyone knows how to hardcode this content-type in LocalFS.py ?
___
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 )



add this line to the typemap:
.css text/css DTMLDocument

It works for me
I hardcoded it into LocalFS.py (the last line is the one you need to add):
_types = {
'.html': ('text/html', 'DTMLDocument'),
'.htm': ('text/html', 'DTMLDocument'),
'.css': ('text/css', 'DTMLDocument'),  # ***SmileyChris *NEW*


___
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 security and packing the database

2005-10-10 Thread Cameron Beattie
I have created a script based on zope_pack from the Zope book which allows a 
username and password to be specified when it is called. I wish to create a 
user specifically for this purpose that only has the ability to pack the 
ZODB.


I've created a custom role and a user that has this role. Then I went to 
http://mydomain.com/Control_Panel/Database/main/manage_access and granted 
the backup role all available permissions. But the user can't login to 
http://mydomain.com/Control_Panel/Database/main/manage_workspace in order to 
pack the database. Obviously I'm missing something very fundamental here. 
Could anyone point me in the right direction please?


Regards

Cameron 


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