Re: [Zope-dev] Zope2.7.0rc2 AttributeError: 'NoneType' object has no attribute 'setHeader'
Thanks again for the reply Dieter, On 6 Feb 2004, at 21:14, Dieter Maurer wrote: REQUEST.RESPONSE is set up in ZServer.HTTPServer.zhttp_handler.continue_request. It should be impossible that is is None. Agreed. Maybe, we have a memory corruption. I have seen objects magically becoming None in Python versions with memory corruption problems (Python 2.1.1). -- Dieter Could be memory perhaps, but this is python2.3.3. Christian Heimes wrote: [...] And the next one: Python2.3.3/Zope2.70rc2/Plone2rc5. Exception Type AttributeError Exception Value 'str' object has no attribute 'RESPONSE' [...] Module Products.CMFPhoto.Photo, line 510, in clearCache AttributeError: 'str' object has no attribute 'RESPONSE' The relevant code line is self.REQUEST.RESPONSE.setHeader(). The error occured at object creation. Something really bad is going on! Christian The problem I'm having is that these are all stock Zope products from a Zope2.7.0rc2 release. The traceback is coming from the Zope core. Traceback (innermost last): ... Module Shared.DC.Scripts.Bindings, line 320, in __render_with_namespace__ Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec Module App.special_dtml, line 175, in _exec Module DocumentTemplate.DT_Util, line 201, in eval - __traceback_info__: RESPONSE Module string, line 0, in ? AttributeError: 'NoneType' object has no attribute 'setHeader' This also seems different from what Christian is reporting; Christian Heimes wrote at 2004-2-6 23:01 +0100: And the next one: Python2.3.3/Zope2.70rc2/Plone2rc5. Exception Type AttributeError Exception Value 'str' object has no attribute 'RESPONSE' [...] Module Products.CMFPhoto.Photo, line 510, in clearCache AttributeError: 'str' object has no attribute 'RESPONSE' The relevant code line is self.REQUEST.RESPONSE.setHeader(). The error occured at object creation. Something really bad is going on! So, I'm still baffled by this. Many thanks to all those providing more data points. I *think* this is a 'Zope' thing and not a 'Tone' thing, but I've been wrong in that area before ;) cheers tone. -- Dr Tony McDonald, Asst Director, FMSC. 0191 245 4223 Project Manager, FDTL-4 ePortfolios http://www.eportfolios.ac.uk/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] Zope2.7.0rc2 AttributeError: 'NoneType' object has no attribute 'setHeader'
Hi all, We're in the process of migrating our sites to 2.7, so to get the guys up to speed we picked a site at random today. Did the /usr/local/zope/bin/mkzopeinstance.py jig (works very well), copied the Data.fs, some external methods, a Zwiki product and were good to go. This is from a Zope-2.6.1 site. We found out that LocalFS needed updating, so found a 2.7 compatible version and installed that. http://www.my-zope.org/Members/kedai/LocalFS-1-1-0.tgz/file_view Now we have a very peculiar error, that I'm not posting to the Zope list as it's the RC2 version of Zope2.7 that we're using. We have an index_html (initially DTML document, then tried method) that can be created (located at /prototype/myporfolio/index_html), have it's security settings changed quite happily. Then when the object is called we get the error in the subject line. The system specs are; Zope Version (2.7.0rc2, python 2.3.3, sunos5) Python Version 2.3.3 (#3, Jan 23 2004, 13:36:43) [GCC 2.95.3 20010315 (release)] System Platform sunos5 SOFTWARE_HOME /usr/local/zope/lib/python ZOPE_HOME /usr/local/zope and the traceback is; Traceback (innermost last): Module ZPublisher.Publish, line 100, in publish Module ZPublisher.mapply, line 88, in mapply Module ZPublisher.Publish, line 40, in call_object Module Shared.DC.Scripts.Bindings, line 306, in __call__ Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec Module App.special_dtml, line 175, in _exec Module Shared.DC.Scripts.Bindings, line 320, in __render_with_namespace__ Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec Module App.special_dtml, line 175, in _exec Module DocumentTemplate.DT_Util, line 201, in eval - __traceback_info__: RESPONSE Module string, line 0, in ? AttributeError: 'NoneType' object has no attribute 'setHeader' I have never seen anything like this from Zope before (been using it since 1.0.3 so I've seen it do quite a bit! :). I've looked through the zope-dev archives and can't find anything related (unless it's got something to do with manage_page_charset not being callable? The only thing I could find on the collector was issue 381, http://collector.zope.org/Zope/381 'HEAD request method broken' - but that doesn't seem relevant in this condition. *Any* thoughts would be gratefully received. To recap, we took a pretty plain 2.6.1 site, loaded it into 2.7.0rc2 and get the traceback above... cheers tone. -- Dr Tony McDonald, Asst Director, FMSC. 0191 245 4223 Project Manager, FDTL-4 ePortfolios http://www.eportfolios.ac.uk/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Zope2.7.0rc2 AttributeError: 'NoneType' object has no attribute 'setHeader'
Thanks for the response Dieter, On 5 Feb 2004, at 18:51, Dieter Maurer wrote: Tony McDonald wrote at 2004-2-5 12:43 +: ... We have an index_html (initially DTML document, then tried method) that can be created (located at /prototype/myporfolio/index_html), have it's security settings changed quite happily. Then when the object is called we get the error in the subject line. The system specs are; ... and the traceback is; Traceback (innermost last): ... Module Shared.DC.Scripts.Bindings, line 320, in __render_with_namespace__ Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec Module App.special_dtml, line 175, in _exec Module DocumentTemplate.DT_Util, line 201, in eval - __traceback_info__: RESPONSE Module string, line 0, in ? AttributeError: 'NoneType' object has no attribute 'setHeader' Looks like RESPONSE is None. I do not see how this can happen... Exactly! - this is why I said I'd never seen this before. It's a 2.6.1 Data.fs that's been dropped into a stock 2.7.0rc2 release and I get this error. I have no idea why this is happening, so I was hoping that it was an artifact of the 2.7.0rc2 release itself. Probably, I would start debugging. Quite likely, but I have *no* idea where to start with this. All the modules mentioned in the trackback are Zope supplied ones, not third party ones, so I'd assumed it might be the core software. -- Dieter once again, thanks for the reply Dieter. tone. -- Dr Tony McDonald, Asst Director, FMSC. 0191 245 4223 Project Manager, FDTL-4 ePortfolios http://www.eportfolios.ac.uk/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Call Profiler
On 1/2/02 1:13 am, Richard Jones [EMAIL PROTECTED] wrote: I've just announced our Call Profiler product on zope.org and the zope announce list (waiting for people in different timezones to authorise them :) ( http://www.zope.org/Members/richard/CallProfiler/ for the impatient) [snip] Any comments? I've been using it for *5* minutes and have found a method that was taking 95%! of one of our most often used scripts and another python script that was effectively stalling the servergobsmacked. Huge kudos and thanks to Richard!! :) Tone. -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 243 6140 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/zope ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] Upgrading to python 2.1.2 and Zope 2.5b4
Hi all, I want to upgrade to python 2.1.2 (from an existing 2.1 installation) and at the same time upgrade to 2.5b4 in the hopes that this combination will fix the threading problem under Solaris. Q1: Is this the right combination to use, I've read that I should use 2.1.2 and 2.4.4 (possible numbering scheme). If so, I can wait (but we are getting core dumps regularly now) Q2: (and apologies, as this is a more python-orientated question) Can I just do a 'make install' of python 2.1.2 and be sure that it's not going to make my MySQL and other modules in site-packages unusable? (sorry if this is a daft question - I have a *lot* of zope sites using python 2.1 at the moment) Many thanks Tone -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 243 6140 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/zope ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] Where to put time.sleep(0.01) to get around solaris threadingissue?
/select_trigger.py: thread.start_new_thread (thread_function, (tf, self.count, n)) ./ZServer/medusa/thread/thread_channel.py:thread.start_new_thread ( ./lib/python/ZODB/bpthread.py:start_new_thread=apply And pointed a zope Data.fs that has the test methods at this new distribution. No joy. That is, testing the 'sleeper' script still blocks other requests until it is finished, when those requests are then serviced. Can anyone see what I'm doing wrong here? Tone. -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 243 6140 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/zope ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope] Problems with list?
I've had no email from this list since Friday at 06:50am. Is there anything wrong with it? Tone -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] How do I form an XML-RPC query to a remote server?
On 15/11/00 5:58 pm, "Michel Pelletier" [EMAIL PROTECTED] wrote: Tony McDonald wrote: Hi all, I'm experimenting with collating data from a remote database that uses XML-RPC. I can send it messages like; import xmlrpclib medweb = xmlrpclib.Server("http://bogus.server.com") medweb.getImages('scar') '?xml version="1.0" encoding="ISO-8859-1" ?\015\012\011data\015\012\011\011titleMedwebb Images/title \0 (lots of stuff snipped) But I just can't figure out how to send the XML version of the same query, ie ?XML VERSION="1.0"? methodCall methodNamegetimages/methodName params param valuestringscar/string/value /param /params /methodCall to the server. How does it fail? Did you set the right content type (text/xml I think?)? Thanks for the reply Michel, Yes the content type is text/xml, but I guess I'm doing something else wrong. Why do you want to send a hand built query to the server? That's what xmlrpclib is for. Oh definitely, but I'm trying to do it this way as I think the queries may get more complex... -Michel I've got a nasty feeling that when I get told how to do this, I'm going to slap my forehead bloody hard Do what I do, where a helmet to work. I like that! :) -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] How do I form an XML-RPC query to a remote server?
On 16/11/00 7:10 am, "Edward Muller" [EMAIL PROTECTED] wrote: On Wed, 15 Nov 2000, Tony McDonald wrote: Hi all, I'm experimenting with collating data from a remote database that uses XML-RPC. I can send it messages like; import xmlrpclib medweb = xmlrpclib.Server("http://bogus.server.com") medweb.getImages('scar') That looks right... Yup, that bit works! :) '?xml version="1.0" encoding="ISO-8859-1" ?\015\012\011data\015\012\011\011titleMedwebb Images/title \0 (lots of stuff snipped) That doesn't ... I don't think they have a well formed XML-RPC document, so xmlrpclib can't parse it... I think that is ok XML. The \015\012 are just LF-CRs and are ignored. But I just can't figure out how to send the XML version of the same query, ie xmlrpclib handles the marshaling/un-marshaling to xml/from python for you... Absolutely, and it works fine when I do it from a Python prompt. ?XML VERSION="1.0"? methodCall methodNamegetimages/methodName params param valuestringscar/string/value /param /params /methodCall to the server. I'm really just trying to get a Zope equivalent of the Userland 'debugger' at http://frontier.userland.com/stories/storyReader$1077 as I think these queries may get more complex. xmlrpc lib is already constructing this...or it should be,,, I've got a nasty feeling that when I get told how to do this, I'm going to slap my forehead bloody hard See above :-) I'll take Michels advice and wear a helmet to work! :) Cheers, Tone. -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] MySQL Connection String
On 17/11/00 4:36 pm, "Aitor Grajal Crespo" [EMAIL PROTECTED] wrote: I have installed ZMySQLDA 1.1.4, anybody knows the format of the database connection string??? I have put database user passw , and doesn't work Thanks database@host user passwd 'host' can be 'localhost' for database servers on the same machine as Zope... hth Tone -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] Newbie Install: Solaris/Zeus
On 16/11/00 4:23 am, "Lee Hunter" [EMAIL PROTECTED] wrote: I'm trying to install Zope 2.2.2 on a shared web host that uses Zeus running on Solaris. When I try to run "python w_pcgi.py" I get the following error: Zope requires Python thread support! The version of Python on the machine is 1.5.2 Any thoughts on what I'm doing wrong? Cheers Lee Yes. Zope needs thread support to run. You can download the binary release of Zope for Solaris from the website and use that. The binary release has its *own* copy of Python bundled with it. Alternatively, you can compile up your own *version 1.5.2* of Python under Solaris and use that globally through your system. People have said that Zope works with Python 2.0 - but I'd wait until the DC troops say it's ok if I were you. I'd also advise not trying with Python 1.6. hth tone ------ Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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 )
[Zope] How do I form an XML-RPC query to a remote server?
Hi all, I'm experimenting with collating data from a remote database that uses XML-RPC. I can send it messages like; import xmlrpclib medweb = xmlrpclib.Server("http://bogus.server.com") medweb.getImages('scar') '?xml version="1.0" encoding="ISO-8859-1" ?\015\012\011data\015\012\011\011titleMedwebb Images/title \0 (lots of stuff snipped) But I just can't figure out how to send the XML version of the same query, ie ?XML VERSION="1.0"? methodCall methodNamegetimages/methodName params param valuestringscar/string/value /param /params /methodCall to the server. I've got a nasty feeling that when I get told how to do this, I'm going to slap my forehead bloody hard As you can see the data is returned in XML format, and whilst I'm fine with Python code for XML parsing (usually use sgmlop), I'm a bit lost on where to start here. An External Method seems the best way, but I'd like the received wisdom on this. Ta muchly, tone -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] FYI: Digital Creations secures $12M round of investment
On 14/11/00 3:15 am, "Paul Everitt" [EMAIL PROTECTED] wrote: Hello Zope friends. At long last we at Digital Creations are able to publicly say it: we've closed a $12M round of investment: http://www.digicool.com/News/CRound.html It's out on the newswire now. We'll start pushing it out more over the next 24 hours. This is excellent news. Congratulations to all the DC troops... -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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 )
[Zope] Populating a :list variable from the results of a ZSQL method
Hi all, Say I've got a form with this in it select type="checkbox" name="options:list" option value="1"number 1 option value="2"number 2 option value="3"number 3 /select When this is put into an SQL database, the field 'options' is this (string) ['1', '2', '3'] or ['2', '3'] etc. When I get the data back from the database, 'options' comes back as a string, and dtml-in options ... /dtml-in gives errors (basically, it can't iterate over a string). I tried dtml-call "REQUEST.set('new_options:list', options)" and then tried iterating over new_options, but the variable didn't exist... Has anyone got any solutions for this? TIA Tone -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] Populating a :list variable from the results of a ZSQLmethod
On 10/11/00 10:52 am, "Phil Harris" [EMAIL PROTECTED] wrote: tone, How about (untested): where 'dboptions' is the string pulled from the DB, and 'options' is the list needed. dtml-call "REQUEST.set('options',[])" dtml-in "_.string.split(dboptions[1:-1],',')" dtml-call "options.append(_.int(_['sequence-item']))" /dtml-in This would then give you take the string "['1','2','3']" and turn it into the list [1,2,3]. hth Phil Aha! That's just about what I'd come up with before. Ok, well to be honest I actually got as far as the string.split and ended up using a _.string.find() construct to get a pseudo-lookup working :) I suppose to make it more generic, you'd lose the _.int() part. Thanks for the info Phil. -- Dr Tony McDonald, Assistant Director, FMCC, http://www.fmcc.org.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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 )
[Zope] how do I get rid of 'ghost' objects in Data.fs
Hi all, I've been trying to install EventFolder into a Zope 2.2.1 system. I've followed the instructions (I wouldn't be writing here if I hadn't! :) and keep getting an error message; Error type: Could not load oid รท, pickled data in traceback info maycontain clues Error value: None and the traceback... (Info: ('\000\000\000\000\000\000\015\367', '(cExtensionClass\012ExtensionClass\012q\001(U\014TrackerIssueq\002(cZ Classes.ZClass\012PersistentClass\012q\003cProducts.TrackerBase.Tracke rBase Now the thing is, I *do not have* TrackerBase.TrackerBase in my Products folder. To try and get rid of this error, I have deleted *all* the products in my Products Folder and restarted my server. The error message still comes up. I have packed the database and tried 'grep' 215 % grep -i trackerbase Data.fs Binary file Data.fs matches doh! I change my PYTHONHOME to point to a Zope 2.2.1 installation that a lot of servers use. The lib/python/Products directory there shows no TrackerBase there. No TrackerBase in the (local, ie server-specific) directory, Products, either. Can anyone give me a clue as to where to look for this errant Product? Tone ps *excellent* news about BDFL and his troupe joining DC! -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] How small a box can zope run on?
At 10:15 am +0100 26/10/00, Toby Dickenson wrote: On Wed, 25 Oct 2000 18:43:57 +0200, "Alexander Limi" [EMAIL PROTECTED] wrote: We are building some device controller software and to control those we have a normal 486 with 24MB RAM running linux. Has anybody tried running zope on such a modest setup? There is only going to be one or two users connected to Zope at once, so we don't need much performance in terms of page views per second :) Yes, Im using Zope in a similar scenario and it works well. I found a benefit in using a smaller number of publisher threads (I use -T 2 ). Each thread gets its own copy of the ODB, which is an unnecessary memory hog for the expected load. !!! This is the first I've ever seen written on this subject. If it's correct (and I have no reason to disbelieve Toby - I've tried a few things on our box here and it seems to pan out), then this explains large memory consumption on our servers (roughly 80 - 180 Mbyte RAM used per server). I shall be doing a sweep of our Zope servers and packing the databases (the ODBs that is). One thing though, is there a 'party line' on what number the -T parameter should be set to? Coming from an Apache background, I'm used to having dozens of httpd processes hanging around waiting for something to happen. I've always assumed that threads did much the same thing. Perhaps I'm wrong thoughts? Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] Sendmail examples
At 10:01 pm +1000 22/1/01, steve smith wrote: Anyone have any good, real-world examples using DTML-Sendmail tags? Would especially appreciate examples integrating SQL queries. Ta! Steve What, you mean including ones that send mail into the future? :) (couldn't resist). Assuming you've set up a MailHost object called 'MailHost' Set up a FORM with variables: recipient, name and comments and make the ACTION URL the following piece of DTML (with appropriate sugar around it) !--#sendmail mailhost="MailHost"-- To: Feedback Recipient !--#var recipient-- From: Zope Feedback Form zope_form@thoth Subject: Feedback from the web Feedback from : !--#var name-- Comments: !--#var comments-- !--#/sendmail-- hth tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] dtml-sqlvar quote
Hi all How can i pass a string to a sql method that won't be quoted. i.e so i can do somthing like this . group by foo,blah order by dtml-sqlvar spam thanks mark don't quote it? ... order by dtml-var spam I use this all the time for things like select * from data where dtml-var search_field like '%dtml-var search_term%' tone ___ 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] Medusa Monitor
At 1:18 pm -0700 16/10/00, Karl Anderson wrote: Terry Kerr [EMAIL PROTECTED] writes: I don't think the monitor gives you any advantage? I have never used a ptyhon prompt before...I will have to give it a go. terry Actually, the advantage of the monitor is that it runs in the same process as your server, so you can track resource issues. Mounting the database separately avoids this. -- Karl Anderson [EMAIL PROTECTED] Karl, Is there anywhere documented that describes how to track resource issues? I regularly have Zope processes that hit 150 Megs of RAM and would like to know if I'm doing anything dopey. cheers tone. -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] How to use the date fmt's
At 2:08 pm +0100 16/10/00, Jonathan Cheyne wrote: Hi all, in the various docs it shows various fmt= to display different date types etc. It also shows some date formats that seem more like methods themselves, ie IsCurrentMonth returns true if etc. try this http://www.zope.org/Members/AlexR/CustomDateFormats tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] Need preferred 'import' format for ReportLab Imagemodule
At 2:37 pm +0200 12/10/00, Rik Hoekstra wrote: to reply to Andy? In my own reportlab distribution I changed; import Image to from PIL import Image Well, it sounds right and if it works then it probably is ;-) It probably depends exactly where you install PIL, though, which I haven't done yet :-S The Photo product and the ExtImage products do more or less the same - this seems to become the standard way. It would be nice to have one place to put PIL, though. the lib/python/shared directory would be a good place I think. Rik Is this because you're thinking of the binary releases of Zope? If you're using the reportlab libraries, then you've probably installed them into /usr/local/lib/python1.5/site-packages (ie you're used to using source distributions). If you can do that, you're probably ok with putting PIL into lib/python/shared. So why not have it in site-packages? Or have I missed something obvious (I probably have - it's been a looong day). tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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 )
[Zope] Need preferred 'import' format for ReportLab Image module
Hi all, This is of interest to those people using the (excellent) PDF generator, ReportLab http://www.reportlab.com/ under Zope. As you may know, there is an import conflict with the 'Image' module from PIL and the built in Zope 'Image' module when using ReportLab. The snippet below is from the main ReportLab developer, Andy Robinson. If it's not too much trouble, that would be very useful for those of us using Zope (the number is growing all the time). We will try to do this. But which import format does Zope require? 'import Image' of 'import PIL.Image'? And is this some sort of packaged 'PIL-for-Zope'? If it was just PIL on your hard disk, you would have 100% control over the problem just by adding the right directory to your path. Sorry, I'm working all hours and don't have time to download and play with Zope this month. - Andy -- So, can anyone with a higher 'import' Zope Zen please give me a clue as to how to reply to Andy? In my own reportlab distribution I changed; import Image to from PIL import Image and that seemed ok, but I'd like a 'definitive' answer on this from some bods with Nirvana-level Zen BTW, If you're not a reportlab user (open source, free download), then you're missing out - this is terrific software...we have it connected to ZSQL methods and are churning out PDF documents *very* quickly. cheers, Tone ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: Upload just file headers?
Much thanks to Knight and to Peter Bengtsson (who replied off-list), I know have at least two possible avenues to explore. If I ever get this to work, I'll post it! Please do - we've got people uploading PowerPoints of up to 25-30 Megabytes (record was an attempt at 170 Mb) and we'd like to offer a software solution before we have to 'send the lads round'. Cheers Tone. ___ 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] Bizarre ZMySQLDA problem...
Hi all, I've just installed Zope-2.2.1 onto a clean Solaris 8 machine. I've built Python 1.5.2 from source and have MySQL 3.22 on the server. I've compiled up the ZMySQLDA product and put the MySQLModule.so in the correct place (ie one directory up from the src directory). I've restarted the Zope server, checked that ZMySQLDA is not broken and created a connection: test@localhost root I've created a ZSQL method that is essnetially 'select * from my_table' (and there *is* data in this table). The DA reports: There was no data matching this Z MySQL Database Connection (connected) query. The same query produces a flood of data from the mysql monitor. I'm totally baffled here, and would really appreciate any advice... Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 A Zope list for UK HE/FE http://www.fmcc.org.uk/mailman/listinfo/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] Help with Zope 'pitch'
At 11:35 am +0100 15/9/00, [EMAIL PROTECTED] wrote: I hear Zope learning curves are steep, so I wonder if anyone can suggest how I can persuade Managers that it is worth investing time and effort. To do many things is dead easy. This includes things like database lookups and reuse of web page 'components' (think of them as server-side-includes). The learning curve comes about because of the very different way that Zope works - and this is almost solely down to Object-Orientated principles. For example, in a static web site, you create an index.html page in every folder in your web site. If you have 2000 folders, then you need 2000 index.html files (or index.php3 or whatever). With Zope, you can have *one* index.html file at the top level of your web hierarchy that would do for all your 2000 folders. In folders that are special, say admin folders, you can change the index.html to be something else. You can also lock that file down so people need to authenticate to get into the folder. Suppose your web site is composed something similar to this; admin contacts internal external research contacts internal external undergrad contacts admissions courses year1 ... year5 postgrad contacts admissions courses taught year1 research year1 ... year5 (extend this out as much as you like) You can see there's a lot of duplication there. Using Zope, You can effectively 'create' those 2000 folders by simply writing out a URL, such as /postgrad/courses/taught/year1/action. The 'action' part will collect all the components together and create a composite web page. This is where some of the learning curve kicks in, as what you need to do to use Zope to greatest benefit is to look for commonality and uniqueness amongst all the components you are collecting together. Can anyone say in a few paras what Zope can do and what its benefits might be (lay language appreciated); I've probably gone way over the top there, but essentially you get to create dynamically rich *maintainable* web sites in a very short period of time. These web sites can be broken into logical chunks, that allows for very easy distributed management. eg in 'admin' above, you pass off the management of that 'branch' to someone else. If they then create an internal section of admin, they can also pass off responsibility of that part to someone else. also any anecdotes of how long it took to get to grips with it. I had some people come to the Med School on a Sunday and had them creating pages that were built from components in about 20 minutes. By the end of the afternoon they had several pages made and one or two had pages that were doing a database lookup. Is it worth using it for a Web site that is predominantly static pages (with ambitions for development)? There are some excellent 'products' (think plugins) that can mirror a static web site quite happily. You can then add the dynamic parts as you gain in confidence. I'm specifically thinking of the LocalFS product. Still a Web Novice but working on it - Linda Doyle! not for long we hope... Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] problem logging in to /manage resource
Hello, I've been tryhing hard for the last two weeks to use zope but I can't seem to get it to go past the /manage resource. Ouch! - you'll like it once you get started. I'm running zserver, I tried the default password, changing it with zpasswd, removing domain restrictions, everything, but it still gives me authentication failed. Please help me. I'm going insane here. Thanks for your time =) Try this; Edit 'access' with a simple text editor, delete the entire line. Replace the entire line with superuser:123 then (assuming unix - my only domain knowledge wrt Zope) % ./stop % ./start See if you can login now - the {SHA} stuff isn't there anymore (might be getting in the way - although I can't figure out why that might be the case). Are you connecting to the right server? (assumes you're running multiple servers, possibly on multiple ports). You're not frontending ZServer with Apache are you? (to get authentication in this instance means you need to use ReWrite rules in Apache). If the answer to all these questions is "yes, yes, of course I am" then I'm baffled. Sorry. HTH Tone ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Patch for Netscape 'tree' bug?
At 10:09 am +0200 18/8/00, Pierre-Julien Grizel wrote: ** Reply to message from [EMAIL PROTECTED] on Fri, 18 Aug 2000 04:36:34 +0100 (BST) [Hoping you didn't receive my previous message.] If you talk about the www.xlogx.org patch, I've made the site available again, you can find it at http://www.xlogx.org/Zope/TreeTag.query_expr.patch Be careful, it has a problem with trees deeper than 3 levels, I think it's not a big work to correct this but I hate html and I don't have time to do it. I should take time those weeks, but I can't promise Regards, Thanks Pierre, we've downloaded it and installed it. It looks better, but as you say, it gets confused with trees deeper than 3 levels. We don't have time to look at the code to try and fix it at the moment, but thanks for your help. We'll probably stick with 3 level trees for the time being. There's been some talk on the Zope list about rewriting the tree tag somewhat. Can I make a plea that this is considered too? cheers tone. -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] anyone got a foolproof 2.1.6 - 2.2.0 via import schema?
On Mon, 21-Aug-2000, you wrote: Tony McDonald wrote: I get KeyErrors from 2.2.0 with an Error value of a rubbish character when trying to import a folder of various objects. This also happens when trying to import the XML version, except the Error Value is 'id' (but with no idea of where the error is in the XML file ... irritating). any ideas? this is driving me up the bloody wall. ta tone Hi, Tony. 2.2.0 had some problems with the ZDOM that prevented XML documents from functioning properly. This should be fixed in more recent versions. Hope that helps, Thanks for the info Ethan. I managed to fix things (read: hack) to get me out of that bind, but I'll wait for the newer version of Zope as well.. cheers tone. ___ 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] getting rid of PTKDemo
At 7:22 pm +0200 16/8/00, [EMAIL PROTECTED] wrote: Hello Tony, sure I would come for such a pint offered, but for now, I am in just the same situation - without access to this tab of any ZSQL method. So, please, should you get an answer (I mean, a solution) could you be so kind to share it with me? I'm not sure that this is a solution Ralf, but it fixed something here and made the ZSQL advanced tab usable again. I was having problems importing a folder. Errors like 'KeyError' with a crap character were showing up when I tried to import. I found that in the folder were subfolders with an ID of the type 'folder.gif', and title 'c://Dan/Images/folder.gif' - ie as though someone had uploaded an image, but it had created a folder instead (this behaviour by itself is pretty weird). I deleted these folders, and exported the folder I was interested in. I then got a clean 2.2.0 Data.fs.in and started up another Zope instance (BTW, the excellent HowTo at http://www.zope.org/Members/4am/instancehome should be required reading for those running multiple Zope sites from a single Zope installation...). I then imported the .zexp file and voila, everything was working and I could get to my 'Advanced' tab again. I have no idea whether PTKDemo is in my Data.fs, but this is encouraging! :) 112 % grep PTKDemo Data.fs | more 113 % grep MySQL Data.fs | more Binary file Data.fs matches (and the old Data.fs) 116 % grep PTKDemo Data.fs- | more Binary file Data.fs- matches If you *don't* have any ID's with 'unusual' characters in them, then I guess I can't help you out... Thank again, greeting from a Berlin draught drinker... -- Ralf Herold :) Tone ps Ralf, I've taken the liberty of ccing this to the list as it might help others... -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] mysqlUserFolder woes
At 4:12 pm +0100 17/8/00, Stephen Harrison wrote: I've been trying out mysqlUserFolder lately, but have had quite a major problem with it. Basically, everything works fine - for a while - then it starts to intermittently fail as the load to the server increases, until it is completley broken, with the system error below. Has anyone else come across this, or is it just me? Cheers, Stephen I'd suggest using UserDB. It's been pretty good for us. I looked at mysqlUserFolder (seemed overly complex), GUF (couldn't get it to work) and even LoginManager (too much Zen needed) and came back to UserDB. hth tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Patch for Netscape 'tree' bug?
Hi, It seems that 2.2.0 doesn't have the patch for the infamous Netscape 'tree' bug. The site that did have the patch is no longer available. Has anyone got the patch availble? TIA Tone ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] getting rid of PTKDemo
Anyone know how I can get rid of this? I don't have it in my lib/python/Products folder. I don't have it in my Control_Panel/Products folder. I have compacted the database and restarted my server. I still get errors when trying to do selecte the 'Advanced tab' in *any* ZSQL method. Anyone who tells me how to get rid of this thing gets a pint (you'll have to come to Newcastle to collect) cheers Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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 can I find memory leaks in External Methods?
I have an External method that is used to upload files to a unix file system. Thing is, it seems to be causing more and more memory to be used by Zope. Can anyone give me some pointers on what might be causing this? TIA Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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 uploads causing memory to be used up
Hi all, I have an external method that uploads RTF files(and only RTF files) into a unix directory. It works fine, except it doesn't seem to release the memory it uses up in uploading the file. The method is; def process_file(self, file, location, REQUEST): if file.read(1) == '': return "NO file. Something wrong?" file.seek(0) split = string.split(file.filename, '\\') filename = string.lower(split[-1]) # save the file into the correct directory oname = os.path.join(savedir + location, filename) f = open(oname, "wb") body = file.read() f.write(body) f.close() if type(body) is not type(''): body=body.data content_type, enc = guess_content_type(oname, body, None) if content_type == 'application/rtf': # it's ok, we can go ahead and process this file. # need to strip off the .rtf extension however guideid = string.replace(filename, '.rtf', '') filesize = os.stat(oname)[6] # copy the file from savedir to opsdir os.system("cp -f %s %s" % (oname, opsdir)) # now cd to the operations directory and do some stuff. os.chdir(opsdir) # actually do the grinding... os.system("DoAGuide %s" % guideid) # return the output of the log file logfilename = os.path.join(opsdir, "%s.log" % guideid) f = open(logfilename, "r") logoutput = f.read() f.close() # get the template we're going to use for output. template_str = self.done.read_raw() template = DocumentTemplate.HTML(template_str) theresult = template(self, filename=filename, contenttype=content_type, filesize=filesize, guideid=guideid, logoutput=logoutput) return theresult return "File saved %s, size (bytes) %s. content-type [%s]" % (filename, filesize, content_type) The files are roughly 2-3 megs in size, and each time they're uploaded the amount of memory (as reported by 'top') used by the process increases by about that amount. *Any* ideas or thoughts would be greatly appreciated. We've had our server brought down twice by a python process (ie zope) that was taking up 1.1 gigs of RAM. Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Import Error 'PTKDemo' - but *no* PTKDemo objects around..
Hi all, I'm having a nightmare here. I have a Zope 2.2 (src, solaris) installation that I built from scratch. Then, because *it would not* import an exported folder from a 2.1.6 installation I had to use the Data.fs from the 2.1.6 installation and strip out everything other than the folder I was interested in. Things seemed to be ok, but I found a nasty error I can't get around. I wanted to use the 'advanced' tab on a ZSQL method and immediately got this traceback. This happens on *any* ZSQL method. I use the ZMySQL database adaptor. !-- Error type: ImportError Error value: No module named PTKDemo -- !-- Traceback (innermost last): File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 222, in publish_module File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 187, in publish File /home/zope/Zope-2.2.0/lib/python/Zope/__init__.py, line 221, in zpublisher_exception_hook (Object: person_details) File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 171, in publish File /home/zope/Zope-2.2.0/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: manage_advancedForm) File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: manage_advancedForm) File /home/zope/Zope-2.2.0/lib/python/App/special_dtml.py, line 121, in __call__ (Object: manage_advancedForm) File /home/zope/Zope-2.2.0/lib/python/DocumentTemplate/DT_String.py, line 502, in __call__ (Object: manage_advancedForm) File /home/zope/Zope-2.2.0/lib/python/Shared/DC/ZRDB/DA.py, line 505, in manage_product_zclass_info (Object: person_details) File /home/zope/Zope-2.2.0/lib/python/ZODB/Connection.py, line 447, in setstate ImportError: (see above) -- I've also tried this with Zope 2.2.1b1 and get the same result. Any thoughts would be appreciated here, I'm out of ideas. tone. -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5116 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] anyone got a foolproof 2.1.6 - 2.2.0 via import schema?
I get KeyErrors from 2.2.0 with an Error value of a rubbish character when trying to import a folder of various objects. This also happens when trying to import the XML version, except the Error Value is 'id' (but with no idea of where the error is in the XML file ... irritating). any ideas? this is driving me up the bloody wall. ta tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Can't create ZClass under 2.2.0
Hi all, I've got the Beehive tutorial on Zclasses and thought I'd try it out on a 2.2.0 system we have here. I have 'create constructor types' and 'nclude standard Zope persistent object base classes? ' set. I've tried selecting various Base Classes (and no base classes), but get the following traceback. !-- Error type: Could not load oid info maycontain clues Error value: None -- !-- end of bodytext area -- /body /html !-- Traceback (innermost last): File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 222, in publish_module File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 187, in publish File /home/zope/Zope-2.2.0/lib/python/Zope/__init__.py, line 221, in zpublisher_exception_hook (Object: ElementWithAttributes) File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 171, in publish File /home/zope/Zope-2.2.0/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: manage_addZClass) File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: manage_addZClass) File /home/zope/Zope-2.2.0/lib/python/ZClasses/ZClass.py, line 154, in manage_addZClass (Object: ElementWithAttributes) File /home/zope/Zope-2.2.0/lib/python/OFS/ObjectManager.py, line 260, in _setObject (Object: ElementWithAttributes) File /home/zope/Zope-2.2.0/lib/python/ZClasses/ZClass.py, line 421, in manage_afterAdd (Object: bookclass) File /home/zope/Zope-2.2.0/lib/python/ZClasses/ZClass.py, line 374, in _register (Object: bookclass) File /home/zope/Zope-2.2.0/lib/python/ZODB/Connection.py, line 447, in setstate File /home/zope/Zope-2.2.0/lib/python/ZODB/Connection.py, line 213, in _persistent_load (Info: File /home/zope/Zope-2.2.0/lib/python/ZODB/Connection.py, line 154, in __getitem__ (Info: ('\000\000\000\000\000\000\014\300', '(cExtensionClass\012ExtensionClass\012q\001(U\006ZDItemq\002(cZClasse s.ZClass\012PersistentClass\012q\003cProducts.ZDBase.ZDiscussions\012Z DItem\012q\004cOFS.SimpleItem\012SimpleItem\012q\005tq\006}q\007(U\004 iconq\010UWControl_Panel/Products/ZDiscussions/ZDTopic/propertysheets/ methods/ZDItem%20/ziconImageq\011U\012_p_changedq\012K\001U\007__doc__ q\013U\021ZDiscussions Itemq\014U\006_p_oidq\015U\010\000\000\000\000\000\000\002Lq\016U\011m eta_typeq\017U\021ZDiscussions Itemq\020U\016propertysheetsq\021(U\010\000\000\000\000\000\000\014\30 3q\022(NU\010\000\000\000\000\000\000\014\277q\023Qttq\024QU\011replyF ormq\025cZClasses.Method\012MW\012q\026NRq\027}q\030U$_ZClassMethodPer missionMapperMethod_q\031(U\010\000\000\000\000\000\000\014\304q\032(U \016OFS.DTMLMethodq\033cOFS.DTMLMethod\012DTMLMethod\012q\034ttq\035Qs bU\012index_htmlq\036h\026NRq\037}q h\031(U\010\000\000\000\000\000\000\014\305q!(h\033h\034ttqquot;QsbU\ 016manage_optionsq#(}q$(U\005labelq%U\010Securityqamp;U\006actionq\'U \015manage_accessq(u}q)(h%U\004Viewq*h\'U\012index_htmlq+u}q,(U\005lab elq-U\012Propertiesq.U\006actionq/U\025manage_propertiesFormq0utq1U\01 2ziconImageq2(U\010\000\000\000\000\000\000\014\306q3(U\011OFS.Imageq4 cOFS.Image\012Image\012q5tq6tq7QU\022__ac_permissions__q8)U\011_p_seri alq9U\010\003/\363\246\016\005\353\325q:U\012__module__q;U\031*73biqpA I2QDa2iKPitv57g==qlt;utq=t.N.')) Could not load oid contain clues: (see above) -- Thing is, I've deleted the ZDiscussions and ZBase products as well as packing the database - these products shouldn't be there Anyone got any ideas? ta tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Silly send mail problem
At 9:04 am +0100 27/7/00, Phil Harris wrote: When using the dtml-sendmail tag you need to structure it like this: dtml-sendmail smtphost="mail.xyz.com" mailto="[EMAIL PROTECTED]" mailfrom="[EMAIL PROTECTED]" Subject="Testing from my machine" To: [EMAIL PROTECTED] From: [EMAIL PROTECTED] Subject: Testing from my machine mail body /dtml-sendmail hth Phil [EMAIL PROTECTED] ...and make sure you *don't* put any spaces before the Subject:, To:, From: and Subject: lines, ie have them hard up against the LHS of the textarea box. In other words, for the sendmail tag, whitespace (or rather the lack of it) *is* important. hth tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Need an SQL based auth system that works with Zope 2.2
At 9:38 am +0800 19/7/00, Bak @ kedai wrote: On Wed, 19 Jul 2000, Tony McDonald wrote: Hi all, I think the time has come to bite the bullet and change our authentication engine to work in line with Zope 2.2 and above. UserDB-1.2 seems to have some problems with it (see my message today), a i use userdb with 2.2 and it worked great. no problems at all. maybe you could try it on a fresh zope install or try it on a copy of your zope install. Thanks for the input Bak, thing is the product works fine *if* you've already set things up via the Properties tab in another Zope installation. By that, I mean it does authentication very well. If you click the Properties tab however, you get the traceback (if you're going to try it, please do it on a copy of your installation - I'd hate to think I'd done damage to someones DB!!). cheers tone. -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Need an SQL based auth system that works with Zope 2.2
At 12:43 pm +1200 19/7/00, Graham Chiu wrote: In article v0422081ab59a36ddacad@[128.240.198.13], Tony McDonald [EMAIL PROTECTED] writes Can anyone who's using an SQL based authentication system with Zope 2.2 successfully please let me know which one you used and how you did it? What are the requirements for such a beast? Very simple really. I'd like to use the functionality of UserDB in Zope 2.2. UserDB-1.2 (and 1.3) give me errors when I select the Properties tab (used for the docLogin docLogout screens and SQL methods). This means that USerDBs imported from Old Zopes work fine, but creating new ones is a no-no. I've looked at LoginManager, but can't get my head around it. GUFolder was promising, but I couldn't get it to work. I'm now looking at Shane Hathaways' DatabaseAPI which looks very interesting, but I'll need to spend some time with it.. cheers tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Date time format
At 5:46 pm +0800 19/7/00, [EMAIL PROTECTED] wrote: Hi all, Anyone know if there is any good tutorial for date time format ? Like abstract the day or month or year in a ZopeTime string. as if by magic http://www.zope.org/Members/AlexR/CustomDateFormats hth tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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 2.2.0 and UserDB-1.2.0 conflict
Hi, I've just set up a new 2.2 system and moved my Data.fs file across and started it up. That is, I *haven't* moved all my tar.gz products and rebuilt them. I have built MySQL (ZMySQLDA-1-1-3) , LocalFS-0.9.3 , TinyTableB2, and PythonMethod-0.1.7 (with do_XXX set to '1', ie devil methods) It seems to work ok, but when I try to click 'properties' in a UserDB object from the management screen, I get the following; !-- Error type: KeyError Error value: SQLConnectionIDs -- [snipped] !-- Traceback (innermost last): File /home/zope/Zope/lib/python/ZPublisher/Publish.py, line 222, in publish_module File /home/zope/Zope/lib/python/ZPublisher/Publish.py, line 187, in publish File /home/zope/Zope/lib/python/Zope/__init__.py, line 221, in zpublisher_exception_hook (Object: RoleManager) File /home/zope/Zope/lib/python/ZPublisher/Publish.py, line 171, in publish File /home/zope/Zope/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: manage_properties) File /home/zope/Zope/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: manage_properties) File /home/zope/Zope/lib/python/App/special_dtml.py, line 121, in __call__ (Object: manage_properties) File /home/zope/Zope/lib/python/DocumentTemplate/DT_String.py, line 502, in __call__ (Object: manage_properties) File /home/zope/Zope/lib/python/DocumentTemplate/DT_In.py, line 630, in renderwob (Object: SQLConnectionIDs) KeyError: (see above) -- This is 2.2.0 built from source on Solaris 2.5 and Python 1.5.2 Any thoughts would be mightily appreciated. tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Need an SQL based auth system that works with Zope 2.2
Hi all, I think the time has come to bite the bullet and change our authentication engine to work in line with Zope 2.2 and above. UserDB-1.2 seems to have some problems with it (see my message today), and frankly, I haven't got the time to try and figure out why. Another point against UserDB is that it's not being developed any more. Ah well, it did the job for a long time Can anyone who's using an SQL based authentication system with Zope 2.2 successfully please let me know which one you used and how you did it? ta muchly, tone. -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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 snippet...
Here's a quickie. If you're using MySQL and return integers, you'll see L added to the end of your numbers (it's a Python thing!) Try this dtml-var result fmt="%u" et volia!, no L added to the end of your numbers... Ithangyu. Tone. -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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.org Hidden Stats
Hi all, under /Software this is shown. The machine is running RedHat 6.1. The Zope installation is a CVS checkout with fairly conservative updating. The content is served completely out of the Zope database. Apache is used as the web server in front of Zope.org, using PCGI to integrate with the Zope server. Soon we will migrate to using FastCGI. Can someone please clarify something for me here. (I've been Zoping for 15 months and *still* don't know the correct answer) If you're running Zope from behind Apache/PCGI then you *have* to run Zope single threaded. Am I correct? Therefore, that implies that Zope org is not using ZServer to serve up documents. Still correct? If this is the case then I'm even more impressed, but would like to ask why not use Ansers 'Apache/ZServer HowTo' and get the best of both worlds? TIA Tone. -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Plea: sequence-item and sequence_item in 2.2?
Hi all, Can I make a plea that the .diff patch that Jonothan Farr posted a while back be included into the 2.2 release? http://www.zope.org/Members/jfarr/Patches/dtml-in-sv I believe it would help a lot of newbies and delay the (inevitable :) day when they *really* need to use the _ namespace and python expressions Cheers, Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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.org Hidden Stats
At 10:52 am + 8/6/00, Oleg Broytmann wrote: On Thu, 8 Jun 2000, Tony McDonald wrote: If you're running Zope from behind Apache/PCGI then you *have* to run Zope single threaded. Am I correct? No, you r not! Yoy can run multithreading ZServer and connect Apache to it via PCGI. There are two PCGI servers in Zope - single-threaded and builtin (as a component) in ZServer. Oleg.(All opinions are mine and not of my employer) Thanks for that Oleg, Well you live and learn... To the zope list, I'm going to go really slowly here, as this is something that has been bugging me for yonks! (I have read doc/WEBSERVER.txt ... again and again). 1) Zope + Apache redirected to Zope.cgi with PCGI_PUBLISHER = pcgi/pcgi_publisher.py = single threaded server. No ZServer activity. Uses ZPublisher? 2) Zope + Apache redirected to Zope.cgi with PCGI_PUBLISHER = ZServer/PCGIServer.py = ZServer based multi-threaded server. Implies better throughput. If I'm anywhere near close, can someone please point out any resources that will show me how to get option (2) working? Additionally, can I ask that if (2) *is* correct, then with the 2.2 release another script (w_zserver_pcgi.py ?) be released. cheers, tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] stupid question I guess
At 12:05 am +1000 8/6/00, Andrew Kenneth Milton wrote: +[ Chris Withers ]- | josh on wrote: | can I set a local variable in zope on a dtml page | dtml-var variablename = 1 | | Yup: | | dtml-call "REQUEST.set('variablename',1)" | | Nice syntax, huh? ;-) Tsk tsk, that's global :-) dtml-let variablename=1 ... ... /dtml-let Tsk tsk tsk - it don't work ;) dtml-let variablename="1" ... ... /dtml-let tone.. ------ Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Newbie question: graphics in subdirs
At 11:35 am -0400 7/6/00, Randy Edwards wrote: dtml-var standard_html_header h2dtml-var title_or_id/h2 pThis is the dtml-var id Document./p pNow show a graphic: br dtml-var logo.jpg /p dtml-var standard_html_footer That references an image file in the root directory called logo.jpg. Everything works, it displays fine. However, I want to keep all of my commonly used image files in a subdirectory called /images. So I create a folder called "images", upload another copy of logo.jpg into it, everything's fine. I change the dtml in the "test" document to be "dtml-var /images/logo.jpg". And it doesn't work, giving me an error message of: try dtml-with images dtml-var logo.jpg /dtml-with It can get complex quickly though - I'm sure I remember something on thew Zope list about this, I think it was a word of wisdom from Phil Harris... hth tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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] Really dumb newbie question
At 5:01 pm +0100 23/5/00, Andy Gates wrote: This one is so dumb you'll be laughing, but any help would be greatly appreciated. I need to evaluate an IF. That's all. I have a variable called Action that's a string, and it can be null, "Add", "Update" etc. I try something along the lines of: dtml-if action == "add" blah /dtml-if dtml-if "action == 'add'" blah /dtml-if As an aside, whenever anything is in " .. " - it becomes a Python expression. hth Tone -- Dr Tony McDonald, FMCC, Networked Learning Environments Project http://nle.ncl.ac.uk/ The Medical School, Newcastle University Tel: +44 191 222 5888 Fingerprint: 3450 876D FA41 B926 D3DD F8C3 F2D0 C3B9 8B38 18A2 ___ 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 )