Re: [Zope-dev] mounting obj to more than one zodb location

2001-01-18 Thread Chris Withers
Shane Hathaway wrote: It depends on the product you use for mounting, but generally you'll get a shared database with independent connections. So it will work, but if you make conflicting changes, the transaction should fail. Oooo... was this thread about mounted databases? Sorry, I got

[Zope-dev] Implementing a URL path resolver

2001-01-18 Thread morten
Hi guys, I've been tinkling with a function that does what REQUEST.resolve_url does, except without it relying on having a REQUEST instance available. That is, just resolving the path itself, something like this: path ÿstring.split(relative_url, '/') path ÿfilter(None, path) new_path ÿ'%s' %

Re: [Zope-dev] Implementing a URL path resolver

2001-01-18 Thread Steve Alexander
[EMAIL PROTECTED] wrote: Hi guys, I've been tinkling with a function that does what REQUEST.resolve_url does, except without it relying on having a REQUEST instance available. Have you seen the methods restrictedTraverse and unrestrictedTraverse in lib/python/OFS/Traversable.py ? These

Re: [Zope-dev] Implementing a URL path resolver

2001-01-18 Thread Morten W. Petersen
[[EMAIL PROTECTED]] (Bug in the encoding of the message, MHA) | path = string.split(relative_url, '/') | path = filter(None, path) | new_path = '%s' % path[0] | path = path[1:] | | for element in path: | | new_path = new_path + "['%s']" % element | | return eval("self%s" % new_path)

Re: [Zope-dev] Implementing a URL path resolver

2001-01-18 Thread Morten W. Petersen
[Steve Alexander] | Have you seen the methods restrictedTraverse and unrestrictedTraverse in | lib/python/OFS/Traversable.py ? Exactly what I needed. Thank you. -Morten ___ Zope-Dev maillist - [EMAIL PROTECTED]

[Zope-dev] MountedFileStorage

2001-01-18 Thread Steve Alexander
I've just been trying out the MountedFileStorage product (by Anthony Baxter) with Zope 2.3. I've got it mostly working, by patching a couple of typos, and making the SubApplication class derive from Traversable before Application. I've *almost* got ZClasses defined in the root storage working

[Zope-dev] skinscript and URL traversal question

2001-01-18 Thread Aaron Payne
Hi all, I originally posted this to the zope list and, upon suggestion, I am reposting it to zope-dev. I'm using a zsql method in a skinscript with query ... compute ... and it mostly works. Retrieving the dataskin with getItem() works. For example, Cid is the id of the coupon dataskin.

[Zope-dev] Calling HTMLFiles

2001-01-18 Thread Morten W. Petersen
Hi, I'm having difficulties calling an HTML file from python.. Here's the code: [...] from events import conflicting_events calendar_event_add_redirect = HTMLFile('calendar_event_add_redirect', globals()) manage_add_calendar_event_form =

RE: [Zope-dev] Specialists and __bobo_traverse__

2001-01-18 Thread Roch'e Compaan
Phillip J. Eby wrote: I'm pretty sure DTML methods *won't* work. "Python Methods" might. I don't know about external methods, python scripts, etc. I have successfully used PythonScripts for this. Did you have to do anything special in setting up rights for your traversal method. I

Re: [Zope-dev] MountedFileStorage

2001-01-18 Thread Shane Hathaway
Steve Alexander wrote: I've just been trying out the MountedFileStorage product (by Anthony Baxter) with Zope 2.3. I've got it mostly working, by patching a couple of typos, and making the SubApplication class derive from Traversable before Application. I've *almost* got ZClasses

[Zope-dev] ZPatterns: Attribute Providers

2001-01-18 Thread Steve Alexander
Here's my understanding of how Persistent Attribute Providers work: Persistent Internal Attribute Provider DataSkins and Attributes are ultimately stored like this: Rack's BTree | | | Slots: key:value | |-('ZPatterns.Rack','Self') : DataSkin instance

[Zope-dev] Fw: PythonMethods and ZClass generation problem

2001-01-18 Thread Alexander Limi
Sorry if I'm overstepping any bounds here, but I tried posting this to the main list, but the answers I get do not help me. I figured maybe somebody on the PTK- or the Dev-list might be able to help. This is a bit of a crisis, since our site has been down for a week due to this problem. I also

Re: [Zope-dev] Fw: PythonMethods and ZClass generation problem

2001-01-18 Thread seb bacon
hi, sounds to me like you're confusing Product with ZClass: * Alexander Limi [EMAIL PROTECTED] [010118 17:04]: ...Our constructor is called Artist_add, and resides in our product "Artist". ... "registerartist" tries to call the constructor of our Artist ZClass to add an Artist object

Re: [Zope-dev] MountedFileStorage

2001-01-18 Thread Johan Carlsson
http://www.zope.org/Members/hathawsh/ExternalMount Sound interesting. Is it possible to mount a read-only database from several different Zope-clients? Regards, Johan ___ Zope-Dev maillist - [EMAIL PROTECTED]

Re: [Zope-dev] MountedFileStorage

2001-01-18 Thread Shane Hathaway
Johan Carlsson wrote: http://www.zope.org/Members/hathawsh/ExternalMount Sound interesting. Is it possible to mount a read-only database from several different Zope-clients? Yes. The database should be inside a ZEO storage server. ExternalMount can mount ZEO ClientStorages (that's

[Zope-dev] Q: how to retrieve transactions from a Data.fs fragment?

2001-01-18 Thread Shawn Murphy
Yes We experienced a nasty confluence of suprises: - CanOfRaid is imperfect, - reiserfsck is imperfect, - our backups were imperfect [We already knew we were imperfect.] The result is that all we have left of about 6 weeks of several peoples development effort is two Data.fs scraps

[Zope-dev] Re: [Zope-PTK] Fw: PythonMethods and ZClass generation problem

2001-01-18 Thread Alexander Limi
From: "Shane Hathaway" [EMAIL PROTECTED] You were *SO* close. :-) I think you want this: return self.artists.manage_addProduct['Artist'].Artist_add(_.None,_) to be like this: return self.artists.manage_addProduct['Artist'].Artist_add(_.None,_,REQUEST) Tried both of those already. When

[Zope-dev] Re: [Zope-PTK] Fw: PythonMethods and ZClass generation problem

2001-01-18 Thread Shane Hathaway
Alexander Limi wrote: From: "Shane Hathaway" [EMAIL PROTECTED] You were *SO* close. :-) I think you want this: return self.artists.manage_addProduct['Artist'].Artist_add(_.None,_) to be like this: return

Re: [Zope-dev] ZPatterns: Attribute Providers

2001-01-18 Thread Phillip J. Eby
At 04:57 PM 1/18/01 +, Steve Alexander wrote: Here's my understanding of how Persistent Attribute Providers work: Persistent Internal Attribute Provider DataSkins and Attributes are ultimately stored like this: Rack's BTree | | | Slots: key:value |

RE: [Zope-dev] Specialists and __bobo_traverse__

2001-01-18 Thread Phillip J. Eby
At 04:45 PM 1/18/01 +0200, Roch'e Compaan wrote: Phillip J. Eby wrote: I'm pretty sure DTML methods *won't* work. "Python Methods" might. I don't know about external methods, python scripts, etc. I have successfully used PythonScripts for this. Did you have to do anything special

Re: [Zope-dev] skinscript and URL traversal question

2001-01-18 Thread Phillip J. Eby
At 08:54 AM 1/18/01 -0500, Aaron Payne wrote: Hi all, I originally posted this to the zope list and, upon suggestion, I am reposting it to zope-dev. I'm using a zsql method in a skinscript with query ... compute ... and it mostly works. Retrieving the dataskin with getItem() works. For

[Zope-dev] Find broken in 2.2.2?

2001-01-18 Thread Ty Sarna
Is there something wrong with the Find mechanism in 2.2.2? "containing" searches never find anything. I've looked at the changelogs for post-2.2.2 versions and didn't see anything about this being fixed, so either it was fixed but not documented, it's still broken, or it's something peculiar to

[Zope-dev] CSS file serving

2001-01-18 Thread richard
I've ended up hacking a version of special_dtml / ClassicHTMLFile that serves up CSS. Has anyone got a better way of doing it (that detects changes in the file and serves it up with the correct Content-Type)? Richard -- Richard Jones [EMAIL PROTECTED] Senior Software Developer, Bizar