[Zope-dev] Why use apply(foo.__call__, ..)?

2000-09-01 Thread Ross Boylan

In looking over the code for ZWiki/ZC, I see a lot of places with the 
following construct:
apply(foo.__call__, some, arguments)
Why not just say
foo(some, arguments)?

Examples of the construct from ZWikiPage.py:
apply(self.aq_parent.standard_wiki_page.__call__,
   (None, REQUEST, REQUEST.RESPONSE))
or
apply(DTMLDocument.__call__,(self, self.aq_parent,
  REQUEST, REQUEST.RESPONSE))

[OK, in this case the question technically is why use apply(foo.__call__, 
(a, b, c)) instead of foo(a,b,c)? Hmmm...
x.foo(a, b, c) - foo.__call__(x, a, b, c).]

These requests are mostly, if not entirely, directed at 
WikiPages/Headers/etc, whose definition is, in part,
class ZWikiPage(DTMLDocument): #, CatalogAware):
 def __call__(self, client=None, REQUEST={}, RESPONSE=None, **kw):
 """Render a zwiki page, with standard header  footer
 """

I thought the use of keyword argument dictionaries in apply might explain 
this, but, as the two opening examples show, not all cases have 
keywords.  Second, even if they do one could say
aDocument(self, REQUEST, REQUEST.RESPONSE, kw).

I understand from Johan that this is "inherited" code (in the non OO 
sense), so I thought I'd throw this out as a general question.  Is there 
some subtlety of the interaction of Zope (acquisition, perhaps, or 
extension classes in general) and python that makes foo(x) and 
foo.__call__(x) have different meanings?
Is it something about standard_zwiki_page, which I notice is not a regular 
python variable?

I don't need the answer to this to do something; I'm just trying to 
understand how things work.

Thanks.




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




[Zope-dev] strange ZopeTime-behavior

2000-09-01 Thread Joachim Schmitz

The following dtml-snipplet:

dtml-var vonjahr
dtml-var vonmonat
dtml-var vontagbr
dtml-var bisjahr
dtml-var bismonat
dtml-var bistag
dtml-call
"REQUEST.set('vondatum',ZopeTime(vonjahr+'-'+vonmonat+'-'+vontag))"
dtml-call
"REQUEST.set('bisdatum',ZopeTime(bisjahr+'-'+bismonat+'-'+bistag))"
brdtml-var vondatum
dtml-var bisdatum
brdtml-var vondatum fmt="%d.%m.%Y" bis:
dtml-var bisdatum fmt="%d.%m.%Y"

produces the following output:

2000 8 1
2000 8 2 
2000/08/01 2000/08/02 --- correct 

31.07.2000 bis: 01.08.2000 --- one day less if used with fmt

Bug or feature ?

there is no TZ enviromentvariable set. 
Server is Zope-2.2.0 on RH 6.2 behind Apache with PCGI.


Mit freundlichen Grüßen

Joachim Schmitz  

  
AixtraWare, Ing. Büro für Internetanwendungen
Hüsgenstr. 33a, D-52457 Aldenhoven  
Telefon: +49-2464-8851, FAX: +49-2464-905163


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




Re: [Zope-dev] Compatibility issues: ZPatterns 0.4.2

2000-09-01 Thread Steve Alexander

Steve Alexander wrote:

 Phillip J. Eby wrote:

  Now, I can provide *unfiltered* linkage by direct delegation, but this
  would mean dropping the ability to selectively take only certain
  attributes
  or sheets from the parent.  But I suppose that, compared to dropping the
  capability to acquire altogether, this might be preferable.
 
 
 This sounds fine for my use of Triggers that apply across everything
 that a Specialist manages.

I've got ZPatterns 0.4.2a1 now.

I see that Folders w/ customizer support now have their own 
Data-plug-ins tab (they didn't before), and that it does direct 
delegation, rather than filtered forwarding.

Does this mean that your suggestion above has become a design decision 
for ZPatterns? Data plug-ins directly in Customizers and Specialists 
aren't due to be deprecated? I'm guessing that this is the case.

Also, it is a bit of a pain to refresh each of the DataManager instances 
on each upgrade. How about an external method in ZPatterns to walk the 
object tree and update instances as required? Perhaps it could use 
ZopeFind. Or, seeing as Specialists and Customizer folders contain other 
DataManagers, could you add a button to a tab in Specialists and 
Customizer folders that refreshes them, and recursively all the 
DataManagers they contain? Then I'd just have to go to each top-level 
datamanager and refresh them when I upgrade.


Oh also, FYI, we're using ZPatterns for a couple of medium sized 
projects, one of which is functionally complete. SkinScript has proved 
extremely useful. I've been able to evolve an application in a very 
clean way using propertysheets and SkinScript, whereas before I'd have 
had to retrofit a custom base class.

Phillip and Ty, thanks for your sharing your work and sharing your ideas.

 
-- 
Steve Alexander
Software Engineer
Cat-Box limited
http://www.cat-box.net


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




Re: [Zope-dev] MailHost, 2.2.1, and tracebacks

2000-09-01 Thread Shane Hathaway

Bill Anderson wrote:
 
 OK, I've bee trailing this bug for quite some time, and haven't found a solution 
other than not use 2.2.1 :(
 (snip)
   File /local/ZopeSites/TestBed/lib/python/OFS/DTMLMethod.py, line 172, in __call__
 (Object: mailPasswordTemplate)
   File /local/ZopeSites/TestBed/lib/python/DocumentTemplate/DT_String.py, line 528, 
in __call__
 (Object: mailPasswordTemplate)
   File /local/ZopeSites/TestBed/lib/python/Products/MailHost/SendMailTag.py, line 
182, in render
 (Object: MailHost)
   File /local/ZopeSites/TestBed/lib/python/OFS/DTMLMethod.py, line 194, in validate
 (Object: mailPasswordTemplate)
   File /local/ZopeSites/TestBed/lib/python/AccessControl/SecurityManager.py, line 
139, in validate
   File /local/ZopeSites/TestBed/lib/python/AccessControl/ZopeSecurityPolicy.py, line 
178, in validate
   File /local/ZopeSites/TestBed/lib/python/AccessControl/Owned.py, line 152, in 
getOwner
 (Object: mailPasswordTemplate)
 ValueError: (see above)

By any chance does it say something to the effect of "Unpack tuple of
incorrect size"?  If so, I suggest you add a "print owner" statement
just before line 152 of Owner.py and tell us what it says.

Shane

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




[Zope-dev] Not Globals.default__class_init__(Article) :-(

2000-09-01 Thread Chris Withers

Chris McDonough wrote:
 Did you run the Article class through Globals.default__class_init__()?
 E.g. (at the module level), e.g.:
 
 Globals.default__class_init__(Article)

Yup, all the possible related classes have been run through this...

cheers,

Chris

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




[Zope-dev] Acquisiton, wrapping and persistence...

2000-09-01 Thread Chris Withers

Brian Lloyd wrote:
 (I'm coming to this late, so ignore me if this is covered
 ground...)

It isn't :S

 Are you certain that you are not losing the acquistion context
 on your Articles somehow? 

There's a good chance that's right :S
Is there anything bad about storing wrapped attributes in a persistent
object?
Butch seemed pretty religious about unwrapping objects before he stored
them, and maybe he ain't quite wrapping them up right on the way out...

This may be a stupid question, but why does the object need to be
wrapped for security to work anyway?

cheers,

Chris

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




RE: [Zope-dev] Acquisiton, wrapping and persistence...

2000-09-01 Thread Brian Lloyd

  Are you certain that you are not losing the acquistion context
  on your Articles somehow? 
 
 There's a good chance that's right :S
 Is there anything bad about storing wrapped attributes in a persistent
 object?
 Butch seemed pretty religious about unwrapping objects before 
 he stored
 them, and maybe he ain't quite wrapping them up right on the 
 way out...

At one time (Jim would know if this is still the case), the 
ZODB didn't want to store wrapped objects. Wrapping (or 
"context") is a run-time, in-memory thing while "containment" 
is a persistent thing. Wrapping really shouldn't be 
persistent, since context changes based on the way you 
_access_ things and isn't really meaningful to the 
persistent state of an object hierarchy.

When you access a subobject via getattr, the Acquisition  
machinery will ensure that the returned object is correctly 
wrapped. If you store objects under the hood in a way that 
does not go through getattr, you always need to ensure 
wrapping yourself:

class Things(Implicit):
  # Things contains individual Thing objects. They are 
  # stored as direct attributes.

  def getThing(self, id):
# dont need to wrap, since we're going through getattr
return getattr(self, id)

class TrickyThings:
  # TrickyThings stores its Things internally in a dict
  # and thus we don't go through getattr. So we have to 
  # do wrapping manually

  def __init__(self):
self.things={}

  def getThing(self, id):
# need to wrap object before returning it
object=self.things[id]
return object.__of__(self)


...so I'd be looking for some of this sort of trickiness 
in the code where the result is not being wrapped.


 This may be a stupid question, but why does the object need to be
 wrapped for security to work anyway?

Because security is predicated on acquisition - that is why 
you can set a permission high in the tree and allow objects 
lower in the tree to "acquire permission settings" from that 
original setting. It lets you aggregate permission settings 
down the heirarchy.

So - technically if _all_ of your permission settings were 
made directly on the object in question (i.e. all of the 
"acquire permission settings" checkboxes were unchecked 
and all appropriate permission settings were checked 
directly on that object), then it would work. But (as in 
most cases) you are using acquired settings then the 
object will have to be wrapped and have an intact 
acquisition chain at the time permissions are checked in 
order to get the result you expect.


Brian Lloyd[EMAIL PROTECTED]
Software Engineer  540.371.6909  
Digital Creations  http://www.digicool.com 



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




Re: [Zope-dev] Compatibility issues: ZPatterns 0.4.2

2000-09-01 Thread Steve Alexander

"Phillip J. Eby" wrote:
 
 I see that Folders w/ customizer support now have their own
 Data-plug-ins tab (they didn't before), and that it does direct
 delegation, rather than filtered forwarding.
 
 Direct delegation?  I've lost you here.  If it's doing that, then
 something's broken.  

sorry -- I didn't really mean that.

 Check and see if you have any "Link to Parent Data
 Plug-ins" in your customizers (they're added by default now on new
 customizers).  You can filter the parent providers by selecting the ones
 you want to leave out on the "exclude" property.

That's what I meant. Great.

 Does this mean that your suggestion above has become a design decision
 for ZPatterns? Data plug-ins directly in Customizers and Specialists
 aren't due to be deprecated? I'm guessing that this is the case.
 
 Argh.  I knew there was something (else) I was forgetting to document in
 the CHANGES file.  I had better go fix that now.

I'll take that as a "yes" then. :-)

 Also, it is a bit of a pain to refresh each of the DataManager instances
 on each upgrade. How about an external method in ZPatterns to walk the
 object tree and update instances as required? Perhaps it could use
 ZopeFind. Or, seeing as Specialists and Customizer folders contain other
 DataManagers, could you add a button to a tab in Specialists and
 Customizer folders that refreshes them, and recursively all the
 DataManagers they contain? Then I'd just have to go to each top-level
 datamanager and refresh them when I upgrade.
 
 It isn't actually be necessary to refresh on every upgrade.  IIRC, that
 note about refreshing is in reference to pre-0.4.x versions.  I guess I
 need to fix that too...

I had a bit of oddness with a Folder with Customizer Support on
upgrading from 0-4-1snap1 to 0-4-2a1. Until I added then removed a
datamanager, there was some attribute error occuring. Unfortunately, I
didn't look into it before I accidentally fixed it. I'll be upgrading
another zope instance with ZPatterns later on, so I'll watch out for the
same behaviour then.

 do you think you could
 perhaps be persuaded to write a short reference and/or tutorial for us to
 include (perhaps as a help screen from the SkinScript method object's
 management screens)?  Thanks.

I have a DataSkins how-to / short introduction that is about half
complete. I was hoping to get this out by today, but then I discovered
SkinScript, and also real work got in the way :-)

I'll try and get it finished this weekend. Perhaps some of that can be
reused as help in the management screens.

--
Steve Alexander
Software Engineer
Cat-Box limited
http://www.cat-box.net

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




[Zope-dev] But I used __ac_permissions__! :S

2000-09-01 Thread Chris Withers

Brian Lloyd wrote:
 
 Here's a quick thing to try- if 'subject' is an attribute
 of your Article class, try adding:
 
 class Article(...):
   subject__roles__=None
 
 then restart and see if you still get unauthorized...

yup, I do :-(

And besides, 'subject' is already in __ac_permissions__, as you can see:

(a lot of stuff snipped out though ;-)

__ac_permissions__ = (
('View', ['subject','getThread'], ('Anonymous', 'Manager')),
)

and I do appropriate Globals.default__class_init__'s...

Man, I really have no idea, and not even any clue where to look.

The big factor seems to be that 'subject' is a string. I had a similar
problem with the SquishFile class with the 'icon' attribute.

When it was a string:

# protected by 'View' permission
icon = 'misc_/Squishdot/squishfile_img'

...even though it was a class variable and protected in
__ac_permissions__, I was getting very similar errors to the above...

I was lucky, in that case, because it was a class variable, I could turn
it into a method:

# protected by 'View' permission
def icon(self):
return 'misc_/Squishdot/squishfile_img'

...and, lo and behold, no more security errors from there... :S

Unfortunately, the string attributes in the Article class are instance
attributes, not class attributes, so I can't do the same thing :-(

Any ideas?

cheers,

Chris

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




Re: [Zope-dev] _setObject error - urgent!

2000-09-01 Thread Andy McKay

Sorry for the cross post and so on, panicked with a deadline approaching.
The error was caused my a cataloguing error after intialisation.

Thanks.

- Original Message -
From: "Andy McKay" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Thursday, August 31, 2000 10:00 AM
Subject: [Zope-dev] _setObject error - urgent!


 Hi,

 I think I have traced my error with cut and paste, I am getting an error
on
 _setObject. If the object is not registered with Zope properly this will
be
 a problem. Basic synopsis:

 Im importing an object from a script so Im getting a handle to the folder
I
 would like the object to be in: this is obj.

 Then I call add and set object:

 obj._setObject(id, globals()[doctype](id, m))

 This rather unusual syntax allows me to use a constructor for man
different
 objects. The type is specified in 'doctype', I then get this error:

 2000-08-31T16:56:57 PROBLEM(100) ASPNDoc Error: [exceptions.NameError:
 cat]

 Any ideas?

 Thanks in advance


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



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




[Zope-dev] StructuredText.py - bug or feature

2000-09-01 Thread nw_moriarty

I took an example of strucuture text from the document string of StructuredText.py

- Text encloded by double quotes followed by a colon, a URL, and concluded
  by punctuation plus white space, *or* just white space, is treated as a
  hyper link. For example:

"Zope":http://www.zope.org/ is ...

  Is interpreted as 'a href="http://www.zope.org/"Zope/a is '
  Note: This works for relative as well as absolute URLs.

The paragraph ends with a 'example' but the next line beging with "Zope" is not 
formatted as PRE but as a link.  If one moves the 'For example:' in a new paragraph 
we have better results.

Am I missing something?

Nigel


--== Sent via Deja.com http://www.deja.com/ ==--
Before you buy.

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




[Zope-dev] ZCatalog: text searches fail with sort_on + patch

2000-09-01 Thread Steve Alexander

I'm getting an error in Catalog when I specify sort_on on a field-index,
and also search on a text index.

Zope 2.2.1, Python 1.5.2


Error Type: TypeError
Error Value: loop over non-sequence

Traceback (innermost last):
  File lib/python/ZPublisher/Publish.py, line 222, in publish_module
  File lib/python/ZPublisher/Publish.py, line 187, in publish
  File lib/python/Zope/__init__.py, line 221, in
zpublisher_exception_hook
(Object: ProviderContainer)
  File lib/python/ZPublisher/Publish.py, line 171, in publish
  File lib/python/ZPublisher/mapply.py, line 160, in mapply
(Object: search)
  File lib/python/ZPublisher/Publish.py, line 112, in call_object
(Object: search)
  File lib/python/OFS/DTMLDocument.py, line 177, in __call__
(Object: search)
  File lib/python/DocumentTemplate/DT_String.py, line 528, in __call__
(Object: search)
  File lib/python/DocumentTemplate/DT_In.py, line 630, in renderwob
(Object: SiteIndex)
  File lib/python/Products/ZCatalog/ZCatalog.py, line 463, in
searchResults
(Object: Traversable)
  File lib/python/Products/ZCatalog/Catalog.py, line 602, in
searchResults
  File lib/python/Products/ZCatalog/Catalog.py, line 555, in
_indexedSearch
TypeError: (see above)

This seems to be a simple type incompatibility error.

Attached is a patch that fixes this.

In Collector, http://classic.zope.org:8080/Collector/1586/view

--
Steve Alexander
Software Engineer
Cat-Box limited
http://www.cat-box.net

*** Catalog.py.orig
--- Catalog.py
***
*** 552,558 
  if intset: 
  append((k,LazyMap(self.__getitem__, intset)))
  else:
! for r in rs:
  append((sort_index._unindex[r],
 LazyMap(self.__getitem__,[r])))
  
--- 552,558 
  if intset: 
  append((k,LazyMap(self.__getitem__, intset)))
  else:
! for r,x in rs.items():
  append((sort_index._unindex[r],
 LazyMap(self.__getitem__,[r])))
  



Re: [Zope-dev] But I used __ac_permissions__! :S

2000-09-01 Thread Phillip J. Eby

This is just a SWAG (Strategic Wild-Ass Guess), but Ty and I have been
having a problem with the search feature in Squishdot 0.7.0 that seems
possibly to be related.  Our trace of the problem shows that catalog
searches from the SquishSite return objects which are wrapped with a
*different* acquisition hiearchy than the SquishSite itself or from the
User object it's trying to check roles on.  Thus, *even though* the user
has the right roles, user.allowed() disallows the roles as invalid because
they're being granted from a (seemingly) different hiearchy.

What we found is that ZCatalog uses the older REQUEST.resolve_url() method
to access the "true" objects, which has this side effect.  If it used the
new 2.2 traverse methods, the acquisition hierarchy would be the same.  As
it stands, the objects returned by ZCatalog.getobject (by way of
SquishSite.__call__) even have different REQUEST objects than the original
REQUEST object for the web hit.

Does this sound like it's anything related to the problems you're having?

At 05:00 PM 9/1/00 +0100, Chris Withers wrote:
Brian Lloyd wrote:
 
 Here's a quick thing to try- if 'subject' is an attribute
 of your Article class, try adding:
 
 class Article(...):
   subject__roles__=None
 
 then restart and see if you still get unauthorized...

yup, I do :-(

And besides, 'subject' is already in __ac_permissions__, as you can see:

(a lot of stuff snipped out though ;-)

__ac_permissions__ = (
('View', ['subject','getThread'], ('Anonymous', 'Manager')),
)

and I do appropriate Globals.default__class_init__'s...

Man, I really have no idea, and not even any clue where to look.

The big factor seems to be that 'subject' is a string. I had a similar
problem with the SquishFile class with the 'icon' attribute.

When it was a string:

# protected by 'View' permission
icon = 'misc_/Squishdot/squishfile_img'

..even though it was a class variable and protected in
__ac_permissions__, I was getting very similar errors to the above...

I was lucky, in that case, because it was a class variable, I could turn
it into a method:

# protected by 'View' permission
def icon(self):
return 'misc_/Squishdot/squishfile_img'

..and, lo and behold, no more security errors from there... :S

Unfortunately, the string attributes in the Article class are instance
attributes, not class attributes, so I can't do the same thing :-(

Any ideas?

cheers,

Chris

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




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




[Zope-dev] Converters.field2date, allow empty string to return None?

2000-09-01 Thread Brad Clements

One thing that has been bothering me is that I can't easily test my 
ZSQL Methods if they accept a date type unless I completely fill all the 
date arg types.

For example, if the sqlmethod has argument type 
  startdate:date=''


and in the body I have
 dtml-if startdate ...

When i use the test form, I can't leave the date field empty, otherwise I 
get a conversion error from Converters.field2date()

I also have this problem with any form that has type date, if the end-user 
doesn't put a date in the form, I get a conversion error.

Its okay with me to receive an empty string, which gets converted to 
None .. I just put NULL in the sql database.

So .. what's the correct fix to allow empty fields to return either '' or 
None from field2date?

I can alter Converters.py...

I see that converters required: exists, but does that imply that all other 
converters allow an empty string to return None? Or do we need to add 
an explicit "optional" type?

Either way, I'd like to fix this, but what's the best way?


Brad Clements,[EMAIL PROTECTED]   (315)268-1000
http://www.murkworks.com  (315)268-9812 Fax
netmeeting: ils://ils.murkworks.com   AOL-IM: BKClements

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




Re: [Zope] indexing pdf files

2000-09-01 Thread Kapil Thangavelu

Terry Kerr wrote:
 
 Hi,
 
 I need to be able to index the text within pdf files.  I assume I will
 somehow use PrincipiaSearchSource, but I need to know how to get the
 text out of the pdf when it is uploaded to the ZODB.  Has anyone done
 this before?  Are there any packages around that I can use that run in
 python or at least on a linux box that I can pipe to and from?
 
 terry



from xml2pdf there are a multitude of ways in python

XSLT - check out the ibm.com/developer xmlzone they have an article in
the education lib for transforming xml to pdf.

platypus packages from
http://www.reportlab.com/

they might give you some help in going the other way..

as for implementation... 

looking at a pdf in a text viewer it appears to be formating text and
encoded display strings. 

you could write a subclass of file, which read its content upon upload
stripping the formatting string and decoding the display strings and
storing that as a property to be indexed. 


Kapil

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




Re: [Zope] indexing pdf files

2000-09-01 Thread Terry Kerr

I just answered my own question.

The program is pdftotext, part of the xpdf package available for unix
machines.

It is very cool and very fast.

terry


Kapil Thangavelu wrote:

 Terry Kerr wrote:
 
  Hi,
 
  I need to be able to index the text within pdf files.  I assume I will
  somehow use PrincipiaSearchSource, but I need to know how to get the
  text out of the pdf when it is uploaded to the ZODB.  Has anyone done
  this before?  Are there any packages around that I can use that run in
  python or at least on a linux box that I can pipe to and from?
 
  terry
 

 from xml2pdf there are a multitude of ways in python

 XSLT - check out the ibm.com/developer xmlzone they have an article in
 the education lib for transforming xml to pdf.

 platypus packages from
 http://www.reportlab.com/

 they might give you some help in going the other way..

 as for implementation...

 looking at a pdf in a text viewer it appears to be formating text and
 encoded display strings.

 you could write a subclass of file, which read its content upon upload
 stripping the formatting string and decoding the display strings and
 storing that as a property to be indexed.

 Kapil

--
Terry Kerr ([EMAIL PROTECTED])
Adroit Internet Solutions Pty Ltd (www.adroit.net)
Phone:   +613 9563 4461
Fax: +613 9563 3856
Mobile:  +61 414 938 124
ICQ: 79303381




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




[Zope] Designing with Zope

2000-09-01 Thread Tim Cook


Hoefully this is not too ambiguous. But I'm wondering if there
are any "gotcha's" in developing an application that would
maintain parts of it's data in ZODB and the rest in an RDBMS?  

This might be better stated as a situation where one application
that uses Zope and an RDBMS was a sub-part of a ZODB
application.  Say, a sales management app in ZODB uses an
accounting app that stores its data in an RDBMS through the same
Zope server?

Thanks,
-- Tim Cook --
FreePM Project Coordinator http://www.freepm.org
OS Health Care Alliance Supporter http://www.oshca.org

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




Re: [Zope] ZCatalog in 2.2.x

2000-09-01 Thread Terry Kerr

Hi,

I can rebuild indexes and recatalog etc, it doesn't change anything.  I
don't see how it could change anything...it is a brand new zcatalog
instance.  Simply, the ZCatalog is created, the indexes are created, and
the zcatalog is initially empty.  Then I create one CatalogAware object,
and it catalogs itself.  I can see this object in the catalog, and I can
see the textindexed words in the vocabulary.  But when I search for a word
in the vocabulary using a textindex (which obviously belongs to the only
object in the catalog), I get an empty result.  The only way I can get a
non empty result it to search for the id of the object or one other
property I have which are indexed as field indexes.

The product I am working on is Etailer.  If anyone is kind enough to take a
look, you can download it at http://e-tailer.adriot.net/download.html.  The
function that does the search is searchFor(), at line 419 of Etailer.py.
Creating an instance of etailer in 2.1.6 works fine, but creating an
instance of etailer in 2.2.x and the catalog doesn't work.


i am very confused ;-).


Chris McDonough wrote:

 This is not right, obviously.  Can you rebuild your indexes (by deleting
 and reentering them), recatalog, and see if the problem goes away?  We
 haven't had any colluding reports of something like this, and I'm using
 the 2.2.1 catalog with textindexes successfully on a customer project.

  -Original Message-
  From: Terry Kerr [mailto:[EMAIL PROTECTED]]
  Sent: Wednesday, August 30, 2000 3:27 AM
  To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
  Subject: Re: [Zope] ZCatalog in 2.2.x
 
 
  I am not searching from a form in that sense...I am talking
  about at the python
  level.
 
  I have self.searchResults({'description':'blah'})  where
  description is meta
  data in the catalog and a textindex and 'blah' is in the
  Vocabulary.  This
  previously worked in zope2.1.6.  Now in 2.2.0 and 2.2.1 it
  doesn't work.  The
  only thing way I can get searchResults() to return a non
  empty list is to search
  using a Field index and a valid string to match with.
 
 
  [EMAIL PROTECTED] wrote:
 
   Terry Kerr [EMAIL PROTECTED] said:
  
Hi,
   
I have a python product which uses a ZCatalog and CatalogAware
products.  The catalog has a number of Field and
  TextIndex indexes.
Search the ZCatalog has worked fine when my product is
  instantiated in
2.1.6.  But now when I instantiate my product in 2.2.0 or 2.2.1,
searching only works when I search using a field index.
  Searching using
a textindex always results in an empty result, even tho I
  can see the
words I am searching for in the Vocabulary!  Any
  suggestions?  I have
tried reindexing, completey recreating the Zcatalog,
  recreating the
Vobulary and reindexing, and nothing has changed the
  behaviour.  Are
textindexes simply broken?
   
   
ZCatalog seems very volatile to me!  Every time I have
  upgraded way back
from zope2.1.3, something in zcatalog has changed and
  boken my product.
So far I have managed to find fixes, but this one has got
  me baffled!!
   
  
   My experience has been that if field indexes are
  unspecified, the catalog
   will only match where those fields are empty.  In other
  words, by not
   specifing anything for the field indexes, you are actually
  specifying that
   for a match, they need to be empty.
   To get around this, I put another method between the form
  for entering what
   you wish to search for, and the method that actually
  searches the form.  This
   method looks at the field indexes, and if nothing has been
  specified, it
   doesn't pass them on to the method that does the actual search.
   An alternative to this, is to use names for the field
  indexes that aren't in
   the catalog index, and then at the start of the search
  method, check those
   names, and if they have a value associated with them, add
  to REQUEST what the
   names in the index are with the appropriate values.
  
   There may be a better way, I'm still pretty new to Zope and
  DTML sort of
   stuff.
  
   Peter Armstrong
 
  --
  Terry Kerr ([EMAIL PROTECTED])
  Adroit Internet Solutions Pty Ltd (www.adroit.net)
  Phone:   +613 9563 4461
  Fax: +613 9563 3856
  Mobile:  +61 414 938 124
  ICQ: 79303381
 
 
 
 
  ___
  Zope maillist  -  [EMAIL PROTECTED]
  http://lists.zope.org/mailman/listinfo/zope
  **   No cross posts or HTML encoding!  **
  (Related lists -
   http://lists.zope.org/mailman/listinfo/zope-announce
   http://lists.zope.org/mailman/listinfo/zope-dev )
 

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

--
Terry Kerr ([EMAIL PROTECTED])
Adroit Internet Solutions Pty Ltd 

[Zope] Copying a dtml method when creating a ZClass instance

2000-09-01 Thread kamon ayeva

Hi,

I need some help.
I have a DTML method at the root of Zope called 'Template'.
How can I make the constructor of a ZClass (folderish) to copy this method 
to each of its instances ? Can someone provide me with a complete snippet to 
add in the ZClass constructor ?

Many thanks.

Kamon
_
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


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




[Zope] Good Examples of Zope in Action

2000-09-01 Thread Chris Withers

Marty McKeever at Work wrote:
 The question is this:  "What are some examples of high-profile and/or
 enterprise level ecommerce or web production sites using zope?"
 
 Send me examples and i'll post them to the original thread.

Paul,

Maybe now would be a good time to chime in with the CBS and
Yahoo!(HomeSite?) examples you mentioned in Paris :-)

cheers,

Chris

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




Re: [Zope] a redirect of an url in Python

2000-09-01 Thread Chris Withers

[EMAIL PROTECTED] wrote:
 
 I want to redirect my current url to another in Python. I've tried
 return REQUEST.get('url'), but It only writes the url on the screen.

Firstup, posting HTML mail to the list doesn't help anyone ;-)

That said, It sounds like what you want to do is end your python method
with:

return REQUEST.RESPONSE.redirect(REQUEST['url'])

HTH,

Chris

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




[Zope] RE: Good Examples of Zope in Action

2000-09-01 Thread Paul Everitt


First, note that I can only talk on the record about things that are
here now and that I have the OK to talk about.  There have been a number
of big things we've done over the last year, like our work with HomeGain
that you allude to below.  It's important for me to work closely with
them to get the correct statement on the record.

It's not always a fast process, but these things are likely to get
accelerated in September.

--Paul

 -Original Message-
 From: Chris Withers [mailto:[EMAIL PROTECTED]]
 Sent: Friday, September 01, 2000 2:33 AM
 To: [EMAIL PROTECTED]
 Cc: Marty McKeever at Work; [EMAIL PROTECTED]
 Subject: Good Examples of Zope in Action
 
 
 Marty McKeever at Work wrote:
  The question is this:  "What are some examples of 
 high-profile and/or
  enterprise level ecommerce or web production sites using zope?"
  
  Send me examples and i'll post them to the original thread.
 
 Paul,
 
 Maybe now would be a good time to chime in with the CBS and
 Yahoo!(HomeSite?) examples you mentioned in Paris :-)
 
 cheers,
 
 Chris
 

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




Re: [Zope] Success in installing ZPoPyDA (after 3 months...)

2000-09-01 Thread Bak @ kedai

where did you find lin ux.h that's needed by PoPy?  thtt stump me from
continuing.

thanks
-Original Message-
From: Hung Jung Lu [EMAIL PROTECTED]
To: [EMAIL PROTECTED] [EMAIL PROTECTED]
Date: Friday, September 01, 2000 4:04 AM
Subject: [Zope] Success in installing ZPoPyDA (after 3 months...)


Good news. I finally succeeded in installing ZPoPyDA (PostgreSQL database
adapter for Zope.) I think it was more than 3 months ago when I started to
try to install ZPoPyDA.

The process involved many tricky steps, the most tricky one was, uh,
installing a whole new Linux operating system. (Upgrade from 5.2 to 6.2) :)

But sweat and blood were involved in many other little tiny things.
Including installing PostgreSQL and its dev package RPMs, Python Dev,
figuring out what was missing in os.h and where to find linux.h for the
PostgreSQL, version compatibility problems between PoPy and ZPoPyDA, etc.
So
many steps that I don't remember them all, now.

Do I recommend PostgreSQL to other Zope users? Probably yes. But I'd advise
them to give themselves *plenty* of time to deal with installation issues.
I
know, some have been lucky and did not have any problems. But for me, it's
been a horrible experience. But I hope the reward of a good (and cheap)
database will compensate all the bad times.

regards,

Hung Jung

_
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at
http://profiles.msn.com.


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



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




RE: [Zope] Is anyone know when Zope was born ???

2000-09-01 Thread Paul Everitt


As far as I'm concerned, Zope was born Saturday, June 8, 1996.  This was
Jim Fulton's plane trip back from IPC4:

  http://www.python.org/workshops/1996-06/

Beyond that, Zope (as a unification of previous software) was announced
in November 1998 and released in December 1998.

DC had some prior art in the field before IPC4, such as my W3C tech note
on the "ILU Requester", technology for making web servers talk CORBA to
services.  Also, Brian Lloyd had, with someone else here at the time,
cooked up an early ORB to handle message dispatch from the web into
Python.  However, our work was tiny compared to Jim's plane trip back.

I pick the 1996 date because, well, from a marketing perspective it
makes Zope look more mature. :^)  But that's the best date.  Here's "the
rest of the story".

Jim joined Digital Creations about a week before IPC4.  He had already
scheduled to go to IPC4, and I had scheduled to go and teach a CGI
class.  Instead, I decided to go on vacation and make him teach the
class.  Slight problem: he had never heard of CGI.

So on the plane ride there he read the CGI spec, some background
material, and rewrote my presentation.  In the process he decided CGI
was broken and needed a bunch of things, primarily object orientation.
The "python object publisher" (an ORB) was conceived during the
conference and was largely written on the plane ride back.  The ORB
quickly took over our consulting business.  Within a year we added a
template system, then a persistent object system, then...

That's the story.  So there, we have a birthdate!

--Paul

 -Original Message-
 From: Chris Withers [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, August 30, 2000 5:17 AM
 To: Frederic Quin
 Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: Re: [Zope] Is anyone know when Zope was born ???
 
 
 Frederic Quin wrote:
  
  Is anyone know when Zope was born ???
 
 Paul, you must know the answer to this one ;-)
 
 cheers,
 
 Chris
 

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




Re: [Zope] Is anyone know when Zope was born ???

2000-09-01 Thread Andrew Kenneth Milton

+---[ Paul Everitt ]--
| 
| As far as I'm concerned, Zope was born Saturday, June 8, 1996.  This was
| Jim Fulton's plane trip back from IPC4:
| 
|   http://www.python.org/workshops/1996-06/

That's the conception date, if you always skip straight to the birth, you're 
missing out on some fun d;)

| Within a year we added a
| template system, then a persistent object system, then...



-- 
Totally Holistic Enterprises Internet|  P:+61 7 3870 0066   | Andrew Milton
The Internet (Aust) Pty Ltd  |  F:+61 7 3870 4477   | 
ACN: 082 081 472 ABN: 83 082 081 472 |  M:+61 416 022 411   | Carpe Daemon
PO Box 837 Indooroopilly QLD 4068|[EMAIL PROTECTED]| 

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




[Zope] ZCatalog and OR searching

2000-09-01 Thread Chris Withers

Dieter Maurer wrote:
 A ZCatalog search usually combines searches to the different
 indexes with an "And".
 You want to combine them with an "Or".

Don't you wish there was a decent query language for ZCatalog so this
kindof rediculous complexiting to achieve a simple outcome wasn't
necessary?

cheers,

Chris

PS: The example in the Advanced ZCatalog How-To does away with most of
the catalog's advantages (like lazy searches, small results set, etc)

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




RE: [Zope] Is anyone know when Zope was born ???

2000-09-01 Thread Oleg Broytmann

Hello!

   Very interesting! Could you please publish the story somewhere on
zope.org?

On Fri, 1 Sep 2000, Paul Everitt wrote:
 As far as I'm concerned, Zope was born Saturday, June 8, 1996.  This was
 Jim Fulton's plane trip back from IPC4:
 
   http://www.python.org/workshops/1996-06/
 
 Beyond that, Zope (as a unification of previous software) was announced
 in November 1998 and released in December 1998.
 
 DC had some prior art in the field before IPC4, such as my W3C tech note
 on the "ILU Requester", technology for making web servers talk CORBA to
 services.  Also, Brian Lloyd had, with someone else here at the time,
 cooked up an early ORB to handle message dispatch from the web into
 Python.  However, our work was tiny compared to Jim's plane trip back.
 
 I pick the 1996 date because, well, from a marketing perspective it
 makes Zope look more mature. :^)  But that's the best date.  Here's "the
 rest of the story".
 
 Jim joined Digital Creations about a week before IPC4.  He had already
 scheduled to go to IPC4, and I had scheduled to go and teach a CGI
 class.  Instead, I decided to go on vacation and make him teach the
 class.  Slight problem: he had never heard of CGI.
 
 So on the plane ride there he read the CGI spec, some background
 material, and rewrote my presentation.  In the process he decided CGI
 was broken and needed a bunch of things, primarily object orientation.
 The "python object publisher" (an ORB) was conceived during the
 conference and was largely written on the plane ride back.  The ORB
 quickly took over our consulting business.  Within a year we added a
 template system, then a persistent object system, then...
 
 That's the story.  So there, we have a birthdate!
 
 --Paul

Oleg.
 
 Oleg Broytmannhttp://phd.pp.ru/[EMAIL PROTECTED]
   Programmers don't die, they just GOSUB without RETURN.


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




[Zope] ZPatterns Stability

2000-09-01 Thread Chris Withers

Tim Cook wrote:
  If you're brave you could try ZPatterns and then realyl not care at all
  ;-)
 
 
 Don't you mean; 'If you're insane...' ?

No, I really don't!

ZPatterns is very cool, but still not documented. It's alpha but seems
stable enough for production in a lot of cases.

Phil? Steve A? backup? ;-)

cheers,

Chris

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




Re: [Zope] Re: HappySession

2000-09-01 Thread Philipp Auersperg


I also use HappySession and when catching the SessionNotFoundError
weird things happen: 
here my  code:

dtml-try
   dtml-call "SESSION.set('FLinkID','0')"
dtml-except
session error!
/dtml-try

When the session is expired the error is not caught correctly and I get the error 
mentioned below. Plus, I have to restart my server because ZODB reports a 
transactional error and sets itself to read-only.


thanks
Philipp Auersperg (zwork)
---
  Zope Error
Zope has encountered an error while publishing this resource. 

Error Type: KeyError
Error Value: SessionUID
---
and the traceback:
Traceback (innermost last):
  File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 214, in 
publish_module
  File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 179, in 
publish
  File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Zope/__init__.py, line 202, in 
zpublisher_exception_hook
(Object: ElementWithAttributes)
  File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 169, in 
publish
  File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZODB/Transaction.py, line 275, in 
commit
  File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Shared/DC/ZRDB/TM.py, line 120, in 
tpc_finish
(Object: TM)
  File 
/usr/local/Zope-2.1.4-linux2-x86/lib/python/Products/HappySession/HappySession.py, 
line 168, in _finish
(Object: TM)
  File 
/usr/local/Zope-2.1.4-linux2-x86/lib/python/Products/HappySession/HappySession.py, 
line 291, in _onTransactionEnded
(Object: SESSION)
  File 
/usr/local/Zope-2.1.4-linux2-x86/lib/python/Products/HappySession/HappySession.py, 
line 255, in _store
(Object: SESSION)
KeyError: (see above)


*** REPLY SEPARATOR  ***

On 31.08.2000 at 19:03 Hung Jung Lu wrote:

My conjecture now is that your error-handling HTML might be accessing 
attributes from Zope server. A more correct way of handling exceptions 
should have been using the dtml-try...dtml-except.../dtml-try block. 
But I kind of make a cheat sheet recipe recommendation, tweaking the 
standard_error_message, which was not a good idea. When Zope arrives to 
standard_error_message, the transaction has been aborted and if your 
session_not_found_html is not simple enough and uses more DTML features, I 
can see that it can cause transaction error.

Can you send me your session_not_found_html? I think this was the problem.

In the future I will remove the standard_error_message trick from the help 
file and instead tell people to use proper exception handling, which is the 
right way of doing things. But it will require people to structure their 
sites more carefully so they can catch the SessionNotFound exception. 
Basically, it is recommended that you have single (or few) index_html on 
your site, and place a dtml-try...dtml-except ../dtml-try block to 
capture all exceptions from Zope and deal with them. It's the right way of 
doing things, it's just that many people tend to have many index_html and it 
will make their site harder to catch exceptions and deal with them in a 
centralized way.

In short, HappySession itself is probably not the cause of the transaction 
error. The problem probably comes from bad exception handling. If you want 
to use the standard_error_message trick, then please use a simple html page 
for session_not_found_html without additional Zope features. If I find out 
more, I'll let you know.

regards,

Hung Jung

_
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


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




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




[Zope] Re: HappySession

2000-09-01 Thread Diego Rodrigo Neufert

Well, this problem just accours when I restart the server or I stay too much
time idle and the session expires...
The frame[0] (the first to be loaded) show a session not found message and in
frame[1] I got this error:
Error Type: KeyError
Error Value: NDxCfgEr_89YtG
So, if I refesh the page zope show me the transaction error and everything
stops working I need to restart zope and my netscape (to clean all cookies)
to get things working again
Here's my session not found page but this error occours when I doesnt have one
too... well, in the standard html header I call call a method that do a call in
all my sessions I have two SESSION objects, one in the root of zope and
other in the opt folder of zope look how I call the SESSIONS
in standard_html_header
dtml-call callSession

The callSession method:
dtml-call SESSION
dtml-call opt.SESSION

 session_not_found_html:
dtml-var standard_html_header
font face=Arial size=2
O tempo maacute;ximo de duraccedil;atilde;o foi ultrapassado.br
Os items existentes no seu carrinho foram apagados.brbr
Continue suas compras normalmente agora...
/font
dtml-var standard_html_footer


On Thu, 31 Aug 2000, you wrote:
 My conjecture now is that your error-handling HTML might be accessing 
 attributes from Zope server. A more correct way of handling exceptions 
 should have been using the dtml-try...dtml-except.../dtml-try block. 
 But I kind of make a cheat sheet recipe recommendation, tweaking the 
 standard_error_message, which was not a good idea. When Zope arrives to 
 standard_error_message, the transaction has been aborted and if your 
 session_not_found_html is not simple enough and uses more DTML features, I 
 can see that it can cause transaction error.
 
 Can you send me your session_not_found_html? I think this was the problem.
 
 In the future I will remove the standard_error_message trick from the help 
 file and instead tell people to use proper exception handling, which is the 
 right way of doing things. But it will require people to structure their 
 sites more carefully so they can catch the SessionNotFound exception. 
 Basically, it is recommended that you have single (or few) index_html on 
 your site, and place a dtml-try...dtml-except ../dtml-try block to 
 capture all exceptions from Zope and deal with them. It's the right way of 
 doing things, it's just that many people tend to have many index_html and it 
 will make their site harder to catch exceptions and deal with them in a 
 centralized way.
 
 In short, HappySession itself is probably not the cause of the transaction 
 error. The problem probably comes from bad exception handling. If you want 
 to use the standard_error_message trick, then please use a simple html page 
 for session_not_found_html without additional Zope features. If I find out 
 more, I'll let you know.
 
 regards,
 
 Hung Jung
 
 _
 Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
 
 Share information about yourself, create your own public profile at 
 http://profiles.msn.com.
-- 
---
Diego Rodrigo Neufert
-webmaster
---
(Magic Web Design)
(email) ([EMAIL PROTECTED])
(curitiba) (pr)

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




[Zope] Zope.org is slow, it's being hit hard! :-)

2000-09-01 Thread Chris Withers

Curtis Maloney wrote:
 Sometimes (much of the time) it comes through just fine.  But on some days
 (and it does seem to last just the day) it's slower than a wet weekend.
 What would be interesting to know is WHY it gets slow.  

This might help explain it:

 I noticed this also, it appears from the logs that we're being crawled
 by about 7 different bots. I guess popularity has its price...
 
 
 -- 
 - Matthew Burleigh
 - Systems Administrator, Digital Creations - publishers of Zope.
 - (888)344-4332 -- http://www.digicool.com - http://www.zope.org

Maybe it's be possible to have some sort of 'current load indicator' in
the standard_html_footer on zope.org?

Matt mentioned a quick hack:

 watch "netstat -an | grep "1380" -c"
 
 Averages around 140, since I've been watchin for last couple mins

I wonder if something similar could be bent to the job?

 If it really is
 something beyond their control, perhaps mirror sites?

Well, NIP would be happy to do this, but, as you may or may not know,
Zope doesn't mirror very well :-(

cheers,

Chris

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




Re: [Zope] Copying a dtml method when creating a ZClass instance

2000-09-01 Thread Tino Wildenhain

Hi Kamon,

kamon ayeva wrote:
 
 Hi,
 
 I need some help.
 I have a DTML method at the root of Zope called 'Template'.
 How can I make the constructor of a ZClass (folderish) to copy this method
 to each of its instances ? Can someone provide me with a complete snippet to
 add in the ZClass constructor ?

Copy? Why?
aquisition should make it 'visible' in every subfolder automatically.

Regards
Tino

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




RE: [Zope] Wish for the next Zope Release: Doc tab for every Zope entity

2000-09-01 Thread Philipp Auersperg

Is DC planning to do something in that matter?

also the docstring should perhaps not be just one property, but
structured (author,parameters,prerequisites...) as it is in
javadoc (ok, we don't like java, but thats a point where we can learn from java)

The next point:
if there is a 'Documentation' tab then
every Zope developer is leaded to document his code.
( DTML is not always simple to read for other people except the author ;-)

just my 2 cents...

phil
*** REPLY SEPARATOR  ***

On 01.09.2000 at 08:16 Chris McDonough wrote:

I agree that instances of DTML methods, DTML documents, SQL methods,
Python methods, objects based on ZClasses, etc. should have "docstring"
capabilities in some sort of common-denominator fashion.

dtml-comment is the only way this can be done for DTML methods.

The other objects can have properties, which could be documentation.

-Original Message-
From: Philipp Auersperg [mailto:[EMAIL PROTECTED]]
Sent: Friday, September 01, 2000 6:23 AM
To: [EMAIL PROTECTED]
Subject: [Zope] Wish for the next Zope Release: Doc tab for every Zope
entity


Mostly when developing a project it should be documented as well :)
The best would be a strucutral documentation that can be generated 
out of the project so that it always keeps track of the software and is
up to date

- Python has that because there are the doc strings for classes and
methods
- Java has it (javadoc)
- Zope - ?

For Zope it would be fine if every entity in the ODB has a
'Documentation' tab
So I could when developing a Zope site always on the fly document its
structure 
without having to leave y developing environment.

Then its an easy thing to write a doc generator that queries the objects
in the ODB
and their documentation.

Did I miss something and such a beast exists or is there really
something to be done?
I don't mean documentation in dtml-comment, I mean documentation as
seperate 
property for each object and method.

Philipp Auersperg (zwork)




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




RE: [Zope] Wish for the next Zope Release: Doc tab for every Zope entity

2000-09-01 Thread Chris McDonough

 Is DC planning to do something in that matter?

It's not a priority right now.  You may want to propose something on
dev.zope.org if you think you have an idea of how it should work.

 
 also the docstring should perhaps not be just one property, but
 structured (author,parameters,prerequisites...) as it is in
 javadoc (ok, we don't like java, but thats a point where we 
 can learn from java)

Good point.

 
 The next point:
 if there is a 'Documentation' tab then
 every Zope developer is leaded to document his code.
 ( DTML is not always simple to read for other people except 
 the author ;-)

Perhaps.  It depends on the developer.

 
 just my 2 cents...

Thanks...

 phil
 *** REPLY SEPARATOR  ***
 
 On 01.09.2000 at 08:16 Chris McDonough wrote:
 
 I agree that instances of DTML methods, DTML documents, SQL methods,
 Python methods, objects based on ZClasses, etc. should have 
 "docstring"
 capabilities in some sort of common-denominator fashion.
 
 dtml-comment is the only way this can be done for DTML methods.
 
 The other objects can have properties, which could be documentation.
 
 -Original Message-
 From: Philipp Auersperg [mailto:[EMAIL PROTECTED]]
 Sent: Friday, September 01, 2000 6:23 AM
 To: [EMAIL PROTECTED]
 Subject: [Zope] Wish for the next Zope Release: Doc tab for 
 every Zope
 entity
 
 
 Mostly when developing a project it should be documented as well :)
 The best would be a strucutral documentation that can be generated 
 out of the project so that it always keeps track of the 
 software and is
 up to date
 
 - Python has that because there are the doc strings for classes and
 methods
 - Java has it (javadoc)
 - Zope - ?
 
 For Zope it would be fine if every entity in the ODB has a
 'Documentation' tab
 So I could when developing a Zope site always on the fly document its
 structure 
 without having to leave y developing environment.
 
 Then its an easy thing to write a doc generator that queries 
 the objects
 in the ODB
 and their documentation.
 
 Did I miss something and such a beast exists or is there really
 something to be done?
 I don't mean documentation in dtml-comment, I mean documentation as
 seperate 
 property for each object and method.
 
 Philipp Auersperg (zwork)
 
 
 
 
 ___
 Zope maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists - 
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope-dev )
 

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




[Zope] Newbie: ZClass questions

2000-09-01 Thread Nick Trout



Hi, I'm new to Zope. I'm just flailing around in 
all the docs and examples at the moment. I'm 
setting up a small intranet for our office.

I've been reading about ZClasses (havent done any 
SQL). Are these a very efficient way of storing data? Are these more/less 
efficient than setting up a database and managing it using ZSQL?

I read that any changes to a class instance is 
stored in the Zope database. Is there a way of turning this feature off to avoid 
the undo facility? ie. if you dont want undo.

I'm trying to set up a simple chat room as a 
teaching exercise. I'm thing I should implement a ZClass which is the room, 
containg a ZClass which will be a chat item. I've noticed an example, ZRTChat 
but everything there is implemented in Python (yuck!). It's much nicer to use 
the interface to create your classes. What are the pros and cons of the 2 
approaches. Why implement it all in Python?

Cheers,
Nick.




Re: [Zope] The Challenge: Zealots vs. Skeptics

2000-09-01 Thread Marty McKeever at Work

At 11:22 AM 9/1/2000 +0200, you wrote:
curiosity... what web development list is this?

As i mentioned before, i do not want to mingle the threads, or incite a
riot on either list. 
All i will say is that it is a very high profile list for professional web
artists.  Mainly Silicon Alley types
If that describes you, you should know what list i mean.

Others have asked "what to you mean by enterprise?"
I'll rephrase that part of the question.  "What large US corporations are
creating mission-critical e-business applications (and of what type -- send
URLs if you can) with zope?"

As for traffic figures, someone in my office (you know who) claims that
zope can easily handle 1million hits per day running on crappy hardware.
Hardware aside, where are the Zope sites that generate this kind of
traffic?  Certainly not toyota-motosports.com

Thanks for your participation.
Marty


##   Marty McKeever - [EMAIL PROTECTED]
##   Manager / Web Services Division
##   Going Virtual LLC., Matthews NC 
##   http://www.goingv.com (704) 849-0731

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




[Zope] http://zdnetindia.com/

2000-09-01 Thread Chris Withers

IIRC, someone working on this tells em it takes several hundred thousand
hits a day on a Dual PIII. he could be lying though ;-)

cheers,

Chris

PS: Whoever told me about this, please comment ;-)

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




RE: [Zope] manage

2000-09-01 Thread neeloy_saha

Hi dieter,

Thx for ur reply.  

The child window  pop ups when u do http://localhost:8080/manage . One
enters the username and password there. That is validated against the
acl_user folders member names or if it is a superuser who installed zope it
validates it against the access file.

I want to look at the source code and understand the authentication
mechanism.That's why i want to know the following:-

1.what is the python file which pops up that child window for entering
username and password ?
2.After u give the username and password what is the file / module name
against which  the username and password is authenticated.
3.what is this 'manage'? method/module???

Thx in advance

-neeloy



-Original Message-
From: Dieter Maurer [mailto:[EMAIL PROTECTED]]
Sent: Friday, September 01, 2000 1:34 AM
To: neeloy_saha
Cc: '[EMAIL PROTECTED]'
Subject: Re: [Zope] manage


neeloy_saha writes:
  when i do http://localhost:8080/manage it pops up a login window which
asks
  for username and password. what is the entry point after that??
That is exactly what one would expect.

Enter the username and password that was assigned during installation
or that you set with

python zpasswd.py access

  Is there a way of running zope with debugger?? 
There is "Test.py" in "lib/python/ZPublisher".
It will, however, not help you with the above problem.


Dieter

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




[Zope] Render the number of occurrence in a batch

2000-09-01 Thread Francois-Regis CHALAOUX

Hi,

How to render the total number of result coming from the search in a ZCatalog
even if the batch will be render in several sequences ?

Howto render  : "Your search contain  results"

FR.

  
  
  
  
  
  
  
  
  
  
 

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




[Zope] Re: HappySession

2000-09-01 Thread Hung Jung Lu

From: Diego Rodrigo Neufert [EMAIL PROTECTED]
...
too... well, in the standard html header I call call a method that do a 
call in
all my sessions

Okie, now I see why you get the Transaction error problem. After an 
exception is raised, Zope aborts the http request transaction, and any 
attempt to further use Zope objects that are transaction-aware will cause an 
error. In the next release of HappySession I will try to detect whether the 
transaction has ended, and return some meaningless result like None. But the 
real thing is, after the exception happens, SESSION object should not be 
called again.

If you really need to call SESSION in your standard_html_header, then please 
do two things:

(1) Please use a standard_error_message, and it should start with something 
like:

  dtml-if "not error_message and error_type == 'SessionNotFoundError'"
dtml-return session_not_found_html
  /dtml-if

  !--#var standard_html_header--

  !--#if error_message--
   !--#var error_message--
  !--#else--
   

(2) In your session_not_found_html, please do NOT use dtml-var 
standard_html_header. Instead, write another DTML and call it 
session_ended_html_header, and use it instead. Inside your 
session_ended_html_header, please do NOT call the SESSION object.

I have two SESSION objects, one in the root of zope and
other in the opt folder of zope look how I call the SESSIONS
in standard_html_header
dtml-call callSession

The callSession method:
dtml-call SESSION
dtml-call opt.SESSION

(Hmmm... multiple SESSION objects... in typical situations usually one 
single SESSION object should be enough. Notice that two SESSION objects mean 
two separate storage. Although HappySession is designed to handle multiple 
SESSION objects sharing the same key cookie, the expiration time might be a 
tricky issue... I do not recommend multiple SESSION objects.)

The thing I don't understand is why you need to make explicit call to the 
SESSION objects. Ohh...! I see, you probably think that SESSION objects need 
to be initialized? OK, unlike FSSession or SQLSession, HappySession's 
SESSION objects do NOT need to be initialized! You don't need to make an 
explicit call to SESSION in your standard_html_header. HappySession is smart 
enough to initialize itself whenever you touch it the first time using any 
of its methods. No explicit initialization call needed.

(I'll add an observation on this in the help file in the future.)

-

In short, I think that by simply removing your callSession method and its 
reference in standard_html_header, you will be fine and happy! :)

regards,

Hung Jung

_
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


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




Re: [Zope] Render the number of occurrence in a batch

2000-09-01 Thread Kapil Thangavelu

Francois-Regis CHALAOUX wrote:
 
 Hi,
 
 How to render the total number of result coming from the search in a ZCatalog
 even if the batch will be render in several sequences ?
 
 Howto render  : "Your search contain  results"
 
 FR.
 
 

dtml-var "_.len(YOURSEQUENCEGENERATOR)"


dtml-in "YOURSEQUENCEGENERATOR"

/dtml-in


Kapil

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




Re: [Zope] Success in installing ZPoPyDA (after 3 months...)

2000-09-01 Thread Hung Jung Lu

From: "Bak @ kedai" [EMAIL PROTECTED]
where did you find linux.h that's needed by PoPy?  thtt stump me from
continuing.

Download postgresql-7.0.2 source (not the RedHat's RPM), unzip and untar it, 
and the file is located at:

postgresql-7.0.2/src/include/port/linux.h

What I did was:

  (1) copy this file into your /usr/include/pgsql
  (2) delete /usr/include/pgsql/os.h (which is merely a link, not an actual 
file)
  (3) rename /usr/include/pgsql/linux.h to /usr/include/pgsql/os.h

Oh, I also had to tweak some of the Makefiles at some point, so the include 
directory becomes pgsql instead of postgresql.

regards,

Hung Jung

_
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


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




[Zope] What's up with zope.org?

2000-09-01 Thread ethan mindlace fremen

"Bak @ kedai" wrote:
 
 what's happenng to zope.org?  i got this message when i tried accessing it

Ok, this is a bit late, but "Running into ZEO/ mounted file storage
bugs" is the answer.  

Aparently, our in-house MountedClientStorage (and the MountedDatabase)
doesn't play nice with ZEO.  So we've backed off of ZEO for the moment,
pending the magic Jim touch.
-- 
ethan mindlace fremen
Zopatista Community Liason
Abnegate I!

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




Re: [Zope] Re: ZOPE Python edit debug cycle

2000-09-01 Thread Toby Dickenson

On Tue, 29 Aug 2000 16:52:02 -0700, "Loren Stafford"
[EMAIL PROTECTED] wrote:

There's also the Refresh product
(http://www.zope.org/Members/hathawsh/Refresh) which helps reload some
(most) products without restarting Zope.

Is this still needed? Are you still suffering from Zope taking a long
time restart?


Toby Dickenson
[EMAIL PROTECTED]

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




RE: [Zope] manage

2000-09-01 Thread Holger Lehmann

Am Fre, 01 Sep 2000 schrieben Sie:
 Hi dieter,
 
 Thx for ur reply.  
 
 The child window  pop ups when u do http://localhost:8080/manage . One
 enters the username and password there. That is validated against the
 acl_user folders member names or if it is a superuser who installed zope it
 validates it against the access file.
 
 I want to look at the source code and understand the authentication
 mechanism.That's why i want to know the following:-
 
 1.what is the python file which pops up that child window for entering
 username and password ?

It is your web browser, not a python script :-) It does that because it got a
"401 authentication required" response from zope.

 2.After u give the username and password what is the file / module name
 against which  the username and password is authenticated.

Well, username/password will be send together with all subsequent requests to
zope. Zope veryfies if username and password match against the info retreived
from the acl_users folder. What happens there depends on what object
*is* acl_users (i.e. Generic User Folder, mySQLuser, ACL Manager, Login Manager
)

 3.what is this 'manage'? method/module???

Well, that is the way to get the management screen. Source can be viewed at
zope-install/lib/python/OFS/manage.dtml

 
 Thx in advance
 
 -neeloy

- Holle

 
 
 
 -Original Message-
 From: Dieter Maurer [mailto:[EMAIL PROTECTED]]
 Sent: Friday, September 01, 2000 1:34 AM
 To: neeloy_saha
 Cc: '[EMAIL PROTECTED]'
 Subject: Re: [Zope] manage
 
 
 neeloy_saha writes:
   when i do http://localhost:8080/manage it pops up a login window which
 asks
   for username and password. what is the entry point after that??
 That is exactly what one would expect.
 
 Enter the username and password that was assigned during installation
 or that you set with
 
   python zpasswd.py access
 
   Is there a way of running zope with debugger?? 
 There is "Test.py" in "lib/python/ZPublisher".
 It will, however, not help you with the above problem.
 
 
 Dieter
 
 ___
 Zope maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists - 
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope-dev )
-- 
---
catWorkX GmbH Hamburg
Dipl.-Ing. Holger Lehmann
Stresemannstr. 364
22761 Hamburg
Tel: +49 40 890 646-0
Fax: +49 40 890 646-66
mailto:[EMAIL PROTECTED]
http://www.catworkx.de
http://www.catbridge.de

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




Re: [Zope] a redirect of an url in Python

2000-09-01 Thread Kapil Thangavelu

[EMAIL PROTECTED] wrote:
 
Part 1.1Type: Plain Text (text/plain)



in python you have to raise a redirect, search the lists for exact
syntax 
something along the lines of

raise Redirect "url"


Kapil

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




Re: [Zope] _setObject error - urgent!

2000-09-01 Thread Andy McKay

Yeah I know, I apologise I was just panicking with a deadline approaching.
Sorry.

- Original Message -
From: "Chris Withers" [EMAIL PROTECTED]
To: "Andy McKay" [EMAIL PROTECTED]
Sent: Friday, September 01, 2000 2:26 AM
Subject: Re: [Zope] _setObject error - urgent!


 Andy McKay wrote:
  I think I have traced my error with cut and paste, I am getting an error
on
  _setObject. If the object is not registered with Zope properly this will
be
  a problem. Basic synopsis:

 Well, what you're doing is kindof weird...

 sounds like something for the zope-dev guys. My only comment would be:

  **   No cross posts or HTML encoding!  **

 I know it's urgent (although putting that in the subject line will lower
 it in a lot of people's priorities ;-) but things generally belong in
 one list or another...

 Sorry for seeming like a 'list nanny' but it degrades the identity and
 the quality of the lists if there are too many cross-posts...

 cheers,

 Chris



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




Re: [Zope] _setObject error - urgent!

2000-09-01 Thread Andy McKay

Traced the problem to a faulty catalog attribute, which automatically
happens. Damn, its been a while I still cant see why I cant cut and paste.

- Original Message -
From: "Andy McKay" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, September 01, 2000 9:11 AM
Subject: Re: [Zope] _setObject error - urgent!


 Yeah I know, I apologise I was just panicking with a deadline approaching.
 Sorry.

 - Original Message -
 From: "Chris Withers" [EMAIL PROTECTED]
 To: "Andy McKay" [EMAIL PROTECTED]
 Sent: Friday, September 01, 2000 2:26 AM
 Subject: Re: [Zope] _setObject error - urgent!


  Andy McKay wrote:
   I think I have traced my error with cut and paste, I am getting an
error
 on
   _setObject. If the object is not registered with Zope properly this
will
 be
   a problem. Basic synopsis:
 
  Well, what you're doing is kindof weird...
 
  sounds like something for the zope-dev guys. My only comment would be:
 
   **   No cross posts or HTML encoding!  **
 
  I know it's urgent (although putting that in the subject line will lower
  it in a lot of people's priorities ;-) but things generally belong in
  one list or another...
 
  Sorry for seeming like a 'list nanny' but it degrades the identity and
  the quality of the lists if there are too many cross-posts...
 
  cheers,
 
  Chris
 


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



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




[Zope] Catalog AND Zieve

2000-09-01 Thread Menard . Jean-Francois

I'm trying to use the Zieve product with my Catalog to sort the results on a
variable key.  Since the Catalog do not return the actual objects, how can I
use Zieve with it?  

Maybe an external method returning the object list?  If so, how
shold I do that?

Jean-François Ménard
Intranet DPAS
Pratiques d'affaires et orientations
*(514) 840-3000  poste 3939
*  (514) 840-5585
*  [EMAIL PROTECTED]
* 855 Ste-Catherine est, 6e étage
  Montréal, Qué. H2L 4P5


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




[Zope] Re: ZPatterns Stability

2000-09-01 Thread Tim Cook

Chris Withers wrote:
 
 Tim Cook wrote:
   If you're brave you could try ZPatterns and then realyl not care at all
   ;-)
  
  
  Don't you mean; 'If you're insane...' ?
 
 No, I really don't!
 
 ZPatterns is very cool, but still not documented. It's alpha but seems
 stable enough for production in a lot of cases.
 


Thanks for the tip Chris. I had not even looked at ZPatterns (I'm
having enough problems getting basic Zopisms into my head g).
It looks very exciting but I think it'll wait for the next
version. Complete redesign would be in order to take advantage of
the concepts.

-- Tim Cook --
FreePM Project Coordinator http://www.freepm.org
OS Health Care Alliance Supporter http://www.oshca.org

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




[Zope] Getting Zope running on IIS or Apache using PCGI....

2000-09-01 Thread Chris Withers

Tina Sawyer wrote:
 Problem is : I was running Zope on Win 2000 Platform with IIS 5.0
 I could not get zope to run as a pcgi. So.. I set up a Linux server using
 Redhat version 6.2, running apache and I still cannot get zope to run as a
 pcgi. Any thoughts on this?

Might be best to ask on the [EMAIL PROTECTED] list instead of the PTK one
(I've copeid the message there)

You could also do with describing, in detail, what the problem you
encoutnered were.

Error messages and the like are always helpful,

cheers,

Chris

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




[Zope] Silly string question

2000-09-01 Thread Satheesh Babu

Aaarghhh!!!

I want to print the following line exactly as it
appears on a web page (no HTML coding).
 !--#include file="header.inc" --

How do I do that in  DTML without Zope cribbing
about tags are not good?

I got it to print it without using quotes like this
dtml-var expr="'!--#include file=header.inc --'"

However I need the quotes around header.inc too.
I tried escaping quotes with \, but doesn't work.

I don't want to put lt;!--include 

Zopistas, I think I'm missing something very basic here.
HELP!!!

Zope 2.1.6 on NT4. Browser IE5.5 on Win98.

vsb
http://easy.to/babu/

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




RE: [Zope] Newbie SQL problem: Query Error: Cannot render query template

2000-09-01 Thread Farrell, Troy

When I try to test my connection
(http://jester/profiles/Jet_database_connection/manage_test).  SQL is as
follows:

INSERT INTO test VALUES ( 'line one', 123456)

I get an error with the following traceback:

Error Type: Query Error
Error Value: Invalid Operation

Traceback (innermost last):
  File C:\PROGRA~1\JESTER\lib\python\ZPublisher\Publish.py, line 222, in
publish_module
  File C:\PROGRA~1\JESTER\lib\python\ZPublisher\Publish.py, line 187, in
publish
  File C:\PROGRA~1\JESTER\lib\python\Zope\__init__.py, line 221, in
zpublisher_exception_hook
(Object: RoleManager)
  File C:\PROGRA~1\JESTER\lib\python\ZPublisher\Publish.py, line 171, in
publish
  File C:\PROGRA~1\JESTER\lib\python\ZPublisher\mapply.py, line 160, in
mapply
(Object: manage_test)
  File C:\PROGRA~1\JESTER\lib\python\ZPublisher\Publish.py, line 112, in
call_object
(Object: manage_test)
  File C:\PROGRA~1\JESTER\lib\python\Shared\DC\ZRDB\Connection.py, line 180,
in manage_test
(Object: RoleManager)
  File C:\PROGRA~1\JESTER\lib\python\Products\ZJetDA\db.py, line 130, in
query
Query Error: (see above)

Testing my SQL inside Access yields expected results.  The SQL is fine.
If a user tries to access a dtml_document that trys to modify the database,
they get the same error.  I'm thinking that Zope 2.2.0 and 2.2.1 have some
big problems with DA's under Windoze.  Unfortunately, my app _MUST_ use
Access.  I'm not thrilled.  Can anyone more familiar with Python clue me in
on this?

Troy Farrell

-Original Message-
From: Philipp Auersperg [mailto:[EMAIL PROTECTED]]
Sent: Thursday, August 31, 2000 10:14 AM
To: [EMAIL PROTECTED]; Stephen Nosal
Subject: Re: [Zope] Newbie SQL problem: Query Error: Cannot render query
template


When starting Zope as a service under Win NT always make sure that
the ODBC data sources you use are *system* data sources and not *user* data
sources.

This could explain why your ODBC connections work when you start Zope from
the console and
don't work when starting it as service.

Anyhow:
Zope 2.1.6 is not the best for SQL (problems with recordsets show up
when used in dtml-tree)
Zope 2.2.0 has problems with ZODBC under Windows 2000 (Authorisation
dialogs pop up).

My hint:
Use 2.1.4 or 2.2.1 (does it fine with SQL under Linux and Windows )


phil

*** REPLY SEPARATOR  ***

On 31.08.2000 at 06:40 Stephen Nosal wrote:

Troy-

Have you tried running this from the DOS prompt? I ran into all sorts of
problems running 2.1.6 on NT4WS with the ODBCDA. Everything was fine when I
used the start and stop scripts from the command line. When I moved to
starting zope as a service, my ODBC connections kept failing. Never did find
an NT solution, I just moved everything to Linux.

It's worth a try.

- Steve

On Wed, 30 August 2000, "Farrell, Troy" wrote:

 
 Hello.
 
 I am running Zope as a service on NT4WS.  I have multiple MS Access
 databases connected to different ZJetDAs and I am not able to modify the
 data in them with SQL statements.  For example, INSERT INTO test VALUES
 (dtml-sqlvar value_one type=string, dtml-sqlvar value_two type=int)
 returns the error "Query Error: Cannot render query template".  Can you
tell
 me what the cause is.  I think it might be a permissions problem, but I
have
 everything wide open and I can't figure it out.
 
 Thanks.
 Troy Farrell
 
 Troy Farrell
 Video Operations Technician II
 Williams VYVX Services
 918.573.3029
 918.573.1441 fax
 mailto:[EMAIL PROTECTED]
 http://www.williams.com

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




Re: [Zope] Copying a dtml method when creating a ZClass instance

2000-09-01 Thread kamon ayeva

Thanks Tino and Chris for your feedback.

From: Tino Wildenhain [EMAIL PROTECTED]
To: kamon ayeva [EMAIL PROTECTED]
CC: [EMAIL PROTECTED]
Subject: Re: [Zope] Copying a dtml method when creating a ZClass instance
Date: Fri, 01 Sep 2000 14:18:25 +0200

Hi Kamon,

kamon ayeva wrote:
 
  Hi,
 
  I need some help.
  I have a DTML method at the root of Zope called 'Template'.
  How can I make the constructor of a ZClass (folderish) to copy this 
method
  to each of its instances ? Can someone provide me with a complete 
snippet to
  add in the ZClass constructor ?

Copy? Why?
aquisition should make it 'visible' in every subfolder automatically.

Regards
Tino

I have several reasons whay I need to attach a template to each ZClass. 
Among them are:
1/ cases like high level folders where I might want to customize the page's 
rendering and/or skin,
2/ cases like contained objects which uses a generic skin (but you can still 
customize the skin of one among them, if you want)
3/ my site needs to be easily designed / modified by Web Designers that do 
not understand Acquisition.

Thanks for the tip Chris, I was able to do it by adding my 
ZClass-specific-template in the Zope Product folder and adding a call to
manage_clone(ZClass-specific-template, 'standard_template', [REQUEST]) in 
the ZClass constructor method. I use the same id 'standard_template' to 
exploit acquisition globally on the site (the Web designer would not have to 
care about that).
Next thing is generalising this method to also allow multiple templates 
available for each object i.e. the Content Manager can choose a prefered 
skin when instanciating an object.

Best Regards,
Kamon
Ecubateur

_
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


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




Re: [Zope] HappySession

2000-09-01 Thread Dieter Maurer

Diego Rodrigo Neufert writes:
  I'm making a site with frames with session management. I'm using HappySession
  to do it...
  I need to call SESSION['something'] in various frames at the same time, but
  when a SESSION expire I got a Transaction Error that blow up my Zserver...
  
  Anyone know how to solve this or another SESSION product that doesnt have that
  problem?
I can tell you, that FSSession has the same problem, at least
the version before the current one (announced some days ago).

I would expect that SQLSession is more robust. But beware,
there may well be transaction conflicts, because several
threads may try to change the same record in the database.
If this indeed happens, than at least one transaction cannot
be committed and must be roled back.


Dieter

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




[Zope] Re: ZCatalog and OR searching

2000-09-01 Thread Dieter Maurer

Chris Withers writes:
  Dieter Maurer wrote:
   A ZCatalog search usually combines searches to the different
   indexes with an "And".
   You want to combine them with an "Or".
  
  Don't you wish there was a decent query language for ZCatalog so this
  kindof rediculous complexiting to achieve a simple outcome wasn't
  necessary?
I do -- but not enough to implement it ;-)


Dieter

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




RE: [Zope] manage

2000-09-01 Thread Dieter Maurer

neeloy_saha writes:
   authentication 
  1.what is the python file which pops up that child window for entering
  username and password ?
In plain vanilla Zope (i.e. without GUF, LoginManager or some other
login catcher)
Zope simply raises an Unauthorized exception.
This is turned into an HTTP Unauthorized response.
Your browser, upon receipt of such a response, pops up the dialog
and ask you for username and password.
It then automatically reissues the request.

  2.After u give the username and password what is the file / module name
  against which  the username and password is authenticated.
For any request, Zope traverses the hierarchical WebSite object
guided by the request's URL. At the URL's end, it reaches
some object (or has raised a "NotFound" exception).
From that object, Zope looks back along its path for
objects that are able to authenticate some users.
Usually, these are objects that contain a "user folder", usually
called "acl_users".
Authentication is done by such a "user folder".
You find the code near the end of "ZPublisher.BaseRequest.traverse".

A user folder has a method "validate".
It gets the request, authentication information and
(optionally) the list of roles necessary to access the target
object. It returns a user object, if it can one authenticate
for the given authentication information and with the required
roles, otherwise, it returns None.
If it return None, Zope looks furhter up in the path.
If it reaches the end without being able to authenticate
the user, it raises an Unauthorized exception (this leads to 1) above).

You find Zope's vanilla user folder in "AccessControl.User.UserFolder".

  3.what is this 'manage'? method/module???
There is none.



Dieter

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




Re: [Zope] Site Access 2.x problem

2000-09-01 Thread Dieter Maurer

Hi Joshua,

Joshua Brauer writes:
  I have Site Access running on the latest Zope (2.2) but I cannot seem to get "Site 
 Root" to show up in my list of available products. Those sites that already have site 
 roots seem to work fine, but I cannot add new site roots. Anybody else having this 
 problem or have ideas?
Fetch the latest Zope distribution (2.2.1, not 2.2.1b1), because
earlier versions had a logging bug.

Start your Zope with a "STUPID_LOG_FILE=zope.log" argument.

Look into "zope.log", if you see any message related to "SiteAccess".


Dieter

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




Re: [Zope] a redirect of an url in Python

2000-09-01 Thread Bill Welch

Both this one line python method:

raise 'Redirect', 'http://www.zope.org'

and this DTML method

dtml-raise type="Redirect"
http://www.zope.org
/dtml-raise

work.

P. S. the double quotes around Redirect in the DTML method are
significant. With single quotes, it shows up as an error named Redirect

Bill.

On Fri, 1 Sep 2000, Kapil Thangavelu wrote:

 in python you have to raise a redirect, search the lists for exact
 syntax 
 something along the lines of
 
   raise Redirect "url"


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




Re: [Zope] HappySession

2000-09-01 Thread Pavlos Christoforou

On Fri, 1 Sep 2000, Dieter Maurer wrote:

 I can tell you, that FSSession has the same problem, at least
 the version before the current one (announced some days ago).

FSSession has no longer such problem. However you might still loose data
if you access the same SessionUID from many frames. I don't thing there is
a general solution to the problem without involving read locks which will
slow down the whole Zope site. Or raising ConflictErrors which for frame
usage like the case you mention will occur very often. The same problem
will occur whether you store the Session info in an RDBMs or not. For
instance:

Thread A reads Session1
Thread B reads Session1
Thread A modifies Session1 and commits
Thread B modifies Session1 and commits.

This creates a conflict and the solution I have chosen is to keep the last
to commit. In general we can achieve very high write rates because there
is a natural isolation among requests, one thread per SessionUID. Problems
will occur if multiple concurrent requests try to access the same
SessionUID. This could occur in situations that employ frames but (at
least in our case) most of the time the Session info is required only in
one frame. In any case I have tested the latest version of FSSession
against multiple frames accessing the same SessionUID and I do not get
TransactionErrors.

Actually there is a slightly better way but it will involve a lot of
complicated programming so I won't even mention it ... :-)

Pavlos


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




Re: [Zope] ZCatalog in 2.2.x

2000-09-01 Thread Dieter Maurer

Terry Kerr writes:
   only field searches yield non empty query results 
  The product I am working on is Etailer.
I downloaded Etailer and looked into the problem.

Indeed, I could reproduce your observation.

I analysed the problem and now do understand what went
wrong here in my installation:

  I have 2 vocabularies, both named 'Vocabulary'.
  One is in my root, the other is in the Etailer "Catalog".

  When objects are indexed, this happens in the context
  of "Etailer/Catalog". Therefore, "Etailer/Catalog/Vocabulary"
  is used for this purpose.

  When objects are searched for, this happens in the context
  of "Etailer". Therefore, "/Vocabulary" is used for
  word lookup. It does know nothing about the words
  used in my Etailer products.

Maybe, in your installation things are similar.
At least, Etailer is very volatile when there is
another object called 'Vocabulary' above it.
This results from line 159 of "Etailer.py":
searchResults = ZCatalog.searchResults

You should provide a true, redirecting definition for
"searchResults":

def searchResults(self,REQUEST=None, used=None, **kw):
  " "
  return apply(self.Catalog.searchResults,(REQUEST,used),kw)

to make it more robust.



Dieter

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




Re: [Zope] Silly string question

2000-09-01 Thread Evan Simpson

From: Satheesh Babu [EMAIL PROTECTED]
 I want to print the following line exactly as it
 appears on a web page (no HTML coding).
  !--#include file="header.inc" --

These aren't general solutions, but off the top of my head (tested):

dtml-var expr=" '' "!--#include file="header.inc" --

dtml.missing--;!--#include file="header.inc" --

Cheers,

Evan @ digicool  4-am


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




[Zope] Regaining lost privileges

2000-09-01 Thread Andrew Kenneth Milton

Is there anyway to regain 'root' privs from inside a zope product?

Using the -u flag to start causes the privs to be permanently gone because
z2.py uses setuid + setgid (and python doesn't seem to define sete[ug]id, at
least not on my system).

Other than running zope as root permanently (which I really would like to
avoid), does anyone have any quick ideas on how to achieve this?

I saw people asking about building 'admin' systems using Zope, this isn't
going to be trivially possible without super user privs.

-- 
Totally Holistic Enterprises Internet|  P:+61 7 3870 0066   | Andrew Milton
The Internet (Aust) Pty Ltd  |  F:+61 7 3870 4477   | 
ACN: 082 081 472 ABN: 83 082 081 472 |  M:+61 416 022 411   | Carpe Daemon
PO Box 837 Indooroopilly QLD 4068|[EMAIL PROTECTED]| 

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




[Zope] problems installing PoPy-1.3.4 (fwd)

2000-09-01 Thread Sebastien Billard


I'm on a suse 6.4 system, with postgresql installed.  I've got the latest
zope installed from tarball.. and I get this problem trying to install
PoPy

 ./autogen.sh --with-postgres-libraries=/usr/lib/pgsql/lib
--with-postgres-includes=/usr/lib/pgsql/include
loading cache ./config.cache
checking for python... /usr/bin/python
checking python version... 1.5
checking python installation prefix... /usr
checking python installation exec_prefix... /usr
checking definitions in Python library makefile... done
checking location of python
library... $(prefix)/lib/python1.5/site-packages
checking location of python shared
modules... $(exec_prefix)/lib/python1.5/site-packages
checking for PQconnectStart in -lpq... no
configure: error: can't build without PostgreSQL libraries

Now type 'make' to compile PoPy python module.




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




Re: [Zope] What's up with zope.org?

2000-09-01 Thread Bak @ kedai


-Original Message-
From: ethan mindlace fremen [EMAIL PROTECTED]
To: Bak @ kedai [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED] [EMAIL PROTECTED]
Date: Friday, September 01, 2000 11:49 PM
Subject: [Zope] What's up with zope.org?


"Bak @ kedai" wrote:

 what's happenng to zope.org?  i got this message when i tried accessing
it

Ok, this is a bit late, but "Running into ZEO/ mounted file storage
bugs" is the answer.

Aparently, our in-house MountedClientStorage (and the MountedDatabase)
doesn't play nice with ZEO.  So we've backed off of ZEO for the moment,
pending the magic Jim touch.
--
so, if i use only ZEO, it should be a problem then?

ethan mindlace fremen
Zopatista Community Liason
Abnegate I!

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


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




Re: [Zope] Regaining lost privileges

2000-09-01 Thread Nigel Head

Hi Andrew!

On Fri, 01 Sep 2000, you wrote
...
 I saw people asking about building 'admin' systems using Zope, this isn't
 going to be trivially possible without super user privs.

That people was me. Having looked into things a little further (but not
actually started the admin tool yet due to "day job" pressures) I've decided
to go the route (root?!) of using something like 'sudo' or 'runas'  which
allow you to provide a selection of suid scripts and specify which users are
allowed to run them (zope, in my case, I suppose).

I'm still considering the relative merits of using a sort of 'quarantine'
file/database where zope will dump requests to do things and a cron job will
poll it periodically to grab things out again and execute them.

As I wrote that,  I realise dthat it would be interesting to see if that file
couldn't be made a ZODB storage so I could transfer
structured information 'tween Zope and a python admin backend; perhaps make it
a mountable storage from the zope point of view? This would have the added
advantage of a little mild 'security through obscurity' for the file format for
casual hackers who may get near to it one day ...

--  Nigel Head Houbits Hi-Tech
Servers [EMAIL PROTECTED]

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