[Zope] dtml-tree and REQUEST.form
Hi, I'm currently implementing a tree using... dtml-tree. In the document I use, I just have the tree and a table which desplays results according both to the tree state and some form data (passed through REQUEST.form). I.e. my URLs should look like the following : http://xxx.xxx/xxx/yyy/zzz/MyPage?MyVar=toto when I first open the page, and it SHOULD look like http://xxx.xxx/xxx/yyy/zzz/MyPage?MyVar=totoe-tree=tree-stuff. You guess - it doesn't look like this at all. This because the dtml-tree tag doesn't use the REQUEST.form dictionnary data to build its URLs. Instead, it just discards, in the URLs it builds, every single GET variable you wish to use. I'm currently patching the TreeTag.py file to support the REQUEST.form data, but I'd like to know if someone ever had this problem, and maybe corrected it - I hate patching. Also, if there is no other solution, I'd like to know if there are peolple intersted in this patch. Thanks, P.-J. ___ 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] SQLProperties - missing files?
Does anyone have SQLProperties working? The product on Zope.org seems to be missing the 'dbspecific' directory of SQL files. If anyone can send me a sample of what those files should look like I would appreciate it. This product seems like it would help in my quest to reduce the size of my "data.fs" database. Shouldn't it? Also is there any way to use the Zope Catalog with SQL data? It would be great to have full text searching on my SQL data. Thanks, -Ben ___ 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] get objects DTML Document having Property order...
Hello, I want to do : dtml-in "objectValues('DTML Document')" sort=order ... /dtml-in I have some DTML Documents which don't have the property "order", and I don't want to consider those documents in my loop. But if I put the "sort=order" option, Zope raises an error How can I do ??? Thanks a lot, Frederic ___ 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] Use of lambda expression in DTML
- Original Message - From: "Lalo Martins" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, May 29, 2000 11:40 PM Subject: Re: [Zope] Use of lambda expression in DTML On Mon, May 29, 2000 at 10:58:54PM -0400, Chris McDonough wrote: dtml-in "_.map (lambda item: Catalog.getobject (item.data_record_id_), Catalog (REQUEST)" How could someone understand this when you're finished with it? Perfectly clearly for anyone used to functional programming; I'd even say, clear on first sight. A lot easier to understand and maintain than a separate method. Assuming I'm reading this correctly, I think I'd probably express this as: dtml-in "Catalog(REQUEST)" dtml-with "Catalog.getobject(data_record_id_)" ...foo... /dtml-with /dtml-in BTW, I agree that exprs should be a part of DTML. You don't want to put significant program logic in DTML, but there are many places in which exprs are useful: Total: dtml-var "subtotal + shipping" I'll grant that you can set up all of the variables you need via a PythonMethod beforehand, but things like this can be nice and convenient... Any power that can be given to PythonMethods securely is a boon. Kevin ___ 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] get objects DTML Document having Property order...
"QUIN Frédéric" wrote: Hello, I want to do : dtml-in "objectValues('DTML Document')" sort=order ... /dtml-in I have some DTML Documents which don't have the property "order", and I don't want to consider those documents in my loop. But if I put the "sort=order" option, Zope raises an error How can I do ??? Here's a convoluted hack (untested). I wonder if anyone can come up with a better way. dtml-let values="objectValues('DTML Document')" filtered="[]" dtml-in values dtml-if order dtml-call "filtered.append(_['sequence-item'])" /dtml-if /dtml-in dtml-in filtered sort=order ... your code here ... /dtml-in /dtml-let ... but the version of Zope in the CVS repository already has a change that makes it so the sorting code will consider fields that don't exist to have the value "None". This makes it so you can sort the natural way. Shane ___ 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] Question about dtml-in sorting
Does sort only sort in one direction? I am looking to sort news items so that the newest items are on top, and when sorting on a date field, I get the opposite behaviour. Any easy way to reverse the sort order? Thanks pk ___ 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] ZClass Error
I've created a ZClass that was subclassed from a custom Python class. Everything is working well, thanks to the help of this mailing list, but I am having one problem that I am unable to figure out. If I add my subclass to the root of my Zope world, then I am unable to click on the Properties tab while managing it. However, if I create my ZClass anywhere else (ie not in the root), everything works fine. Here is the traceback that I receive. Any help would be appreciated, I am also using 2.2.0a1. Thanks. Traceback (innermost last): File /home/zope/lib/python/ZPublisher/Publish.py, line 224, in publish_module File /home/zope/lib/python/ZPublisher/Publish.py, line 189, in publish File /home/zope/lib/python/Zope/__init__.py, line 221, in zpublisher_exception_hook File /home/zope/lib/python/ZPublisher/Publish.py, line 175, in publish File /home/zope/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: manage) File /home/zope/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: manage) File /home/zope/lib/python/App/special_dtml.py, line 121, in __call__ (Object: manage) (Info: /home/zope/lib/python/OFS/properties.dtml) File /home/zope/lib/python/DocumentTemplate/DT_String.py, line 500, in __call__ (Object: manage) File /home/zope/lib/python/App/special_dtml.py, line 121, in __call__ (Object: manage_tabs) (Info: /home/zope/lib/python/App/manage_tabs.dtml) File /home/zope/lib/python/DocumentTemplate/DT_String.py, line 500, in __call__ (Object: manage_tabs) File /home/zope/lib/python/DocumentTemplate/DT_With.py, line 146, in render (Object: _(manage_options=filtered_manage_options())) File /home/zope/lib/python/DocumentTemplate/DT_With.py, line 133, in render (Object: _(option=manage_options[a_])) File /home/zope/lib/python/DocumentTemplate/DT_Util.py, line 333, in eval (Object: _(option=manage_options[a_])) (Info: manage_options) File string, line 0, in ? NameError: (see above) -- Peter Kazmier http://www.kazmier.com PGP Fingerprint 4FE7 8DA3 D0B5 9CAA 69DC 7243 1855 BC2E 4B43 5654 ___ 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] ZClass and python subclass __init__ method
According to the Zope Developer's Guide, when you create a ZClass by subclassing from custom python classes "your subclass's __init__ method will not be called when instances of the Z Class are created." Could someone help explain why my __init__ method is being called? Is the document just out of date? What should be the correct behavior? Also, is there a simple way of detecting from my python class's init method if it is being called within the Zope environment? I'm trying to keep my python class as non-Zope centric as possible because I use that class in other programs as well. Oh, I am using the 2.2.0a1. Thanks, Pete -- Peter Kazmier http://www.kazmier.com PGP Fingerprint 4FE7 8DA3 D0B5 9CAA 69DC 7243 1855 BC2E 4B43 5654 ___ 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] Question about dtml-in sorting
"Patrick J.M. Keane" wrote: Does sort only sort in one direction? I am looking to sort news items so that the newest items are on top, and when sorting on a date field, I get the opposite behaviour. Any easy way to reverse the sort order? Yes, by adding reverse to the sort tag ;-) dtml-in sortablelist sort=sorting_variable reverse Rik ___ 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] IRC Chat - tools[win32]
quote Jim Fulton and Paul Everett are going to be availiabe for a chat at Wednesday, May 31 at 1:00 PM EST on the #zope channel of irc.openprojects.net. /quote I have not used IRC before, but would love to join the chat session. I just just downloaded a trial version of 'mIRC' software for Win32 from http://www.mirc.co.uk which seems to work ok. For the benefit of any other IRC newbies like me on Win32, hre are some trivial how-to notes help 1. Under 'options' menu select category=connect and then click 'Add' 2. Description = anynameyouwant, server = irc.openprojects.net, port=6667[default, works ok], grouppassword = blank 3.This will return you to 'options' menu select category=connect. Enter your name and email etc..Then select new server named anynameyouwant from the pop-up menu, and click 'Connect to IRC Server' button 4. A window with scrolling list named "mIRC Channels Folder" should appear.For the first time type "#zope" in the field titled "Enter name of channel to join".. #zope will be added to the list. 5. Now select #zope from the scrolling list and click the 'Join' button Voila..! You should now be in the zope chat window - other users will be listed on right hand margin help irseeya - Jason Jason CUNLIFFE = NOMADICS.(Interactive Art and Technology).Design Director ___ 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] file upload
i want to make a section in my web page where a net surfer can come to my page and upload image files and store it in directory i created in my linux filesystem? I can't seem to figure out a way to do it in zope since it cannot access a directory in my filesystem ? Is there a way to do this ? 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 )
Re: [Zope] dtml-tree and REQUEST.form
I'd be interested when it's done. Phil [EMAIL PROTECTED] - Original Message - From: "Pierre-Julien Grizel" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: 30 May 2000 16:42 Subject: [Zope] dtml-tree and REQUEST.form Hi, I'm currently implementing a tree using... dtml-tree. In the document I use, I just have the tree and a table which desplays results according both to the tree state and some form data (passed through REQUEST.form). I.e. my URLs should look like the following : http://xxx.xxx/xxx/yyy/zzz/MyPage?MyVar=toto when I first open the page, and it SHOULD look like http://xxx.xxx/xxx/yyy/zzz/MyPage?MyVar=totoe-tree=tree-stuff. You guess - it doesn't look like this at all. This because the dtml-tree tag doesn't use the REQUEST.form dictionnary data to build its URLs. Instead, it just discards, in the URLs it builds, every single GET variable you wish to use. I'm currently patching the TreeTag.py file to support the REQUEST.form data, but I'd like to know if someone ever had this problem, and maybe corrected it - I hate patching. Also, if there is no other solution, I'd like to know if there are peolple intersted in this patch. Thanks, P.-J. ___ 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] file upload
i want to make a section in my web page where a net surfer can come to my page and upload image files and store it in directory i created in my linux filesystem? I can't seem to figure out a way to do it in zope since it cannot access a directory in my filesystem ? Is there a way to do this ? Yep, in fact I'm playing with this right this moment. You'll want the excellent LocalFS product from Jonothan Farr which is available from: http://www.zope.org/Members/jfarr/Products/LocalFS John -- John Chandler / Software Developer / New Information Paradigms Ltd [ Linux in the office, AmigaOS in the home, PalmOS in the pocket ] The opinions above aren't those of my company... ...but then, they aren't really mine either. ___ 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] Before I install zope
I'd say the easiest way is to give them different ports: give zope1 port 8080 and zope2 port 9080 If you've installed the Zopes as NT services you need to change the parameters to the services in regedit: goto hkey_local_machine/currentcontrolset/services/zope2 and change/add a parameter to change the default port base. The parameter you want is -P (upper case P) if you change/add it so that you have -P 9000 on the second instance then that user would connect on port 9080 for http and 9021 for ftp. Some of the instructions may not be exactly right but this should give you enough info to get you started, :) hth Phil [EMAIL PROTECTED] - Original Message - From: "J. Michael Mc Kay" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: 30 May 2000 16:40 Subject: [Zope] Before I install zope I want to install Zope in multiple instances. Apparently if you provide a unique name and user names you can do this. My question is, "How would you gain access to each individual Zope?" For instance, I would like "manager 1" to have access to "Zope 1" on port:8080. He will use Zope in tandem with his static web. I then want "manager 2" to have access to "Zope 2" in the same capacity as "manager 1." They will also use thier own separate product preferences. I want to set-up some fellow newbie types to share the Zope Road to Enlightenment with. What I don't understand from the install.txt and the "how to" is just how each manager is going to access the correct Zope. They each have a static webspace via a web server on port:80. I am not concerned right now about .pcgi, frontend and backend servers, but separating and accessing two standard installs of Zope on an NT server. I am a bit embarrased asking this because I did have this scenario working via pcgi. I got distracted for a couple of weeks and cannot reproduce it. So I want to do it again with straight installs, then .pcgi and later fool around with employing Site Access. Hope I've provided enough info...and that the answer is not too time consuming to return. Thanks, hisnibs Virginia Web http://www.virginiaweb.com [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 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] ZOracleDA woes - cannot connect
Please help!!! I am trying to connect to Oracle server. Running Zope 2.1.4, ZServer alone (for now), Debian frozen(potato). I have stable ZOracleDA 2.1.0. After a lot of work, I succeeded to compile the DCOracle package, and I am able to connect with the Python script DCOracle_test.py, which is included. I am only able to connect when I am a user 'oracle'. But when I try to connect from Zope, the connection never happens,and Zope returns "Document contained no data. Contact your network administrator". Sometimes, Zope dies. I am really desperate by now, as I try to make connection for three days now. I searched all FAQs on Zope site, nothing found. Any idea what I am doing wrong? Thanks, Michal Bukovjan ___ 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] Use of lambda expression in DTML
In brief: I get a NameError when invoking "filter(...)" from DTML. I thought this was a built-in python method, so I'm a bit puzzled. Python's ideas of 'built-in' is simply any method in the module stored in the global variable called __builtins__. Any code executed with a non-standard global variable space may or may not have the same set of builtins as normal Python code. Unfortunately Zope does not expose all of the 'builtin' python methods to DMTL expressions. Some obviously need to be cut out (such as 'open') for security reasons, but the reasons why others were dropped are less obvious. If you really need any of the missing builtins back in you have a couple of choices. Both require you have full access to your Zope system. If you want the function available throughout your Zope system simply edit DocumentTemplate\DT_Util.py. Look for the list beginning 'None', 'abs', 'chr' and simply add 'filter' into the list. Alternatively if you dont want to patch Zope directly, create an external python method that exposes filter. 5) In the dtml-tree tag, I change it to: dtml-tree Technical leaves=dtcTemplate branches_expr="filter( lambda f: not f.hasProperty('blockTreeBranching', false), objectValues(['Folder']) )" which, all things equal, should DoTheRightThang. Even if you make the filter function visible as described above, this still won't quite work. For example the method 'objectValues' is not in scope within the function. The way around this is to pass in an extra parameter _vars. Try (untested): branches_expr="filter( lambda f, _vars=_vars: not f.hasProperty('blockTreeBranching', 0), objectValues(['Folder']) )" and it might work. Alternatively use something like a PythonMethod, or even a DTML method and simply write the filter loop out in full using 'for' or 'dtml- in'. -- Duncan Booth [EMAIL PROTECTED] int month(char *p){return(124864/((p[0]+p[1]-p[2]0x1f)+1)%12)["\5\x8\3" "\6\7\xb\1\x9\xa\2\0\4"];} // Who said my code was obscure? http://dales.rmplc.co.uk/Duncan ___ 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] file upload
Take a look at this product sounds like what you need. http://yyy.zope.org/Members/jfarr/Products/LocalFS -Original Message- From: Oai Luong [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 30, 2000 8:40 AM To: [EMAIL PROTECTED] Subject: [Zope] file upload i want to make a section in my web page where a net surfer can come to my page and upload image files and store it in directory i created in my linux filesystem? I can't seem to figure out a way to do it in zope since it cannot access a directory in my filesystem ? Is there a way to do this ? 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 )
RE: [Zope] IRC Chat - tools[win32]
// I have not used IRC before, but would love to join the chat session. I've not used IRC either. Can I monitor the discussion using MS NetMeeting? ___ 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] Zope Email (syndication)
Yup, this sounds like mail-in content to me, which is what I'm after :-) If the goal is mail-in content, I'm not sure I understand IMAP to be anything approaching what you want: IMAP doesn't ACCEPT messages, at least not any of the IMAP servers I've seen, it serves messages up to clients (one of which could be Zope, like WorldPilot does). MailMan supports external archivers (how, I don't know, just saw it mentioned), and with the right archiver plugged in, that would give you the capability to archive email lists however you wanted. Also, I saw mention of someone using a script to archive msgs via WebDAV from mailman. The same sort of script could be used with any inbound MTA (postfix, qmail, sendmail, exim, etc...). Here's a URL to the post in Mailman-Developers: http://www.python.org/pipermail/mailman-developers/2000-February/001826.html I have written an archiver that uses WebDAV to archive messages [with or without decoded attachments] to a WebDAV enabled web server. I'm currently using Apache, but there is no reason why it shouldn't work "out of the box" with Zope (Zope has a WebDAV enabler). Email if you want patches/code... it works *very* well. We will be going into full production with it in the next week [www.bebusy.com]. A webdav-aware script, without mailman, could give you very simple mail-in access to Zope. With Mailman, a full alternative archiver. I'm just getting started with Zope, so I won't be coding this up, but hopefully this is enough for someone else to go on. Also: I'd like to voice some opposition to expending the effort to turn Zope into a full-blown SMTP MTA -- that's a lot of effort to down the "not-invented-here" path, complete with its' own security issues, etc, to be tackled. Building on other mail systems with proven scaleability (i.e. what happens when your Zope store is getting 100,000 message an hour?) makes more sense to me. Seems to me that tools to integrate Zope with existing mail tools would see the widest use. Thanks, Karl ___ 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 does it mean?
"The Zope Gadfly product is a free Zope adapter [...] so it should not be used to create large databases. What does large databases mean in this context? -Morten - How to reply to email: http://home.sol.no/~vidaandr/news/OBSquoting.html (norsk) http://home.sol.no/~vidaandr/news/FAQquoting.html (english) Who is the bigger fool? The fool or the fool who follows him? ___ 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] Use of lambda expression in DTML
Chris McDonough wrote Nope. Lamba, filter, reduce, and map should IMHO not be part of DTML. Actually, exprs probably shouldn't be in there in the first place. People are trying to use DTML as a way to process non-UI elements. This is a slippery slope, and leads to something like PHP or ASP. My opinion is this: Generate and format your HTML with DTML, and do everything else in Python. This gives you the added benefit that you can change the return values of functions by changing the Python code without having to muck with DTML, which is painful any way you look at it. Until PythonMethods are back in the distribution, you can't stop people from using DTML for this stuff - the only alternative is to give everyone who ever needs to do something more than simple HTML access to the file system. I can't see that happening on zope.org, or many other sites. I agree whole-heartedly that DTML's expr syntax is nightmarish and needs to be deprecated - but right now there's nothing to replace it with. As far as the issue at hand - whether lambda/map/reduce/filter should be allowed - the simplest way to enable them for PythonMethods also enables them for dtml-expr. Anthony -- Anthony Baxter [EMAIL PROTECTED] It's never too late to have a happy childhood. ___ 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 do I get field names from a query
how do I get the names of the fields returned from a SQL query ? ( I would like to generate stuff using the names automatically) I know they must be available because I can use them directly ! I've tried lots of alternatives of the form dtml-in "sqlListTable(table_name='personnel')" dtml-in sequence-item Pdtml-var sequence_item /dtml-in which give me the values but not the names, and looked through lots of the old msgs. Thanks in advance if anyone can help adam [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 previous and next items in list
I am using a dtml-in to walk through a catalog and display the results for a given query. When someone clicks on an item in a list, I would like to be able to pass the id of the item above it and below it. For example, Given this result set: Title Desc - -- Item 1 This is item 1. Item 2 This is item 2. Item 3 This is item 3. If the user click on Item 2, I want to pass the id of Item 1 and Item 3 to the next page. Does either dmtl-in or ZCatalog provide a variable that stores the id's for those (i.e. something like 'sequence-1' and 'sequence+1')? Thanks, 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] delete dictionary
hello, i've created some dictionaries in a dtml-document, for example like this: dtml-call "REQUEST.set('Monday',{'titel' : 'this is to do on monday'})" dtml-call "REQUEST.set('Tuesday',{'titel' : 'this is very bizarrr'})" dtml-call "REQUEST.set('Wednesday',{'titel' : 'how to do that?'})" ... and a bit later in the document i need to delete them again ... how can i do that? no one of my DELETE-experiments worked ... thnx.urs ___ 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] Q: Using WebDav to edit Zope DTML Methods. SOLVED!
Itamar Shtull-Trauring wrote: Graham Heyes wrote: Hello, I have been using Zope to set up a new web site for documentation and maintainance os a large software project. Until now I have been using a combination of LocalFS and ftp to edit content. Neither method is perfect especially since I often work from my laptop at home which is on the wrong side of the firewall and can't get ftp to work. Just the other day I discovered WebDav and life looks much better. I can tunnel my connection to port 8080 through ssh and manage my Zope site from home. One problem remains: When I use "get" or "edit" to get a DTML method (web page in my case) from the site I get a page with all the DTML tags expanded. This is clearly useless to me since I don't want to edit the rendered DTML but the original code. Am I doing something wrong (I hope so) if so what should I do? I am using Zope 1.whatever but also tried Zope2. I am running on RedHat Linux 6.1 with Apache web server but I point the WebDAV tools at http://localhost:8080/ "http://localhost:8080/" i.e. the ZServer. I have tried the "cadaver" command line tool and "DAVExplorer" java application with the same result. Thanks to the info from Martijn Pieters this turned out to be trivial. The unrendered source for a DTML method is reached by appending /document_src to the end of the URL. For example, http://localhost:8080/mystuff becomes http://localhost:8080/mystuff/document_src . In the context of DAVExplorer the solution is to modify the GET so that the /document_src is appended correctly. Not that this can't be done too early since the URL is used for other internal book keeping. I found that the folowing modification works In dav_explorer/classes/DAVExplorer/WebDAVManager.java make the following change at line number 119 ... try { Response = Con.Generic(MethodName, ResourceName, Body, Headers); WebDAVResponseEvent webdavResponse = GenerateWebDAVResponse(Response,tn); fireResponse(webdavResponse); } ... becomes ... try { if (MethodName.equals("GET")) { Response = Con.Generic(MethodName, ResourceName + "/document_src", Body, Headers); } else { Response = Con.Generic(MethodName, ResourceName, Body, Headers); } WebDAVResponseEvent webdavResponse = GenerateWebDAVResponse(Response,tn); fireResponse(webdavResponse); } ... note you don't need to change PUT since PUT does the right thing. I've tested this out quickly and it seems to do what I want. The sources to DAVExplorer can be found via a link at www.webdav.org to http://www.ics.uci.edu/~webdav/ enjoy! Graham --- Beware of Geeks bearing GIFS. http://www.jlab.org/coda Jefferson lab DAQ group ___ 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] ZServerSSL trouble
Hello all, I just installed ZServerSSL, and I'm having the following problem: I start Zope with the command, $ ./starts -w '' -f '' -W 8180 HTTPS=on and it appears to boot up without problems. However, when I try to access the default Zope page, Zope spits the following and dies: Traceback (innermost last): File "/home/ivan/src/Zope-2.1.6-src/z2s.py", line 681, in ? asyncore.loop() File "/home/ivan/src/Zope-2.1.6-src/ZServer/medusa/asyncore.py", line 107, in loop poll_fun (timeout) File "/home/ivan/src/Zope-2.1.6-src/ZServer/medusa/asyncore.py", line 55, in poll (r,w,e) = select.select (r,w,e, timeout) ValueError: filedescriptor out of range in select() This is my configuration: RedHat Linux 6.1 Python 1.5.2 (the RPM distribution in RH Linux 6.1) Zope 2.1.6 M2crypto 0.05-snap2 ZServerSSL 0.04 OpenSSL 0.9.5a Please help. Thanks, Ivan Raikov ___ 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] Question about dtml-in sorting
Patrick J.M. Keane writes: Does sort only sort in one direction? I am looking to sort news items so that the newest items are on top, and when sorting on a date field, I get the opposite behaviour. Any easy way to reverse the sort order? Thanks pk dtml-in MyItems sort=whatever reverse Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats. ___ 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] Q: Using WebDav to edit Zope DTML Methods. SOLVED!
On Tue, May 30, 2000 at 02:30:47PM -0400, Graham Heyes wrote: Thanks to the info from Martijn Pieters this turned out to be trivial. The unrendered source for a DTML method is reached by appending /document_src to the end of the URL. For example, http://localhost:8080/mystuff becomes http://localhost:8080/mystuff/document_src . In the context of DAVExplorer the solution is to modify the GET so that the /document_src is appended correctly. Not that this can't be done too early since the URL is used for other internal book keeping. I found that the folowing modification works [SNIP changes to a Java WebDAV client] Note that your changes only work for objects that support the document_src methods. It may be that now or in the future other objects require you to use a different method to retirve the unrendered source. I'd still be better if you could find out if there are WebDAV properties about the resource accessible in that piece of code, check for the source link, and if present, use that instead of the original URL. Such a change can then be used on other WebDAV servers prividing the source link as well, and can be included in the original client sources. -- Martijn Pieters | Software Engineermailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ | The Open Source Web Application Server - ___ 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] IRC clients
I haven't been to an IRC chat in over 5 years so this is pretty new to me. I also just built myself a new Linux machine for development and was not familiar with any Linux IRC clients. For those in a similar situation here is a little info on some Linux/*nix IRC clients. I think I'll try X-Chat as I use Gnome. We'll see. See y'all there tomorrow. By the way the links below came from Linuxberg.com aka Tucows. If you click on one it should take you to a page to direct you to the closest mirror. Hope this helps. Jimmie Houchin IRCII (console client, most popular, full featured) 5 penguins http://download.tucows.com/perl/linuxRegion.html?Target=/conhtml/preview/017-002-003-006C.html X-Chat (according to the Gnome site, "X-Chat: the canonical GNOME IRC client") Can be compiled with or without Gnome. 4 penguins Homepage for more info: http://xchat.linuxpower.org/ http://download.tucows.com/perl/linuxRegion.html?Target=/gnomehtml/preview/020-002-004-002C.html YagIRC (GTK client, similar to mIRC) 5 penguins http://download.tucows.com/perl/linuxRegion.html?Target=/x11html/preview/019-002-004-009C.html kIRC (KDE client, similar to mIRC) 4 penguins http://download.tucows.com/perl/linuxRegion.html?Target=/kdehtml/preview/021-002-004-002C.html ___ 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] Q: Using WebDav to edit Zope DTML Methods. SOLVED!
Martijn Pieters wrote: On Tue, May 30, 2000 at 02:30:47PM -0400, Graham Heyes wrote: Thanks to the info from Martijn Pieters this turned out to be trivial. The unrendered source for a DTML method is reached by appending /document_src to the end of the URL. For example, http://localhost:8080/mystuff becomes http://localhost:8080/mystuff/document_src . In the context of DAVExplorer the solution is to modify the GET so that the /document_src is appended correctly. Not that this can't be done too early since the URL is used for other internal book keeping. I found that the folowing modification works [SNIP changes to a Java WebDAV client] Note that your changes only work for objects that support the document_src methods. It may be that now or in the future other objects require you to use a different method to retirve the unrendered source. I'd still be better if you could find out if there are WebDAV properties about the resource accessible in that piece of code, check for the source link, and if present, use that instead of the original URL. Such a change can then be used on other WebDAV servers prividing the source link as well, and can be included in the original client sources. -- Martijn Pieters | Software Engineermailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ | The Open Source Web Application Server - Yes, what I did was to look at the RFC that you sent me then look at the WebDAV properties that DAVExplorer reads. The properties for the source list looks like... n:source n:link n:src /test_dtml /n:src n:dst /test_dtml/document_src /n:dst n:link /n:source ... the property tagged by dst is the link to the unrendered source. What I really need to do is extract this from the properties rather than simply appending /document_src onto the end of everything. As you point out (partially) document_src has no meaning in the context of some objects and also other WebDAV servers may use a different syntax than simply adding /document_src on the end of the URL. At least this works for Zope. For my next trick ;^) I am going to try to make it general, as you suggest and add a "Get Source" menu option so that the user has some choice over getting the rendered or unrendered source. Also, I am working on adding an "Edit" option which does a "get source" into a temp file then fires up the user's editor of choice and a thread to monitor the modification time of the temp file. Each time the file changes it gets put back into Zope. That way the user can use the "Save" command on the editor. (By the way I E-mailed the authors of DAVExplorer to get their input. waiting for a reply.) Anyway I'm having fun and getting somewhere at last!! Graham --- Beware of Geeks bearing GIFS. http://www.jlab.org/coda Jefferson lab DAQ group ___ 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] Question about dtml-in sorting
Patrick J.M. Keane wrote: I get the opposite behaviour. Any easy way to reverse the sort order? Well, I found there _is_ a reverse attribute to the dtml-in tag, but it's not documented in my version (2.1.0, 1999/12/17) of the DTML Reference. It works. Cheers, Nils ___ 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] Working with ZopeTime
The python expression syntax strikes again :( Tom Scheidt wrote: dtml-if "date1 == 'dtml-var ZopeTime fmt=Day'" You're trying to embed DTML within python here. you really want (untested): dtml-if "date1 == _DateTime.now().Day()" 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] delete dictionary
"urs.beyeler" wrote: dtml-call "REQUEST.set('Wednesday',{'titel' : 'how to do that?'})" ... and a bit later in the document i need to delete them again ... how can i do that? no one of my DELETE-experiments worked ... thnx.urs Try the following (untested): dtml-call "del REQUEST.misc['Wednesday']" I found this in the mailing list archives at: http://zope.nipltd.com/public/lists.html 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] Zope 2.0.1 export
Paul Gresham wrote: Hi, I have an old linux system running a document store I wrote some time ago in Zope 2.0.1. I've tried exporting my document store but cannot seem to get it re-imported into the latest version of Zope. I can ftp the documents out, but of course lose all the information about each document. Does anyone have any ideas on how to get this working ? Have you tried just replacing the data.fs of a new Zope insatll with the old one? Maybe give it a try with 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] Working with ZopeTime
Shane Hathaway wrote: Close but no brownies for you. :-) Make that... dtml-if "date1 == _.DateTime().Day()" Ack, a genuine typo... I'm going home to sulk ;( 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] ZDiscussions and Zope 2.2
What version are you using? J From: "Cary O'Brien" [EMAIL PROTECTED] Date: Tue, 30 May 2000 10:31:44 -0400 (EDT) To: [EMAIL PROTECTED] Subject: [Zope] ZDiscussions and Zope 2.2 I can't seem to add a ZDiscussions topic any more. I keep getting authorization failures. Managers are allowed to all zdiscussion topics on the security page, though. Is this related to the problem with ZSQL queries and the new permissions scheme with 2.2? -- cary ___ 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] file import
- Original Message - From: "Rick Pasotto" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, May 30, 2000 4:21 PM Subject: [Zope] file import Second (unrelated) question: When I create and then select a new version I get a screen that says the version is not active and to press the button to activate it. Pressing the button returns me to the same screen saying that no version is active. What have I missed in using versions? Not sure about your first question. As for this one, do you have cookies turned off in your browser? Zope uses a cookie to keep track of which version you're working in. Kevin ___ 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] product installation voodoo
- Original Message - From: "michael angelo ruberto" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, May 30, 2000 4:11 PM Subject: [Zope] product installation voodoo why do some products install fine on their own and others require voodoo incantations and sacrificial goats? Usually, products written completely in Python can be installed just by untarring the file. Products built through the web (ZClasses) usually comes as a .zexp file, which is essentially the pickled objects that make up the ZClasses, DTML Methods, etc. These need to be imported from the Products Control Panel. Is that the voodoo you're talking about? The difference is basically whether the product is just distributed as files that go in your file system, or as objects that need to live somewhere in your ZODB. can somebody tell me what the permissions for products should look like? I'm not sure that it really matters as long as your webserver process can read the files. Kevin ___ 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] file import
On Tue, May 30, 2000 at 04:44:53PM -0400, Kevin Dangoor wrote: - Original Message - From: "Rick Pasotto" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, May 30, 2000 4:21 PM Subject: [Zope] file import Second (unrelated) question: When I create and then select a new version I get a screen that says the version is not active and to press the button to activate it. Pressing the button returns me to the same screen saying that no version is active. What have I missed in using versions? Not sure about your first question. As for this one, do you have cookies turned off in your browser? Zope uses a cookie to keep track of which version you're working in. No, I don't have cookies turned off but I do have the browser set to ask about all cookies and no cookie requester was displayed. *However*, I do run junkbuster so all http requests go through a local proxy. Could that cause the problem? -- In the beginning, the universe was created. This has made a lot of people very angry, and is generally considered to have been a bad move." -- D. Adams Rick Pasotto email: [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] Python development team moves to BeOpen.com
This was on Slashdot earlier today. See original letter below Nitin Borwankar [EMAIL PROTECTED] http://www.pythonlabs.com/letter.html ___ 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] product installation voodoo
From: Kevin Dangoor [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 30, 2000 4:48 PM To: michael angelo ruberto; [EMAIL PROTECTED] Subject: Re: [Zope] product installation voodoo - Original Message - From: "michael angelo ruberto" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, May 30, 2000 4:11 PM Subject: [Zope] product installation voodoo why do some products install fine on their own and others require voodoo incantations and sacrificial goats? Usually, products written completely in Python can be installed just by untarring the file. Products built through the web (ZClasses) usually comes as a .zexp file, which is essentially the pickled objects that make up the ZClasses, DTML Methods, etc. These need to be imported from the Products Control Panel. Is that the voodoo you're talking about? The difference is basically whether the product is just distributed as files that go in your file system, or as objects that need to live somewhere in your ZODB. can somebody tell me what the permissions for products should look like? I'm not sure that it really matters as long as your webserver process can read the files. Kevin i've had situations where trying to import a .zexp does not work until the file's permissions are set to nobody:nobody ? ___ 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] SQL query results as dtml values ?
Maybe my question was too dense. I will try again. lets say I do this in a ZSQL method SELECT * FROM foo; of course I get a table of results. Now can I some how run another query base on the results, like to do an UPDATE and have the dtml-sqlvar type=blah use the values from the table ? Please, I just need a little help here. Thanks Richard ___ 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] Working with ZopeTime
Hi Tom, But not with: dtml-if "date1 == 'dtml-var ZopeTime fmt=Day'" (and yes, the day I'm doing it on is Tuesday). Usually, DTML-tags cannot be nested. Exceptions: tags in compound tags such as "if, in, let, with, ...". In your case, the "dtml-var" is simply not recognized and treated as a string rather than expanded. I assume (though I am not sure), that "ZopeTime" is a "DateTime" object. In this case, you could use: dtml-if "date1 == ZopeTime.Day()" 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] ZCatalog previous and next items in list
Hi Chris, I am using a dtml-in to walk through a catalog and display the results ... If the user click on Item 2, I want to pass the id of Item 1 and Item 3 to the next page. "dtml-in" iterates over a sequence. You can directly access elements of the sequence. This looks like: dtml-let S=sequence dtml-in S dtml-var "S[_['sequence-index']-1].data_record_id_" /dtml-in /dtml-let Of cause, you must handle boundary problems, maybe with dtml-try or dtml-if. 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] product installation voodoo
michael angelo ruberto wrote: can somebody tell me what the permissions for products should look like? To which Kevin actually wrote: I'm not sure that it really matters as long as your webserver process can read the files. Kevin To which Michael responded: i've had situations where trying to import a .zexp does not work until the file's permissions are set to nobody:nobody ? Of course. This was because your zope, running as nobody.nody, could not read the .zexp file, as read was apparently not enabled for everybody. Chowning it to nobody.nobody allowed the zope process to read 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 )
[Zope] Zope documentation
I may be a bit naive, but it seems to me that one should be able to build a tool (object inspector) which when queried will produce all the methods of a queried object, the property sheets, the variables of the property sheets, the applicable methods, and report back the ancestry of the product. The same report could then be run on the ancestors. This could serve as a documentation tool. -- Regards, Graham Chiu gchiuatcompkarori.co.nz http://www.compkarori.co.nz/index.php Powered by Interbase and Zope ___ 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] Use of lambda expression in DTML
On Tue, May 30, 2000 at 10:28:42PM +0200, you wrote: Minor note: "lambda" is not a builtin but part of the syntax (a keyword). I am sure, they will work in expressions. Uh. Of course that is correct. []s, |alo + -- Hack and Roll ( http://www.hackandroll.org ) News for, uh, whatever it is that we are. http://zope.gf.com.br/lalo mailto:[EMAIL PROTECTED] pgp key: http://zope.gf.com.br/lalo/pessoal/pgp Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar ___ 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] Zope documentation
Graham Chiu wrote: I may be a bit naive, but it seems to me that one should be able to build a tool (object inspector) which when queried will produce all the methods of a queried object, the property sheets, the variables of the property sheets, the applicable methods, and report back the ancestry of the product. The same report could then be run on the ancestors. This could serve as a documentation tool. I can tell you right now that yes it can be done and eventually someone will probably do it. I wish I had time to do it myself. It would be very, very useful. Shane ___ 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] Oh
Regarding my reverse sort question. I guess the answer is, just because it isn't documented, doesn't mean it isn't already there. :) I found it. pk ___ 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 Chat
Jim and Paul are going to be availiable for a chat about Zope, Perl Methods, and more. Please join us Wednesday, May 31, 1:00PM EST on irc.openprojects.net , on the #zope channel. If you have any technical questions about joining the chat, feel free to email me ( [EMAIL PROTECTED] ) and I'll help you out. Ethan Mindlace Fremen Zopista Community Liason ___ 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] TimeSheet product?
I could use one too. If someone doesn't have one maybe we can work one out. -Original Message- From: Jean Jordaan [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 30, 2000 7:25 AM To: [EMAIL PROTECTED] Subject: [Zope] TimeSheet product? Hi Zopers I'm looking for something to track the time I spend on different jobs. Has anyone written anything like this? I tried searching through the products, but found only issue trackers. My main criterion is simplicity of use .. I've never managed to use a timesheet continuously, if it's too much trouble to keep it up to date. -- [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 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] IRC Chat redux
Zopistas, I'm just posting some clarifications and follow-up. The chat with Jim Fulton and Paul Everitt will happen at 13:00 EST/08:00 GMT, tomorrow, Wednesday the 31st. It will be on irc.openprojects.net channel #zope. It's the standard IRC port- 6667 . For those of you that are new to IRC, first you need an IRC client. * Windows: Almost all the windows IRC'ers I know use mirc. [1] * Linux: You should have XChat [2] or another IRC client installed. * Mac: ircle [3] is well rated, but I've never used it. More information is availiable at http://www.irchelp.org . If you still have problems connecting, feel free to email me. ~ethan .. [1] http://www.mirc.com/install.html .. [2] http://xchat.linuxpower.org/ .. [3] http://www.ircle.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] IRC Chat redux
ethan mindlace fremen wrote: The chat with Jim Fulton and Paul Everitt will happen at 13:00 EST/08:00 GMT, tomorrow, Wednesday the 31st. Ouch. The sun rises in the east, not the west. 17:00 UTC or 18:00 if you have daylight savings. For a complete list of what time it will be in your city: http://www.timeanddate.com/worldclock/?year=2000mon=5day=31hour=17min=0sec=0 Thanks for your patience, ___ 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 does it mean?
"Morten W. Petersen" wrote: "The Zope Gadfly product is a free Zope adapter [...] so it should not be used to create large databases. What does large databases mean in this context? AFAIK, it means "bigger than ram" because Gadfly loads tables entirely into ram... someone correct me if i'm wrong, ~ethan ___ 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] Zope Chat
At 03:40 2000-05-30 -0600, ethan mindlace fremen wrote: Jim and Paul are going to be availiable for a chat about Zope, Perl Methods, and more. Please join us Wednesday, May 31, 1:00PM EST on irc.openprojects.net , on the #zope channel. Sorry for my ignorance, but what's that in UTC? Thanks. David Trudgett ___ 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 does it mean?
In article [EMAIL PROTECTED], Morten W. Petersen [EMAIL PROTECTED] writes "The Zope Gadfly product is a free Zope adapter [...] so it should not be used to create large databases. What does large databases mean in this context? -Morten I don't think it should be used at all except for testing purposes as the data is stored in ram. So, if your table is going to grow, you might run out of memory :-( -- Regards, Graham Chiu gchiuatcompkarori.co.nz http://www.compkarori.co.nz/index.php Powered by Interbase and Zope ___ 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] Oh
Hi ! Luis Cortes wrote: There is one other worth mentioning, that is ALL ZOPE TIPS which is a collection of useful examples ( unfortunately this is not part of the standard documentation ) you will have to go to the Zope site and download it from the documentation URL. You can find a link on the ZDP site: http://zdp.zope.org/ Look for Zope Tips in HTML All Zope.org Tips in one HTML File (60KB) Everything can be listed from this site in flat mode. (Only the Howtos are missing) Greetings, Maik Röder ___ 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 are the best general books on Object Oriented designprinciples?principles?
Chris, At the end of the article named "Gaining Zope Enlightenment By Grokking Object Orientation", (http://www.zope.org/Members/mcdonc/HowTos/gainenlightenment), you will find a reference to a book by Scott Ambler named "The Object Primer". This is a great starting point. Chris Beaumont wrote: The subject line says it.. What are the best general books on Object Oriented software and database design principles? I'm just starting out, and have no other programming experience to unlearn..(which I have heard is a GoodThing (tm) ) What would you suggest as a good place to start? Obviously one of my goals is that I'd like to be able to start to understand Zope better with this knowledge Basically what I want to say is. did any books just seem clearer and less jargon-ridden than the others..? Thanks.. 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] Testing the Waters ( Job Hunting )
Hi, Is there a short term position for me out there - anywhere? I have a masters in C.S., 5 years experience in C/C++ programming (and a little UML ). Recently I have taken the Zope training course, and used python and zope to do some projects at work, but now I am looking to see what else is out there with a bigger scope. If you hear of anything can you drop me a line and let me know. Thanks ahead of time, Luis. ___ 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] confera, zope 2.2, and attachments
With a confera discussion, I can't seem to add attachments. I can enter a file name into the file upload box, and there are no errors, but when I view the message there is no attachment. Am I doing something wrong? -- cary ___ 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 and Zope 2.2
I can't seem to add a ZDiscussions topic any more. I keep getting authorization failures. Managers are allowed to all zdiscussion topics on the security page, though. Is this related to the problem with ZSQL queries and the new permissions scheme with 2.2? -- cary ___ 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] Working with ZopeTime
Hi All, Im trying to display information based on what day of the week it tis using: dtml-if "date1 == 'dtml-var ZopeTime fmt=Day'" The date1 property on the page I'm calling is "Tuesday". It works when i do this: dtml-if "date1 == 'Tuesday'" But not with: dtml-if "date1 == 'dtml-var ZopeTime fmt=Day'" (and yes, the day I'm doing it on is Tuesday). Any ideas? Thanks. Tom Scheidt | www.falsemirror.com | [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] What are the best general books on Object Oriented designprinciples?principles?
The subject line says it.. What are the best general books on Object Oriented software and database design principles? I'm just starting out, and have no other programming experience to unlearn..(which I have heard is a GoodThing (tm) ) What would you suggest as a good place to start? Obviously one of my goals is that I'd like to be able to start to understand Zope better with this knowledge Basically what I want to say is. did any books just seem clearer and less jargon-ridden than the others..? Thanks.. 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] Use of lambda expression in DTML
Nick Drew wrote: |I can see that argument... it depends on the reader, I suppose. I |wouldn't complain much actually if the Python code had functional stuff |in it. It's having it in DTML that bugs me, for reasons that |have to do |with separating HTML-like stuff from the stuff that actually runs the |site under the hood. I take your point, but it's making an assumption that map, filter, and lambda are going to be used for business logic. In my case (see original topic) would you argue that what I'm trying to do is business logic or presentation? Many apologies, I caught the thread at the tail and didn't look back to see the origin of the topic. This is pretty stupid on my part. I would say that you were indeed trying to do presentation logic. And furthermore, I would say that my arguments were offbase and pretty much knee-jerk reactions to the possibility of what might happen if functional kw's and builtins were added to DTML. After considering it further, it doesn't seem to be such a bad idea if it didn't impact security in any way. It might even reduce the complexity of DTML looping, which would be a good thing. It would most certainly be welcome in Python methods, I'd definitely miss map a lot in Python methods if it wasnt there. If it's something you want badly (and if you haven't already) add it as a feature request to the Collector on Zope.org. Once other folks get past the knee-jerk reaction, maybe it'll sink in as a good thing. In the meantime, you can add it yourself if you like. Hopefully, you'll be so kind as to forgive me. After seeing people post DTML code to the list that they need debugged that computes pay rates, has the shape of an arrowhead and scrolls past the maximum character length of my email client horizontally, I'm a little leery of adding anything whatsoever to DTML, as I think the rest of the folks at DC are. Reducing the complexity of DTML is a good thing, however it can be accomplished. As for HTML-like stuff vs. business stuff wrt to functional expressions: Do you object to CSS, XSLT, and XPath? I can't object to XSLT and XPath, I don't even know enough about them to spell them right. :-) CSS is all about presentation, but AFAICT doesn't have an expression syntax, nor even a way to spell a loop. I think I can see why the ZoPerl discussion is so vociferous... ;¬] I'm not sure I see the connection... ___ 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] Zope Chat
On Wed, 31 May 2000, David Trudgett wrote: At 03:40 2000-05-30 -0600, ethan mindlace fremen wrote: Jim and Paul are going to be availiable for a chat about Zope, Perl Methods, and more. Please join us Wednesday, May 31, 1:00PM EST on irc.openprojects.net , on the #zope channel. Sorry for my ignorance, but what's that in UTC? I think it is American for GMT, so I think it comes out to 3am EST (thats Australian EST) and well past my bed time. -- Stuart Bishop Work: [EMAIL PROTECTED] Senior Systems Alchemist Play: [EMAIL PROTECTED] Computer Science, RMIT University ___ 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] Site Access Counter
hi all, allow me to start by saying that i am relatively new to zope... i have made a web site in zope, but would like to have an access counter on it too. our zope2.1.6 server is running on redhat6.1 with apache1.3.9. i have seen access counter scripts that require perl5, but i have heard that those won't work with zope. can someone please help me? Thank you all in advance! Shaun Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.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-dev] Zope 2.1.6 ZCatalog: minor bug, missing find import -- with patch
I just found a minor bug in Zope 2.1.6's ZCatalog (distribution). "ZCatalog.py" does not import "find". If the "containing" field contains a value, a NameError exception is raised. Patch appended. Dieter Thanks for the report - it looks like this was already fixed for 2.2. 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] Ending up with a wrapped object through the web?
When importing the .zexp, I get an "Attempt to store a wrapped persistent object" error. This is really puzzling, because I'm not sure how a completely through-the-web Product would have a wrapped object stored in it. I tried removing the PythonMethods to see if they were stored in an unusual way, and this did not change the behavior... It's not just you - I've been unable to get any imports to work in current-cvs. Anthony Hi guys - If you are using CVS, you need to do an update in ZODB to update the coptimizations.c file then rebuild the coptimizations module. That should fix the problem... 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] Ending up with a wrapped object through the web?
If you are using CVS, you need to do an update in ZODB to update the coptimizations.c file then rebuild the coptimizations module. That should fix the problem... That did the trick. One oddity, though: I had to reauthenticate as the superuser to do it. Shouldn't a Manager be able to import to Control_Panel/Products? Kevin ___ 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] Z SQL: optional isn't?
On Tue, 30 May 2000 17:09:20 +1000 (EST) you wrote: I like the optional attribute. I'd like to see it do more than sit idle in the code. You don't have to do the typechecking in the 'arguments' box if you don't want. eg. in your arguments section: course="" subject="" O.k., it appears that I can still use that with integers. I can live with that. I don't like setting an integer to what appears to be a string, but it does work. select * from enrolments dtml-sqlgroup where dtml-sqltest course type=int optional dtml-sqltest subject type=nb optional /dtml-sqlgroup The definition of the 'optional' tag from the docs might help here: '''A flag indicating if the test is optional. If the test is optional and no value is provided for a variable, or the value provided is an invalid empty string, then no text is inserted''' I should have been more specific. I was referring to the "optional" attribute of the *argument* (not the sqltest). I found that it's coded in Aqueduct.py, but I'm not aware of any way to set it from the Z SQL method form. Hmm... looking at this definition, it seems you have found a bug (but setting the default value to "" in the arguments section will provide a workaround). Or maybe 'no value provided' means 'is None'. Anyone from DC want to provide a ruling? :-) Originally, after reading the above ("optional" in sqltest) definition, I'd hoped to be able to simply list the variable in the arguments section and make it optional in the sqltest. After looking at the code, I determined that this was not a reasonable expectation. (What if I used two sqltests and it was only optional in one?) In the course of investigating this, however, I found that an optional attribute for an argument is recognized. It seems like this is what should be used. I can live with it either way, but I think that optional is better than integer_var="". I'd like to see whatever is chosen documented, and I'd like to see "optional" removed from Aqueduct.py if it's not going to be supported. (Maybe it's used by something else?) --kyler ___ 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] 'import' busted in current-cvs.
Ok dokey, I've done a rebuild, and now, when trying to import stuff as a user with 'Manager' privs, I get... You are not authorized to access RoleManager. Traceback (innermost last): File /opt/zope/zope-cvs/./lib/python/ZPublisher/Publish.py, line 224, in publish_module File /opt/zope/zope-cvs/./lib/python/ZPublisher/Publish.py, line 189, in publish File /opt/zope/zope-cvs/./lib/python/ZPublisher/Publish.py, line 175, in publish File /opt/zope/zope-cvs/Zope2/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: manage_importObject) File /opt/zope/zope-cvs/./lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: manage_importObject) File /opt/zope/zope-cvs/lib/python/OFS/ObjectManager.py, line 525, in manage_importObject (Object: RoleManager) File /opt/zope/zope-cvs/lib/python/OFS/CopySupport.py, line 371, in _verifyObjectPaste (Object: RoleManager) File /opt/zope/zope-cvs/./lib/python/AccessControl/SecurityManager.py, line 147, in validateValue File /opt/zope/zope-cvs/lib/python/AccessControl/ZopeSecurityPolicy.py, line 212, in validate Unauthorized: (see above) As an aside - should issues with current-cvs go into the Collector? Many times it seems stuff is fixed well before the Collector gets seen to. Anthony -- Anthony Baxter [EMAIL PROTECTED] It's never too late to have a happy childhood. ___ 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] Z SQL: optional isn't?
On Mon, 29 May 2000, Kyler B. Laird wrote: This is not the same functionality as is provided by the "optional" attribute. How would I use it with an integer, for example? I don't want a default value; I want the option of not having the value set at all. I like the optional attribute. I'd like to see it do more than sit idle in the code. You don't have to do the typechecking in the 'arguments' box if you don't want. eg. in your arguments section: course="" subject="" And your method: select * from enrolments dtml-sqlgroup where dtml-sqltest course type=int optional dtml-sqltest subject type=nb optional /dtml-sqlgroup The definition of the 'optional' tag from the docs might help here: '''A flag indicating if the test is optional. If the test is optional and no value is provided for a variable, or the value provided is an invalid empty string, then no text is inserted''' Hmm... looking at this definition, it seems you have found a bug (but setting the default value to "" in the arguments section will provide a workaround). Or maybe 'no value provided' means 'is None'. Anyone from DC want to provide a ruling? :-) -- Stuart Bishop Work: [EMAIL PROTECTED] Senior Systems Alchemist Play: [EMAIL PROTECTED] Computer Science, RMIT University ___ 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] CatalogAwareness for RackMountables
I've been playing around with ZPatterns, and I must say it's very cool - finally you can mix ZCatalog and SQL storage. CatalogAwareness is slightly different than regular Zope objects in that you have to find the ZCatalog in the Rack's acquisition path, but that's about it. The absolute_url function I define here should be moved to the RackMountable class since it may be useful in other situations. - from Products.ZCatalog.CatalogAwareness import CatalogAware from Products.ZPatterns.Rack import _v_rack, RackMountable class RMCatalogAwareMixIn(CatalogAware): """ CatalogAwareness for RackMountables. You need to inherit from this class before RackMountable. Objects are NOT automatically indexed, because no rack has been defined when we're in __init__. """ def absolute_url(self, relative=0): """ URL for catalog-awareness """ return "%s/%s" % (self._v_rack.absolute_url(relative), self.id) def index_object(self): """A common method to allow Findables to index themselves.""" if hasattr(self._v_rack, self.default_catalog): getattr(self._v_rack, self.default_catalog).catalog_object(self, self.url()) def unindex_object(self): """A common method to allow Findables to unindex themselves.""" if hasattr(self._v_rack, self.default_catalog): try: getattr(self._v_rack, self.default_catalog).uncatalog_object(self.url()) except: pass def manage_delete(self, _v_rack=_v_rack): """ Uncatalog this object and then delete it """ self.unindex_object() return RackMountable.manage_delete(self, _v_rack) ___ 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] CatalogAwareness for RackMountables
Sorry if this arrives twice, but mailing lists seem to have swallowed my earlier mail. I've been playing around with ZPatterns, and I must say it's very cool - finally you can mix ZCatalog and SQL storage. CatalogAwareness is slightly different than regular Zope objects in that you have to find the ZCatalog in the Rack's acquisition path, but that's about it. The absolute_url function I define here should be moved to the RackMountable class since it may be useful in other situations. - from Products.ZCatalog.CatalogAwareness import CatalogAware from Products.ZPatterns.Rack import _v_rack, RackMountable class RMCatalogAwareMixIn(CatalogAware): """ CatalogAwareness for RackMountables. You need to inherit from this class before RackMountable. Objects are NOT automatically indexed, because no rack has been defined when we're in __init__. """ def absolute_url(self, relative=0): """ URL for catalog-awareness """ return "%s/%s" % (self._v_rack.absolute_url(relative), self.id) def index_object(self): """A common method to allow Findables to index themselves.""" if hasattr(self._v_rack, self.default_catalog): getattr(self._v_rack, self.default_catalog).catalog_object(self, self.url()) def unindex_object(self): """A common method to allow Findables to unindex themselves.""" if hasattr(self._v_rack, self.default_catalog): try: getattr(self._v_rack, self.default_catalog).uncatalog_object(self.url()) except: pass def manage_delete(self, _v_rack=_v_rack): """ Uncatalog this object and then delete it """ self.unindex_object() return RackMountable.manage_delete(self, _v_rack) ___ 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] Ending up with a wrapped object through the web?
That did the trick. One oddity, though: I had to reauthenticate as the superuser to do it. Shouldn't a Manager be able to import to Control_Panel/Products? worse yet - you can't import _at_ _all_ outside the control panel. A manager can't access RoleManager. superuser can't own objects. Ok - this should be fixed now in CVS. Part of the machinery that checks whether the user is really allowed to create the type of object they are importing was failing spuriously because it expected the object it was checking to be wrapped (which isn't the case when checking an imported object to see if it can be added). Update AccessControl/User.py to get the fix. 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] Ending up with a wrapped object through the web?
"Kevin Dangoor" wrote If you are using CVS, you need to do an update in ZODB to update the coptimizations.c file then rebuild the coptimizations module. That should fix the problem... That did the trick. One oddity, though: I had to reauthenticate as the superuser to do it. Shouldn't a Manager be able to import to Control_Panel/Products? worse yet - you can't import _at_ _all_ outside the control panel. A manager can't access RoleManager. superuser can't own objects. *sigh* Anthony, still trying to get XMLWidgets installed... ___ 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] Memory 2.1.4-2.1.6 a.k.a. how to get objects out of the cache
Bill Anderson: Jason Spisak wrote: [...] That's funny that I am experienceing the same symptoms as you, but my installation is totally different. I'm not using GUF, or any DA's, and I'm running on RH 6.1. We really need to figure this out as a community. I am willing to try just about anything short of shipping my machine somewhere off premisis. ;) Ok, let's dig up some more info ( or perhaps I missed it ). Server setup, as in pcgi/Zserver/Apache w/proxypass, etc? Nothing but straight ZServer/Medusa. Compiled on the machine, or binary distribution? Zope 2.1.1 binary distro. Not sure how it got to be 2.1.4/2.1.6, might have been the other person having problems, or my mistake. But the changes in 2.1.4 and 2.1.6 aren't anything in the Object publisher or Medusa so I don't think it makes a difference. If source, did you start with a clean tree, or did use use the diff upgrade, or did you use a new 2.1.6 tarball, and drop it on top of the 2.1.4 install? Bill RH 6.1 2.2.12smp kernel Hardware RAID dual 350mhz Xenon 1 gig ram Vanilla Zope with no DA's, no Apache. BTW, Matthew gave me some advice last Friday to use the setcheckinterval line in z2.py and the performance gains are quite impressive. Anyone who is running smp should try it. All my best, Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats. ___ 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] Calling DTML methods from Python
Andrew Wilcox wrote: OK, I'll set up a DTML Quick Reference on the ZDP site right now! It's link is http://zdp.zope.org/portals/beginners/DQR We should be able to get this in place. Contributions sought! Do you want me to include my text? Where would it go? Yes. Hm, this is already rather specific. I'll paste it into a section (Topic) called Calling DTML. We may need to revise the topics afterwards, but that doesn't really matter now. Note that you can make your own topics (at least I think you can). Last night I couldn't finish it, but I thought the idea would be there as is. I'll try and work on it a bit today. thanks Rik ___ 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] Memory issue 2.1.1 request for info
Matthew T. Kromer: I'm extremely curious that the cache doesn't clear when you restart Zope. One would normally not expect to see this. Can you do a "ps xauww" and mail it to me / the list? USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND root 1 0.0 0.0 1104 72 ?SMay26 0:05 init [3] root 2 0.0 0.0 00 ?SW May26 0:03 [kflushd] root 3 0.0 0.0 00 ?SW May26 0:02 [kupdate] root 4 0.0 0.0 00 ?SW May26 0:00 [kpiod] root 5 0.0 0.0 00 ?SW May26 0:03 [kswapd] root 6 0.0 0.0 00 ?SW May26 0:00 [mdrecoveryd] root 9 0.0 0.0 00 ?SW May26 0:00 [scsi_eh_0] bin330 0.0 0.0 11960 ?SW May26 0:00 [portmap] root 359 0.0 0.0 1156 144 ?SMay26 0:00 syslogd -m 0 root 370 0.0 0.0 13960 ?SW May26 0:00 [klogd] daemon 386 0.0 0.0 1128 104 ?SMay26 0:00 /usr/sbin/atd root 402 0.0 0.0 1304 108 ?SMay26 0:00 crond root 418 0.0 0.0 11240 ?SW May26 0:00 [inetd] root 434 0.0 0.0 11760 ?SW May26 0:00 [lpd] root 457 0.0 0.0 22040 tty1 SW May26 0:00 [login] root 458 0.0 0.0 10760 tty2 SW May26 0:00 [mingetty] root 459 0.0 0.0 10760 tty3 SW May26 0:00 [mingetty] root 460 0.0 0.0 10760 tty4 SW May26 0:00 [mingetty] root 461 0.0 0.0 10760 tty5 SW May26 0:00 [mingetty] root 462 0.0 0.0 10760 tty6 SW May26 0:00 [mingetty] zope 465 0.0 0.0 17400 tty1 SW May26 0:00 [bash] root 498 0.0 0.0 2360 32 ?SMay26 0:00 [in.rlogind] root 499 0.0 0.0 22880 pts/0SW May26 0:00 [login] jason 500 0.0 0.0 1752 484 pts/0SMay26 0:00 -bash zope 1992 0.0 0.0 31880 tty1 SW May29 0:01 [python] zope 1996 0.0 22.2 220152 216340 tty1 SMay29 1:33 /Zope/bin/python /Zope/z2.py -t 10 -D zope 1998 0.0 22.2 220152 216340 tty1 SMay29 0:02 /Zope/bin/python /Zope/z2.py -t 10 -D zope 1999 0.0 22.2 220152 216340 tty1 SMay29 0:00 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2000 0.0 22.2 220152 216340 tty1 SMay29 0:00 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2001 1.4 22.2 220152 216340 tty1 SMay29 23:39 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2002 0.0 22.2 220152 216340 tty1 SMay29 0:13 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2003 0.0 22.2 220152 216340 tty1 SMay29 0:08 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2004 0.0 22.2 220152 216340 tty1 SMay29 0:00 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2005 0.0 22.2 220152 216340 tty1 SMay29 0:42 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2006 0.0 22.2 220152 216340 tty1 SMay29 0:00 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2007 0.0 22.2 220152 216340 tty1 SMay29 0:00 /Zope/bin/python /Zope/z2.py -t 10 -D zope 2008 1.1 22.2 220152 216340 tty1 SMay29 17:55 /Zope/bin/python /Zope/z2.py -t 10 -D root 2474 0.0 0.0 23600 ?SW 09:35 0:00 [in.rlogind] root 2475 0.0 0.0 22920 pts/1SW 09:35 0:00 [login] jason 2476 0.0 0.0 17480 pts/1SW 09:35 0:00 [bash] jason 2610 0.0 0.0 2508 864 pts/0R11:41 0:00 ps xauww The memory values are significantly smaller % for the threads than they were orignially. Shane had me set the "Target Time Between Accesses" to 3 seconds. I have futzed with it and now have it at 30 seconds. Also, the "target Size" was at 20,000 objects and now I have it at 10,000. Also a "free" would be helpful too. total used free sharedbuffers cached Mem:971452 966896 4556 2448 627104 92608 -/+ buffers/cache: 247184 724268 Swap: 128480 6732 121748 Under linux, shared memory is amongst the last to be scavenged in low memory conditions. I'm curious to see if something is allocating that memory as shared or what. You might also try an "ipcs -a" command to make sure it's not SYSV type shared memory (which can stick around even after a process exits.) -- Shared Memory Segments key shmid owner perms bytes nattchstatus -- Semaphore Arrays key semid owner perms nsems status -- Message Queues key msqid owner perms used-bytes messages Things are moving pretty speedilly since I adjusted the setcheckinterval. Thanks Matt!! I'll send the output of these commands after a Zope exit at the end of our intranet business here today. Just think, with ZEO I won't have
[Zope-dev] New Help System in 2.2
Michel, I was just browsing the help system and can I just say it is terrfic. The .py files especially. Not that python isn't that easy to read, but having the ZQR type stuff handy online is a huge win. Is that stuff updated fro mthe source on the fly? Greatfully, Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats. ___ 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] Cataloging LocalFS content
I think, cataloging "LocalFS" content would be nice. I have the following problems with it: 1. "LocalFS" defines various meta types: "Local File System", "Local Directory" and "Local File". Only "Local File System" is a "true" meta type which should appear in the available objects list of ObjectManager's. However, I may well be useful, to select the others, too, in for "find" and cataloging. This could be done, but my concern is that when changes are made to the file system this will cause the catalog to be out of synch until you re-index. How does this work with Zope objects? If you move or delete a Zope object that is cataloged does it automatically update the catalog? 2. ZCatalog uses "bobo_modification_time" in its meta table and for indexing. For "LocalFS" content, this is not the best modification time to use for indexing. It would be nice, if "bobo_modification_time" could somehow be synchronized with the object's modification time in the file system. With the most recent version of LocalFS, the bobobase_modification_time should be the same as the object's mtime in the file system. Please let me know the details if you're seeing anything different. --jfarr ___ 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] New Help System in 2.2
Shane Hathaway wrote: 1) Enahnce the permissions system to include "Accessible via HTTP", "Accessible via FTP", etc. Add to that 'execute in DTML method' ( + python methods perl methods;-) and you've got what I've been asking for for so long I've atoped trying :( This would prevent the nasty ability to do things like: http://www.zope.org/standard_html_footer This should not be accessible through HTTP, but should be through FTP and DTML... 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] Cataloging LocalFS content
I think, cataloging "LocalFS" content would be nice. I have the following problems with it: 1. "LocalFS" defines various meta types: "Local File System", "Local Directory" and "Local File". Only "Local File System" is a "true" meta type which should appear in the available objects list of ObjectManager's. However, I may well be useful, to select the others, too, in for "find" and cataloging. This could be done, but my concern is that when changes are made to the file system this will cause the catalog to be out of synch until you re-index. How does this work with Zope objects? If you move or delete a Zope object that is cataloged does it automatically update the catalog? Only if it is 'Catalog Aware', otherwise you'll have to update it manually. In the case of LocalFS this will always be the only way. Rik ___ 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] New Help System in 2.2
Shane Hathaway writes: Jason Spisak wrote: I was just browsing the help system and can I just say it is terrfic. The .py files especially. Not that python isn't that easy to read, but having the ZQR type stuff handy online is a huge win. Is that stuff updated from the source on the fly? Almost. It's actually written in separate files that mirror the structure of the real source. And I'd like to bring up the point that I wonder why it is written that way. Wouldn't it make more sense to self-document the source? If the issue is that some methods shouldn't be callable from a URL, there are better solutions to that problem (this is written to DC mainly): Is this the reason that it's not pulling the docs from the source? That's not a good idea. With all the effort that Michel put in to work around not documenting in the source, he could have fixed it so that it pulled the docs from the source on the fly without effecting the URL access. 1) Enahnce the permissions system to include "Accessible via HTTP", "Accessible via FTP", etc. 2) Use an underscore as the first character of a docstring to indicate a non-URL-callable method. I just looked at it and that seems like doing work twice. Why not just document your source? Wonderingly, Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats. ___ 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] CatalogAwareness for RackMountables
At 12:53 PM 5/30/00 +0300, Itamar Shtull-Trauring wrote: I've been playing around with ZPatterns, and I must say it's very cool - finally you can mix ZCatalog and SQL storage. CatalogAwareness is slightly different than regular Zope objects in that you have to find the ZCatalog in the Rack's acquisition path, but that's about it. IMHO, you don't need to keep referring to self._v_rack to do the cataloging as described, so long as you retrieve your objects from a Specialist; then the acquisition path is via the Specialist. I would suggest that you modify your patches somewhat to reflect this, and use only self.* attributes, not self._v_rack.*. It will improve your forward-compatibility with 0.4.0. The absolute_url function I define here should be moved to the RackMountable class since it may be useful in other situations. I have to disagree with this, since the standard Zope absolute_url method will work correctly, so long as you access a RackMountable by traversing (via bobo_traverse) from a Specialist. If you would like to make your work easier with version 0.3.0, it would be best for you to move the __of__ wrapping from Specialist.__bobo_traverse__() to Specialist.getItem(), as I have done in the working copy of 0.4.0. This will ensure that whenever you retrieve a rackmountable from a Specialist, it will be wrapped in context of the Specialist. Then, by deriving your classes from RackMountable and CatalogAware, you need only adjust for the absence of add and delete hooks. And you'll only need to adjust for that until 0.4.0 makes add/change/delete hooks available for indexing agents. I don't know if there will be a Catalog IndexAgent released with 0.4.0 yet, but there should be one eventually (or perhaps someone will contribute one). ___ 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] New Help System in 2.2
At 09:09 PM 5/30/00 +, Jason Spisak wrote: Shane Hathaway writes: Jason Spisak wrote: I was just browsing the help system and can I just say it is terrfic. The .py files especially. Not that python isn't that easy to read, but having the ZQR type stuff handy online is a huge win. Is that stuff updated from the source on the fly? Almost. It's actually written in separate files that mirror the structure of the real source. And I'd like to bring up the point that I wonder why it is written that way. Wouldn't it make more sense to self-document the source? If the issue is that some methods shouldn't be callable from a URL, there are better solutions to that problem (this is written to DC mainly): Is this the reason that it's not pulling the docs from the source? That's not a good idea. With all the effort that Michel put in to work around not documenting in the source, he could have fixed it so that it pulled the docs from the source on the fly without effecting the URL access. 1) Enahnce the permissions system to include "Accessible via HTTP", "Accessible via FTP", etc. 2) Use an underscore as the first character of a docstring to indicate a non-URL-callable method. I just looked at it and that seems like doing work twice. Why not just document your source? I just talked to Amos and Michel last Friday about that and they researched for a long time, whether it would be better to document the source or to have different files. They both decided it is the best to have the documentation separately. I believe that they looked at the issue from all angles and had good reasons, why they went with the current way. Furthermore, the help system will become even more than just the screen help. The .py files you see, are just the start of the new API documentation. Furthermore, we will include a new DTML reference soon. Do you know about anything else, that should be included? Regards, Stephan -- Stephan Richter CBU - Physics and Chemistry Web2k - Web Design/Development Technical Project Management ___ 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] ZDOM alpha release 2
See release notes for changes (installation process simplified w/ release of 4DOM/4XSLT/4XPATH): -- Chimezie Thomas-Ogbuji Consultant Fourthought Inc. (303) 583 9900 ext 104 [EMAIL PROTECTED] ZDOM is the result of a collaborative venture by Digital Creations and Fourthought Inc. to integrate the W3C Document Object Model interface with Zope, allowing effortless and familiar traversal of a Zope heirarchy. The current alpha release is based on Fourthought's 4DOM , which is one component of Fourthought's 4Suite. Fourthought provides custom technological solutions based on open technologies. 4Suite is a powerful set of Python tools developed by Fourthought for Web-based applications in areas such as Intranets, E-Commerce and knowledge-management. Elements of 4Suite have been adopted as core XML technologies in Zope and in the Python XML distribution The necessary files (which are all available on our ftp server: ftp.fourthought.com) are ftp://ftp.fourthought.com/pub/mirrors/python4linux/redhat/i386/python-xml-nodom-0.5.4-1.i386.rpm (Py-XML w/out DOM) ftp://ftp.fourthought.com/pub/mirrors/python4linux/redhat/i386/4DOM-0.10.0-1.noarch.rpm (4DOM core) ftp://ftp.fourthought.com/pub/4Zope/ZDOM-dist.tgz (ZDOM) ftp://ftp.fourthought.com/pub/4Zope/Zope-ZDOM-Patch (patch file for Zope 2.1.6) OR http://www.zope.org/Members/anthony/patches/4ZDOM-vs-CVS-0512.patch (patch file for CVS/alpha 2.2 Zope) Documentation: ftp://ftp.fourthought.com/pub/4Zope/INSTALL.txt (the installation instructions) ftp://ftp.fourthought.com/pub/4Zope/Readme.txt (short description of ZDOM) ftp://ftp.fourthought.com/pub/4Zope/Release.txt (release notes) links: Fourthought: http://fourthought.com 4Suite: http://fourthought.com/4Suite/ DOM 2 Spec: http://www.w3.org/TR/2000/CR-DOM-Level-2-2307/ Zope http://www.zope.org contact: [EMAIL PROTECTED] Installing ZDOM --- This document describes installing ZDOM on Unix. Important Notes ZDOM REQUIRES ZOPE AND PYTHON 1.5.2! Depending on which Zope version you wish to add ZDOM to, there are two patches to download 1) ftp://fourthought.com/pub/4Zope/Zope-ZDOM-Patch (patches Zope 2.1.6) 2) http://www.zope.org/Members/anthony/patches/4ZDOM-vs-CVS-0512.patch (Anthony Baxter's patch which works on the CVS source tree as of 5/16) ftp://ftp.fourthought.com/pub/mirrors/python4linux/redhat/i386/4DOM-0.10.0-1.noarch.rpm (4DOM core) ftp://ftp.fourthought.com/pub/4Zope/ZDOM-dist.tgz (ZDOM) ftp://ftp.fourthought.com/pub/4Zope/Zope-ZDOM-Patch (patch file for Zope 2.1.6) OR http://www.zope.org/Members/anthony/patches/4ZDOM-vs-CVS-0512.patch (patch file for CVS/alpha 2.2 Zope) Installing First download these files from our FTP server: /pub/mirrors/python4linux/redhat/i386/python-xml-nodom-0.5.4-1.i386.rpm /pub/mirrors/python4linux/redhat/i386/4DOM-0.10.0-1.noarch.rpm /pub/4Zope/ZDOM-dist.tgz /pub/4Zope/Zope-ZDOM-Patch OR http://www.zope.org/Members/anthony/patches/4ZDOM-vs-CVS-0512.patch Install the rpms and decompress ZDOM-dist.tgz somewherer in your PYTHONPATH Install and build Zope 2.1.6 if not already done. This is required for the components to work. The following will install the patches to Zope objects to allow manipulation of Zope object via the DOM interface: (the Zope2.1.6 patch assumes that the Zope src files reside in a 'Zope' directory so a symbolic link is necessary) ln -s [Zope install dir] Zope cd (parent directory of Zope install dir) -- if necessary patch -p0 (location of dowloaded files)/Zope-ZDOM-Patch OR 4ZDOM-vs-CVS-0512.patch Then add '(zope install dir)/lib/python' to your PYTHONPATH. RELEASE NOTES - 5/30/00 changed setAttributeNodeNS to check for aq_base and set to None if it doesn't exist (since _setProperty expects aquisition to be set up -- but might not be necessarily so since an element can be created and attributes can be added WITHOUT it having a parent yet) redirected computed attributes to instance methods so DOM interfaces can be overode added check for aq_base in setAttributeNodeNS (sets to None if it doesnt exist) 5/10/00 ZDOM alpha supports to complete DOM Level 2 Specification (http://www.w3.org/TR/DOM-Level-2/) ZDOM maps the DOM interface to Zope, like so: childNodes - objectValues() mappable subset of DOM 2 Interface - attributes - propdict() parentNode - self.aq_parent Default implmentation of both objectValues() and propdict() are provided on SImpleItem.Item for Zope Objects that do not implement these interfaces. All Zope objects support the DOM Level 2 spec through the inheritence of SimpleItem.Item from Element. All objects (except as noted below) created by the use of the DOM interface (i.e., NodeLists, NamedNodeMaps, childNodes for Attr) are transient. All Zope
[Zope-dev] XMLDocument beta release 3
See release notes for changes (installation process simplified w/ release of 4DOM/4XSLT/4XPATH): -- Chimezie Thomas-Ogbuji Consultant Fourthought Inc. (303) 583 9900 ext 104 [EMAIL PROTECTED] XMLDocument beta is a collection of Zope products and python tools that integrate XML into Zope, above and beyond the current XMLDocument product. Like ZDOM, it is the result of a collaborative venture by Digital Creations and Fourthought Inc. XmlDocument This is a Zope product that wraps XML content for use in Zope. In many ways it behaves similarly to the original XMLDocument, except it only creates a single Zope object upon import or creation. XMLImporter This python module allows users to externally import XML content into the Zope database in a 'controlled' manner. The user has full range of control over import parameters. XSLT Method This is a Zope product that wraps an XSLT stylesheet for use in Zope. Like a DTML method, it can be invoked on a ClobXmlDocument instance and return the resulting XSLT transformation. Fourthought provides custom technological solutions based on open technologies. 4Suite is a powerful set of Python tools developed by Fourthought for Web-based applications in areas such as Intranets, E-Commerce and knowledge-management. Elements of 4Suite have been adopted as core XML technologies in Zope and in the Python XML distribution links: Fourthought: http://fourthought.com 4Suite: http://fourthought.com/4Suite/ DOM 2 Spec: http://www.w3.org/TR/2000/CR-DOM-Level-2-2307/ Zope http://www.zope.org contact: [EMAIL PROTECTED] Installing XMLDocument beta --- This document describes installing XMLDocument beta on Unix. Important Notes XMLDocument requires 4DOM which is covered by the ZDOM installation. Simply installing ZDOM should resolve this dependency XMLDocument also requires 4XPath and 4XSLT You can download the rpms from here: ftp://ftp.fourthought.com/pub/mirrors/python4linux/redhat/i386/4XPath-0.9.0-1.i386.rpm ftp://ftp.fourthought.com/pub/mirrors/python4linux/redhat/i386/4XSLT-0.9.0-1.i386.rpm Installing Download these files from our FTP server (ftp.fourthought.com): /pub/4Zope/XMLDocument/XMLDocument-beta.tgz /pub/4Zope/XMLDocument/XMLImporter-beta.tgz Installing XMLDocument and XSLTMethod: decompress XMLDocument-beta.tgz to your Zope directory Installing Demonstration: Import the testfolder.zexp file in $Zopeinstalldir$/Extensions. Point your browser to where you imported testfolder in the zope heirarchy and follow the directions. NOTE: The demonstration cyclicaly creates and destroys a ZDOM heirarchy in testfolder/, so if you stop it at mid point it may break if you try to restart it (if it's broken run the reset DTML Method: which simply removes folder1, folder2, and ZDOMtester) Installing XMLImporter: decompress XMLImporter-beta.tgz to an arbitrary directory. make sure (Zope install directory)/lib/python is in your PYTHONPATH * read the python files in test_suite for examples on how to use XMLImporter Assuming you've satisfied the dependencies, you should be done! questions? email: [EMAIL PROTECTED] RELEASE NOTES 5/30/2000 1) Solved __call__ problem, XSLTMethods can be invoked programatically 2) Added a default view for XMLDocuments that can return the XML as: syntax highlighted HTML raw XML plain text this can be specified by the output property 3) fixed the copy paste bug 4) added demonstration/example to package 5/16/2000 Moved ClobXMLDocument and XSLTMethod to seperate products changed ClobXMLDocument to XMLDocument ___ XMLDocument beta supports the import and manipulation of XML files in Zope through the use of XSLT. See (XPath: http://www.w3.org/TR/1999/REC-xpath-19991116, and XSLT: http://www.w3.org/TR/1999/REC-xslt-19991116) XMLImporter is currently used as a python based tool to input XML files as Zope Objects. The mapping functionality and XSLT transform are used to manipulate the incomming XML stream into a set of Zope Objects. The transform is applied to the incoming XML to allow manipulation and compression of the incomming XML. See http://216.164.72.7:7780/Wiki/Members/jim/ZDOM/InitialNotes under the heading optimization. The final set of objects created by XMLImporter is defined by the mapping dictionary where keys are the tagNames to be created, and the values are references to python classes. A current limitation of the system is that Zope must not be running during an import. Clob XML Document is a Zope Object that represents a complete XML document. Interfaces are provided to edit the content of the document, and modify how the document is displayed when viewed. XSLTMethod is a Zope Object that applies an XSLT transform to an object. An XSLTMethod can be accessed as any other method of an object. With the ZDOM pakage installed, the XSLTMethod can be
Re: [Zope-dev] Memory 2.1.4-2.1.6 a.k.a. how to get objects out of the cache
Jason Spisak wrote: Bill Anderson: Jason Spisak wrote: [...] That's funny that I am experienceing the same symptoms as you, but my installation is totally different. I'm not using GUF, or any DA's, and I'm running on RH 6.1. We really need to figure this out as a community. I am willing to try just about anything short of shipping my machine somewhere off premisis. ;) Ok, let's dig up some more info ( or perhaps I missed it ). Server setup, as in pcgi/Zserver/Apache w/proxypass, etc? Nothing but straight ZServer/Medusa. Cool, eliminates suspects. Compiled on the machine, or binary distribution? Zope 2.1.1 binary distro. Not sure how it got to be 2.1.4/2.1.6, might have been the other person having problems, or my mistake. But the changes in 2.1.4 and 2.1.6 aren't anything in the Object publisher or Medusa so I don't think it makes a difference. Have you considered trying a source-compile setup? There may have been something in the original binary that gets triggered when dynamically linking (does it do that? I haven't run a binary Zope distribution) to the libraries on your machine. I have witnessed this with X. RH 6.1 2.2.12smp kernel Hardware RAID dual 350mhz Xenon 1 gig ram Vanilla Zope with no DA's, no Apache. BTW, Matthew gave me some advice last Friday to use the setcheckinterval line in z2.py and the performance gains are quite impressive. Anyone who is running smp should try it. It is impressive. I love seing Zope serving static files in the 70rps range. ___ 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] New Help System in 2.2
I too agree the new help system looks nice. I was considering at one point jumping up and writing a documentation system for Python/Zope. Unfortunately my notes, not many, are at work. But some things I had in mind were based on something like JavaDoc. I am not a Java expert and have not really used JavaDoc much but have seen some of its documentation. I was thinking it would be nice to have a parser which could extract documentation from source to create external documentation files which could be generated into multiple formats, html, xml, etc. I would have needed to create a documentation format which could be used in source but extracted. I was not going to use docstrings as they are intended for a different purpose and are compiled into the bytecode. I was thinking that the parser could run over a module and extract functions, methods, variables and properties, etc. and create a stub framework on a form. A documenter could then edit documentation for any or all of the methods, save and it would be inserted appropriately into source. I thought it would also be nice if the documentation tree would also parallel the source tree and have a corresponding colorized html rendering of the module for browsing. This way one could jump from documentation to source at will. I was basically making idea notes. I was going to look at the current doc generating and py2html tools available first. Then Starship went down and I couldn't access them. :( I also wanted to see what the DC team was doing. I think it would be nice to see some ideas and processes for what and how Amos and Michel are doing with the documentation and how the community can help. Just some thoughts. Jimmie Houchin Jason Spisak wrote: Shane Hathaway writes: Jason Spisak wrote: I was just browsing the help system and can I just say it is terrfic. The .py files especially. Not that python isn't that easy to read, but having the ZQR type stuff handy online is a huge win. Is that stuff updated from the source on the fly? Almost. It's actually written in separate files that mirror the structure of the real source. And I'd like to bring up the point that I wonder why it is written that way. Wouldn't it make more sense to self-document the source? If the issue is that some methods shouldn't be callable from a URL, there are better solutions to that problem (this is written to DC mainly): Is this the reason that it's not pulling the docs from the source? That's not a good idea. With all the effort that Michel put in to work around not documenting in the source, he could have fixed it so that it pulled the docs from the source on the fly without effecting the URL access. 1) Enahnce the permissions system to include "Accessible via HTTP", "Accessible via FTP", etc. 2) Use an underscore as the first character of a docstring to indicate a non-URL-callable method. I just looked at it and that seems like doing work twice. Why not just document your source? Wonderingly, Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats. ___ 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 )
Re: [Zope-dev] New Help System in 2.2
Stephan Richter writes: At 09:09 PM 5/30/00 +, Jason Spisak wrote: Shane Hathaway writes: Jason Spisak wrote: I was just browsing the help system and can I just say it is terrfic. The .py files especially. Not that python isn't that easy to read, but having the ZQR type stuff handy online is a huge win. Is that stuff updated from the source on the fly? Almost. It's actually written in separate files that mirror the structure of the real source. And I'd like to bring up the point that I wonder why it is written that way. Wouldn't it make more sense to self-document the source? If the issue is that some methods shouldn't be callable from a URL, there are better solutions to that problem (this is written to DC mainly): Is this the reason that it's not pulling the docs from the source? That's not a good idea. With all the effort that Michel put in to work around not documenting in the source, he could have fixed it so that it pulled the docs from the source on the fly without effecting the URL access. 1) Enahnce the permissions system to include "Accessible via HTTP", "Accessible via FTP", etc. 2) Use an underscore as the first character of a docstring to indicate a non-URL-callable method. I just looked at it and that seems like doing work twice. Why not just document your source? I just talked to Amos and Michel last Friday about that and they researched for a long time, whether it would be better to document the source or to have different files. They both decided it is the best to have the documentation separately. I believe that they looked at the issue from all angles and had good reasons, why they went with the current way. I trust them implicitly. I'm sure that my gut reaction was probably the same one they had, but after careful thought they found a better solution. Furthermore, the help system will become even more than just the screen help. The .py files you see, are just the start of the new API documentation. Oooo. Furthermore, we will include a new DTML reference soon. Do you know about anything else, that should be included? Well if you really want to make it hot, the examples that are in there can keep coming. Web links might not be out of order either. The only problem is that there is no difinitive Zope online docs to link to, to get the most recent info. But when there is, it would be nice to include. Thanks, Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats. ___ 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] New Help System in 2.2
Stephan Richter writes: At 12:02 AM 5/31/00 +, Jason Spisak wrote: Furthermore, we will include a new DTML reference soon. Do you know about anything else, that should be included? Well if you really want to make it hot, the examples that are in there can keep coming. Web links might not be out of order either. The only problem is that there is no difinitive Zope online docs to link to, to get the most recent info. But when there is, it would be nice to include. The next task after the 2.2 release is that we will look through the tutorial and see what it does not cover and then add the missing examples in tutorial form. :) Off-site links are okay, but what happens, if I sit in the plane and I need that piece. Amos leans also towards external links I think, but I would rather keep it in the distribution; it is only a couple thousand bytes more and will not increase the distro size too much. A fact is, that most of the Zope Online Help should be the most up-to-date, meaning that we try to encourage developers to update and patch the help system as they update the code. Personally, I see that same thing might happen that happened to Zope. They'll want to get the product out badly, and since the help system is separate, they'll put it off. Our goal is basically to initialize a good, well organized Zope help system, which content is maintained by the developers, read community. I think this is terrific shot at offering everyone a chance to "get it". BTW, if you find any mistakes or want to make additions to the help texts, please send them to me. I hope I will be able to upload a complete revision of *all* the help screens by the end of the week. I have only 80 documents to go. :) Excellent. I am reading it. I founfa few "not found"'s but that stuff probably just not loaded yet. Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats. ___ 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] New Help System in 2.2
Excellent. I am reading it. I founfa few "not found"'s but that stuff probably just not loaded yet. Yeah, me too. I am fixing that as I am going along. Regards, Stephan -- Stephan Richter CBU - Physics and Chemistry Web2k - Web Design/Development Technical Project Management ___ 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] Re: ZCatalog and Unique IDs
Chris Withers wrote: Tres Seaver wrote: who's the CTO? Jim is. Okay, I get the joke now :-) * "persistent" references are effectively required to be immortal: it is _mandated_ that one be able to stringify the IOR, copy it to a piece of paper, put the paper in a bottle, and cast it on the waves; whoever opens the bottle should be able to transcribe the IOR, reify the reference from the string, and communicate with the object (which may be an entirely new "incarnation" created just for this request). This is the sort of persistent reference I meant, it's one of the reasons I like CORBA as a model ;-) A general-purpose, persistable reference in Zope pretty much has to be represented as an absolute containment path I don't agree. What happens when you move an object? The object doesn't change so why should its persistent reference? In a similar way, what happens when an object moves between storages? I reckon it should have the same POID... What you are missing in my description above is that CORBA persistent IORs may not map one-for-one to "real" objects -- there may be many IOR's whose requests are served by a single "real" object. Persistent IORs encode a promise that, if I come back and invoke on the IOR I got from the bottle, the ORB which published it must do one of the following: * locate / activate the corresponding servant object and delegate to it; * return to my ORB a LOCATION_FORWARD message pointing to the place whither it moved; * raise a NOT_EXIST exception if the object has died and can't be resurrected. CORBA IOR's can actually consist of multiple "profiles" each of which encodes a "search path" to find the object: * "endpoint" data -- address information with which to establish a connection to the POA (persistent object adapter) e.g., hostname/IP + port # for TCP, or pathname for AF_LOCAL sockets; * "POA ID" -- a (possibly hierarchical) name for the object adapter which published the IOR; * "object key" -- the ID for the object, unique *within the POA*. Zope objects already have an OID which is unique within their storage; the problem is that there is no useful way to massage an object given only its OID; lots of Zope's machinery depends on knowing the traversal path used to find it. A man with one watch knows what time it is; A man with two is never sure. That's not quite what I meant... An object is unique. It's aquisition context may give it more attributes to play with, but at the end of the day it is a seperate entity. This entity should have a unique, global identifier; it's POID. I think putting a path in front of this identifies the context, but doesn't really do a lot to identify the object. I guess my view depends on _data_ being stored in the object rather than acquired. Is this the case? The traversal path encodes more than just acquired attributes. For instance, it is entirely possible for a single object to be stored in multiple folders: in one folder, tseaver might not even be able to *see* the object, while in another, I might be able to query or modify it, based on the local roles assigned in each folder. (Note that this can't be done through the stock management interface, but could be done easily in "file-system" Python). Tres. -- === Tres Seaver[EMAIL PROTECTED] Digital Creations"Zope Dealers"http://www.zope.org ___ 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 )