Re: [Zope] PythonMethod problem

2000-12-11 Thread Philipp Auersperg

PythonScripts will come with Zope 2.3


How did you call the method?
perhaps you forgot the 'self'
your call should look like this:

self.foo(...)

phil

*** REPLY SEPARATOR  ***

On 10.12.2000 at 16:22 kosh wrote:

I know I am still using PythonMethods however I have not seen Python
Scripts out yet for 2.2.4.

Okay here is the problem. How do I call one PythonMethod from another
PythonMethod?

Example

object foo is a python method and it takes a='',b='',c='',d=''

does stuff
returns a string


foo_spec takes parameters a1='',b1=''
it should return foo(a=a1,b=b1)

However trying to call that foo gives an error.

I get a NameError on foo when it is used in foo_spec. However using foo
directly does work however I want to make easier customized interfaces for
users.

Thanks


___
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] Zope (after) install problems

2000-12-11 Thread Kai Hofmann

I installed Zope 2.2.2 with Python 1.6 (incl. threads) under Solaris 2.6 
(Sparc) without problems at first.
I changed the z2.py so that Zope runs on port 4081 also I added the -D 
option to the start script.

When I access the Webserver at Port 4081 I got the welcome message :)
But when clicking on "QuickStart" or "management screen" I got only errors:

Error Type: ParserError
Error Value: arglist: internal error; nch != i 

Traceback (innermost last):
  File /home/src/www/Zope-2.2.2-src/lib/python/ZPublisher/Publish.py, line 
222, in publish_module
  File /home/src/www/Zope-2.2.2-src/lib/python/ZPublisher/Publish.py, line 
187, in publish
  File /home/src/www/Zope-2.2.2-src/lib/python/Zope/__init__.py, line 221, in 
zpublisher_exception_hook
(Object: Traversable)
  File /home/src/www/Zope-2.2.2-src/lib/python/ZPublisher/Publish.py, line 
171, in publish
  File /home/src/www/Zope-2.2.2-src/lib/python/ZPublisher/mapply.py, line 
160, in mapply
(Object: index_html)
  File /home/src/www/Zope-2.2.2-src/lib/python/ZPublisher/Publish.py, line 
112, in call_object
(Object: index_html)
  File /home/src/www/Zope-2.2.2-src/lib/python/OFS/DTMLMethod.py, line 
172, in __call__
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 471, in __call__
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 408, in cook
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 242, in parse
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 292, in parse_block
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 242, in parse
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 292, in parse_block
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 242, in parse
(Object: index_html)
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_String.py, line 305, in parse_block
(Object: index_html)
  File /home/src/www/Zope-2.2.2-src/lib/python/DocumentTemplate/DT_If.py, 
line 165, in __init__
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/DT_Util.py, line 389, in name_param
(Info: ({'expr': "objectValues(['Folder'])"}, 'if', 1, 'name'))
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/VSEval.py, line 194, in __init__
(Object: objectValues(['Folder']))
  File /home/src/www/Zope-2.2.2-
src/lib/python/DocumentTemplate/gparse.py, line 293, in compile
ParserError: (see above)


The same happens for the management screen - after the login prompt.
Zope makes no output to the debug console during this.


Last but not least I tried to access the debug-monitor - which results into a 
strange number in the browser and the debug console output "failed 
authorization".


Can somebody help me making Zope working?


Thanks in advance

Kai Hofmann

-- 
Dipl.-Inform. Kai Hofmann [EMAIL PROTECTED]
ISL - Bremen  -  http://www.isl.org/
Universitätsallee GW1 Block A
D-28359 Bremen
Germany

___
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] Install problem with fastcgi

2000-12-11 Thread Holger Hoffmann

Hi,

[EMAIL PROTECTED] wrote:
 
 Hello all,
 I try to install mod_fastcgi but Apache says :
 Cannot load /usr/lib/apache/1.3/mod_fastcgi.so
 into server: / usr/lib/apache/1.3/mod_fastcgi.so:
 undefined symbol: ap_os_is_path_absolute
 /usr/sbin/apachectl start: httpd could not be started
 
 I compiled with the options:
 apxs -o mod_fastcgi.so -c *.c
 apxs -i -a -n fastcgi mod_fastcgi.so
 
 And add in the file http.conf :
 LoadModule fastcgi_module /usr/lib/apache/1.3/mod_fastcgi.so

do you have a ClearModuleList directive ? Then
you should add

AddModule mod_fastcgi.c

 Versions used:
 - Apache 1.3.9-13 (Debian Potato)
 - Mod_fastcgi 2.2.10
 
 Is you see why ...

... Holger

___
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] Read-only zope (not zope from a readonly Data.fs)

2000-12-11 Thread Chris Withers

Pericles Akritides wrote:
 
 Hi,
 
 Is there a way to make zope run read-only(with whatever loss of functionality doing 
that implies)?
 I don't mean to prevent it from trying to write to disk (demo storage, -r),
 I mean to make it impossible to change persistent objects in the running Zope 
instance,
 something like disabling their __setattr__ (since it is hooked by Persistent, right?)

run python z2.py -h

I'm sure there's a command l;ine option described there to do just that
:-)

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] Squishdot base href

2000-12-11 Thread Chris Withers

Hanno Schulz wrote:
 
 Hi!
 
 We got a base href at the first line of every squishdot page!
 Where does it come from??? And it kill our siteroot at this site.

It's generated by zope. 

Search mail mailing list archives at
http://zope.nipltd.com/public/lists.html and you'll find a few threads
about this.
It shouldn't kill your siteroot if your siteroot is doign what it should
;-)

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] updating the catalog - successfully!

2000-12-11 Thread josh on

I was having a lot of problems with keeping a catalog up to date when I
manipulated data in an instance of a zclass (catalog aware).  I was calling
this, from a dtml file in the same folder as the instances, and one folder
down from the Catalog:

dtml-call "_[userid].propertysheets[1].manage_changeProperties(REQUEST)"
dtml-call reindex_object

This just was not re-indexing the Catalog successfully at all.  I checked
the zope list and I think that a lot of people have had the same problem,
including myself a few months back... All the answers suggest using:

dtml-call reindex_object

or even:

dtml-call reindex_object
dtml-call reindex_object

So I just littered that all through my code in the vein hope that the
Catalog would get the hint. But it was stubborn.  The data would be altered,
meanwhile the Catalog remained oblivious.

The good news is that I have seemingly found a way to update my catalog by
making a method of my zclass called update_dtml which I call when change the
data of an instance. the method contains only one thing (of course):

dtml-call reindex_object

I call it from the dtml that manipulates the data of the instance (from a
file in the same directory as the instances):

dtml-call "_[userid].propertysheets[1].manage_changeProperties(REQUEST)"
dtml-in "objectValues(['zclassuser'])"
dtml-var update_dtml/dtml-in

The bad news is that I don't have a clear understanding of why this works. I
guess that the dtml-call reindex_object is context sensitive and is a
method of the zclass, so it needs to be called from there.

Does this make sense ?  If it does I think that it should be turned into a
how to.

or am I just being silly?

josh on

===
write: [EMAIL PROTECTED]
read: www.futurefarmers.com
read: www.crd.rca.ac.co.uk/~josh
interrupt (i love it): (415) 552 2124
=


___
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] ZDiscussions compatible to Zope-2.2.4??

2000-12-11 Thread Kaeidinejad, Shahram

Hi,

is ZDiscussions compatible to Zope-2.2.4?
I tried to install ZDiscussions-0.2.0 but i got this error:

Error Type: SystemError
Error Value: Failed to import class _ZClass_for_ZDTopic from module
Products.ZDBase

Traceback (innermost last):
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
222, in publish_module
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
187, in publish
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/Zope/__init__.py, line 221, in
zpublisher_exception_hook
(Object: Traversable)
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
171, in publish
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/mapply.py, line
160, in mapply
(Object: manage_importObject)
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
112, in call_object
(Object: manage_importObject)
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/OFS/ObjectManager.py, line
535, in manage_importObject
(Object: Traversable)
  File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZODB/ExportImport.py, line
208, in importFile
SystemError: (see above)



bye

Shahram


___
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] (no subject)

2000-12-11 Thread Cornelis J. de Brabander

I have an educational application in which teachers and students can upload
all kinds of documents as files. Since I upgraded from Zope 2.0.1 to 2.1.6 I
have a problem with html-documents that are added as files. What happens is
that the text in the last HTML-paragraph is cut off somewhere in the middle.
Checking the source of the added document shows that after the point where
the text is cut off all text and codes have disappeared. Does anybody have
similar experiences and/or a clue as to what might cause this strange
behavior? The file is added by a method that essentially is a wrapper around
'manage_addFile'

tia, cb

Cornelis J. de Brabander
==
Department of Education, Leiden University
P.O.Box 9555, NL-2300 RB Leiden
+31 71 527 3422/3401
[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] Patch to avoid hypenation variables and more

2000-12-11 Thread Tino Wildenhain

Hi again,

anybody had time to test this? Chances for next zope release?
Any remarks? Alternatively, btw. would be a name attribut,
which defaults to "sequence". 

Regards
Tino

Tino Wildenhain schrieb:
 
 Michel Pelletier schrieb:
 
 
   The second problem is if you put one in-tag into another.
   You have to use dtml-let oder REQUEST.set() with variables
   of the outher in-tag to be able to reference them in the inner
   loop. The code becomes very ugly this way. So my idea was to
   give the in-tag an optional argument, called "prefix" to
   prefix all the sequence-variables with a custom identifier.
   So you can write:
  
   dtml-in some_sequence prefix="outer_"
  dtml-in some_other_sequence
dtml-var outer_sequence_item:dtml-var sequence_item
  /dtml-in the inner sequence
   /dtml-in the outer sequence
  
   What do you think about this?
 
  It's cool.  Your patches are big and therefore, naturally, are a bit
  worrisome to us in terms of checking them into the core.  Do you have a
  set of test DTML scripts that verify your patch?  Say, a set of scripts
  that verifies backwards compatibity, and a set of scripts that verifies
  the new functionality?  I would suggest even investigating "ZUnit" and
  creating DTML unit tests.  Then we would *really* love you.  ;)
 
 Have to find this ZUnit... ;)
 Ok, I made some further tests and improvements. There was a mistake
 (ok, it comes from variables spilled randomly over DT_In.py and
 DT_InSV.py ;)
 with the prefix. In some cases it wasnt there as supposed.
 
 Now all the prefix-handling should be ok. I've made an yet simple
 test-suite, all available thru
 http://www.zope.org/Members/tino/
 (See "Patch for dtml-in" there)
 
 Note: the prefix prepends only the in-tags own variables. Any attribute
 coming from the sequence is untouched. This is also true for statistic
 variables and the magic "mapping" symbol.
 
 While it could easy be implemented, I think prefixing all attributes is
 not such a good idea. If you are ilterating over database queries you
 can rename the attributes there.


___
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] Patch to avoid hypenation variables and more

2000-12-11 Thread Tino Wildenhain

Hi,

anybody had time for testing? May be we could have it in the next 
zope release. Any comments, remarks? How about an alternatively or
extra "name"-attribute wich defaults to "sequence" ?

Another issue: what about an alias for dtml-var called something
like: dtml-print dtml-output or dtml-out ? Just for the 
ones that lern zope. Since I often see the missunderstood meaning
of dtml-var in such constructs like: dtml-var "somelist[dtml-var
indexvar]"
you know what I mean? I think it would be more obvious, if the
tag would usually be called dtml-out or something.

Regards
Tino


Tino Wildenhain schrieb:
 
 Michel Pelletier schrieb:
 
 
   The second problem is if you put one in-tag into another.
   You have to use dtml-let oder REQUEST.set() with variables
   of the outher in-tag to be able to reference them in the inner
   loop. The code becomes very ugly this way. So my idea was to
   give the in-tag an optional argument, called "prefix" to
   prefix all the sequence-variables with a custom identifier.
   So you can write:
  
   dtml-in some_sequence prefix="outer_"
  dtml-in some_other_sequence
dtml-var outer_sequence_item:dtml-var sequence_item
  /dtml-in the inner sequence
   /dtml-in the outer sequence
  
   What do you think about this?
 
  It's cool.  Your patches are big and therefore, naturally, are a bit
  worrisome to us in terms of checking them into the core.  Do you have a
  set of test DTML scripts that verify your patch?  Say, a set of scripts
  that verifies backwards compatibity, and a set of scripts that verifies
  the new functionality?  I would suggest even investigating "ZUnit" and
  creating DTML unit tests.  Then we would *really* love you.  ;)
 
 Have to find this ZUnit... ;)
 Ok, I made some further tests and improvements. There was a mistake
 (ok, it comes from variables spilled randomly over DT_In.py and
 DT_InSV.py ;)
 with the prefix. In some cases it wasnt there as supposed.
 
 Now all the prefix-handling should be ok. I've made an yet simple
 test-suite, all available thru
 http://www.zope.org/Members/tino/
 (See "Patch for dtml-in" there)
 
 Note: the prefix prepends only the in-tags own variables. Any attribute
 coming from the sequence is untouched. This is also true for statistic
 variables and the magic "mapping" symbol.
 
 While it could easy be implemented, I think prefixing all attributes is
 not such a good idea. If you are ilterating over database queries you
 can rename the attributes there.


___
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:API and namespace

2000-12-11 Thread Sven Hohage

Hallo Alexander,
this works for me-

dtml- with "manage_addProduct['myProduct']"
 dtml- call "NewFolder_add (_.None, _, NoRedir=1)" 
/dtml-with   
dtml-with "_.getitem(idOfNewFolder)"
 dtml- with "manage_addProduct['myProduct']"
  dtml- call "Document_add (_.None, _, NoRedir=1)"
 /dtml-with
/dtml-with
Bye
   Sven

___
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] ZDiscussions compatible to Zope-2.2.4??

2000-12-11 Thread J. Atwood

Try ZUBB 0.6.0

http://www.zope.org/Members/BwanaZulia/ZUBB

I have not tried it on 2.2.4 but it works fine on 2.2.2

J

At 11:00 AM +0100 12/11/2000, Kaeidinejad, Shahram wrote:
Hi,

is ZDiscussions compatible to Zope-2.2.4?
I tried to install ZDiscussions-0.2.0 but i got this error:

Error Type: SystemError
Error Value: Failed to import class _ZClass_for_ZDTopic from module
Products.ZDBase

Traceback (innermost last):
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
222, in publish_module
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
187, in publish
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/Zope/__init__.py, line 221, in
zpublisher_exception_hook
 (Object: Traversable)
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
171, in publish
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/mapply.py, line
160, in mapply
 (Object: manage_importObject)
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZPublisher/Publish.py, line
112, in call_object
 (Object: manage_importObject)
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/OFS/ObjectManager.py, line
535, in manage_importObject
 (Object: Traversable)
   File /dgn-devel01/opt/Zope-2.2.4/lib/python/ZODB/ExportImport.py, line
208, in importFile
SystemError: (see above)



bye

Shahram


___
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] ZClass with images

2000-12-11 Thread Aleksander Salwa

On Sat, 9 Dec 2000, Diego Rodrigo Neufert wrote:

 Anyone know how to put some images in  ZClass? I have done things like 
 putting ZClass with base class OFS:Image but with it I can only assing one 
 Image do the object... I need to assign two or tree images do the object.

Try to subclass OFS:Folder. In that folder you can put as many images as
you want.
I have 1 ZClass deriving from both Folder and DTMLMethod and it works
fine. (I had some trouble with setting view tabs properly, but finally I
solved it.)

[EMAIL PROTECTED]

/--\
| `long long long' is too long for GCC |
\--/





___
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] API and namespace

2000-12-11 Thread Alexander DePauli

Hi all,

so I was in error as I finally judged myself unterstanding the namespace
concept... ;)

Via a configuration interface, I want to add a folder, add some
properties for the new folder, then add and fill a dtml-document within
the new folder.
Adding the folder works fine, but then I can't change the namespace to
work with the new folder - the namespace sticks to the parent-folder and
my code stupidly tries to add the new properties and document there.

How can I switch the namespace to the new folder (dtml-with
new_folderid doesn't do the trick...)

My code right now looks as follows (the dtml-method is called via a
form):

--! add a new folder --
dtml-call "manage_addProduct['OFSP'].manage_addFolder 
(id=REQUEST['new_folderID'], title=REQUEST['new_folderID'])"
[..]

dtml-with new_folderID ...tried dtml-with "_.namespace(folder =
new_folderID)" as well...

--! add some properties --
dtml-call "manage_addProperty(id='bestand', 
value=REQUEST['bestand'], type='int')"
[..]

--! now add a new index_html --
dtml-call "manage_addDocument(id='index_html', 
title=REQUEST['animalID'])"
[..]

/dtml-with


Any help highly appreciated!
Cheers, Alexander
~
http://www.herrenausstatter.de - Der Online-Herrenausstatter
Kostenlose Serviceline: 0800 -999 66 33
Versandkostenfreie Lieferung - 30 Tage Rückgaberecht
~
Verwaltungsadresse:
DePauli.com Aktiengesellschaft
Stahlgruberring 3 - 81829 München
Telefon: 089 / 530 75 170 - Telefax 089 / 514 50 666

___
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] z2.py -i

2000-12-11 Thread [EMAIL PROTECTED]

hello all
can anybody shed some light on the "-i" option in z2.py.  according to the 
help 

-i n
 
Set the interpreter check interval. This integer value
determines how often the interpreter checks for periodic things
such as thread switches and signal handlers. The Zope default
is 120, but you may want to experiment with other values that
may increase performance in your particular environment.

can anybody explain in plain english please.  if i decrease the number, 
what'll happen?  if i increase it?  what the heck is it anyway?

dummy, that's me..

tia
-- 

http://www.kedai.com.my/kk 
http://www.kedai.com.my/eZine 

Just bring it!



___
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] Patch to avoid hypenation variables and more

2000-12-11 Thread Jose Soares



Tino Wildenhain wrote:

 Hi,

 anybody had time for testing? May be we could have it in the next
 zope release. Any comments, remarks? How about an alternatively or
 extra "name"-attribute wich defaults to "sequence" ?

 Another issue: what about an alias for dtml-var called something
 like: dtml-print dtml-output or dtml-out ? Just for the
 ones that lern zope. Since I often see the missunderstood meaning
 of dtml-var in such constructs like: dtml-var "somelist[dtml-var
 indexvar]"
 you know what I mean? I think it would be more obvious, if the
 tag would usually be called dtml-out or something.


Yes. I vote for dtml-print  some_var



 Regards
 Tino

 Tino Wildenhain schrieb:
 
  Michel Pelletier schrieb:
  
 
The second problem is if you put one in-tag into another.
You have to use dtml-let oder REQUEST.set() with variables
of the outher in-tag to be able to reference them in the inner
loop. The code becomes very ugly this way. So my idea was to
give the in-tag an optional argument, called "prefix" to
prefix all the sequence-variables with a custom identifier.
So you can write:
   
dtml-in some_sequence prefix="outer_"
   dtml-in some_other_sequence
 dtml-var outer_sequence_item:dtml-var sequence_item
   /dtml-in the inner sequence
/dtml-in the outer sequence
   
What do you think about this?
  
   It's cool.  Your patches are big and therefore, naturally, are a bit
   worrisome to us in terms of checking them into the core.  Do you have a
   set of test DTML scripts that verify your patch?  Say, a set of scripts
   that verifies backwards compatibity, and a set of scripts that verifies
   the new functionality?  I would suggest even investigating "ZUnit" and
   creating DTML unit tests.  Then we would *really* love you.  ;)
  
  Have to find this ZUnit... ;)
  Ok, I made some further tests and improvements. There was a mistake
  (ok, it comes from variables spilled randomly over DT_In.py and
  DT_InSV.py ;)
  with the prefix. In some cases it wasnt there as supposed.
 
  Now all the prefix-handling should be ok. I've made an yet simple
  test-suite, all available thru
  http://www.zope.org/Members/tino/
  (See "Patch for dtml-in" there)
 
  Note: the prefix prepends only the in-tags own variables. Any attribute
  coming from the sequence is untouched. This is also true for statistic
  variables and the magic "mapping" symbol.
 
  While it could easy be implemented, I think prefixing all attributes is
  not such a good idea. If you are ilterating over database queries you
  can rename the attributes there.
 

 ___
 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] Important Fix for Zope 2.0 through 2.1.6

2000-12-11 Thread Hannu Krosing

Evan Simpson wrote:
 
 Thanks to Jeff Ragsdale, we've finally been able to kill a
 longstanding bug that allows POST requests to interfere with
 each other.  Symptoms include corrupted or aborted File and
 Image uploads, and stupid-log messages about
 "AttributeError: data" killing threads.

Could something similar be happening in PCGIServer too ?

We are getting some weird and hard-to-reproduce errors when activity 
goes up and several file uploads are going on simultaneously?

---
Hannu

___
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] PCGI crash problem with SQL/LIMIT

2000-12-11 Thread Mayers, Philip J

I'm running Zope 2.2.4 and am having a *very* annoying problem (either I'm
missing something, or Zope is broken).

I've got an SQL table called "users". An SQL query of the form:

select * from users limit 10

Works, but:

select * from users

Fails spectacularly - pcgi_publisher crashes with the error message:

Temporarily Unavailable 
The resource you requested is temporarily unavailable - please try again
later. 
 
(116) unable to connect, fd=6 

I then get a 20 second timeout while PCGI restarts Zope. Grr. Help please

Regards,
Phil

+--+
| Phil Mayers, Network Support |
| Centre for Computing Services|
| Imperial College |
+--+  

___
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:API and namespace

2000-12-11 Thread Sven Hohage

Hi Alexander,
I think I've made a mistake.
I thought you are about ZClasses.
My snippet adds two ZClasses (a folder-like and a document).
These Classes are self-defined(take a look at the HowTos or the 
Developer-Guide"http://www.zope.org/Documentation/Guides/ZDG").
For you this is sufficient -
   dtml- call "manage_addFolder (FolderName)" 
  
dtml-with "_.getitem(FolderName)"
dtml- call "manage_add (DocumnetName)"
/dtml-with

Here are some starting-hints:
They are all taken from the Zope Quick Reference

--manage_addFolder(id, [title, createPublic, createUserF, REQUEST])
   Add a new Folder object with id id. If the createPublic 
   and createUserF parameters are set to 
   any true value, an index_html and a UserFolder objects
   are created respectively in the new folder. 


--manage_addDTMLDocument(id, [title, file, REQUEST, submit])
   Add a DTML Document object with the contents of file.
   If file is empty, default document text is used. 
--getitem(name,flag)
   Lookup a name in the namespace. If the value is callable
and 
   the flag is true, then the result of calling the value 
   is returned, otherwise the value is
   returned. flag defaults to false. 


You find the reference at --http://zdp.zope.org/
 Hope that helps!
 Bye

___
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] regex vs ts_regex

2000-12-11 Thread Brian Lloyd

 Apropos http://www.zope.org/Documentation/How-To/ThreadSafety
 
 Am I missing something here? 
 There seem to be a number of places in the current 2.2.4 source where
 the python regex module is used - not ts_regex, thus apparently
 violating your advice on thread safety? 
 
 For example, I was just spelunking through
 /lib/python/AccessControl/User.py, App/Product.py so I started greping a
 few subdirectories.
 
 DateTime.py uses ts_regex as does OFS/ObjectManager.py but NOT
 OFS/SimpleItem.py ...
 
 Is there some reason why it's ok for some modules to use regex rather
 than ts_regex ???

It is safe to use it in certain cases where the thread 
safety problems of the regex internals are not an issue. 

I think Jim and some others who have used regex purposefully 
have added a #TS comment to indicate that they have thought 
through the threading issues before using it.

This will be moot in the future - one of the things 
we'll _have_ to do to move to Python2.0 is become 
SRE compliant.

Hope this helps!


Brian Lloyd[EMAIL PROTECTED]
Software Engineer  540.371.6909  
Digital Creations  http://www.digicool.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] Freelance Programmers

2000-12-11 Thread Brendon Grunewald

Hi Zopistas,

I have some work that needs doing and can't make / find the time to do it,
hence am looking for some assistance. (The usual Xchange sites typically are
weak in Zope and Python skills.) I would ideally like to find a couple of
people that want to do this part time on a project by project basis. This is
and will not require full time work, and the size of projects will vary.
(e.g the first project will be to integrate several existing zope products
into a functional site, no layout and web design needed, just the back end
integration.)

Can you point me in the right direction?

Regards
Brendon

--
70South: the No.1 source for Antarcticles.
For the latest news and views on Antarctica visit : http://www.70south.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] Re: API and namespace

2000-12-11 Thread Alexander DePauli

Rehi Sven,

thanks a lot for your patience with the dummy - which is me :)

Sorry to say that my problem consists even when applying your snippet.

Your statement
dtml-with "_.getitem('NewFolder')" 
looks fine to me, but ZOPE insists on creating the new document in 
   /OldFolder 
instead of 
   /OldFolder/NewFolder

Some more stuff for wondering:
If I do a 
   dtml-with "_.getitem('NewFolder')" 
   dtml-var "_.getitem('NewFolder',0)"
to get an actual value for testing purposes, ZOPE returns the *correct*
value.

But if I do an additional 
   dtml-in objectItems
id: dtml-var sequence-key,
type: dtml-var meta_type
   /dtml-in
to get the objects in the actual namespace (surely *after* the above
dtml-with.., 
the output is the one of the /OldFolder-namespace, not that of the
/OldFolder/NewFolder.

...I'm sure this is a rookie-problem and can be solved by turning a
switch or two (perhaps in my brain), but I'm stuck.

Do you/anybody has any clue?

Thanks in advance + all the best
Alexander


Sven Hohage schrieb:
 For you this is sufficient -
dtml- call "manage_addFolder (FolderName)"
 
 dtml-with "_.getitem(FolderName)"
 dtml- call "manage_add (DocumnetName)"
 /dtml-with

~
http://www.herrenausstatter.de - Der Online-Herrenausstatter
Kostenlose Serviceline: 0800 -999 66 33
Versandkostenfreie Lieferung - 30 Tage Rückgaberecht
~
Verwaltungsadresse:
DePauli.com Aktiengesellschaft
Stahlgruberring 3 - 81829 München
Telefon: 089 / 530 75 170 - Telefax 089 / 514 50 666

___
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] Incrementing a form field

2000-12-11 Thread César A. K. Grossmann

Hi!

I have a form that is used to insert some records to a database, and one
of the fields is a sequence number. I want to increment this number when
the form is used, unless is the first time it is loaded.

The form (idea copied from the SmartForms HOWTO) have the name
"Register", and is something like this:

dtml-var standard_html_header

dtml-if "REQUEST.REQUEST_METHOD=='POST'"
  Record inserted.
/dtml-if

dtml-if my_number
  dtml-call "REQUEST.set('my_number', my_number + 1)"
dtml-else
  dtml-call "REQUEST.set('my_number', 1)"
/dtml-if

form action="Register" method="POST"
A Field input name="my_field" value="some value"br
A Number input name="my_number" value="dtml-var my_number"br
input type="submit" value="OK"
/form

dtml-var standard_html_footer

It work for the first load, but when I press the OK button, I get an
error message:

Error Type: TypeError
Error Value: illegal argument type for built-in operation

The traceback:

!--
Traceback (innermost last):
  File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 222,
in publish_module
  File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 187,
in publish
  File /usr/share/zope/lib/python/Zope/__init__.py, line 221, in
zpublisher_exception_hook
(Object: Traversable)
  File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 171,
in publish
  File /usr/lib/python1.5/site-packages/ZPublisher/mapply.py, line 160,
in mapply
(Object: Register)
  File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 112,
in call_object
(Object: Register)
  File /usr/share/zope/lib/python/OFS/DTMLMethod.py, line 172, in
__call__
(Object: Register)
  File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_String.py,
line 528, in __call__
(Object: Register)
  File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_Util.py,
line 342, in eval
(Object: REQUEST.set('my_number', my_number + 1))
(Info: REQUEST)
  File string, line 0, in ?
TypeError: (see above)

--

What is wrong? How do I increment the value?

[]s
-- 
 +-+-+
 | César A. K. Grossmann   | Capacitação Solidária   |
 | [EMAIL PROTECTED]| http://www.uol.com.br/umminuto/ |
 | http://members.xoom.com/ckant/  | Clique e doe - é de graça   |
 +-+-+
   http://www.halcyon.com/sciclub/cgi-pvt/instr/instr.html
  A ética do iG: http://antispambr.abranetrj.org.br/not-20001023.html

One Bell System - it used to work before they installed the Dimension!

___
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] unicode,python20,SQL DB Adapters

2000-12-11 Thread Philipp Auersperg

Python 2.0 has unicode support and once Zope will officially run with it -

has anybody evaluated how several database adapters will be 
able to read and write unicode varchars ? (of course only if the DB supports unicode :)

DB's with my special interest are:

Oracle
MSS SQL Server

and the database adapters:
mxODBC
ZOracleDA
ZSybaseDA

thanks in advance

phil


___
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] Fw: [Zope] Incrementing a form field

2000-12-11 Thread Andy McKay

You could use FSCounter to do your counting:
http://www.zope.org/Members/andym/wiki/FSCounter.

There is a How-To on using unique_ids:
http://www.zope.org/Members/andym/FSCounter/unique_ids

In your code try explicilty using an int:

   dtml-call "REQUEST.set('my_number', _.int(my_number) + 1)"
--
  Andy McKay, Developer.
  ActiveState.

- Original Message -
From: "César A. K. Grossmann" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, December 11, 2000 10:44 AM
Subject: [Zope] Incrementing a form field


 Hi!

 I have a form that is used to insert some records to a database, and one
 of the fields is a sequence number. I want to increment this number when
 the form is used, unless is the first time it is loaded.

 The form (idea copied from the SmartForms HOWTO) have the name
 "Register", and is something like this:

 dtml-var standard_html_header

 dtml-if "REQUEST.REQUEST_METHOD=='POST'"
   Record inserted.
 /dtml-if

 dtml-if my_number
   dtml-call "REQUEST.set('my_number', my_number + 1)"
 dtml-else
   dtml-call "REQUEST.set('my_number', 1)"
 /dtml-if

 form action="Register" method="POST"
 A Field input name="my_field" value="some value"br
 A Number input name="my_number" value="dtml-var my_number"br
 input type="submit" value="OK"
 /form

 dtml-var standard_html_footer

 It work for the first load, but when I press the OK button, I get an
 error message:

 Error Type: TypeError
 Error Value: illegal argument type for built-in operation

 The traceback:

 !--
 Traceback (innermost last):
   File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 222,
 in publish_module
   File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 187,
 in publish
   File /usr/share/zope/lib/python/Zope/__init__.py, line 221, in
 zpublisher_exception_hook
 (Object: Traversable)
   File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 171,
 in publish
   File /usr/lib/python1.5/site-packages/ZPublisher/mapply.py, line 160,
 in mapply
 (Object: Register)
   File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line 112,
 in call_object
 (Object: Register)
   File /usr/share/zope/lib/python/OFS/DTMLMethod.py, line 172, in
 __call__
 (Object: Register)
   File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_String.py,
 line 528, in __call__
 (Object: Register)
   File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_Util.py,
 line 342, in eval
 (Object: REQUEST.set('my_number', my_number + 1))
 (Info: REQUEST)
   File string, line 0, in ?
 TypeError: (see above)

 --

 What is wrong? How do I increment the value?

 []s
 --
  +-+-+
  | César A. K. Grossmann   | Capacitação Solidária   |
  | [EMAIL PROTECTED]| http://www.uol.com.br/umminuto/ |
  | http://members.xoom.com/ckant/  | Clique e doe - é de graça   |
  +-+-+
http://www.halcyon.com/sciclub/cgi-pvt/instr/instr.html
   A ética do iG: http://antispambr.abranetrj.org.br/not-20001023.html

 One Bell System - it used to work before they installed the Dimension!

 ___
 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] LoginManager broken?

2000-12-11 Thread Mayers, Philip J

Does it even *work*? Even a little bit? Because other than repeating the
same process 12 damn times, so far I'm not convinced. Maybe I'll look in the
source code to see if there's actually anything in the files (other than a
HOWTO.txt, which is empty, which BTW is more annoying than there not being
one).

The "LoginManager with SQL database" on the Zope site seems to end up with
me having a folder I can't access through the management interface (unless
you count "management" as "this is the index_html" document) Wow, thanks!
Now I have to delete it and start all over again...

In all seriousness - there *must* be one person who has gotten an SQL-backed
LoginManger working with 2.2.4 - surely?

Thanks for all the great work (little bugs aside...) - Zope is a wonderful
product! Now if only it could serve XML as well as Cocoon...

Regards,
Phil

+--+
| Phil Mayers, Network Support |
| Centre for Computing Services|
| Imperial College |
+--+  

___
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] access log analyzer (analog, webalizer etc.)

2000-12-11 Thread sean . upton

You could use grep/sed, etc, and a some shell scripts (or perl or python
scripts).  Instead of sed and grep (and regexes, and inconsistent results,
and a lot of manual work), what perhaps a lot of folks need is unified,
aggregated logging that actually looks into Zope's architecture and uses
mod_perl for static stuff and CGIs served in Apache.

I've thought about this a bit, and it seems to me that many sites (at least
bigger ones) often use a combination of technologies (as well as multi-node
server farms) to serve up their site(s).  As such, if you are running stuff
served from Zope, Apache, CGI, other app servers, etc, you want a unified
logging platform.  Add to the complication HA/load-balanced/multi-server
farms, and you want to be able to aggregate logs from all boxes on all
server platforms to log to a unified system.

The answer seems to me to be use of a relational database, mod_perl, and the
example DBI Apache logger code in O'Reilly's _Writing Apache Modules_ with
the following tweaks:

1 - Add persistence to the mod_perl DB connection with Apache::DBI
2 - Tweak the tables to add the following fields:
box (server node number, for HA farms)
mime-type 
user
object_id (used, along with URL to determine what object is 
being used by X method)
3 - mime-types determined for Apache-served static pages with RegEx
on URL
4 - Zope-served pages are excluded from Apache's logging, use ZSQL
methods inside Zope to log (below)
5 - ZSQL method for logging is created.  Logs the relevant stats to
the relational database
AUTHENTICATED_USER is logged to user, and dmtl-var id is 
logged to object_id - mime-type is the object's mime-type
6 - Insert dtml-call expr="mylogmethod()" into standard_html_header
in top level (all acquired use of standard_html_header will log)
7 - Roll your own report-system using Zope, perhaps...

I've already started working on something of this sort for a long-term
project I have to implement logging for my company's new HA server farm.
Such an approach might also be a good thing if one is using a ZEO setup.  So
far, I have set up the Apache side of things, logging to MySQL, and I am
working on the Zope side of things.   The real work, though is not in
logging, but report generation, which would be a nice Zope product.  Perhaps
in a few months, I might have something worth showing...

Any thoughts?

Sean

=
Sean Upton
Senior Programmer/Analyst
Web Infrastructure
SignOnSanDiego.com
The San Diego Union-Tribune
619.718.5241
[EMAIL PROTECTED]
=
 

-Original Message-
From: Martin Winkler [mailto:[EMAIL PROTECTED]]
Sent: Sunday, December 10, 2000 5:26 PM
To: [EMAIL PROTECTED]
Subject: [Zope] access log analyzer (analog, webalizer etc.)


Hi listies,

since we all use names for urls that are not "standardized" - ending with 
".html", ".gif" etc -  I am wondering how to do a good logfile analyzing 
with standard tools like those in the subject line. I am usually running 
zope behind a http-accelerated squid, so I've configured squid to use 
"emulate_httpd_log on". But how webalizer doesn't recognize whether it's an 
image or html output.

Did someone already write a tool that converts these logfiles like this (or 
similar):

logfileconverter reads the logfile line by line -- checks against the ZODB 
whether the url outputs a "jpg", "gif" or "html" -- converts the line in 
the logfile accordingly (e.g. "/mydir/mymethod" to "/mydir/mymethod.html" 
and "mydir/mypic" to "mydir/mypic.jpg") -- then saves the modified logfile 
to disk or pipes it to webalizer.

Thanks for your input!

Martin


___
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] LoginManager broken?

2000-12-11 Thread Dan L. Pierson

You might look at http://www.zope.org/Members/dlpierson/sqlLogin for a
different approach that works for me in early testing.  Note that it
needs additional work before being turned loose on a live site.

Dan Pierson

"Mayers, Philip J" [EMAIL PROTECTED] writes:

 Does it even *work*? Even a little bit? Because other than repeating the
 same process 12 damn times, so far I'm not convinced. Maybe I'll look in the
 source code to see if there's actually anything in the files (other than a
 HOWTO.txt, which is empty, which BTW is more annoying than there not being
 one).
 
 The "LoginManager with SQL database" on the Zope site seems to end up with
 me having a folder I can't access through the management interface (unless
 you count "management" as "this is the index_html" document) Wow, thanks!
 Now I have to delete it and start all over again...
 
 In all seriousness - there *must* be one person who has gotten an SQL-backed
 LoginManger working with 2.2.4 - surely?
 
 Thanks for all the great work (little bugs aside...) - Zope is a wonderful
 product! Now if only it could serve XML as well as Cocoon...
 
 Regards,
 Phil
 
 +--+
 | Phil Mayers, Network Support |
 | Centre for Computing Services|
 | Imperial College |
 +--+  
 
 ___
 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] LoginManager broken?

2000-12-11 Thread Oliver Bleutgen

 Does it even *work*? Even a little bit? Because other than repeating the
 same process 12 damn times, so far I'm not convinced. Maybe I'll look in
 the
 source code to see if there's actually anything in the files (other than a
 HOWTO.txt, which is empty, which BTW is more annoying than there not being
 one).

 The "LoginManager with SQL database" on the Zope site seems to end up with
 me having a folder I can't access through the management interface (unless
 you count "management" as "this is the index_html" document) Wow, thanks!
 Now I have to delete it and start all over again...

 In all seriousness - there *must* be one person who has gotten an
 SQL-backed
 LoginManger working with 2.2.4 - surely?


Well, not 2.2.4 but 2.2.3, and I had some bugs when
trying it on a copy of a production server. I couldn't
get the "old" installation to work in a different directory,
although I thought I changed every path in start etc..
I also deleted all pyc files and reran wo_pcgi.py.
One symtom was that loginmanager didn't acquire users from
a level above. Later on it wouldn't want to to the sql-query,
nothing showed up in I postgres' debugging output.

Btw. can anybody tell me if and how it's possible to relocate
an installed Zope?

Back to your question, loginmanager now works fine for me now,
and it did so flawlessly on a fresh installed zope.

Did you eventually try to use the loginmanager-with-SQL-howto
in the toplevel folder? 
IIRC, this will lock you out permanently.
Did you reuse a user name (just a guess
that this might cause problems)?

Try to find out whether and which sql-queries are issued by
LoginManager, I guess other dbs than postgres will also allow
to find that out.
Oh, and if you try LM in a subfolder, have a look at the
undo tab if things go wrong ;-), you might at first use some
fake methods at first which always return 1, manager etc.
and change them step by step (and say goodbye to security).

cheers,
oliver






___
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] LoginManager broken?

2000-12-11 Thread Mayers, Philip J

Thanks, I'll take a look.

Re: LoginManager - After a fast turnaround (confirming my ample faith in
Open Source software) Magnus Heino pointed me in the right direction - the
dtml methods and SQL objects need to be inside the UserSource folder, *not*
the LoginManager folder as the Howto implies (or maybe I just can't
read...). Can someone confirm that the SQL methods need to be inside the
UserSource folder? (which is mildly annoying, but there we go...)

I'm still having some problems getting multiple roles working, but it's
behaving itself for now. Now all I have to do is solve my LIMIT problem...

Regards,
Phil

+--+
| Phil Mayers, Network Support |
| Centre for Computing Services|
| Imperial College |
+--+  

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 11 December 2000 20:18
To: Mayers, Philip J
Cc: '[EMAIL PROTECTED]'
Subject: Re: [Zope] LoginManager broken?


You might look at http://www.zope.org/Members/dlpierson/sqlLogin for a
different approach that works for me in early testing.  Note that it
needs additional work before being turned loose on a live site.

Dan Pierson

"Mayers, Philip J" [EMAIL PROTECTED] writes:

 Does it even *work*? Even a little bit? Because other than repeating the
 same process 12 damn times, so far I'm not convinced. Maybe I'll look in
the
 source code to see if there's actually anything in the files (other than a
 HOWTO.txt, which is empty, which BTW is more annoying than there not being
 one).
 
 The "LoginManager with SQL database" on the Zope site seems to end up with
 me having a folder I can't access through the management interface (unless
 you count "management" as "this is the index_html" document) Wow, thanks!
 Now I have to delete it and start all over again...
 
 In all seriousness - there *must* be one person who has gotten an
SQL-backed
 LoginManger working with 2.2.4 - surely?
 
 Thanks for all the great work (little bugs aside...) - Zope is a wonderful
 product! Now if only it could serve XML as well as Cocoon...
 
 Regards,
 Phil
 
 +--+
 | Phil Mayers, Network Support |
 | Centre for Computing Services|
 | Imperial College |
 +--+  
 
 ___
 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] LoginManager broken?

2000-12-11 Thread Oliver Bleutgen


 Well, not 2.2.4 but 2.2.3, and I had some bugs when
ehm replace 2.2.3 with 2.2.2

___
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] LoginManager broken?

2000-12-11 Thread Dan L. Pierson

"Mayers, Philip J" [EMAIL PROTECTED] writes:

 Thanks, I'll take a look.
 
 Re: LoginManager - After a fast turnaround (confirming my ample faith in
 Open Source software) Magnus Heino pointed me in the right direction - the
 dtml methods and SQL objects need to be inside the UserSource folder, *not*
 the LoginManager folder as the Howto implies (or maybe I just can't
 read...). Can someone confirm that the SQL methods need to be inside the
 UserSource folder? (which is mildly annoying, but there we go...)

This isn't required in my experience.  The UserSource will find them
via acquisition if the permissions are OK.  I tend to keep them in a
level above the acl_users (i.e. the LoginManager) in question while
debugging just in case I wind up turning off permissions to that
folder accidentally.


___
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] Freelance Programmers

2000-12-11 Thread Tim Cook

Brendon Grunewald wrote:
 
 Hi Zopistas,
 
 Can you point me in the right direction?
 

I got great response from comp.lang.python after also being
disappointed with the other jobs services.

HTH,
-- Tim Cook, President --
Free Practice Management,Inc. | http://FreePM.com
Office: (901) 884-4126
Censorship: The reaction of the ignorant to freedom.

___
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] Signed Zope Book Winners

2000-12-11 Thread Michel Pelletier


Last week we announced a content to win free, signed copies of the
book for finding errors in the book releated to calling a Script a
Method.  We have winners!  Thanks folks, there are real bugs my eyes
missed, and we've fixed them all.  As soon as the book hits our
local shelves, we'll get your signed copies in the mail.  Here are
the official winners!

  o "jimbo"

  o M. Adam Kendall

  o Jason Cunliffe

  o Lalo Martins

  o Jochen Knuth

  o Holger Hoffmann

  o "Bak@kedai"

  o Magnus Heino

We'll be contacting the winners by email.  If I sent you an email
saying you *did* win and you're not in this list, fwd: it back to me
and we'll get you a book, you may have slipped through the cracks
(my mail filtering isn't all that hot).  Please do *not* send it to
the zope list, cuz then my filters send it off to the big pile that I
don't read that often.

-Michel



___
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] ANNOUNCE: Zope 2.3.0 alpha 1 released...

2000-12-11 Thread Brian Lloyd

Hello all,

  As promised, Zope 2.3.0 alpha 1 is now available. You can 
  download it from Zope.org:

  http://www.zope.org/Products/Zope/2.3.0a1/

  This release contains a number of important new usability 
  features, and also marks the first release where a 
  substantial amount of the work done happened in the Fishbowl 
  on dev.zope.org. Some highlights of this release:

- Python Scripts are now part of the Zope core. Big whopping 
  kudos to Evan Simpson for all of the work he has put into 
  this! Having Python Scripts in the core will allow people 
  to much more easily separate logic and presentation (and 
  get that logic out of DTML!) More information and prototype 
  documentation for Python Scripts can be found in the 
  dev.zope.org project:

  http://dev.zope.org/Wikis/DevSite/Projects/PythonMethods


- The process of creating an initial user at install time 
  has finally been fixed. Before you had to create a superuser, 
  login as the superuser, create a normal manager, logout, then 
  log back in as the normal manager. This was obtuse and caused 
  big problems for newbies who would log in as the superuser and 
  start trying to work immediately (leading to errors since the 
  superuser cannot own objects). 

  This process is now much more sane. Now, at install time a 
  default initial manager (not a superuser) is created. The 
  superuser has been renamed to the "emergency user" and is 
  not even created by default. If you ever have a need to log 
  in as the emergency user, you can use zpasswd.py to create it.


- The new security assertion support has been checked in. For 
  more information and an updated version of the "Zope security 
  for developers" guide see the project on dev.zope.org:

  http://dev.zope.org/Wikis/DevSite/Projects/DeclarativeSecurity


- Added new getId() method to SimpleItem.Item. This should 
  now be used instead of referencing 'object.id' directly, 
  as it is guaranteed to always be a method and to always 
  return the right thing regardless of how the id of the 
  object is stored internally. This relieves DTML writers of
  the contortions they previously had to go through to handle 
  varying cases of 'id' being a method or an attribute.

- Improved Ownership controls. Now you simply choose whether
  or not to take ownership of sub-objects when taking
  ownership. Implementation details about whether ownership 
  is implicit or explicit are no longer forced on the user.

- Unit testing infrastructure for the Zope core. PyUnit has been 
  checked in, and a utility has been added that will allow us to 
  incrementally begin accumulating (and running) test suites. The 
  new testrunner.py in the utilities directory is a basic utility 
  for running PyUnit based unit tests. It can 
  be used to run all tests found in the Zope tree, all test suites
  in a given directory or in specific files. The testrunner will 
  be used to ensure that all checked in tests pass before releases 
  are made. For more information, see the docstring of the actual
  testrunner.py module.

  For more information on what is new in this release, see the 
  CHANGES.txt and HISTORY.txt files for the release:

   http://www.zope.org/Products/Zope/2.3.0a1/CHANGES.txt

   http://www.zope.org/Products/Zope/2.3.0a1/HISTORY.txt


  *Please note* that we do not build binary distributions for alpha 
  releases - the alpha is available as a source release only. When we 
  move into the beta period for 2.3, we will build and distribute 
  binary releases.



Brian Lloyd[EMAIL PROTECTED]
Software Engineer  540.371.6909  
Digital Creations  http://www.digicool.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] ANNOUNCE: Zope 2.3.0 alpha 1 released...

2000-12-11 Thread Spicklemire, Jerry

Outstanding! 

Sometimes I wonder if ther rest of the Open Source world 
has a glimmer of how FAST Zope is developing. let alone 
commercial vendors. 

Can't wait to dig in!

Congratulations to all,
Jerry S.

___
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] LocalFS question

2000-12-11 Thread Leichtman, David J


How do you access an individual object in a LocalFS? By that, I mean:

If I wanted the last_mod time of any Zope object, I could say dtml-var
"object.subobject.bobobase_modification_time".
However, if you try to do the same thing with a LocalFS object, i.e.
dtml-var "localfs_object.localfs_subobject.bobobase_modification_time",
you get the error NameError: localfs_subobject
This leads me to believe that LocalFS subobjects are not really objects. But
then how does the Zope management interface deal with them, and how can 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] LoginManager broken?

2000-12-11 Thread Michael Bernstein

"Mayers, Philip J" wrote:
 
 Thanks, I'll take a look.
 
 Re: LoginManager - After a fast turnaround (confirming my ample faith in
 Open Source software) Magnus Heino pointed me in the right direction - the
 dtml methods and SQL objects need to be inside the UserSource folder, *not*
 the LoginManager folder as the Howto implies (or maybe I just can't
 read...). Can someone confirm that the SQL methods need to be inside the
 UserSource folder? (which is mildly annoying, but there we go...)
 
 I'm still having some problems getting multiple roles working, but it's
 behaving itself for now. Now all I have to do is solve my LIMIT problem...

If you're having dificulties getting LoginManager to work
with the local roles management interface, maybe this
solution (which I only tested using LoginManger+Membership)
will help:

http://lists.zope.org/pipermail/zope-dev/2000-September/006953.html

I ahve no idea how this would work with SQL users, but
hopefully it'll give you a clue.

HTH,

Michael Bernstein.

___
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] SiteAccess, SSL + SiteRootBASE

2000-12-11 Thread jeremie

Hi everyone, 

 I am using Apache+Zserver+SSL (see How-to from TJ. Mannos), and it works 
 fine. The thing is that I have to set manually a SiteRoot Object in a 
 ssl Folder to make all this work and I would like to do it dynamically! 
 So, when I create my SiteRoot object and enter 
 "https://www.fightclub.com" as base, the page also displays a comment 
 saying: 
 "If Base is not set, the SiteRoot will first attempt to acquire 
 SiteRootBASE and then search the REQUEST for it. The same holds for Path 
 and SiteRootPATH." 

 So I was thinking that maybe I could set SiteRootBASE dynamically and 
 make it work the same. Unfortunately, I made some attempts and it does 
 not seem to work. 

 Does anybody have any idea of how to make it work? 

 Thanx, jeremie



___
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] apache and zserver interaction

2000-12-11 Thread [EMAIL PROTECTED]

hi all

during peak period/or simulated with ab -n200 -c 100 http://mysite/
i did this:

-8---
 telnet mysite 80
Trying mysite...
Connected to mysite.
Escape character is '^]'.  
GET / HTTP/1.1
host:mysite


... response
-8
what puzzled me is that the response time between typing in host:mysite \n\n 
and getting the response from the server is *very* high.
what may cause the latency?  is it between apache and zope, or zope itself?  
or does it depend on what the rest of mysite is doing?   i'm at a lost here.  
i want to speed up response time, but not sure which knobs to turn.  apache's 
or ZServer's.  i've increased the keepalive to 30s in apache.  will 
increasing the zserver thread number help?  i also changed zserver -i option 
to 60, but not that much different result.

thanks

-- 

http://www.kedai.com.my/kk 
http://www.kedai.com.my/eZine 

as you woke this morning, and open up your eyes, did you notice the tear 
stains lining your face were mine..


___
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] Problem on connect to MySQL

2000-12-11 Thread Angietel



When i type in the Connection String , it will 
prompt out the error message - "illegal operation" and in my python it will 
exactly like this:-

Files\WebSite\z2.py" 
-D--2000-12-12T03:15:10 PROBLEM(100) ZServer Computing default 
hostname--2000-12-12T03:15:11 INFO(0) ZServer Medusa (V1.16.4.2) 
started at Tue Dec 12 11:15:11 
2000 Hostname: 
ANGIE Port:8080

--2000-12-12T03:15:11 INFO(0) ZServer FTP 
server started at Tue Dec 12 11:15:11 
2000 
Authorizer:None Hostname: 
angie Port: 
8021--2000-12-12T03:15:11 INFO(0) ZServer PCGI Server started at Tue 
Dec 12 11:15:11 2000 Inet 
socket port: 8090--2000-12-12T03:15:11 INFO(0) ZServer Monitor 
Server (V1.8) started on port 8099

C:\Program Files\WebSite #// 
Thisis error msg 

and i would like to confirm to u whether the 
Connection String is write like this:-
customerDb[@localhost]Password 
pass52696


In mySQL i set up the user password like 
this:-
INSERT INTO user
VALUES('localhost','password',PASSWORD=Password('pass52696'),'Y','Y','Y',Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y');
and my Database name is CustomerDb

P/s let me know where is my mistake! Thank 
You!


Re: [Zope] Important Fix for Zope 2.0 through 2.1.6

2000-12-11 Thread Evan Simpson

From: "Hannu Krosing" [EMAIL PROTECTED]
 Could something similar be happening in PCGIServer too ?

 We are getting some weird and hard-to-reproduce errors when activity
 goes up and several file uploads are going on simultaneously?

I'm not sure.  I've peeked at the code, and the exact same bug doesn't seem
to be at work.

One way to tell is to create two File objects, open their Upload tab in
side-by-side browser windows, choose the same long file (1MB is good) in
both windows, then start the uploads together (as close as you can manage).

Next, change one of the windows into a Folder add form (any form will do,
really).  Now start the large file upload, then quickly submit the add form.

If there is a similar bug in PCGIServer, the first experiment will give you
a corrupted File (wrong size) and a weird log entry, and the second should
kill a thread with an "AttributeError:data" log entry.

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 )




RE: [Zope] Problem on connect to MySQL

2000-12-11 Thread Eric Walstad

Hello Angie,

Are you able to create a "Z MySQL Database Connection" inside Zope?
I'm not sure exactly when you are receiving your error message.  Is it when
you Click the "Change" button while in the "Z MySQL Database Connection?"

Your connection string looks like it is missing a user name.  It should look
something like (assuming your MySQL user name is "angie"):
customerDb@localhost angie pass52696
or in general terms
database@host user passwd

Generally when you see square brackets [ ] in documentation, the enclosed
code is optional.  In the case of the connection string, the host name is
optional.
However, in my setup, I have to include the host name or my connection to
the database will fail.

Hope that helps.

Eric.

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Angietel
Sent: Monday, December 11, 2000 7:37 PM
To: [EMAIL PROTECTED]
Subject: [Zope] Problem on connect to MySQL


When i type in the Connection String , it will prompt out the error
message - "illegal operation" and in my python it will exactly like this:-

Files\WebSite\z2.py" -D
--
2000-12-12T03:15:10 PROBLEM(100) ZServer Computing default hostname
--
2000-12-12T03:15:11 INFO(0) ZServer Medusa (V1.16.4.2) started at Tue Dec 12
11:
15:11 2000
Hostname: ANGIE
Port:8080

--
2000-12-12T03:15:11 INFO(0) ZServer FTP server started at Tue Dec 12
11:15:11 20
00
Authorizer:None
Hostname: angie
Port: 8021
--
2000-12-12T03:15:11 INFO(0) ZServer PCGI Server started at Tue Dec 12
11:15:11 2
000
Inet socket port: 8090
--
2000-12-12T03:15:11 INFO(0) ZServer Monitor Server (V1.8) started on port
8099

C:\Program Files\WebSite  #// This is error msg

and i would like to confirm to u whether the Connection String is write like
this:-
customerDb[@localhost]Password pass52696


In mySQL i set up the user password like this:-
INSERT INTO user
VALUES('localhost','password',PASSWORD=Password('pass52696'),'Y','Y','Y',Y',
'Y','Y','Y','Y','Y','Y','Y','Y','Y','Y');
and my Database name is CustomerDb

P/s let me know where is my mistake! Thank You!


___
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] How about a Zope 2.3a1, ZBook 2.3a1, and Python 2.3a1

2000-12-11 Thread jimbo

Just a thought.  About a month ago this would have sounded far fetched, but now that 
Guido is in the house, when might we expect the Zope Python version to change from 
1.5.2 to 2.x?  Imho for the book the Python version for Zope should at least be 2.xa1

 It seems to me that by the time the book is finalized your team could deliver a basic 
core Zope 2.x Python 2.x release.  My understanding is that its not that big of an 
issue.  I'm sure it would just make the marketing team giddy.
-Jimbo

___
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] append() and spaces

2000-12-11 Thread Sven Hohage

Hallo,
I've got a strange problem.
I use RESPONSE.redirect and pass values the usual way --
('car?bought=1amount=%s')%(Amount)
where Amount is a list-variable.
I build Amount dynamically with the append-method, and 
strangely I can't pass this variable(Error: Bad Request) because Python
puts 
spaces between the values -[1, 3, 4]
So, I have to extract the list and build a new string but this is very
uncomfortable!
Any hint?
Thanks!

___
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-dev] Meta-Types

2000-12-11 Thread Andre Schubert

Hi,

i have a question on using meta_types in my Product.
My Product contains some classes that are Folder, each Folder has
different meta_types.
One of these Folder(Folder4) can be added everywhere. These Folder
should contain only the meta_types of the Parent Folder in which he was
created.

Folder1(mt='a','b')
Folder4(mt='a','b')

Folder2(mt='a','c')
Folder4(mt='a','c')

Folder3(mt='e','f')
Folder4(mt='e','f')

Does anyone understand what i mean and can anyone help me?


___
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] confused about folder methods

2000-12-11 Thread Robin Becker

Why is it that I can use http:/F/objectIds, but not http:/F/objectItems?
F is a folder.

I have a ZClass derived from ZObject, ZFolder and find that I can use
objectIds, objectItems etc in dtml methods of the class.

Now with a class derived from ZObject, ZDTMLDocument, ZFolder I find
that I cannot. I can use other manage methods to add images, but I can't
call objectIds on the instances etc.

Is there a way to get at the base classes somehow?
-- 
Robin Becker

___
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] Announce: IRC client for zope (alpha)

2000-12-11 Thread Carlos Neves

Hello,

I have just uploaded to http://www.zope.org/Members/neli/zIRCon a development
version of my zope IRC console product. The reason I post it in this alpha
state is so that the shining minds around there might have an idea on how to
solve a tiny problem I'm having... I hang on to the socket connection waiting
for feedback from the server, so that things feel like real-time. But the 10
secs I wait before automagically refreshing and, therefor, releasing for
moments the socket just seem too much when I'm hangin on to ALL the channels
medusa makes available, rendering the zope install a bit too slow on the
'waiting for reply' state.
Anyway, it works with some limitations, wich are not documented (yet). But the
raw bases are all there and the code is (slightly) documented.

Hope you can find some time to have fun with it and *please* send me your
feedback on that socketing issue.

-- 
"Kill processes, not people."
- Larry Cohen

Carlos Neves
[EMAIL PROTECTED]

___
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] Pending bugs in collector - how do I send this patch?

2000-12-11 Thread Brad Clements

I have found a bug in ZSQL methods that is describe by this collector 
item:

http://classic.zope.org:8080/Collector/718/view

This item was posted over a year ago! The bug is still in the program, so 
I'm guessing that DC folks are too busy to get to this.

The collector item described above describes a weak work-around 
because the submitter didn't understand how this exception can occur.. 
Here's how it happens..

If a query is executed twice, the second time beyond the cache time 
limit. Then the query string is stored in tcache{} twice (two different 
times) but in cache{} only once.

Eventually the cache reaches it's maximum size and entries are expired 
in reverse time order. The earlier tcache{} entry is encountered and the 
query in cache{} is deleted.

Eventually the later query is also deleted from tcache{}, but the query no 
longer exists in cache{} and a KeyError is raised.

Here's the fix I'm applying. I'm only deleting the cache{} entry if it's time 
matches the tcache{} entry that is about to be deleted.

I couldn't figure out how to post a patch for a pending collector item. 
Also didn't want to duplicate the pending bug report either. 

--

lib/python/Shared/DC/DA.py line 392 or so

while keys and (len(keys)  max_cache or keys[-1]  t):
key=keys[-1]
q=tcache[key]
del tcache[key]
if int(cache[q][0]) == key:
del cache[q]
del keys[-1]


My change is:

if int(cache[q][0]) == key:
del cache[q]


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-dev] Gadfly and Zope 2.2.4

2000-12-11 Thread Michel Pelletier

On Sun, 10 Dec 2000, Josh Zeidner wrote:

 Hello,
 
   I tried to add a Gadfly Database connection to my Zope installation 
 without changing any of the parameters and got an error message saying: "The 
 parameter, connection, was omitted from the request." .  What, if anything, 
 am I doing wrong?

You're not selecting a data source.  This is one of the items in the list
box on the add form (the default setup comes with one data source called
'demo'.  To add your own data sources, see the Gadfly docs.

-Michel


  
 -josh zeidner
 Brooklyn Media Labs, LLC.
 
 _
 Get more from the Web.  FREE MSN Explorer download : http://explorer.msn.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 )
 
 


___
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] ANNOUNCE: Zope 2.3.0 alpha 1 Documentation Release

2000-12-11 Thread Michel Pelletier


On the heels of Brian's announcement, we are gurgling with joy to announce
a sychronized release of the Zope Book for the Zope 2.3 alpha release.

http://www.zope.org/Members/michel/ZB/

This release marks the first time the book and Zope are "in sync" enough
for you to be able to fully try out all the examples and understand all
the concepts.

This also marks the first time in long time that Zope has a (fairly)
complete, up-to-date manual!  Truely exciting times are these.  Remember
though, both the software *and* the manual are alpha, they both will have
bugs.  Please report any bugs, suggestions, or comments in the book to
[EMAIL PROTECTED]

Happy reading!

-Michel


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