[Zope-Coders] Zope tests: 8 OK
Summary of messages to the zope-tests list. Period Wed Aug 10 11:01:02 2005 UTC to Thu Aug 11 11:01:02 2005 UTC. There were 8 messages: 8 from Zope Unit Tests. Tests passed OK --- Subject: OK : Zope-2_6-branch Python-2.1.3 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:25:59 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002807.html Subject: OK : Zope-2_6-branch Python-2.3.5 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:27:29 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002808.html Subject: OK : Zope-2_7-branch Python-2.3.5 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:28:59 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002809.html Subject: OK : Zope-2_7-branch Python-2.4.1 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:30:29 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002810.html Subject: OK : Zope-2_8-branch Python-2.3.5 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:31:59 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002811.html Subject: OK : Zope-2_8-branch Python-2.4.1 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:33:30 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002812.html Subject: OK : Zope-trunk Python-2.3.5 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:35:00 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002813.html Subject: OK : Zope-trunk Python-2.4.1 : Linux From: Zope Unit Tests Date: Wed Aug 10 23:36:30 EDT 2005 URL: http://mail.zope.org/pipermail/zope-tests/2005-August/002814.html ___ Zope-Coders mailing list Zope-Coders@zope.org http://mail.zope.org/mailman/listinfo/zope-coders
[Zope-Coders] Out for Holidays
Just to let you know: I am off for holiday from August 20th until September 13th...no email, no phone, no Zope during that time :-) Andreas pgp48pNsrfqta.pgp Description: PGP signature ___ Zope-Coders mailing list Zope-Coders@zope.org http://mail.zope.org/mailman/listinfo/zope-coders
[Zope-dev] Re: Catalog and Unicode
Dieter Maurer wrote: Florent Guillaume wrote at 2005-8-9 17:18 +0200: We're seeing problems in one application here due to the catalog and interactions with Unicode. Here's what happens: - an object is indexed with a Unicode title, so in the catalog the metadata tuple has for instance (u'cafe',) - later that title is changed to latin-1, so the new metadata tuple would be ('caf\xe9',) The problem is that Catalog.py has in updateMetadata() the code: if data.get(index, 0) != newDataRecord: data[index] = newDataRecord try: changed = data.get(index, 0) != newDataRecord except UnicodeDecodeError: changed = True if changed: data[index] = newDataRecord Objections ? I fear, you will get similar problems in the indexes. You should avoid mixed unicode/non-unicode in fields or indexes (or the the default encoding appropriately). For indexes I agree, and indeed my example of Title was not ideal. But metadata fields can have nothing to do with indexes... Suppose you're migrating your code from using utf-8 encoded str to unicode. You have no way to recatalog the thing, it will blow in updateMetadata... Florent -- Florent Guillaume, Nuxeo (Paris, France) CTO, Director of RD +33 1 40 33 71 59 http://nuxeo.com [EMAIL PROTECTED] ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-PAS] Cookie Auth Monopolizes Challenge?
Hi Sidnei, I had to deal with this at some point and I wrote a PAS multiplugin that implemented the unauthorized method (forget which interface that belongs to)... here it is along with a helper method to figure out if a request came from a DAV client: security.declarePublic('unauthorized') def unauthorized(self): Override cookieauthplugin unauthorized to deal properly with DAV requests req = self.REQUEST resp = req['RESPONSE'] # If we set the auth cookie before, delete it now. if resp.cookies.has_key(self.cookie_name): del resp.cookies[self.cookie_name] if self.isDAVRequest(req): # DAV clients/EE can't deal with form-based auth, so # we give them a basic auth 401 response code realm = resp.realm if realm: resp.addHeader('WWW-Authenticate', 'basic realm=%s' % realm) m = You are not authorized to access this resource. if resp.debug_mode: if resp._auth: m = m + 'p\nUsername and password are not correct.' else: m = m + 'p\nNo Authorization header found.' resp.setBody(m, is_error=1) resp.setStatus(401) return 1 # Redirect if desired. url = self.getLoginURL() if url is not None: came_from = req.get('came_from', None) if came_from is None: came_from = req.get('URL', '') query = req.get('QUERY_STRING') if query: if not query.startswith('?'): query = '?' + query came_from = came_from + query else: # If came_from contains a value it means the user # must be coming through here a second time # Reasons could be typos when providing credentials # or a redirect loop (see below) req_url = req.get('URL', '') if req_url and req_url == url: # Oops... The login_form cannot be reached by the user - # it might be protected itself due to misconfiguration - # the only sane thing to do is to give up because we are # in an endless redirect loop. return 0 url = url + '?came_from=%s' % quote(came_from) resp.redirect(url, lock=1) return 1 # Could not challenge. return 0 security.declarePublic('isDAVRequest') def isDAVRequest(self, request): method = request.get('REQUEST_METHOD', 'GET') if method in DAV_METHODS: return True if request.maybe_webdav_client and not method in ('GET', 'POST'): return True useragent = request.get_header('User-Agent') or '' for agent in DAV_USERAGENTS: if useragent.find(agent) != -1: return True return False On Thu, 2005-08-11 at 15:46 -0300, Sidnei da Silva wrote: So, leaving other issues aside *wink*, I'm no puzzled by the challenge code in PAS. It looks like there was some attempt at distinguishing challenging by some sort of 'protocol', but it leaves a lot to be desired, or I don't understand how it's supposed to work. The problem I'm facing now is that using the Cookie Auth plugin effectively breaks WebDAV (and possibly FTP and XML-RPC), because as soon as the Cookie Auth plugin is hit on challenge, it does a redirect to the login form. Changing the Cookie Auth to come after Basic Auth doesn't help either, as then instead of a browser client being directed to the login form it gets a basic auth dialog instead. Is it possible that nobody noticed this yet? Or is it just me not getting enough sleep last night? ___ Zope-PAS mailing list Zope-PAS@zope.org http://mail.zope.org/mailman/listinfo/zope-pas
Re: [Zope-PAS] Cookie Auth Monopolizes Challenge?
On Thu, Aug 11, 2005 at 03:18:43PM -0400, Chris McDonough wrote: | Hi Sidnei, | | I had to deal with this at some point and I wrote a PAS multiplugin that | implemented the unauthorized method (forget which interface that | belongs to)... here it is along with a helper method to figure out if a | request came from a DAV client: snip code Yes, that is what I would do too. But isn't it odd that you have to do this in the first place? I would say the challenge method of the PAS user folder is halfway there. In fact is so close I can barely believe it doesn't work. So my question really is: Is this a bug in PAS that it doesn't do this even if it pretends to? Or are people really expected to keep reinventing the wheel? -- Sidnei da Silva Enfold Systems, LLC. http://enfoldsystems.com ___ Zope-PAS mailing list Zope-PAS@zope.org http://mail.zope.org/mailman/listinfo/zope-pas
RE: [Zope-PAS] Cookie Auth Monopolizes Challenge?
[Sid] So, leaving other issues aside *wink*, I'm no puzzled by the challenge code in PAS. It looks like there was some attempt at distinguishing challenging by some sort of 'protocol', but it leaves a lot to be desired, or I don't understand how it's supposed to work. Probably both ;) The discussion on this is a little spread out, but almost all threads at http://mail.zope.org/pipermail/zope-pas/2004-October/thread.html relate to it in some way. The problem I'm facing now is that using the Cookie Auth plugin effectively breaks WebDAV (and possibly FTP and XML-RPC), because as soon as the Cookie Auth plugin is hit on challenge, it does a redirect to the login form. Yeah, that is by design IIUC. The problem was that a cookie auth plugin wants to reponds to an unauthorized exception by doing a redirect, but http auth wants to do it via 401. IIRC, the basic flow was: * via a little magic, PAS would arrange for an Unauthorized exception to call the main PAS 'unauthorized' function. That may be what Chris patched in his previous mail. * PAS would call all challenge plugins in the order they were defined. PAS needs to call *all* plugins - it can not simply stop after it finds a plugin that does something. Consider HTTP basic and NTLM authentication - *both* those plugins must be called, so both the www-authenticate headers appear. However, as soon as the cookie plugin is invoked, which does a redirect, the challenges setup by the other plugins have been lost. Thus, a protocol was invented. The first plugin to set a protocol means that protocol wins. All plugins that use www-authenticate use the same prefix - so once initiated, an Unauthorized challenge will not get trumped by a redirect. Changing the Cookie Auth to come after Basic Auth doesn't help either, as then instead of a browser client being directed to the login form it gets a basic auth dialog instead. Yep - as above, that is by design. Is it possible that nobody noticed this yet? Or is it just me not getting enough sleep last night? It sounds like the problem is that PAS does not have any concept of the source of the request. The existing behaviour seems correct (enough) for the standard case of a web browser hitting the site on a standard HTTP port - but not for the other ways to get at the site. What *might* be possible is something like the following untested patch, adapted from what Chris posted: --- PluggableAuthService.py 27 May 2005 19:10:45 - 1.31 +++ PluggableAuthService.py 12 Aug 2005 01:00:58 - @@ -990,7 +990,13 @@ plugins = self._getOb('plugins') challengers = plugins.listPlugins( IChallengePlugin ) -protocol = None +if self.isDAVRequest(request): +# DAV clients/EE can't deal with form-based auth, so +# we insist on the http protocol +protocol = http +else: +# Other sources get anything that might be configured. +protocol = None for challenger_id, challenger in challengers: challenger_protocol = getattr(challenger, 'protocol', However, I assume the same concerns exist even when the request comes via xmlrpc, ftp, etc. I'm not sure what to do about those cases. Also, the above patch will not work if someone wants something other than http auth on their dav port. eg, consider a site that is configured to not use cookies or http, but their own custom auth scheme, and therefore with its own protocol. The above patch would kill their site as their existing, working plugin would be excluded. It would not be hard to handle that though. Hope that helped a little, Mark ___ Zope-PAS mailing list Zope-PAS@zope.org http://mail.zope.org/mailman/listinfo/zope-pas
Re: [Zope] BTree Folders questions
I am using CMF 1.5.2 and Zope 2.8.0 - will upgrading again this week to 1.5.3 and 2.8.1 I removed my BTreeFolder2 product as it was indicating it was duplicated product in my event log after my recent upgrade - so it appears to have become part of the distribution. It is part of 2.8, yes, so you will not need to install BTreeFolder2 separately in that case (you did not mention version numbers in your original mailing). I did not really understand the difference between a BTreeFolder2 and a CMFBTreeFolder since CMFBTreeFolder did not appear as content even though it is displayed as an option in Core Content in ZMI. Content type registration for the ZMI and for CMF are two different things. An item showing up in the ZMI does not mean it exists in the types tool. A CMFBTreeFolder is just a BTreeFolder2 with all the necessary trimmings so it plays nice with CMF. Portal buildout upon instantiation and types creation is handled through CMFSetup XML-based profiles. There is no way to express If product A is installed, install type B. So for CMF 1.5, which can be run on Zope 2.7 and 2.8, you will have to do this step manually, tough luck, nothing you can do about it. In CMF-HEAD, which depends on Zope 2.8 and thus guarantees the availability of BTreeFolder2, it is an oversight that CMFBTreeFolder is not one of the automatically installed types upon portal instantiation. I filed a collector issue and will look at it over the next couple days: http://www.zope.org/Collectors/CMF/371 jens ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Accessing Zope site through network
Hello, I am very new to Zope. I managed to install zope in my machine. Now I am not able to access this site through a network. It is giving connection refused error. Please tell me what to do. Any pointers will be greatly appreciated. Thanks, Saura. ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Accessing Zope site through network
--On 11. August 2005 13:31:26 +0530 Saura Ramachandran [EMAIL PROTECTED] wrote: Hello, I am very new to Zope. I managed to install zope in my machine. Now I am not able to access this site through a network. It is giving connection refused error. Please tell me what to do. Any pointers will be greatly appreciated. Thanks, Saura. Check the ip-address settings in etc/zope.conf. -aj pgp4ZT3Ewu3wP.pgp Description: PGP signature ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Aquisition
Hi All, Sorry for long message. I have a simple Zope product which is an ObjectManager descendant and contains a database connection and a ZSQL method. It creates these objects during its initialisation. app.inventory Inventory instance at b7300f20 app.inventory['db-connection'] Connection instance at b724a980 app.inventory.list SQL instance at b724a8f0 Everything is OK except one thing. A problem appears when I go to the manage_main page of the ZSQL method. It can't find any database connection using the SQLConnectionsIDs function from the ${ZOPE_HOME}/lib/python/Products/ZSQLMethods/SQL.py module. The function is called from ${ZOPE_HOME}/lib/python/Products/ZSQLMethods/dtml/edit.dtml To investigate the problem I have added some debugging output statements to this function: def SQLConnectionIDs(self): Find SQL database connections in the current folder and above This function return a list of ids. ids={} have_id=ids.has_key StringType=type('') LOG('ZSQL', INFO, 'self.aq_chain: %s' % self.aq_chain) LOG('ZSQL', INFO, 'self.id: %s' % self.id) while self is not None: if hasattr(self, 'objectValues'): for o in self.objectValues(): try: LOG('ZSQL', INFO, 'o.id: %s' % (o.id())) except: LOG('ZSQL', INFO, 'o.id: %s' % (o.id)) if (hasattr(o,'_isAnSQLConnection') and o._isAnSQLConnection and hasattr(o,'id')): id=o.id if type(id) is not StringType: id=id() if not have_id(id): if hasattr(o,'title_and_id'): o=o.title_and_id() else: o=id ids[id]=id if hasattr(self, 'aq_parent'): self=self.aq_parent else: self=None ids=[ (item[1], item[0]) for item in ids.items() ] ids.sort() LOG('ZSQL', INFO, 'ids: %s' % (ids)) return ids The output shows that SQLConnectionsIDs is called in wrong context. 2005-08-11T10:57:31 INFO(0) ZSQL self.aq_chain: [Application instance at b73483b0, RequestContainer instance at b767ccb0] -- 2005-08-11T10:57:31 INFO(0) ZSQL self.id: bound method Application.id of Application instance at b73483b0 -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: acl_users -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: Control_Panel -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: temp_folder -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: session_data_manager -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: browser_id_manager -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: error_log -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: standard_error_message -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: standard_template.pt -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: index_html -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: standard_html_header -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: standard_html_footer -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: virtual_hosting -- 2005-08-11T10:57:31 INFO(0) ZSQL o.id: inventory -- 2005-08-11T10:57:31 INFO(0) ZSQL ids: [] Any help is greatly appreciated. Thanks, -- Timur Izhbulatov OILspace, 26 Leninskaya sloboda, bld. 2, 2nd floor, 115280 Moscow, Russia P:+7 095 105 7245 + ext.205 F:+7 095 105 7246 E:[EMAIL PROTECTED] Building Successful Supply Chains - One Solution At A Time. www.oilspace.com ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: ZDatabaseTool - does this still exist?
I'm looking for a phpmyadmin type tool for managing the ZODB.The control panel view in zope doesn't let you do anything apart from the basics. Obviously I could use python to access the db but looking for something easier. On 8/10/05, Dieter Maurer [EMAIL PROTECTED] wrote: michael nt milne wrote at 2005-8-8 17:49 +0100: ... Are there any other database manager tools for the ZODB? To do what? There is a Database Manager in the Control_Panel -- but (of course), the ZODB is very easy to manage. That's why the Manager is so simple... -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: ZDatabaseTool - does this still exist?
On 11 Aug 2005, at 10:31, michael nt milne wrote: I'm looking for a phpmyadmin type tool for managing the ZODB.The control panel view in zope doesn't let you do anything apart from the basics. Obviously I could use python to access the db but looking for something easier. What exactly do you want to do that zope doesn't let you do? The ZODB is not a relational database, in case that isn't already clear. You cannot compare the tasks you can do using tools like phpmyadmin with tasks that make sense for the ZODB. jens ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] BTree Folders questions
This is really super, Jens! This is what I was hoping. Many thanks for your help and suggestions. Regards, David In CMF-HEAD, which depends on Zope 2.8 and thus guarantees the availability of BTreeFolder2, it is an oversight that CMFBTreeFolder is not one of the automatically installed types upon portal instantiation. I filed a collector issue and will look at it over the next couple days: http://www.zope.org/Collectors/CMF/371 ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] bad ZCatalog behavior
On Wednesday 10 August 2005 04:32 pm, Dieter Maurer wrote: Andy Altepeter wrote at 2005-8-8 08:15 -0500: There seems to be a problem with my ZCatalog, and it seems to be getting worse as time goes by. ... Module ZODB.Connection, line 562, in setstate Module ZODB.Connection, line 601, in _set_ghost_state AttributeError: 'str' object has no attribute 'append' In fact, this looks like a broken pickle in your ZODB storage (and not like a ZCatalog problem). I think I've fixed this issue, but for future reference, is there any way to remove a broken pickle? ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: ZDatabaseTool - does this still exist?
Hi I've already made it clear in this thread exactly what I want to do! It doesn't to be a relational db to be able to easily add fields.The database browser tools in the ZMI are ok but basic. On 8/11/05, Jens Vagelpohl [EMAIL PROTECTED] wrote: On 11 Aug 2005, at 10:31, michael nt milne wrote: I'm looking for a phpmyadmin type tool for managing the ZODB.The control panel view in zope doesn't let you do anything apart from the basics. Obviously I could use python to access the db but looking for something easier. What exactly do you want to do that zope doesn't let you do? The ZODB is not a relational database, in case that isn't already clear. You cannot compare the tasks you can do using tools like phpmyadmin with tasks that make sense for the ZODB. jens ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev ) ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: ZDatabaseTool - does this still exist?
On 11 Aug 2005, at 15:01, michael nt milne wrote: Hi I've already made it clear in this thread exactly what I want to do! It doesn't to be a relational db to be able to easily add fields.The database browser tools in the ZMI are ok but basic. No you haven't. First of all, the application you point to at the beginning of the thread is a tool for managing a relational database, but your wording sounds like you assume it is a tool for managing the ZODB. That tool has exactly zilch to do with the ZODB, apart from the fact that it runs on Zope. The ZODB is not a relational database. You don't add fields. You add objects and manipulate them. The ZMI and code you write are all you need. jens ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: ZDatabaseTool - does this still exist?
Hi Michael, michael nt milne wrote: I've already made it clear in this thread exactly what I want to do! It doesn't to be a relational db to be able to easily add fields.The database browser tools in the ZMI are ok but basic. I'm as puzzled as other readers, but now you have said add fields, I'm even more puzzled! What do you want to add fields to? Do you mean to add properties to an object? What sort of object? If so, arguably the whole ZMI is your database tool, and the database tools elements are just some maintenance utilities... N.B. Am not trying to needle you - am trying to get some traction on your problem! :-) -- Regards, PhilK Email: [EMAIL PROTECTED] PGP Public key: http://www.xfr.co.uk Voicemail Facsimile: 07092 070518 You'll find that one part's sweet and one part's tart: say where the sweetness and the sourness start. - Tony Harrison ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: ZDatabaseTool - does this still exist?
Whether you call them objects or fields it's still clear what I want to do and there's no easy way to do it. Surprised someone hasn't developed a product tn do this. I'm looking at CMFMember and perhaps it will fit the bill. On 8/11/05, Jens Vagelpohl [EMAIL PROTECTED] wrote: On 11 Aug 2005, at 15:01, michael nt milne wrote: Hi I've already made it clear in this thread exactly what I want to do! It doesn't to be a relational db to be able to easily add fields.The database browser tools in the ZMI are ok but basic. No you haven't. First of all, the application you point to at the beginning of the thread is a tool for managing a relational database, but your wording sounds like you assume it is a tool for managing the ZODB. That tool has exactly zilch to do with the ZODB, apart from the fact that it runs on Zope. The ZODB is not a relational database. You don't add fields. You add objects and manipulate them. The ZMI and code you write are all you need. jens ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev ) ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: ZDatabaseTool - does this still exist?
On 11 Aug 2005, at 15:15, michael nt milne wrote: Whether you call them objects or fields it's still clear what I want to do and there's no easy way to do it. Surprised someone hasn't developed a product tn do this. I'm looking at CMFMember and perhaps it will fit the bill. Maybe I'm too dense, but fields are not objects. If you expect help from a group you should try to utilize a terminology the group shares. And if your description cannot be understood you will get blank stares, if anything. jens ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: ZDatabaseTool - does this still exist?
Hi Michael, michael nt milne wrote: Whether you call them objects or fields it's still clear what I want to do and there's no easy way to do it. Surprised someone hasn't developed a product tn do this. I'm looking at CMFMember and perhaps it will fit the bill. There are a bunch of things to say here - first of all, it may be clear to /you/, but it's not clear to /us/! You do need to respect the fact that others may use different terms (or consider different things implicit), to communicate usefully. I've become frustrated myself whilst getting to grips (to the extent that I have!) with these tools, but it doesn't help...what helps is chipping away at it with a positive attitude until you arrive at some common ground. Now you mention CMFMember, it seems that you want to add fields (attributes?) to the Member record (object?). If you think of the ZODB as a database, and Zope as an application server, you are now getting into the specifics of an /application/ (CMF/Plone), and in that context your needs are perhaps more complex than you think: You need to store your data, yes, but you also need to integrate the capture and updating of that data into an existing application. So you are not really asking for a database management tool but a product which does that and more besides - which goes to show that the terminology /is/ important! -- Regards, PhilK Email: [EMAIL PROTECTED] PGP Public key: http://www.xfr.co.uk Voicemail Facsimile: 07092 070518 You'll find that one part's sweet and one part's tart: say where the sweetness and the sourness start. - Tony Harrison ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] The Login Blues
Hi, All- I have the login blues. My company site allows anonymous visitors to enter a user login id and password, with the Role 'CoPersonnel'. It then allows them to create a project page and their project info... All is well and good until later, when they login to edit their page. It works, BUT it gives them permission to edit anyone else's page that has the Role 'CoPersonnel'! It also seems that while the first login is successful, they retain an 'Anonymous User' role. These two reside in a Projects folder: login_html, acl_users. The individual projects are located in a Projects subfolder: projects_current. Do the acl_users and login_html file have to reside in the individual project folder? (BTW, I got the code from The Book of Zope.) Any help greatly appreciated, this seems weird and I'm baffled. Thanks! Kevin ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] input type=image name=method:action and ZPublisher?
hi all! i read something about using image submit buttons with zope here: http://www.dieter.handshake.de/pyprojects/zope/#bct_sec_6.13 there's a patch for zope 2.5's zpublisher, quite old :/ so i patched ZPublisher.py by hand, anybody interested in the patch against zope 2.8.0? (i'll upgrade to 2.8.1 anytime soon, but i guess that changes to ZPublisher between 2.8.0 and 2.8.1 should be nonexistant) regards, juergen herrmann ___ XLhost.de - eXperts in Linux hosting Jürgen Herrmann Bruderwöhrdstraße 15b, DE-93051 Regensburg Fon: +49 (0)700 XLHOSTDE [0700 95467833] Fax: +49 (0)721 151 463027 WEB: http://www.XLhost.de ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: input type=image name=method:action and ZPublisher?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Jürgen Herrmann wrote: hi all! i read something about using image submit buttons with zope here: http://www.dieter.handshake.de/pyprojects/zope/#bct_sec_6.13 there's a patch for zope 2.5's zpublisher, quite old :/ so i patched ZPublisher.py by hand, anybody interested in the patch against zope 2.8.0? (i'll upgrade to 2.8.1 anytime soon, but i guess that changes to ZPublisher between 2.8.0 and 2.8.1 should be nonexistant) I think such a patch would be fine. Please submit it as feature+fix to the collector: http://www.zope.org/collectors/Zope Tres. - -- === Tres Seaver +1 202-558-7113 [EMAIL PROTECTED] Palladion Software Excellence by Designhttp://palladion.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.5 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFC+2u/+gerLs4ltQ4RAintAJwNZKP64msSjq73pSanIdexA0hixwCgv8Nb VJPuuxpN+EAql6RHU2ur5fg= =6W/9 -END PGP SIGNATURE- ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Context - how can I be here when I'm there
Hello all, First post. I've read (past tense) tfm, but still don't know quite how to do this. I'm writing a Python script called by a zpt page. How can I obtain the resource/object which was first called by the visitor to the site, from the python script. I've tried context.PUBLISHED , but that is not quite what I want, as it gives more of a url style. I'm tring to get something that I can compare to an objectValues() list. I had two ideas already, one was to call back to zpt and then do a comparison to /here, the other was to pass /here from my zpt page to the Python script. I think either of those might work, but would like to know if there is a way to access the /here from Python? Chris Matheson ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Context - how can I be here when I'm there
--On 11. August 2005 11:42:05 -0400 Chris Matheson [EMAIL PROTECTED] wrote: Hello all, First post. I've read (past tense) tfm, but still don't know quite how to do this. I'm writing a Python script called by a zpt page. How can I obtain the resource/object which was first called by the visitor to the site, from the python script. I've tried context.PUBLISHED , but that is not quite what I want, as it gives more of a url style. I'm tring to get something that I can compare to an objectValues() list. 'context' - as the name says - is the current object your dealing with. If you call TTW /path/to/x/y/z/your_zpt then 'context' is the object behind the URL /path/to/x/y/z -aj pgpB4fX9AZPPz.pgp Description: PGP signature ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] REQUEST.setHeader doesn't seem to work?
Hi, I have a dtml file on FSDV which should return a file in text/plain format. The dtml method starts with: dtml-call expr=RESPONSE.setHeader('content-type', 'text/plain') ... some content ... However, when I use 'curl -I' to check which Content-Type header is returned, I find it is still 'text/html', despite the call to setHeader. Where could the problem lie? I am using Zope 2.7.6, with Apache configured as frontend (with rewrite enabled). Could it be caused by Apache? -- Hong Yuan 大管家网上建材超市 www.homemaster.cn ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] bad ZCatalog behavior
Andy Altepeter wrote at 2005-8-11 07:22 -0500: ... In fact, this looks like a broken pickle in your ZODB storage (and not like a ZCatalog problem). I think I've fixed this issue, but for future reference, is there any way to remove a broken pickle? No, because there should be no broken pickle in the first place... ...and because the problem did not yet occured often enough... -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: ZDatabaseTool - does this still exist?
michael nt milne wrote at 2005-8-11 05:31 -0400: I'm looking for a phpmyadmin type tool for managing the ZODB.The control panel view in zope doesn't let you do anything apart from the basics. Obviously I could use python to access the db but looking for something easier. Then again my question: what non basic management tasks do you want to do with the ZODB? Keep in mind, that the ZODB is not a relational database system but an object oriented one. Its model is much more general as relations of elementary fields. Therefore, it is much more difficult to standardize management. -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Aquisition
Timur Izhbulatov wrote at 2005-8-11 12:16 +0400: ... I have a simple Zope product which is an ObjectManager descendant and contains a database connection and a ZSQL method. It creates these objects during its initialisation. app.inventory Inventory instance at b7300f20 app.inventory['db-connection'] Connection instance at b724a980 app.inventory.list SQL instance at b724a8f0 Everything is OK except one thing. A problem appears when I go to the manage_main page of the ZSQL method. It can't find any database connection using the SQLConnectionsIDs function from the ${ZOPE_HOME}/lib/python/Products/ZSQLMethods/SQL.py module. The code of SQLConnectionIDs looks like this: ... for o in self.objectValues(): if (hasattr(o,'_isAnSQLConnection') and o._isAnSQLConnection and hasattr(o,'id')): Thus, a candidate SQLConnection must have an id. Now, when you create an object programmatically, it is quite easy to forget to give it an id (specifying the id in _setObject is not enough; the object itself must contain the id redundantly). -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] The Login Blues
Kevin Jones wrote at 2005-8-11 08:38 -0600: ... My company site allows anonymous visitors to enter a user login id and password, with the Role 'CoPersonnel'. It then allows them to create a project page and their project info... All is well and good until later, when they login to edit their page. It works, BUT it gives them permission to edit anyone else's page that has the Role 'CoPersonnel'! It also seems that while the first login is successful, they retain an 'Anonymous User' role. These two reside in a Projects folder: login_html, acl_users. The individual projects are located in a Projects subfolder: projects_current. Do the acl_users and login_html file have to reside in the individual project folder? (BTW, I got the code from The Book of Zope.) There are global and local roles. A global role is assigned to user globally. It applies the the complete subhierarchy governed by the user folder which defined the user. The subhierarchy governed by a user folder is the one whose root contains the user folder. If this does not give you what you need, you have two options: * move the acl_users down (such that it governs a smaller subhierarchy) * use local roles instead of global ones. -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: ZDatabaseTool - does this still exist?
michael nt milne wrote at 2005-8-11 10:01 -0400: It doesn't to be a relational db to be able to easily add fields There are no tables to add fields to. As someone else already pointed out: Zope objects often use so called properties as field emulation. Unlike for a relational database where you specify the fields of a table (and all rows inherit these fields), properties are on individual objects (which are somehow like rows). Zope has a feature where you can define properties not for individual objects but for whole collections of them: ZClasses. Adding properties to a property sheet of a ZClass ensures that all instances of the class have these properties (with the default value defined by the class). -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] ZODB BTrees File Storage error on start up
David Pratt wrote at 2005-8-10 22:07 -0300: Hi Dieter. It is rather strange for sure. The warning has appeared over the past couple of days. First day I removed what I thought might be a bad CMFBTree folder since it was last thing I remember working with from previous night to do with BTrees. Then it appeared again - first restart of the day - it never appeared again that day even after a number of restarts. Received the error again this morning - first restart of day. This time cleared the Data.fs.index and restarted. Again it did not appear again all day after a number of restarts. It almost makes me wonder if it is somehow related to automated backup since it appears consistently on the first restart of the day. Can this make any sense? No, it does not But nevertheless, you see what you see? __basicnew__ is a class method. It must be there independent on the concrete object. If it were not there, then whether or not you see the error may depend on whether or not the index file is present (you should not see it when there is no index file; you may, if there is). But, it should be there. If not, then the shared object BTrees/_fsBTree.{so,pyd} must have been badly executed (maybe because it is corrupt) -- but it would be surprising that this shows up in such a harmless way (one would instead expect a memory violation or bad opcode or something really nasty). -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Context - how can I be here when I'm there
Chris Matheson wrote at 2005-8-11 11:42 -0400: ... First post. I've read (past tense) tfm, but still don't know quite how to do this. Please, be very precise when you ask questions. ... I've tried context.PUBLISHED I doubt that you did that -- as it should be context.REQUEST.PUBLISHED. , but that is not quite what I want, as it gives more of a url style What does gives more of a url style mean? I'm tring to get something that I can compare to an objectValues() list. Another vague description: What should compare to an objectValues() list mean? Comparison operators are usually =, !=, , =, =, . I doubt you mean one of them... I had two ideas already, one was to call back to zpt and then do a comparison to /here, the other was to pass /here from my zpt page to the Python script. I think either of those might work, but would like to know if there is a way to access the /here from Python? The most natural way would be to pass it into your Python Script. In special cases (when you are interested in the objects visited during URL traversal), then the following request variables may help: PUBLISHED the (final) object located via URL traversal PARENTS a list of objects visited during URL traversal in reverse order and without the final object (which is in PUBLISHED). This means PARENTS[0] is the second to last object visited during URL traversal, PARENTS[-1] is the root object. -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: ZDatabaseTool - does this still exist?
Thanks for the help here. Yes I do want to capture extra information about a user who is registering with a site. First name, last name and company, phone number etc. And then to be able to to display this in a membership display tool. Just about to check out CMFMember. Hope it works ok on 2.05.On 8/11/05, Dieter Maurer [EMAIL PROTECTED] wrote: michael nt milne wrote at 2005-8-11 10:01 -0400:It doesn't to be a relational db to be able to easily add fieldsThere are no tables to add fields to.As someone else already pointed out:Zope objects often use so called properties as field emulation.Unlike for a relational database where youspecify the fields of a table (and all rows inherit these fields),properties are on individual objects (which are somehow like rows). Zope has a feature where you can define properties notfor individual objects but for whole collections of them:ZClasses. Adding properties to a property sheet ofa ZClass ensures that all instances of the class have these properties (with the default value defined by the class).--Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: ZDatabaseTool - does this still exist?
PS I also subscribed to the collective-CMFMember list and got some help there: which I include below... Alec Mitchell [EMAIL PROTECTED] to collective-cmf. More options3:39 pm (6 hours ago) On Thursday 11 August 2005 06:19 am, michael nt milne wrote: I've tried a few products in 2.1 -CMFQuestionnaire for example and it produced errors.Also CMFNewsletter didn't work. I'd rather wait until the bugs are ironed out.These are probably not bugs in CMFPlone, but simply products which haven't caught up to the few major changes in 2.1. Unfortunately, they are very unlikely to catch up if you don't report the errors you found with full tracebacks to the authors of those products. It may be helpful to additionally post them to the plone bug tracker as it may point out incompatibilities of which we were unaware. Can CMFMember add totally new fields to registration? What v of plone do you have it working with?CMFMember 1.0 was designed for plone 2.0, and should work. It will allow you to add new fields to the registration by subclassing the Member type and adding new fields to the schema. For greater details you may want to look at Rob's Samplex product and tutorial: http://svn.plone.org/view/collective/Samplex/trunk/docs/SamplexTutorial.stx CMFMember 1.1 (currently unreleased) is the ideal version for working with plone 2.1 (which as Martin says is much improved), but may not at present work with plone 2.0.On 8/11/05, michael nt milne [EMAIL PROTECTED] wrote: Thanks for the help here. Yes I do want to capture extra information about a user who is registering with a site. First name, last name and company, phone number etc. And then to be able to to display this in a membership display tool. Just about to check out CMFMember. Hope it works ok on 2.05.On 8/11/05, Dieter Maurer [EMAIL PROTECTED] wrote: michael nt milne wrote at 2005-8-11 10:01 -0400:It doesn't to be a relational db to be able to easily add fieldsThere are no tables to add fields to.As someone else already pointed out:Zope objects often use so called properties as field emulation.Unlike for a relational database where youspecify the fields of a table (and all rows inherit these fields),properties are on individual objects (which are somehow like rows). Zope has a feature where you can define properties notfor individual objects but for whole collections of them:ZClasses. Adding properties to a property sheet ofa ZClass ensures that all instances of the class have these properties (with the default value defined by the class).--Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: localhost:8080 not found on windows
Thanks for the help here. Much appreciated. Still not running but getting there.On 8/10/05, Philip Kilner [EMAIL PROTECTED] wrote:Hi Michael,michael nt milne wrote: I've even tried using the machine's local IP but that doesn't work in the same way that localhost doesn't. I've installed Apache now as well so as to route requests through that to Zope. I'm going to be using the same IP address that the webmail exchange service uses. It uses mail.sbcscot.com http://mail.sbcscot.com so I guess if I have http://plone.sbcscot.com then I could tell Apache to route that to Zope? How would I tell IIS or ISA not to listen to that domain? Meanwhile I noticed on installing Apache that it failed to bind to port 80! Well, you /can't/ tell IIS not to listen on that domain - it listensat a port on an IP. The host header translation for virtual hosting canonly happen if it can field the request in the first place ( e.g. ifthere are no clashes at that port/IP). If you have a single interface,you are stuck using non-standard ports to avoid clashes. Apache will notbind to port 80 either because you have http://mail.sbcscot.com bound tothe same port IP, or because of the socket pooling nonsense if youhave a separate IP.I would not touch ISA with a barge-pole if I had a choice - but assuming you are on SBS and are/could be behind a separate firewall, I would: -- Leave Zope/Plone on 8080- Change the port for webmail (and any other IIS stuff) to a differenthigh port (e.g. 9080?), so it is no longer clashing with Apache. - Disable socket pooling. spit!- Run Apache on port 80- Use virtual hosts with rewrite rules in the Apache .conf to passrequests to your Zope and Webmail sites.You could probably do something similar with ISA server (I do, but not on the same box as IIS and Zope/Plone), but I'd rather not even thinkabout that...--Regards,PhilKEmail: [EMAIL PROTECTED]PGP Public key: http://www.xfr.co.ukVoicemail Facsimile: 07092 070518You'll find that one part's sweet and one part's tart:say where the sweetness and the sourness start.- Tony Harrison ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Zope on Solaris
From what I can determine Zope does or should run on Solaris on a Sun server. Is that assumption correct. Can anybody point to any resources or have any comments/opinions-- like what versions of Zope/Solaris seem to be compatible, any special issues/requirements? ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Pierugo Massolo/IT/ITC/ALSTOM is out of the office.
I will be out of the office starting 11/08/2005 and will not return until 29/08/2005. I will respond to your message when I return. ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: Zope on Solaris
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Brian Sullivan wrote: From what I can determine Zope does or should run on Solaris on a Sun server. Is that assumption correct. Can anybody point to any resources or have any comments/opinions-- like what versions of Zope/Solaris seem to be compatible, any special issues/requirements? Except for the fact that it will seem dog slow, Zope runs fine on Solaris. The major issue seems to be that the threading model in the Solaris libc is especially punitive for long-running, multi-threaded Python applications. I would recommend running multiple appserver processes, each with a single worker thread, rather than trying to run a truly multi-threaded appserver; you will then need to load balance them (e.g., with Pound). Tres. - -- === Tres Seaver +1 202-558-7113 [EMAIL PROTECTED] Palladion Software Excellence by Designhttp://palladion.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.5 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFC+9nk+gerLs4ltQ4RAhL1AKC+8Rhv2qz9r7xliS/dwXuCJwXW0gCeL33h nujTWQAHRXB74pOMFej+zuM= =nCbx -END PGP SIGNATURE- ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: Zope on Solaris
From what I can determine Zope does or should run on Solaris on a Sun server. Is that assumption correct. Can anybody point to any resources or have any comments/opinions-- like what versions of Zope/Solaris seem to be compatible, any special issues/requirements? Except for the fact that it will seem dog slow, Zope runs fine on Solaris. The major issue seems to be that the threading model in the Solaris libc is especially punitive for long-running, multi-threaded Python applications. Dog slow as compared to what? I would prefer to do the absolute minimum in terms of tuning. Most of my experience with Zope and otherwise is with Windows. Can I potentially get by just installing and running? How would it run that way on a current Solaris server with appropriate memory compared to say running on a P4 3meg Win2003 machine with appropriate memory. I would recommend running multiple appserver processes, each with a single worker thread, rather than trying to run a truly multi-threaded appserver; you will then need to load balance them (e.g., with Pound). I am not exactly sure what you are saying -- is this something to be done at the Zope end or with Solaris knowledge or both? ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: Zope on Solaris
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Brian Sullivan wrote: From what I can determine Zope does or should run on Solaris on a Sun server. Is that assumption correct. Can anybody point to any resources or have any comments/opinions-- like what versions of Zope/Solaris seem to be compatible, any special issues/requirements? Except for the fact that it will seem dog slow, Zope runs fine on Solaris. The major issue seems to be that the threading model in the Solaris libc is especially punitive for long-running, multi-threaded Python applications. Dog slow as compared to what? As compared to commodity server-class Linux/Intel hardware (which will cost you around 1/4 to 1/3 what the equivalent Solaris rig does). I would prefer to do the absolute minimum in terms of tuning. Most of my experience with Zope and otherwise is with Windows. Can I potentially get by just installing and running? How would it run that way on a current Solaris server with appropriate memory compared to say running on a P4 3meg Win2003 machine with appropriate memory. Let's put it this way: even if you get paid in cheese sandwiches, it will be cheaper to buy a 1U lintel box to run the server than the time you spend trying to figure out why it is so slow on Solaris, let alone the time you spend trying to remediate it. Unless somebody has a gun to your head, you should not run Zope on Solaris in *any* performance-critical environment. FWIW, I offered once to *buy* the 1U for the client if it didn't smoke their big-iron Solaris box; they declined to take me up on it (but still went ahead and used Solaris, because that was what made the SAs feel warm-n-fuzzy). Matt Hamilton's report is still probably your best resource if you find yourself with the gun to your head: http://www.zope.org/Members/glpb/solaris Tres. - -- === Tres Seaver +1 202-558-7113 [EMAIL PROTECTED] Palladion Software Excellence by Designhttp://palladion.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.5 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFC++aC+gerLs4ltQ4RAkbfAJ43vVB+icfa33K0hMBPQl3vSjkgcgCcCDzc hBc03nMYUYJp+iHDxpodj+s= =NYLg -END PGP SIGNATURE- ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: Zope on Solaris
Dog slow as compared to what? As compared to commodity server-class Linux/Intel hardware (which will cost you around 1/4 to 1/3 what the equivalent Solaris rig does). I would prefer to do the absolute minimum in terms of tuning. Most of my experience with Zope and otherwise is with Windows. Can I potentially get by just installing and running? How would it run that way on a current Solaris server with appropriate memory compared to say running on a P4 3meg Win2003 machine with appropriate memory. Let's put it this way: even if you get paid in cheese sandwiches, it will be cheaper to buy a 1U lintel box to run the server than the time you spend trying to figure out why it is so slow on Solaris, let alone the time you spend trying to remediate it. Unless somebody has a gun to your head, you should not run Zope on Solaris in *any* performance-critical environment. FWIW, I offered once to *buy* the 1U for the client if it didn't smoke their big-iron Solaris box; they declined to take me up on it (but still went ahead and used Solaris, because that was what made the SAs feel warm-n-fuzzy). Matt Hamilton's report is still probably your best resource if you find yourself with the gun to your head: http://www.zope.org/Members/glpb/solaris OK -- I get the picture I think ;-) I will try to dodge the Solaris bullet if I can. ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Zope on Solaris
--On 11. August 2005 17:44:00 -0400 Brian Sullivan [EMAIL PROTECTED] wrote: From what I can determine Zope does or should run on Solaris on a Sun server. Is that assumption correct. Can anybody point to any resources or have any comments/opinions-- like what versions of Zope/Solaris seem to be compatible, any special issues/requirements? As Tres said, Zope runs out-of-the-box on Solaris...f*cking slow...but it runs. Sun hardware is nice and stable but this is maybe the only reason to run Zope on Solaris (but only on the ZEO server side). Sun hardware is always outperformed by decent PC hardware for ZEO clients. -aj pgpVyLHaGZmE4.pgp Description: PGP signature ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: ZDatabaseTool - does this still exist?
--On 11. August 2005 20:30:37 +0200 Dieter Maurer [EMAIL PROTECTED] wrote: Zope has a feature where you can define properties not for individual objects but for whole collections of them: ZClasses. Adding properties to a property sheet of a ZClass ensures that all instances of the class have these properties (with the default value defined by the class). But don't consider using ZClasses in any way...they are an ancient culprit of Zope. DON'T USE. -aj pgpf6Jrc5ceYV.pgp Description: PGP signature ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope-DB] Zope/Plone, interbase, and blob fields
Thanks again for your post, and my sincere apologies for the delay in writing (I've been off and then had to sort out some other stuff which required all of my limited attention!). Thanks also to the off-list help from David Rushby. His advice which sort of worked was basically: Using a database interface that allows you to take advantage of prepared statements and bound parameters, as in: cur.execute(update table_1 set blob_field_1 = ? where other_field_1 = ?, ('blob string value', 'other field value')) This was a slightly different python syntax to that which I was using, and seems to work - but only when using it straight from Python. I can run this absolutely fine (even using gvib!) from the python instance in the Plone installation (Plone\Python\python.exe). There are absolutely no errors, and it updates the field. However, copying the function almost exactly (just inserting a self parameter before the two notes/key parameters .. or even trying it without) does not work. When I call this function, Plone freezes - no errors, nothing, just everything freezes up (there's nothing I can see in the log files apart from it calling the page). I don't know if this is of any significance, but when this happens, for any calls to a page served by Plone, the browser tries to open the page, but nothing happens, no page not found errors, etc, it just keeps trying. Once Plone has been stopped, then the page not found appears. I doubt its of any use, but you can't have too much info!! Anyway, the function in the external method is: def updateEntityNotes(self,notes,entKey): try: dbCon = gvib.connect(theDB, userName, userPass) cur=dbCon.cursor() cur.execute(UPDATE ENTITY SET EN_NOTES=? WHERE EN_KEY=?,(notes,int(entKey))) dbCon.commit() return 'ok' except: return 'bError:/b Sorry, your request could not be processed correctly.br '+str(traceback.format_exception(sys.exc_type, sys.exc_value, sys.exc_traceback)) And it is called with a dtml-let call (so the result can be used): dtml-let err=updateEntityNotes(theNotes,theKey) (theNotes and theKey have already been subject to calls to be str() and int() respectively). I just tested the interface to this from Plone, removing any database access at all, and just returning a random statement, and it works fine. So Plone is accessing the external method, there are no imported functions used that aren't used in other external methods, so it just seems to be executing the cur.execute() statement. Without the dbCon.commit(), Plone still crashes. Can anyone tell me why the actual python instance that came with Plone can do this fine, but Plone itself can't? Kind regards, and thanks once again to everyone who has helped me. Ashley - Original Message - From: bobb [EMAIL PROTECTED] To: Ashley Lloyd [EMAIL PROTECTED]; zope-db@zope.org Sent: Friday, August 05, 2005 6:39 PM Subject: Re: [Zope-DB] Zope/Plone, interbase, and blob fields - Original Message - From: Ashley Lloyd [EMAIL PROTECTED] To: zope-db@zope.org Sent: Friday, August 05, 2005 6:55 AM Subject: [Zope-DB] Zope/Plone, interbase, and blob fields Apologies if this appears twice - I initially sent from the wrong address!! Hi, I've been having trouble updating BLOB (subtype text) fields from Zope. I've a table with several fields, one of which is a blob. Creating a record works fine, but when I attempt to update a record, I get an error. Initially I used gvib, but recently (thanks to a lot of help from another list) I changed to kinterbasdbDA, and I still get errors. The errors I get are as follows: Error Type ProgrammingError Error Value (-413, 'execute.isc_dsql_execute: conversion error from string BLOB. ') Error Trace Traceback (most recent call last): File C:\Program Files\ESOPPlone\Zope\lib\python\DocumentTemplate\DT_Try.py, line 149, in render_try_except result = render_blocks(self.section, md) File C:\Program Files\ESOPPlone\Zope\lib\python\DocumentTemplate\DT_Util.py, line 201, in eval return eval(code, d) File , line 2, in f File C:\Program Files\ESOPPlone\Zope\lib\python\Shared\DC\ZRDB\DA.py, line 428, in __call__ else: result=DB__.query(query, self.max_rows_) File C:\Program Files\ESOPPlone\Zope\lib\python\Products\kinterbasdbDA\db.py, line 198, in query self.cursor.execute(src) File C:\Program Files\ESOPPlone\Zope\lib\python\Products\kinterbasdbDA\kinterbasdb\__init__. py, line 585, in execute res = _kinterbasdb.execute(self._C_cursor, sql, params) ProgrammingError: (-413, 'execute.isc_dsql_execute: conversion error from string BLOB. ') I also get a similar error (same value type) when just testing the SQL method in the ZMI, even when the SQL that the method generates is just: UPDATE ENTITY SET EN_NOTES = 'Hello world' WHERE EN_KEY = 12 The metatata of the table has the notes field definition as: EN_NOTES BLOB SUB_TYPE 1 SEGMENT SIZE 80, Maybe you
[Zope-DB] Pierugo Massolo/IT/ITC/ALSTOM is out of the office.
I will be out of the office starting 11/08/2005 and will not return until 29/08/2005. I will respond to your message when I return. ___ Zope-DB mailing list Zope-DB@zope.org http://mail.zope.org/mailman/listinfo/zope-db