| *** benji has quit IRC | 00:07 | |
| philiKON_ | timte: you really want to open another connection in that thread | 00:08 |
|---|---|---|
| timte | does _p_jar.db() open a new connection? | 00:11 |
| incorrect | i just followed the helloworld screencast | 00:12 |
| timte | no I don't think it does | 00:12 |
| timte | philiKON_: I'm trying to port lovely.remotetask to zope 2.9, may I show you the code I'm trying to port? | 00:13 |
| incorrect | however i've goofed the zcml | 00:14 |
| philiKON_ | timte: i think _p_jar is the db, db.open() opens a new connection, conn.root() gives you the root obj | 00:18 |
| timte | philiKON_: I'm not sure what is opening a connection, does the publishing process do that? | 00:19 |
| timte | (there's no db.open() in my code) | 00:19 |
| philiKON_ | upon each new reuqest, zope does | 00:20 |
| philiKON_ | conn = db.open() | 00:20 |
| philiKON_ | root = conn.root() | 00:20 |
| philiKON_ | root_folder = root['Application'[ | 00:20 |
| philiKON_ | (at least somethingl ike that) | 00:20 |
| timte | but it should close it as well I guess? | 00:20 |
| philiKON_ | of course | 00:20 |
| philiKON_ | at the end of each request, it either aborts or commits the transaction | 00:21 |
| philiKON_ | then it closes the connecdtion | 00:21 |
| philiKON_ | conn.close() | 00:21 |
| philiKON_ | zope.app.publication.zopepublication spells it all out | 00:21 |
| timte | maybe the requests are never ended | 00:21 |
| timte | I'll look into that tomorrow | 00:21 |
| philiKON_ | sure they are | 00:22 |
| timte | maybe a request opens another request or something, I guess that would never end any request | 00:23 |
| philiKON_ | not sure what you're trying to say... | 00:24 |
| timte | if I by mistake recursively open new requests in my code, I guess that could result in lots of open connections | 00:25 |
| timte | that was just on idea | 00:26 |
| timte | one | 00:26 |
| timte | philiKON_: why should a thread get a new connection to the database? | 00:27 |
| timte | for same reason one has one zope client per cpu I guess | 00:28 |
| * timte shuts up | 00:28 | |
| philiKON_ | no | 00:28 |
| philiKON_ | it's just that that's how the zodb handles multi-threadedness, i suppose | 00:29 |
| philiKON_ | all i know is that if each thread has its own connection that's opened and closed properly, it works | 00:29 |
| philiKON_ | because that's how zope itself does it | 00:29 |
| *** incorrect has quit IRC | 00:31 | |
| *** edgordon has joined #zope3-dev | 00:36 | |
| *** deo has quit IRC | 00:46 | |
| *** J1m has quit IRC | 01:04 | |
| *** nathany has quit IRC | 01:08 | |
| *** foxmjay has quit IRC | 01:14 | |
| *** fcorrea has quit IRC | 01:15 | |
| *** edgordon has quit IRC | 01:23 | |
| *** foxmjay has joined #zope3-dev | 01:24 | |
| *** foxmjay has quit IRC | 01:24 | |
| *** jodok has quit IRC | 01:30 | |
| *** timte has quit IRC | 01:42 | |
| *** redir has quit IRC | 01:59 | |
| *** spython has joined #zope3-dev | 01:59 | |
| spython | hi, anyone know how to setup my doctest if i have a <subscriber handler="blah" for="IFoo IBar" /> ? | 02:01 |
| spython | provideHandler(blah) doesn't seem to work | 02:01 |
| wiggy | provideSubscriber or something like that probably | 02:03 |
| spython | thing is, if i move the for="IFoo IBar" into the code as in "@adapter(IFoo, IBar" it works with provideHandler | 02:07 |
| spython | wiggy: i tried provideSubscriptionAdapter | 02:07 |
| spython | failed | 02:08 |
| spython | ah, of course | 02:20 |
| spython | provideHandler(blah, [IFoo, IBar]) | 02:20 |
| *** bigkevmcd has quit IRC | 02:24 | |
| *** tav_ has joined #zope3-dev | 02:26 | |
| *** niemeyer has quit IRC | 02:26 | |
| *** tav has quit IRC | 02:33 | |
| *** pcardune has left #zope3-dev | 02:48 | |
| *** edgordon has joined #zope3-dev | 02:50 | |
| *** spython has quit IRC | 02:51 | |
| *** jsadjohnson has left #zope3-dev | 02:56 | |
| *** tav_ is now known as tav | 03:20 | |
| *** ChanServ sets mode: +o tav | 03:20 | |
| *** ChanServ sets mode: +o srichter | 03:28 | |
| *** pbugni has quit IRC | 03:33 | |
| *** jukart has joined #zope3-dev | 04:05 | |
| *** rcrafton has quit IRC | 04:15 | |
| *** pcardune has joined #zope3-dev | 04:27 | |
| *** alecm has quit IRC | 04:32 | |
| *** jukart has quit IRC | 05:05 | |
| *** pcardune has left #zope3-dev | 05:09 | |
| *** edgordon_ has joined #zope3-dev | 05:18 | |
| *** edgordon_ has quit IRC | 05:32 | |
| *** edgordon_ has joined #zope3-dev | 05:33 | |
| *** edgordon has quit IRC | 05:33 | |
| *** stub has joined #zope3-dev | 06:44 | |
| *** philiKON has joined #zope3-dev | 07:14 | |
| *** philiKON_ has quit IRC | 07:21 | |
| *** marianom has left #zope3-dev | 07:29 | |
| *** Jell-O-Fishi has quit IRC | 07:30 | |
| *** cursor has joined #zope3-dev | 07:40 | |
| *** tjs has joined #zope3-dev | 07:43 | |
| tjs | not sure how many of you guys use vim | 07:43 |
| tjs | but http://rafb.net/p/92l4OV94.html <-- save this to ~/.vim/syntax/doctest.vim | 07:43 |
| tjs | (it expects your python.vim to be in the same dir) | 07:44 |
| tjs | for non-suck doctest highlighting | 07:44 |
| tjs | it uses the python highlighting after the >>> | 07:44 |
| tjs | got sick of the monotone one on vim.org | 07:45 |
| *** baijum has joined #zope3-dev | 08:21 | |
| *** rcrafton has joined #zope3-dev | 08:28 | |
| *** romanofski has quit IRC | 08:28 | |
| *** sorin has joined #zope3-dev | 08:36 | |
| *** sorin is now known as sorindregan | 08:37 | |
| *** zagy has joined #zope3-dev | 08:42 | |
| *** jukart has joined #zope3-dev | 08:42 | |
| *** kleist has joined #zope3-dev | 08:42 | |
| *** rocky has quit IRC | 08:46 | |
| *** yvl has joined #zope3-dev | 09:03 | |
| *** ghendi has joined #zope3-dev | 09:05 | |
| * Theuni checks | 09:21 | |
| Theuni | hrn. it doesn't support doctest blocks correctly | 09:21 |
| *** timte has joined #zope3-dev | 09:21 | |
| Theuni | is that supposed to be for reST files or inline doctests? | 09:22 |
| *** jodok has joined #zope3-dev | 09:25 | |
| *** naro has joined #zope3-dev | 09:27 | |
| tjs | Theuni: doctest files | 09:28 |
| tjs | its just a hacked version of the one on vim.org | 09:28 |
| tjs | to add python support | 09:28 |
| tjs | are all doctest files rest? | 09:28 |
| *** dobee has joined #zope3-dev | 09:35 | |
| Theuni | yup | 09:37 |
| Theuni | the main mode should be doctest and only the >>> (even without whitespace at the beginning of the line!) should be python mode | 09:37 |
| Theuni | s/doctest/rest/ | 09:37 |
| tjs | yeh | 09:38 |
| tjs | that should be fairly straight forward | 09:38 |
| Theuni | hmm, it wasn't for me :) | 09:38 |
| Theuni | but i'm no good at vim syntax files | 09:38 |
| tjs | will take a look tonight :) | 09:38 |
| Theuni | :) | 09:41 |
| *** romanofski has joined #zope3-dev | 10:00 | |
| *** deo has joined #zope3-dev | 10:10 | |
| *** harobed has joined #zope3-dev | 10:33 | |
| *** tarek has joined #zope3-dev | 10:54 | |
| *** jfroche has joined #zope3-dev | 11:03 | |
| *** afd has joined #zope3-dev | 11:05 | |
| *** afd_ has quit IRC | 11:08 | |
| *** afd_ has joined #zope3-dev | 11:09 | |
| *** MJ has joined #zope3-dev | 11:10 | |
| *** rcrafton has quit IRC | 11:14 | |
| *** jodok has quit IRC | 11:23 | |
| *** jodok has joined #zope3-dev | 12:09 | |
| *** tarek has quit IRC | 12:14 | |
| *** jodok has quit IRC | 12:14 | |
| *** tarek has joined #zope3-dev | 12:14 | |
| *** jodok has joined #zope3-dev | 12:14 | |
| *** b52laptop has joined #zope3-dev | 12:32 | |
| *** agroszer has joined #zope3-dev | 12:33 | |
| *** junkafarian has joined #zope3-dev | 12:34 | |
| *** norro has joined #zope3-dev | 12:38 | |
| junkafarian | http://www.xi-online.nl/i/archief/nightw95.jpg | 12:52 |
| junkafarian | oops | 12:52 |
| junkafarian | wrong channel | 12:52 |
| junkafarian | :S | 12:52 |
| junkafarian | sorry | 12:52 |
| *** projekt01 has joined #zope3-dev | 12:54 | |
| *** jfroche_ has joined #zope3-dev | 13:01 | |
| *** ferrafox has joined #zope3-dev | 13:08 | |
| *** lisppaste6 has quit IRC | 13:11 | |
| *** lisppaste6 has joined #zope3-dev | 13:17 | |
| markusleist | projekt01: sorry again, I didn't find "the right context" yesterday? I'm in my Browser-View of obj1 and wants to find obj2 by path-string '/a/b/obj2'. in my view of obj1 i have to use self.request to get (secure) access to obj2, right? But there is no 'url'; where my mistake? Do you have any hint (template/example/doc)? | 13:29 |
| *** jfroche has quit IRC | 13:29 | |
| *** stub has quit IRC | 13:30 | |
| projekt01 | markusleist, you can access the view with a XMLRPC client. | 13:32 |
| projekt01 | at the url of the XMRPC view | 13:33 |
| *** tav_ has joined #zope3-dev | 13:45 | |
| *** MJ is now known as MJ|lunch | 13:50 | |
| *** tav has quit IRC | 13:55 | |
| *** Ariel_Calzada has joined #zope3-dev | 13:57 | |
| *** Newfie2007 has joined #zope3-dev | 14:02 | |
| *** fcorrea has joined #zope3-dev | 14:03 | |
| markusleist | projekt01: i've tested my XMLRPC-View. there is no url-Attribute or something like that. What do you mean: should i do a xmlrpc-call in the method of obj1 to get access to obj2 (eg. over localhost)? | 14:04 |
| markusleist | I think, it's a bit "oversized" and not straight forward for the security mechanism. | 14:05 |
| junkafarian | markusleist: i use the RPC methods to call context methods | 14:06 |
| junkafarian | saves including business logic in the view | 14:07 |
| markusleist | ok, i do it also. but | 14:07 |
| markusleist | i have a browser-request in which i "reached" my obj1. all i want to do is: traverse to an other obj, via "string"-path with the same security-association. | 14:10 |
| *** jodok has quit IRC | 14:11 | |
| markusleist | I'm in browser-view of obj1 and the only one i know is the string-path to obj2. xmlrpc is the preferred way here? | 14:12 |
| *** afd has quit IRC | 14:15 | |
| *** ferrafox_ has joined #zope3-dev | 14:18 | |
| *** rocky has joined #zope3-dev | 14:18 | |
| philiKON | markusleist: no | 14:19 |
| philiKON | markusleist: zope.traverse.api.traversePath or so | 14:20 |
| philiKON | markusleist: my book's API reference should give clues | 14:20 |
| markusleist | philiKON: i'll look. till then. | 14:22 |
| *** dunny has quit IRC | 14:24 | |
| *** romanofski has quit IRC | 14:28 | |
| *** ferrafox has quit IRC | 14:35 | |
| *** ferrafox_ is now known as ferrafox | 14:35 | |
| *** ignas has joined #zope3-dev | 14:36 | |
| *** markusleist has quit IRC | 14:38 | |
| *** MJ|lunch is now known as MJ | 14:50 | |
| *** sm is now known as sm-afk | 14:54 | |
| *** rcrafton has joined #zope3-dev | 15:00 | |
| *** baijum has quit IRC | 15:16 | |
| *** jsadjohnson has joined #zope3-dev | 15:17 | |
| *** ktwilight has quit IRC | 15:18 | |
| *** ktwilight has joined #zope3-dev | 15:18 | |
| *** jfroche_ has quit IRC | 15:19 | |
| *** J1m has joined #zope3-dev | 15:19 | |
| J1m | Theuni, ayt? | 15:20 |
| *** ccomb has quit IRC | 15:25 | |
| *** jsadjohnson has quit IRC | 15:27 | |
| Theuni | J1m: jupp | 15:34 |
| J1m | I'm wondering what your thoughts are relating to the 3.4 release, and, more importantly, how to manage the various package eggs. | 15:35 |
| J1m | I'd like to get most or all of the eggs to final releases. | 15:35 |
| J1m | I'm not sure what the bug status is, I suppose I should look at that. | 15:35 |
| *** greenman has quit IRC | 15:35 | |
| Theuni | My thoughts are that the rc should happen ASAP. IMHO we need some bugfixes for that. I spent some time going through about 80% of the open bugs prioritizing them but some of the work needs to actually be done. | 15:36 |
| Theuni | I think I marked some critical and added them to the 3.4 series | 15:36 |
| J1m | I'd like people to be able to start using the prefer-final option in buildout, but we need more final releases for that to work. | 15:36 |
| Theuni | Right. What do we want the 3.4 rc to be? | 15:37 |
| Theuni | We could make the individual eggs final and include them in the rc, otoh we could make rcs for the eggs and put those in the rc for 3.4. | 15:37 |
| Theuni | (Making them final would require that no critical/high priority bugs for those packages are around) | 15:37 |
| J1m | I didn't think we were using eggs in the 3.4 release. | 15:38 |
| J1m | agreed | 15:38 |
| Theuni | We're pointing to the appropriate branches of the packages. We don't use eggs. | 15:38 |
| J1m | You're pointing to branches? | 15:38 |
| J1m | Hm. | 15:38 |
| Theuni | currently branches + revision | 15:39 |
| J1m | Interesting. | 15:39 |
| Theuni | The plan was to change this to tags on the rc and final. | 15:39 |
| philiKON | IMHO, we should get all the 3.4.x projects to a final release | 15:39 |
| philiKON | (unless they already have been) | 15:39 |
| Theuni | I started doing it on branches + revision and offered to switch to tags in the rc, not the beta. | 15:39 |
| Theuni | philiKON: and unless they have bugs. | 15:39 |
| philiKON | then we should make a 3.4.0rc1 Zope 3 release, pointing to the tags | 15:39 |
| philiKON | Theuni: right | 15:39 |
| Theuni | sounds good to me | 15:40 |
| Theuni | if the release then discovers errors we can make new bugfix releases of the packages and upgrade the externals. | 15:40 |
| philiKON | if we find bugs in the rc, we just release a bugfix release of whichever project is involved | 15:40 |
| philiKON | exactly | 15:40 |
| Theuni | :) | 15:40 |
| philiKON | :) | 15:40 |
| Theuni | we should get a washing list or something. | 15:40 |
| Theuni | I'll do that. | 15:40 |
| philiKON | btw, i think we should use the cheeseshop as our primary relesae target | 15:40 |
| philiKON | not download.zope.org | 15:40 |
| Theuni | I'll create a wiki page that lists the packages that the RC needs to be released. | 15:40 |
| Theuni | right | 15:40 |
| philiKON | with ppix/simple index it's much more usable now | 15:41 |
| J1m | philiKON, I disagree with crapping in the cheeseshop. | 15:41 |
| J1m | We broke out many packahes prematurely. | 15:41 |
| Theuni | Eventually we can use download.zope.org for unstable releases and only put stable releases into the cheeseshop. | 15:41 |
| J1m | It makes us look bad imo. | 15:41 |
| philiKON | well, it's too late now :). | 15:41 |
| philiKON | we have a zope.app.component 0.1dev something there | 15:41 |
| philiKON | whichi s worse than a 3.4.0 | 15:41 |
| Theuni | *g | 15:42 |
| J1m | It's not too late to stop crapping in the cheeseshop. | 15:42 |
| philiKON | i'm not sure i'm following | 15:42 |
| philiKON | 99% of our packages already *are* there | 15:42 |
| philiKON | we're constantly working on improving their front page | 15:42 |
| J1m | Then we suck. | 15:42 |
| philiKON | we probably do :) | 15:43 |
| J1m | Most packages have crappy meta data. | 15:43 |
| philiKON | well, that's something we can work on, can't we | 15:43 |
| J1m | I bet most or all packages that depend on Zope 3 frameworks aren't labeled as such. | 15:43 |
| J1m | Yes, but who's going to do that. | 15:43 |
| J1m | Until we do, I think we should consider pulling things out. | 15:44 |
| J1m | *especially zope.app packages* | 15:44 |
| philiKON | i don't mind pullin gout the crapp 0.1dev or 3.4dev-rXXX releases | 15:44 |
| J1m | That's a start! :) | 15:44 |
| *** goschtl has joined #zope3-dev | 15:44 | |
| J1m | BTW, I'm not criticizing anyone. | 15:45 |
| philiKON | i'll happily work on improving th epackage metadata when i'm encountering a package | 15:45 |
| philiKON | i usually have in the past | 15:45 |
| Theuni | You can criticize the eggs. ;) | 15:45 |
| J1m | I just want to stop making errors. | 15:45 |
| J1m | so, 2 separate issues. | 15:46 |
| J1m | 1. wrt the cheeseshop, while we're thinking about it: | 15:46 |
| J1m | I suggest we remove any packages that have only dev releases. | 15:47 |
| J1m | I suggest we remove zope.app packages unless they have trove classifiers that clearly indicate that they are for the zope 3 frameworks. | 15:47 |
| *** jodok has joined #zope3-dev | 15:47 | |
| J1m | (Or, alternatively update the trove classifiers.) | 15:48 |
| philiKON | right | 15:48 |
| J1m | I'll do this for packages that I own. | 15:48 |
| philiKON | note that some zope.* packages also clearly are for the Zoep 3 framework | 15:48 |
| philiKON | zope.viewlet, fo rexample | 15:48 |
| philiKON | or zope.formlib | 15:48 |
| J1m | If we know of those, then we should apply the same operation. | 15:48 |
| philiKON | yup | 15:48 |
| philiKON | +1 | 15:49 |
| J1m | But I'm not volunteering to think hard. :) | 15:49 |
| J1m | 2. wrt individual projects. we'll move those to final where possible and switch the Zope3 trunk to use tags. | 15:50 |
| J1m | I hope there haven't been changes on the branches. | 15:50 |
| philiKON | the zope 3 trunk or the zope 3.4 branch? | 15:50 |
| J1m | Both I guess. | 15:50 |
| J1m | at least the branch. | 15:50 |
| J1m | But it might be a good idea for the trunk as well. | 15:50 |
| J1m | I'm not sure. | 15:50 |
| Theuni | me neither | 15:51 |
| J1m | It depends on what the trunk is for, | 15:51 |
| philiKON | i think the trunk could point to the trunks | 15:51 |
| Theuni | We didn't define what happens to the trunk actually. | 15:51 |
| philiKON | you know what, we should let those people decide who still want the trunk | 15:51 |
| J1m | well, at least the branch then. | 15:51 |
| philiKON | like projekt01 | 15:51 |
| Theuni | I just split off the branch because we create branches for releases. | 15:51 |
| J1m | Theuni, yup. | 15:51 |
| *** benji has joined #zope3-dev | 15:52 | |
| J1m | What I don't want is branches in individual packages that exist to serve a Zope 3 release branch. | 15:52 |
| Theuni | I'd be happy to create a todo list for all packages that we need to look at, but I can do that earliest in a few hours. | 15:52 |
| Theuni | J1m: ack | 15:52 |
| J1m | Theuni, that would be great. Thanks. | 15:52 |
| J1m | Is that the same as a "wash list"? | 15:53 |
| J1m | I wasn't sure what you meant by that. | 15:53 |
| Theuni | yup. | 15:53 |
| Theuni | german idiom. | 15:53 |
| J1m | k, cool | 15:53 |
| Theuni | looks like it doesn't translate ;) | 15:53 |
| * philiKON wonders what german idiom that is :) | 15:53 | |
| J1m | Sure it does. You just translated. :) | 15:54 |
| Theuni | 'n waschzettel halt | 15:54 |
| philiKON | uh huh :) | 15:54 |
| philiKON | k, ttyl | 15:54 |
| J1m | OK, well that's (package discussion) helpful. Thanks. | 15:54 |
| * Theuni wanders off again | 15:55 | |
| * J1m needs to write a script to get project status info from the cheeseshop... | 15:56 | |
| *** J1m has quit IRC | 15:57 | |
| *** jodok has quit IRC | 16:20 | |
| *** netshade has joined #zope3-dev | 16:21 | |
| *** bigkevmcd has joined #zope3-dev | 16:25 | |
| *** edgordon_ has quit IRC | 16:30 | |
| *** norro has quit IRC | 16:31 | |
| *** J1m has joined #zope3-dev | 16:31 | |
| *** niemeyer has joined #zope3-dev | 16:35 | |
| *** alga has joined #zope3-dev | 16:35 | |
| *** Ariel_Calzada has quit IRC | 16:37 | |
| xbeanx | is there a skin that does the same thing as the zope 3 javascript menu, except not done in javascript? :) | 16:42 |
| philiKON | zope.app.tree has something like that | 16:43 |
| xbeanx | k, thanks | 16:43 |
| xbeanx | cool, just what I was looking for | 16:44 |
| *** benji has quit IRC | 16:46 | |
| *** bigkevmcd has quit IRC | 16:47 | |
| *** bigkevmcd has joined #zope3-dev | 16:49 | |
| *** stub has joined #zope3-dev | 16:54 | |
| *** jodok has joined #zope3-dev | 17:00 | |
| *** Newfie2007 has quit IRC | 17:03 | |
| *** bigkevmcd has quit IRC | 17:10 | |
| *** redir has joined #zope3-dev | 17:12 | |
| *** rlo has joined #zope3-dev | 17:21 | |
| *** nerdalert has joined #zope3-dev | 17:22 | |
| *** MJ has quit IRC | 17:24 | |
| *** cursor has quit IRC | 17:27 | |
| *** redir has quit IRC | 17:28 | |
| *** rinou has joined #zope3-dev | 17:30 | |
| rinou | I have a ZODB mount and I'd like to move an object attribute from my root ZODB into that mount. | 17:34 |
| rinou | When I do it by assignment, the _p_jar of that attribute doesn't change, thus the object sticks in the root ZODB. | 17:34 |
| rinou | How can I force a copy into the other ZODB? | 17:34 |
| J1m | Create a new object, copy the data and stick the new object in the other db. | 17:35 |
| J1m | There isn't an official api for moving/copying an object between dbs. | 17:36 |
| rinou | By copy the data you mean use copy.deepcopy? | 17:36 |
| nerdalert | where is there a detailed doc on setting up ZODB mount points in zope 3? | 17:36 |
| rinou | I have an object in the new database already, which happens to be a portal_catalog | 17:37 |
| philiKON | nerdalert: there isn't afaik | 17:39 |
| philiKON | nerdalert: just put one container stored in one db into a container stored in the other db | 17:39 |
| nerdalert | philiKON: yeah, I had trouble finding one. I found one for zope 2 though | 17:39 |
| philiKON | it's as simple as that | 17:39 |
| *** norro has joined #zope3-dev | 17:39 | |
| nerdalert | philiKON: do mount points exist in zope 3? | 17:39 |
| philiKON | not as such | 17:40 |
| philiKON | i just explained how it's done | 17:40 |
| philiKON | zope 2 doesn't do it any different | 17:40 |
| nerdalert | okay, that answers my question | 17:40 |
| philiKON | except that it allows you to do it from zope.conf | 17:40 |
| nerdalert | do you still configure your different storages in zope.conf? | 17:41 |
| philiKON | yes | 17:41 |
| nerdalert | how do you name them? | 17:41 |
| nerdalert | or key them somehow | 17:41 |
| *** jodok has quit IRC | 17:42 | |
| J1m | rinou, I mean whatever works for the object. | 17:42 |
| J1m | nerdalert, you are probably missing the simplicity that philiKON is trying to convey. | 17:42 |
| J1m | There are no mounts in z3 because mounts are no-longer needed. | 17:43 |
| J1m | zodb now supports cross-database references. | 17:43 |
| *** marianom has joined #zope3-dev | 17:43 | |
| J1m | OTOH, there are certain dark corners/pitfalls that aren't yet well documented. | 17:44 |
| J1m | :/ | 17:44 |
| philiKON | it would be nice if this whole procedure were documented | 17:44 |
| philiKON | at least in zope 2 it's user friendly | 17:44 |
| philiKON | i'm not saying it's harder in zope 3, but perhaps a bit less obvious | 17:44 |
| nerdalert | J1m: okay, that makes sense, but I'm still confused about how I would actually get access to another storage | 17:44 |
| philiKON | anyway, to answer nerdalert's question | 17:45 |
| J1m | if you have a connection, call get_connection(database_name) | 17:45 |
| J1m | so for example, if I want to access on object in foo: | 17:45 |
| *** MJ has joined #zope3-dev | 17:45 | |
| J1m | some_object_I_already_have._p_jar.get_connection('foo').... | 17:46 |
| philiKON | ah, didn't know that | 17:46 |
| J1m | so you get the connection and then use it to get the object you want. | 17:46 |
| philiKON | do i have to close that connection again? | 17:46 |
| J1m | no | 17:46 |
| philiKON | that's very cool | 17:46 |
| *** junkafarian has left #zope3-dev | 17:46 | |
| J1m | In multidatabases, connections are managed as a collection. | 17:46 |
| philiKON | i only knew that you coudl access the databases by getUtility(IDatabase, 'foo') | 17:47 |
| *** ghendi has quit IRC | 17:47 | |
| philiKON | so if i did conn = getUtility(IDatabase, 'foo').open(), would that be equiavlent? | 17:47 |
| nerdalert | J1m: if I store a reference to that object in another storage, is the connection automatically reopened when I try to access it? | 17:47 |
| J1m | Yeah, but that's not how application develoeprs should acess multiple databases. | 17:47 |
| J1m | nerdalert, yes | 17:47 |
| philiKON | ok, gotcha | 17:47 |
| nerdalert | sweet | 17:47 |
| philiKON | as for naming, this is done in zope.conf | 17:47 |
| J1m | The reason is that a connection in one database always needs to use the *same* connection when accessing objects in another database. | 17:48 |
| philiKON | http://paste.plone.org/16426 | 17:48 |
| J1m | That's why ZODB does this connection management. | 17:48 |
| philiKON | yeah, makes sense | 17:48 |
| nerdalert | J1m: do I have to get_connection programmatically, or is there also a zcml configuration directive for that? | 17:48 |
| philiKON | nerdalert: J1m just showed you how to get to it | 17:49 |
| J1m | The second part of your connection makes no sense to me. | 17:49 |
| philiKON | some_persistent_obj._p_jar.get_connection(...) | 17:49 |
| J1m | The second part of your question makes no sense to me. | 17:49 |
| J1m | exactly | 17:49 |
| J1m | basically, call the get_connection method of a connection you already have. | 17:50 |
| nerdalert | philiKON: I think your paste answers the question I had about naming DBs | 17:50 |
| philiKON | right | 17:50 |
| philiKON | nerdalert: anyway, if you have a blog, this would be a good time to put it to use and document this for the rest of the world :) | 17:51 |
| nerdalert | nerdalert: hehe. sounds good | 17:51 |
| philiKON | (and make sure the feed is on planetzope.org) | 17:52 |
| J1m | You could reference the existing documentation at: | 17:53 |
| J1m | http://svn.zope.org/ZODB/trunk/src/ZODB/tests/multidb.txt?view=auto | 17:53 |
| J1m | :) | 17:53 |
| J1m | That file is fairly well hidden. | 17:53 |
| J1m | Only the worthy are told about it. You should be proud. ;) | 17:54 |
| philiKON | haha | 17:54 |
| wiggy | documentation shouldn't be in blogs though | 17:58 |
| *** markusleist has joined #zope3-dev | 17:59 | |
| *** projekt01 has quit IRC | 18:02 | |
| nerdalert | J1m: thanks =) | 18:11 |
| nerdalert | philiKON: and thank you =) | 18:12 |
| *** tomus has joined #zope3-dev | 18:13 | |
| * markusleist pays tribute to philiKON, too | 18:21 | |
| markusleist | Problem solved, solution found in the API-Doc of your book: | 18:22 |
| *** yvl has quit IRC | 18:23 | |
| markusleist | my obj1: print self.context.getObjectId(): b4a7ee9c596f6c44113629f4293e8debb | 18:24 |
| *** jsadjohnson has joined #zope3-dev | 18:24 | |
| markusleist | the find obj2: obj2 = traverse(self,"/14d2768d378cda7dc923283a4d58ff572", request=self.request) | 18:24 |
| markusleist | print obj2.getObjectId() | 18:24 |
| markusleist | print obj2.getObjectId(): 14d2768d378cda7dc923283a4d58ff572 | 18:24 |
| *** goschtl has quit IRC | 18:25 | |
| markusleist | there we are, thanx | 18:25 |
| markusleist | by: from zope.traversing.api import traverse | 18:26 |
| *** kleist has quit IRC | 18:29 | |
| *** ignas has quit IRC | 18:43 | |
| *** bigkevmcd has joined #zope3-dev | 18:46 | |
| *** stub has quit IRC | 18:46 | |
| *** dobee_ has joined #zope3-dev | 18:55 | |
| *** dobee has quit IRC | 18:55 | |
| *** alecm has joined #zope3-dev | 18:56 | |
| *** timte has quit IRC | 18:57 | |
| *** jukart has quit IRC | 19:08 | |
| rlo | I am trying to figure out if I can create per field permission based constraints in an interface. I.e. zope.Public can see and modify this field but only display this other field if the principal has zope.ManageContent permission | 19:09 |
| rlo | Say I want anonymous users to provide feedback, but I want any logged in user to be able to attach a document, can I do this at tthe interface level? | 19:10 |
| *** alga has quit IRC | 19:16 | |
| *** dobee_ has left #zope3-dev | 19:17 | |
| J1m | rlo, you can't state permission requirements as part of an interface definition. | 19:20 |
| *** dobee has joined #zope3-dev | 19:20 | |
| rlo | Jim is there a way to do it in zcml? I hope my question makes sense | 19:23 |
| J1m | Your orginal questions doesn't make sense, since zope.Public is a permission. | 19:23 |
| J1m | You can make permission declarations in zcml. | 19:23 |
| rlo | I am used to plone's AT and defining a field/widget and setting the permissions on the widget itself | 19:23 |
| rlo | I am trying to discern if I need a new way of thinking | 19:24 |
| J1m | interfaces are much narrower in scope that AT schemas. | 19:24 |
| J1m | You need a new way of thinking. | 19:24 |
| rlo | or if the same form can appear differently to different permission levels | 19:24 |
| rlo | I see | 19:24 |
| J1m | zope.schema is only supposed to be specification. | 19:24 |
| J1m | Other features, like widgets are added via adaptation. | 19:25 |
| J1m | You can use interfaces in permission declarations in zcml. | 19:25 |
| rlo | still new here and using formlib to magically adapt widgets to schemas for me:( | 19:25 |
| J1m | so you can say "you need this permission to access that interface". | 19:25 |
| J1m | well, the adaptation is normally fairly automatic. | 19:26 |
| rlo | But I assume I can only make permission definitions on the whole interface, not on parts | 19:26 |
| J1m | But there are separation of converns. | 19:26 |
| J1m | concerns. | 19:26 |
| J1m | rlo, yes | 19:26 |
| rlo | It sounds like I really need to interfaces on for anon and one for authenticated | 19:26 |
| rlo | s/to/two | 19:27 |
| J1m | AT schemas mix lots of concerns, which is a Zope 2 tradition. | 19:27 |
| *** tomus has quit IRC | 19:27 | |
| J1m | Honestly, I don't have time to help you work out your specific use case. Sorry. | 19:27 |
| rlo | np | 19:27 |
| rlo | thanks for the answers | 19:27 |
| J1m | yw | 19:28 |
| *** dobee has joined #zope3-dev | 19:30 | |
| *** bao has joined #zope3-dev | 19:32 | |
| *** tav_ is now known as tav | 19:33 | |
| *** ChanServ sets mode: +o tav | 19:33 | |
| *** MJ has quit IRC | 19:36 | |
| *** jsadjohnson has quit IRC | 19:52 | |
| *** redir has joined #zope3-dev | 20:00 | |
| *** rlo has quit IRC | 20:00 | |
| *** redir has quit IRC | 20:00 | |
| *** nathany has joined #zope3-dev | 20:06 | |
| *** harobed has quit IRC | 20:09 | |
| *** sm-afk is now known as sm | 20:11 | |
| *** benji has joined #zope3-dev | 20:32 | |
| *** hazmat has quit IRC | 20:34 | |
| *** spython has joined #zope3-dev | 20:40 | |
| *** nathany has quit IRC | 20:42 | |
| *** hazmat has joined #zope3-dev | 20:44 | |
| *** ChanServ sets mode: +o hazmat | 20:44 | |
| *** timte has joined #zope3-dev | 20:48 | |
| *** nathany has joined #zope3-dev | 20:50 | |
| *** hazmat has quit IRC | 20:51 | |
| *** pbugni has joined #zope3-dev | 20:54 | |
| *** ferrafox has quit IRC | 21:00 | |
| *** dobee_ has joined #zope3-dev | 21:05 | |
| *** b52laptop has quit IRC | 21:06 | |
| *** jsadjohnson has joined #zope3-dev | 21:07 | |
| *** dobee has quit IRC | 21:15 | |
| *** dobee has joined #zope3-dev | 21:15 | |
| *** ignas has joined #zope3-dev | 21:16 | |
| *** norro has quit IRC | 21:18 | |
| *** agroszer has quit IRC | 21:20 | |
| *** markusleist has quit IRC | 21:20 | |
| *** dobee_ has quit IRC | 21:33 | |
| J1m | Are there fields/widgets for doing simple file upload? | 21:34 |
| *** dunny has joined #zope3-dev | 21:44 | |
| philiKON | sure | 21:44 |
| philiKON | use the Bytes field | 21:44 |
| J1m | That loads the file into a string. | 21:45 |
| J1m | I want a file. | 21:45 |
| philiKON | right | 21:45 |
| philiKON | ah | 21:45 |
| philiKON | i don't know of such a thing | 21:45 |
| J1m | It's not a big deal for what I'm working on atm, I'm just surprized we don't have this. | 21:45 |
| philiKON | oh, hang on | 21:45 |
| philiKON | there's http://cheeseshop.python.org/pypi/hurry.file | 21:45 |
| timte | philiKON: I found out the problem with loads of open db connections, I needed to do request.close() after calling ZPublish.Publish.publish() | 21:46 |
| philiKON | J1m: but apparently, this is just a widget as well, not a file field | 21:46 |
| philiKON | J1m: i think the reason we don't have this yet is that blobs are fairly new | 21:47 |
| J1m | hm, oh well. | 21:47 |
| J1m | There are other applications that blobs. | 21:47 |
| philiKON | because i don't see how a file field would work for persistent objects any other way | 21:47 |
| J1m | Like uploading files for processing. | 21:47 |
| J1m | Not everything gets stored. :) | 21:48 |
| philiKON | right | 21:48 |
| philiKON | i guess nobody had to deal with this so far then | 21:48 |
| philiKON | a volatile file handle | 21:48 |
| J1m | oh well | 21:48 |
| philiKON | given that the publisher already hands you a file handle upon upload, this shouldn't be too hard to do | 21:48 |
| philiKON | (the widget part) | 21:48 |
| J1m | no | 21:48 |
| J1m | or the field part for that matter. | 21:48 |
| philiKON | right | 21:49 |
| J1m | I guess it isn't anyone's priority. | 21:49 |
| J1m | I don't *need* it for what I'm doing atm. | 21:49 |
| *** dobee has quit IRC | 21:49 | |
| *** norro has joined #zope3-dev | 21:50 | |
| *** hazmat has joined #zope3-dev | 21:52 | |
| *** ChanServ sets mode: +o hazmat | 21:52 | |
| *** hazmat has quit IRC | 21:53 | |
| *** hazmat has joined #zope3-dev | 21:55 | |
| *** ChanServ sets mode: +o hazmat | 21:55 | |
| *** hazmat has quit IRC | 21:56 | |
| *** nathany has quit IRC | 22:26 | |
| *** edgordon has joined #zope3-dev | 22:27 | |
| *** edgordon_ has joined #zope3-dev | 22:29 | |
| *** jodok has joined #zope3-dev | 22:36 | |
| *** edgordon_ has quit IRC | 22:40 | |
| *** edgordon_ has joined #zope3-dev | 22:46 | |
| *** edgordon has quit IRC | 22:46 | |
| *** dunny has quit IRC | 22:49 | |
| *** dobee has joined #zope3-dev | 22:59 | |
| *** hazmat has joined #zope3-dev | 23:01 | |
| *** ChanServ sets mode: +o hazmat | 23:01 | |
| *** greenman has joined #zope3-dev | 23:02 | |
| *** natea|away has joined #zope3-dev | 23:10 | |
| *** jsadjohnson has quit IRC | 23:24 | |
| *** stub has joined #zope3-dev | 23:29 | |
| *** b52laptop has joined #zope3-dev | 23:31 | |
| *** natea|away is now known as natea | 23:36 | |
| *** naro has quit IRC | 23:38 | |
| *** pbugni has quit IRC | 23:41 | |
| *** pbugni has joined #zope3-dev | 23:44 | |
| *** jodok has quit IRC | 23:53 | |
| *** stub has quit IRC | 23:58 | |
Generated by irclog2html.py 4.0.0 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!