*** J1m has quit IRC | 00:08 | |
*** rocky is now known as rocky|away | 00:10 | |
*** runyaga__ has joined #zope3-dev | 00:12 | |
*** runyaga_ has quit IRC | 00:30 | |
*** TrevorP has quit IRC | 00:39 | |
*** TrevorP has joined #zope3-dev | 00:48 | |
*** J1m has joined #zope3-dev | 00:52 | |
*** philiKON has joined #zope3-dev | 00:58 | |
*** baldtrol has quit IRC | 00:59 | |
*** projekt01 has joined #zope3-dev | 01:01 | |
philiKON | hi J1m. can't sleep? | 01:01 |
---|---|---|
J1m | I'm dealing with this damn security issue. :( | 01:02 |
philiKON | the rest thing? | 01:02 |
J1m | That someone announced in a lightening talk. | 01:02 |
J1m | yes | 01:02 |
philiKON | right, i saw the brazillion emails | 01:02 |
philiKON | on the plain, theuni and i looked at another bug | 01:02 |
J1m | sorry about that. | 01:02 |
philiKON | s/plain/plane | 01:02 |
*** yota has quit IRC | 01:02 | |
J1m | I wasn't sure if it affected zope 3. | 01:02 |
philiKON | right | 01:03 |
J1m | plus, you're pretty involved in z2. | 01:03 |
philiKON | i saw a wrap up of the lightning talk (someone blogged about it) | 01:03 |
philiKON | nah, no problem about the emails | 01:03 |
philiKON | i actually appreciate being included | 01:03 |
J1m | about the security thing? | 01:03 |
philiKON | it seems that docutils has its priorities wrong | 01:03 |
philiKON | right | 01:03 |
J1m | link? | 01:03 |
projekt01 | philiKON, hi | 01:04 |
philiKON | J1m, http://vanrees.org/weblog/archive/2006/07/05/europython-wednesday-lightning-talks | 01:04 |
philiKON | hi projekt01 | 01:04 |
projekt01 | philiKON, did you see my mail about the codespeak repo access? | 01:04 |
philiKON | projekt01, i saw your email :) | 01:04 |
philiKON | haven't read yet :) | 01:04 |
philiKON | just got back 1 hour ago | 01:04 |
projekt01 | np | 01:04 |
J1m | They did a nice job of not mentioning zope. | 01:05 |
J1m | Good for them. | 01:05 |
philiKON | J1m, wow, you guys already have a hotfix out | 01:07 |
J1m | It is a quite serious problem. | 01:08 |
philiKON | yes | 01:08 |
J1m | Ironically, it shouldn't have been an issue. | 01:08 |
J1m | The last hot fix we did should have fixed this problem, but it didn't hit enough places. | 01:08 |
philiKON | ic | 01:08 |
philiKON | so, "raw" is like "file" (except for the raw interpretation), and we only disabled "file" but not "raw"? | 01:08 |
J1m | Tres came up with a fix that tore the problem out at the roots. :) | 01:09 |
J1m | The one option we were setting was actually enough. | 01:09 |
J1m | We just didn't set it in enough places. | 01:09 |
philiKON | gotcha | 01:09 |
J1m | disabling input disables input for raw too. | 01:09 |
philiKON | J1m, andreas's checkin says, though: | 01:10 |
philiKON | 'file_insertion_enabled' : 0, | 01:11 |
philiKON | + 'raw_enabled' : 0, | 01:11 |
philiKON | } | 01:11 |
J1m | we were mistaken at that point. | 01:11 |
J1m | It has been a long evening. :( | 01:11 |
philiKON | hehe | 01:11 |
* philiKON takes a look at the hotfix | 01:12 | |
philiKON | lol, i like that hotfix | 01:13 |
dunny | the hotfix README.txt should include Zope 2.9.3 as an affected version? | 01:13 |
dunny | http://www.zope.org/Products/Zope/Hotfix-2006-07-05/Hotfix-20060705/README.txt | 01:13 |
philiKON | yeah | 01:16 |
*** rocky|away has quit IRC | 01:19 | |
*** philiKON has quit IRC | 01:26 | |
*** philiKON has joined #zope3-dev | 01:27 | |
J1m | yes, thanks. | 01:28 |
J1m | I've fixed that. | 01:29 |
dunny | cool | 01:29 |
*** rocky has joined #zope3-dev | 01:30 | |
*** projekt01 has quit IRC | 01:41 | |
*** J1m has quit IRC | 01:43 | |
*** MJ has joined #zope3-dev | 01:45 | |
*** vlado has joined #zope3-dev | 01:55 | |
*** benji has joined #zope3-dev | 01:55 | |
*** nathany has quit IRC | 02:10 | |
*** vlado has quit IRC | 02:39 | |
*** RaFromBRC has quit IRC | 02:51 | |
*** MJ has quit IRC | 02:53 | |
*** oferw has joined #zope3-dev | 03:04 | |
*** philiKON has quit IRC | 03:07 | |
*** _sussi has joined #zope3-dev | 03:22 | |
*** oferw has quit IRC | 03:29 | |
*** _sussi has quit IRC | 03:45 | |
*** dunny has quit IRC | 04:32 | |
*** rocky has quit IRC | 05:32 | |
*** dunny has joined #zope3-dev | 06:19 | |
*** stub has joined #zope3-dev | 06:25 | |
*** dunny_ has joined #zope3-dev | 06:30 | |
*** roym has quit IRC | 06:32 | |
*** roym has joined #zope3-dev | 06:32 | |
*** dunny has quit IRC | 06:42 | |
*** dunny__ has joined #zope3-dev | 06:53 | |
*** dunny___ has joined #zope3-dev | 07:07 | |
*** dunny___ has left #zope3-dev | 07:07 | |
*** dunny_ has quit IRC | 07:08 | |
*** dunny__ has quit IRC | 07:16 | |
*** dobee has joined #zope3-dev | 08:21 | |
*** baijum has joined #zope3-dev | 08:22 | |
*** dobee has quit IRC | 08:27 | |
*** wrobel has joined #zope3-dev | 08:27 | |
*** batlogg has quit IRC | 08:30 | |
*** batlogg has joined #zope3-dev | 08:45 | |
*** zagy has joined #zope3-dev | 08:52 | |
*** flox has quit IRC | 09:03 | |
*** hdima has joined #zope3-dev | 09:06 | |
*** romanofski has joined #zope3-dev | 09:28 | |
*** dobee has joined #zope3-dev | 09:29 | |
romanofski | moin | 09:30 |
*** roym has quit IRC | 09:35 | |
*** Theuni has joined #zope3-dev | 09:45 | |
*** projekt01 has joined #zope3-dev | 09:48 | |
*** whit has joined #zope3-dev | 09:53 | |
*** yota has joined #zope3-dev | 09:57 | |
*** svennhg has joined #zope3-dev | 10:08 | |
*** ClasuX has quit IRC | 10:09 | |
*** ClasuX has joined #zope3-dev | 10:15 | |
*** whit has quit IRC | 10:18 | |
*** elbixio has joined #zope3-dev | 10:26 | |
elbixio | hi everybody, does anyone know a python chart library that understands the datetime type? | 10:27 |
*** svennhg has quit IRC | 10:28 | |
*** svennhg has joined #zope3-dev | 10:29 | |
*** flox has joined #zope3-dev | 10:34 | |
*** Theuni has quit IRC | 10:52 | |
*** elbixio has quit IRC | 11:00 | |
*** eins has joined #zope3-dev | 11:02 | |
eins | hi | 11:02 |
*** projekt01 has left #zope3-dev | 11:17 | |
*** dunny___ has joined #zope3-dev | 11:44 | |
*** Theuni has joined #zope3-dev | 11:50 | |
*** BjornT has quit IRC | 11:56 | |
*** stub has quit IRC | 12:14 | |
*** dobee has quit IRC | 12:17 | |
*** dobee has joined #zope3-dev | 12:23 | |
flox | oups... | 12:42 |
flox | where is gone the "ObjectAnnotationsModifiedEvent" | 12:42 |
flox | i do not find such event in Zope 3.3 | 12:42 |
*** Theuni has quit IRC | 12:59 | |
*** Theuni has joined #zope3-dev | 13:06 | |
*** tarek has joined #zope3-dev | 13:07 | |
*** romanofski has quit IRC | 13:09 | |
*** romanofski has joined #zope3-dev | 13:10 | |
*** projekt01 has joined #zope3-dev | 13:15 | |
*** hannosch has joined #zope3-dev | 13:22 | |
*** BjornT has joined #zope3-dev | 13:43 | |
*** dunny___ has quit IRC | 13:47 | |
*** tarek has quit IRC | 13:51 | |
*** rocky has joined #zope3-dev | 13:56 | |
*** mkerrin has joined #zope3-dev | 13:57 | |
*** BjornT_ has joined #zope3-dev | 14:00 | |
*** BjornT has quit IRC | 14:00 | |
*** dobee has quit IRC | 14:12 | |
*** BjornT has joined #zope3-dev | 14:13 | |
*** dobee has joined #zope3-dev | 14:23 | |
*** _projekt01 has joined #zope3-dev | 14:29 | |
*** projekt01 has quit IRC | 14:29 | |
*** BjornT_ has quit IRC | 14:30 | |
*** _projekt01 has quit IRC | 14:32 | |
*** _projekt01 has joined #zope3-dev | 14:33 | |
*** MJ has joined #zope3-dev | 14:38 | |
*** _projekt01 has quit IRC | 14:41 | |
*** projekt01 has joined #zope3-dev | 14:41 | |
projekt01 | dobee, the problem with the codespeak repos was a bug in the Kaspersky Anti Virus prog | 14:43 |
projekt01 | http://forum.kaspersky.com/index.php?showtopic=16766&hl=subversion | 14:43 |
dobee | projekt01: ah, ok good to know | 14:44 |
dobee | projekt01: btw, hope to see you here at lovely office the next days, stephan is here already | 14:44 |
*** batlogg has quit IRC | 14:45 | |
rocky | hmm... | 14:46 |
rocky | last time i saw dobee it was drunk and acting quite funny... ;) | 14:46 |
rocky | *he was | 14:46 |
rocky | dobee and his wine :) | 14:47 |
*** srichter has joined #zope3-dev | 14:47 | |
dobee | rocky: it was beer ;-) | 14:47 |
rocky | dobee: oh, haha ... it was wine the night before then ;) | 14:47 |
rocky | actually i think it was srichter who kept buying all the wine | 14:47 |
*** ChanServ sets mode: +o srichter | 14:47 | |
dobee | rocky: yes | 14:48 |
srichter | yeah, I had a 120 Euros tab | 14:48 |
rocky | lol | 14:48 |
* rocky had a 30 euros tab from drinking coke ;) | 14:48 | |
projekt01 | dobee, should I come to visit you? | 14:48 |
projekt01 | whould be a nice trip with my new Buell | 14:49 |
rocky | srichter: i took a picture of you during your last drunken episode ... so if you ever run for congress ... beware the blackmail :) | 14:49 |
srichter | darn | 14:49 |
dobee | projekt01: jeah of course | 14:50 |
*** stub has joined #zope3-dev | 14:53 | |
*** jhauser has joined #zope3-dev | 15:07 | |
*** BjornT has quit IRC | 15:10 | |
*** stub has left #zope3-dev | 15:12 | |
*** stub has joined #zope3-dev | 15:12 | |
*** BjornT has joined #zope3-dev | 15:14 | |
*** TrevorP has quit IRC | 15:15 | |
flox | hello, i hav a question about Events | 15:17 |
flox | when we use 'ObjectModifiedEvent', it accepts additional arguments, called "modification descriptions" | 15:18 |
*** tarek has joined #zope3-dev | 15:18 | |
flox | how we use such "modification descriptions"? | 15:19 |
flox | factly, i want to suscribe an event when some change is performed on a custom metadata... but i don't know how to do it. | 15:21 |
*** benji has quit IRC | 15:23 | |
rocky | flox: if you want to subscribe to some change is performed on custom metadata, then you want to create your own custom event and fire off that event when your code changes the custom metadata | 15:26 |
rocky | then you can subscribe to your custom event and content type | 15:26 |
flox | rocky: ok, i'll do that | 15:31 |
flox | rocky: at the same time, i try to figure out how to use "modification descriptions" | 15:31 |
flox | it seems u can use any interface or any z.lifecycle.Attribute or z.lifecycle.Sequence as "modification descriptions" | 15:34 |
flox | but i do not find many examples that use "modification descriptions" | 15:34 |
*** _projekt01 has joined #zope3-dev | 15:50 | |
*** projekt01 has quit IRC | 15:50 | |
*** _projekt01 has quit IRC | 15:51 | |
*** ChrisW has joined #zope3-dev | 15:53 | |
*** gumpa has joined #zope3-dev | 15:53 | |
ChrisW | philiKON: ping? | 15:53 |
ChrisW | *grunt* | 15:54 |
ChrisW | MJ: ping? | 15:54 |
ChrisW | Oh well, is anyone actually alive here? | 15:54 |
ChrisW | I'm looking at http://svn.zope.org/Zope3/trunk/src/zope/i18n/interfaces/__init__.py?rev=40011&view=auto | 15:54 |
ChrisW | the comment for ITranslationDomain.translate refers to a "Domain" object "since it supports all the simplifications" | 15:55 |
ChrisW | where does this Domain object exist?! | 15:55 |
hannosch | ChrisW: heya, it says it's a domain = TextLine, so an object implementing ITranslationDomain should have this attribute | 15:56 |
ChrisW | no, that's just a string attribute identifying the translation domain | 15:57 |
ChrisW | I have a suspicion this mythical "domain" object doesn't exist ;-) | 15:57 |
hannosch | ah you are reffering to the Note, well the closest here is Message objects which store a domain and a text | 15:58 |
ChrisW | yeah, but you can't translate with them | 15:58 |
ChrisW | I'm looking for the Domain object referred to in ITranslationDomain.translate | 15:58 |
ChrisW | but I don't think it exists | 15:58 |
* ChrisW wheels out svn blame... | 15:58 | |
* ChrisW smells srichter | 15:59 | |
ChrisW | srichter: ping? | 15:59 |
* ChrisW wants to add a method to ITranslationDomain anyway, that allows you to get a list of the languages available for that domain... | 16:00 | |
hannosch | ChrisW: that should be simple. If you have a look at the translationdomain implementation, it's probably just returning self._catalogs.keys() | 16:04 |
ChrisW | ah yes, well, not quite that simple | 16:04 |
ChrisW | that gives you a list of ids, some of which are things like en_us or en_gb | 16:04 |
ChrisW | but anyway, the interface needs adding to, since it's defficient | 16:04 |
hannosch | ok, you can normalize them to en_GB if you prefer ;) | 16:05 |
ChrisW | well, what should be returned is the same 3-tuple that you need to call locales.getLocale with... | 16:06 |
*** ChrisW has quit IRC | 16:07 | |
*** projekt01 has joined #zope3-dev | 16:07 | |
*** ChrisW has joined #zope3-dev | 16:11 | |
svennhg | I'm trying to install wcsite-1.2.1.tgz with zope 3.2.1. I have copied wcsite-1.2.1 to lib/python/wcsite, added wcsite-configure.zcml to etc/package-includes and restarted zope. Now what? How do I create a new instance of wcsite? | 16:20 |
*** hannosch has quit IRC | 16:26 | |
baijum | svennhg: I think you have update etc/overrides.zcml | 16:27 |
baijum | <browser:defaultSkin name="WCSite" /> | 16:27 |
baijum | <adapter | 16:27 |
baijum | for="zope.publisher.interfaces.browser.IBrowserRequest" | 16:27 |
baijum | provides="zope.i18n.interfaces.IUserPreferredLanguages" | 16:27 |
baijum | factory="wcsite.language.FixedLanguage" | 16:27 |
baijum | /> | 16:27 |
*** ChrisW has joined #zope3-dev | 16:29 | |
ChrisW | anyone know how I get test.py to run tests in my zope source tree rather than my instance? | 16:29 |
ChrisW | (trying to test the changes I'm making to zope.i18n) | 16:30 |
baijum | ChrisW: make; export PYTHONPATH=/path/to/src;python test.py zope.i18n | 16:32 |
baijum | sorry, python test.py -s zope.i18n | 16:32 |
ChrisW | I'm justing running off a normal build | 16:32 |
*** whit has joined #zope3-dev | 16:32 | |
ChrisW | having to set the python path sucks there | 16:32 |
ChrisW | if zopectl run can find it, why can't zopectl test?! | 16:32 |
ChrisW | *grunt* | 16:33 |
ChrisW | (AND that doesn't work for me...) | 16:34 |
ChrisW | from zope.component.zcml import utility | 16:37 |
ChrisW | ...gives an ImportError | 16:37 |
ChrisW | where does zope.component.zcml live now? | 16:37 |
*** philiKON has joined #zope3-dev | 16:38 | |
ChrisW | ah | 16:38 |
ChrisW | oops | 16:38 |
ChrisW | my bad | 16:38 |
ChrisW | hey, philiKON :-) | 16:38 |
svennhg | baijum: Cannot find any diff between what you wrote and my etc/overrides.zcml. | 16:38 |
ChrisW | just the man I'm after... | 16:38 |
philiKON | hey | 16:38 |
ChrisW | http://svn.zope.org/Zope3/trunk/src/zope/i18n/interfaces/__init__.py?rev=40011&view=auto | 16:39 |
ChrisW | ITranslationDomain.translate refers to a Domain that "supports all the simplifications" | 16:39 |
ChrisW | Stefan wrote the line | 16:39 |
ChrisW | but I can find no such Domain object | 16:39 |
ChrisW | is the comment out of date? | 16:40 |
philiKON | looks like you're after srichter, not me... | 16:40 |
ChrisW | yeah, I know, but he's MIA | 16:40 |
ChrisW | and, as god of all things i18n/five/etc, thought you might have an opinion | 16:40 |
ChrisW | also, how would you feel about adding a listLanguages (or some such) method to ITranslationDomain? | 16:41 |
*** whit_ has joined #zope3-dev | 16:41 | |
philiKON | i can't make any sense about this last paragraph in the docstring | 16:41 |
philiKON | i *assume* it is indeed outdatede | 16:41 |
ChrisW | no, me neither | 16:41 |
ChrisW | mind if I remove it on the trunk? | 16:41 |
philiKON | dating back to when translate() was part of the translation service api | 16:41 |
*** whit has quit IRC | 16:42 | |
philiKON | well, ask srichter | 16:42 |
ChrisW | true | 16:42 |
philiKON | proposals like adding stuff to existing API are best submitted to the z3 list | 16:42 |
ChrisW | yeah, I want to work up a patch first | 16:42 |
philiKON | k | 16:43 |
philiKON | what's the use case? | 16:43 |
ChrisW | listing the available languages | 16:43 |
ChrisW | something PTS did | 16:43 |
philiKON | ChrisW, btw, there's ILanguageAvailabiility | 16:43 |
ChrisW | and Z3 currently does not | 16:43 |
philiKON | further down this file | 16:43 |
philiKON | yes it does | 16:43 |
philiKON | see that interface | 16:43 |
ChrisW | ah | 16:43 |
philiKON | it's just not a required part of ITranslationDomain | 16:43 |
ChrisW | so it does | 16:43 |
philiKON | it's an optional thing | 16:44 |
ChrisW | fair enough, so I guess I just write an adapter? | 16:44 |
philiKON | eh? | 16:44 |
*** sussi has joined #zope3-dev | 16:44 | |
ChrisW | well, sorry | 16:44 |
ChrisW | maybe I use the wrong words... | 16:44 |
philiKON | well, perhaps not. i dunno. an adapter for what to what? | 16:45 |
*** svennhg has quit IRC | 16:46 | |
*** RaFromBRC has joined #zope3-dev | 16:48 | |
*** ChrisWGrrr has joined #zope3-dev | 16:53 | |
baijum | is it necessary to set python path to run unit tests as said here : http://www.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/RunningUnitTests | 16:53 |
*** whit_ has quit IRC | 16:54 | |
ChrisWGrrr | philiKON: ping? | 16:54 |
ChrisWGrrr | grrr, pay per second wireless | 16:54 |
philiKON | ChrisWpong | 16:54 |
philiKON | ChrisWGrrr, pong | 16:54 |
philiKON | [15:44] ChrisWmaybe I use the wrong words... | 16:54 |
philiKON | [15:45] philiKONwell, perhaps not. i dunno. an adapter for what to what? | 16:54 |
ChrisWGrrr | sorry, as I was saying: translationdomain has the information | 16:54 |
philiKON | baijum, no. python test.py should simply work | 16:54 |
ChrisWGrrr | it just needs to grow an getAvailableLanguages method | 16:54 |
philiKON | ChrisWGrrr, though it doesn't seem to expose it in any API | 16:54 |
philiKON | ChrisWGrrr, right | 16:55 |
philiKON | at which point it can formally implement IAvailableLanguage | 16:55 |
*** ChrisW has quit IRC | 16:55 | |
philiKON | or whatever it was called | 16:55 |
*** ChrisWGrrr is now known as ChrisW | 16:55 | |
philiKON | +1 | 16:55 |
ChrisW | okay, but what do I do to make that happen? | 16:55 |
philiKON | uh, what do you mean? | 16:56 |
philiKON | you know how to read code, don't you? | 16:56 |
ChrisW | sorry, I meant in terms of procedure | 16:56 |
ChrisW | do I need to change translationdomain | 16:56 |
*** tarek has quit IRC | 16:56 | |
ChrisW | or can I add some kind of extra component that will make translationdomain grow IAvailableLanguages | 16:57 |
ChrisW | ? | 16:57 |
ChrisW | (hence my thinking of adapter) | 16:57 |
ChrisW | but adapters only adapt interfaces, right? | 16:57 |
philiKON | huh? | 16:57 |
philiKON | adapters adapt objects | 16:57 |
philiKON | but they'll never change existing apps | 16:57 |
philiKON | errr | 16:57 |
philiKON | existing components | 16:57 |
ChrisW | well, they don't need to | 16:57 |
philiKON | well, TranslationDomain doesn't expose its avaiable language sthrough any API | 16:58 |
philiKON | there's nothing that the adapter could use to "grok" the available languages | 16:58 |
ChrisW | I'm looking to adapt a translationdomain.TranslationDomain object to IAvailableLanguages | 16:58 |
ChrisW | I know I need to write a method | 16:58 |
philiKON | how would that adapter work? | 16:58 |
ChrisW | but where do I write that method? | 16:58 |
philiKON | gee, you got my book, right? | 16:58 |
*** baijum has quit IRC | 16:58 | |
philiKON | still, an adapter is the wrong thing here IMO | 16:59 |
ChrisW | I guess my line ofthinking would mean youd' need to be able to adapt a class, and I'm not sure you could do that | 16:59 |
*** bradb has joined #zope3-dev | 16:59 | |
philiKON | sorry, you're not making any sense to me :) | 16:59 |
philiKON | adapting a class, an interface, ?!?! | 16:59 |
philiKON | read my book again :) | 16:59 |
philiKON | adaption won't help you here | 16:59 |
philiKON | just extend (simple)translationdomain and be done with it | 17:00 |
ChrisW | I've read your book | 17:00 |
ChrisW | and I know it can't be done with adapters | 17:00 |
ChrisW | but I wonder if it should be able to? | 17:00 |
ChrisW | afterall, an Interface is just a class | 17:00 |
philiKON | no | 17:01 |
philiKON | an interface is no class | 17:01 |
ChrisW | yeah yeah, I know | 17:01 |
ChrisW | but step back from how things currently are | 17:01 |
philiKON | ok | 17:01 |
ChrisW | what is wrong with adapting a class to an interface | 17:01 |
ChrisW | ? | 17:01 |
ChrisW | (as a concept) | 17:01 |
ChrisW | I know it won't currently work, yada yada... | 17:01 |
philiKON | it wouldn't be adaption in the sense we have it today | 17:02 |
philiKON | classes typically imlement things | 17:02 |
philiKON | so, you'd adapt a class to *provide* that new interface or to *implement* it? | 17:02 |
ChrisW | both ;-) | 17:03 |
ChrisW | but you're correct | 17:03 |
ChrisW | the right thing here is just to write the method in translationdomain.TranslationDomain and then have that implement IAvailableLanguages | 17:03 |
philiKON | indeed | 17:04 |
philiKON | +1 for that on the trunk | 17:04 |
ChrisW | then I guess I'd do zapi.getUtility(ITranslationDomain, 'mydomain').getAvailableLanguages() in my code, right? | 17:05 |
philiKON | well... | 17:05 |
ChrisW | or would I do zapi.getUtility(IAvailableLanguages, 'mydomain') ? | 17:05 |
philiKON | except you couldn't be sure that the 'mydomain' domain object was also providing IAvailableLanguages | 17:05 |
philiKON | first of all, drop that 'zapi' shit :) | 17:05 |
*** pcardune has joined #zope3-dev | 17:06 | |
ChrisW | hey ,I'm just copying what Martijn did in silva :-P | 17:06 |
philiKON | hehe | 17:06 |
philiKON | anyways | 17:06 |
philiKON | the 2nd example wouldn't work, probably | 17:06 |
philiKON | no, not probably | 17:06 |
philiKON | it wouldn't work. period. | 17:06 |
ChrisW | well that's shit | 17:06 |
philiKON | because the 'mydomain' translation domain is not registered for IAVailableLanguages | 17:06 |
ChrisW | ;-) | 17:06 |
philiKON | here's what we should do | 17:07 |
ChrisW | should it be registered? ;-) | 17:07 |
philiKON | yeah, here's my suggestion: | 17:07 |
* ChrisW goes to get champagne :-P | 17:07 | |
philiKON | we create an interface that extends both ITranslationDomain and IAvailableLanguages | 17:07 |
philiKON | call it whatever you like :) | 17:07 |
philiKON | you make translationdomain implement that | 17:07 |
philiKON | and then you make the code whichever registers translation domains (i think zope.i18n.zcml) register them for this interface | 17:08 |
philiKON | and then you can look them up for that interface too | 17:08 |
philiKON | and you'll definitely know that you have the IAVailableLanguages API | 17:08 |
flox | +1 | 17:08 |
flox | hi, i hv error on ztapi.handle() from philiKON book example | 17:08 |
ChrisW | philiKON: can I make a different suggestion? | 17:09 |
philiKON | ChrisW, sure | 17:09 |
*** wdickers has joined #zope3-dev | 17:09 | |
flox | ztapi.handle((IRecipe, IObjectModifiedEvent), notifyModified) | 17:09 |
flox | AttributeError: 'module' object has no attribute 'handle' | 17:09 |
ChrisW | extend ITranslationDomain to include getAvailableLanguages and get rid of IAvailableLanguages | 17:09 |
ChrisW | nothing uses IAvailableLanguages | 17:09 |
philiKON | flox, zope 3.3 isn't BBB with zope x3 3.0 | 17:09 |
philiKON | flox, ztapi.handle is probalby just gone | 17:09 |
philiKON | ChrisW, true, but lots of stuff uses ITranslationDomain | 17:10 |
philiKON | possibly 3rd party stuff | 17:10 |
philiKON | and now we're changing the contract for ITranslationDomain | 17:10 |
philiKON | we can't do that | 17:10 |
philiKON | flox, use zope.component.provideHandler | 17:10 |
philiKON | (has a different argument ordering, though) | 17:10 |
ChrisW | I'd put money that no-one has implemented ITranslationDomain... | 17:10 |
ChrisW | I find these huge numbers of tiny interfaces a complete pain in the arse... | 17:11 |
philiKON | ChrisW, i wouldn't be surprised if launchpad had its own implementation, for example | 17:11 |
ChrisW | yeah, maybe to implement IAvailableLanguages ;-) | 17:11 |
philiKON | plone is looking into doing i18n the z3 way as well | 17:11 |
philiKON | anyways | 17:11 |
philiKON | i don't think we should change the contract | 17:12 |
philiKON | bring it up on the list if you want | 17:12 |
philiKON | well, bring it up on the list either way... | 17:12 |
ChrisW | oh well, for now, I'll subclass translationdomain, make it implement IAvailableLanguages and register my subclass for IAvailableLanguages too | 17:12 |
philiKON | you can do that | 17:12 |
ChrisW | what should I use instead of zapi.getUtility? | 17:12 |
philiKON | zope.component instead of zapi | 17:13 |
ChrisW | *nods* | 17:13 |
ChrisW | cool | 17:13 |
philiKON | anyways, instead of chickening out of the work, you could also help us get it right in z3 :) | 17:13 |
flox | philiKON: thks | 17:13 |
*** MJ has quit IRC | 17:13 | |
ChrisW | right, and getUtility(ITranslationDomain,'mydomain').translate is the way to do translations in my own code? | 17:13 |
flox | philiKON: i succeed in porting example from chapter 14 to Z3.3... | 17:13 |
ChrisW | (ie: non-zpt) | 17:14 |
philiKON | no | 17:14 |
ChrisW | or is there something else I should use | 17:14 |
philiKON | zope.i18n.translate() | 17:14 |
* ChrisW digs out philiKON's book | 17:14 | |
flox | philiKON: trying to do the same with chapter 15 :-) | 17:14 |
ChrisW | and philiKON: not chickening out of the work | 17:15 |
philiKON | good :) | 17:15 |
ChrisW | it's just that this needs discussion on the list, and it can't land before Zope 2.11 | 17:15 |
philiKON | right | 17:15 |
ChrisW | ...which is a little late given I need this for customer work I was due to deliver on the 2nd July ;-) | 17:15 |
philiKON | gotcha :) | 17:16 |
philiKON | so, yeah, custom subclass is good for adhoc then | 17:16 |
ChrisW | aye | 17:17 |
ChrisW | it's why we like zope 3 :-) | 17:17 |
ChrisW | quick refresher on how I register my new subclass for both ITranslationDomain and ILanguageAvailablity? | 17:18 |
ChrisW | zcml or python? | 17:18 |
philiKON | well, you'll want to create instances of these from gettext files, right? | 17:19 |
ChrisW | if you say so, I'm 90% clueless here ;-) | 17:19 |
ChrisW | I have no idea where these are created | 17:19 |
philiKON | <i18n:registerTranslations directory="locales" /> | 17:20 |
ChrisW | I just got them with getUtility(ITranslationDomain) so far :-S | 17:20 |
philiKON | this is what goes thru the 'locales' directory and registers each domain object | 17:20 |
philiKON | getting them is easy | 17:20 |
ChrisW | okay | 17:20 |
philiKON | (you don't really need to get them for trnaslation, though) | 17:20 |
ChrisW | no | 17:20 |
ChrisW | true | 17:20 |
philiKON | zope.i18n.translate() is what you should use for translating messages | 17:20 |
ChrisW | so the only thing I'm actually likely to do is getUtility(ILanguageAvailablity,'mydomain') | 17:21 |
philiKON | btw, hannosch is looking into refactoring some things in zope.i18n | 17:21 |
philiKON | mght be worth a shot talking to him at somepoint too | 17:21 |
philiKON | ChrisW, right | 17:21 |
ChrisW | so, I write my cute subclass with it's one method | 17:21 |
ChrisW | now, how do I wire that in? | 17:21 |
philiKON | look at zope.i18n.zcml.registerTranslations | 17:22 |
ChrisW | urm, I'm using Zope 2.9.3 | 17:22 |
philiKON | so? | 17:22 |
philiKON | ah | 17:22 |
philiKON | zope.app.i18n.metaconfigure | 17:22 |
ChrisW | no .zcml ;-) | 17:22 |
ChrisW | waaggh | 17:23 |
ChrisW | so I have to replace that registerTranslations method? | 17:23 |
philiKON | well, no. | 17:24 |
philiKON | create your own veresion of it | 17:24 |
philiKON | that in addition to doing: | 17:24 |
philiKON | utility(_context, ITranslationDomain, domain, name=name) | 17:24 |
philiKON | also does: | 17:24 |
philiKON | utility(_context, IAvailableLanguages, domain, name=name) | 17:24 |
ChrisW | right | 17:25 |
ChrisW | then how do I wire my new version of registerTranslations in? | 17:25 |
philiKON | and then you register that handler as a new zcml directive | 17:25 |
philiKON | <chrisw:registertranslations /> | 17:25 |
philiKON | or whatever | 17:25 |
ChrisW | bleugh | 17:25 |
philiKON | :) | 17:25 |
ChrisW | can I replace the existing one? | 17:25 |
* ChrisW reiterates that zcml both sucks and blows... *sulk* | 17:26 | |
philiKON | yes you can | 17:26 |
philiKON | if you do it right | 17:26 |
philiKON | you need include your declaration as an override | 17:26 |
philiKON | *after* the metas have been loaded, but *before* the rest of the stuff is loaded | 17:27 |
philiKON | you'll have to copy Five/skel/* to instance_home/etc | 17:27 |
philiKON | and modify etc/site.zcml | 17:27 |
ChrisW | aye | 17:27 |
ChrisW | sounds like a plan | 17:28 |
*** hdima has quit IRC | 17:28 | |
ChrisW | heh, or I can just do what Martijn did and hack it ;-) | 17:28 |
philiKON | sure :) | 17:28 |
ChrisW | see the getAvailableLanguages method on https://infrae.com/viewvc/Silva/trunk/adapters/languageprovider.py?revision=19294&view=markup | 17:29 |
ChrisW | the actual docs for IAvailableLanguages also sucks | 17:30 |
*** efge has joined #zope3-dev | 17:30 | |
ChrisW | what does it actually return? | 17:30 |
philiKON | i would assume an iterable | 17:31 |
ChrisW | it should really return a sequence of 3-tuples that can be used to call locales.getLocale | 17:31 |
philiKON | fine by me | 17:31 |
philiKON | we accept patches :) | 17:31 |
ChrisW | yeah, I have commit rights, can I just change it? | 17:32 |
philiKON | not sure if i am to decide this :) | 17:32 |
philiKON | plus, i think you should get together with hannosch | 17:33 |
ChrisW | fine, I'll do it and see who whine ;-) | 17:33 |
ChrisW | whines, even | 17:33 |
ChrisW | indeed | 17:33 |
philiKON | he's been suggesting refactorings | 17:33 |
ChrisW | where is he? | 17:33 |
philiKON | #plone usually | 17:33 |
ChrisW | was he at epc? | 17:33 |
philiKON | though usually later | 17:33 |
philiKON | no | 17:33 |
ChrisW | oh well, I'm gonna mail a summary of this to the list and hack it for myself :-/ | 17:34 |
philiKON | +1 | 17:34 |
ChrisW | I _am_ going to change IAvailableLanguages though, 'cos it isn't actually clear right now... | 17:34 |
*** eins has quit IRC | 17:39 | |
ChrisW | weird, I don't appear to be able to commit from here :-S | 17:42 |
ChrisW | or is something up with comitting to svn.zope.org right now? | 17:42 |
*** whit has joined #zope3-dev | 17:49 | |
* flox is going to take a drink | 17:50 | |
* flox is over with chapter 15, events and suscribers... and tests are OK (Total: 49 tests, 0 failures, 0 errors) | 17:52 | |
*** projekt01 has left #zope3-dev | 18:01 | |
*** ChrisW has quit IRC | 18:08 | |
*** TresEquis has joined #zope3-dev | 18:17 | |
rocky | philiKON: i think ChrisW has a permban in #plone btw ;) | 18:21 |
Theuni | yupp | 18:24 |
Theuni | that's very likely | 18:24 |
Theuni | :) | 18:24 |
philiKON | rocky, how come? | 18:24 |
rocky | philiKON: because #plone is for helping people and he comes in and basically just talks about how bad archetypes and plone is | 18:25 |
rocky | i think limi setup the ban | 18:25 |
philiKON | hehe, yeah, well, they don't get along :) | 18:25 |
philiKON | chris tends to write emails "i just found a bug. can somebody fix it please"... i'm always tempted to respond "you have checkin rights, right?" | 18:26 |
philiKON | which reminds me, /me needs to to some bug squishing today | 18:26 |
philiKON | we all should do that | 18:26 |
* TresEquis thinks that he might have spent enough time on that yesterday ;) | 18:27 | |
philiKON | and what a bugfix that was! :) | 18:27 |
*** romanofski has quit IRC | 18:28 | |
*** ChrisWGrrr has joined #zope3-dev | 18:29 | |
TresEquis | I still don't get how people use SVN to find out about things which have been removed | 18:29 |
ChrisWGrrr | svn log is your friend | 18:29 |
TresEquis | there doesn't seem to be any notion that "it used to be here" is information somebody would care about | 18:29 |
ChrisWGrrr | TortoiseSVN is absolutely awesome for introspecting repositories | 18:30 |
ChrisWGrrr | I'm sure there's some form of svn log that will effectively ask "what used to be here, forever, ignoring moves,etc" | 18:30 |
ChrisWGrrr | #svn is quite a good place to ask | 18:30 |
ChrisWGrrr | sussman can often be found lurking ;-) | 18:31 |
* TresEquis finds himself digging through gmane's checkin log to figure that out | 18:31 | |
*** nathany has joined #zope3-dev | 18:32 | |
ChrisWGrrr | TresEquis: can you give me an example? | 18:32 |
ChrisWGrrr | and for everyone: how do I register a utlitity? | 18:32 |
ChrisWGrrr | (my specific use case is Zope 2.9.3, but I'm interested more generally) | 18:32 |
Theuni | ChrisWGrrr: local utility or global (if global, zcml or python) | 18:33 |
*** ChrisWGrrr is now known as ChrisW | 18:33 | |
*** bradb has quit IRC | 18:33 | |
ChrisW | mmm, dunno | 18:33 |
Theuni | :) | 18:33 |
ChrisW | global will likely do for this project | 18:34 |
Theuni | is the utility a persistent object? | 18:34 |
ChrisW | no | 18:34 |
ChrisW | no need | 18:34 |
Theuni | then global would be fine | 18:34 |
ChrisW | how'd I register a utility in python? | 18:34 |
ChrisW | *cough* | 18:34 |
ChrisW | I mean zcml? | 18:34 |
TresEquis | ChrisW: OK, suppose you are trying to figure out when zope/app/skins was removed? How do you do that? | 18:35 |
Theuni | decide! zcml or python? | 18:35 |
ChrisW | (oh, and meta-question: are you at the sprints now?) | 18:35 |
* Theuni is at his office now | 18:35 | |
ChrisW | wow, that was quick | 18:35 |
ChrisW | oh yes, you left yesterday | 18:35 |
* ChrisW is in airport | 18:35 | |
ChrisW | and zcml | 18:36 |
Theuni | :) | 18:36 |
Theuni | <utility provides="interface" factory="dottedname"/> | 18:36 |
ChrisW | (otherwise you have to try and get the python triggered somehow, and that usually ends up being zcml *mutter I hate zcml *mutter*) | 18:36 |
ChrisW | Tres: mm | 18:36 |
*** flox has quit IRC | 18:36 | |
ChrisW | I reckon svn log is the way to go | 18:37 |
ChrisW | but I don't think it does it yet, lets see what #svn says | 18:37 |
Theuni | ChrisW: check the api documentation for zcml stuff, all the docs about those things are in there | 18:37 |
ChrisW | ok, another general question, what happens if two utilities register for the same interface? | 18:38 |
ChrisW | which one does a getUtility call return? | 18:38 |
*** benji has joined #zope3-dev | 18:41 | |
ChrisW | hey benji :-) | 18:41 |
benji | hi, ChrisW | 18:41 |
TresEquis | ChrisW: the second registration (assuming they use the same name) will raise a ZCML conflict | 18:41 |
TresEquis | or, if done in overrides, will replace the first | 18:41 |
TresEquis | the key, (interface, name), is unique in the registry | 18:42 |
TresEquis | if you do it in Python, then you need to figure it out yourself :) | 18:42 |
ChrisW | hmm | 18:43 |
ChrisW | see, well, I'll be posting to zope3-dev shortly | 18:43 |
ChrisW | would be interested in your thoughts on that... | 18:43 |
*** benji has quit IRC | 18:53 | |
*** benji has joined #zope3-dev | 18:56 | |
*** RaFromBRC is now known as RaFromBRC|afk | 19:10 | |
*** ChrisW has quit IRC | 19:17 | |
*** jhauser has quit IRC | 19:25 | |
*** RaFromBRC|afk is now known as RaFromBRC | 19:33 | |
*** wdickers has quit IRC | 19:37 | |
*** gump1 has joined #zope3-dev | 19:45 | |
*** gumpa has quit IRC | 19:45 | |
*** gump1 is now known as gumpa | 19:45 | |
*** nathany has quit IRC | 19:51 | |
*** nathany_ has joined #zope3-dev | 19:51 | |
*** flox has joined #zope3-dev | 19:52 | |
*** roym has joined #zope3-dev | 19:55 | |
*** stub has quit IRC | 20:07 | |
*** rock1 has joined #zope3-dev | 20:08 | |
*** srichter has quit IRC | 20:08 | |
*** dobee has quit IRC | 20:11 | |
*** rocky has quit IRC | 20:11 | |
*** drzoltron has joined #zope3-dev | 20:24 | |
drzoltron | evening | 20:25 |
drzoltron | zope throws me a "exceptions.ValueError: Unicode results must have a text content type." on upload of a doc via xml, any idea ? | 20:26 |
*** jhauser has joined #zope3-dev | 20:26 | |
*** sussi has quit IRC | 20:26 | |
*** rocky has joined #zope3-dev | 20:28 | |
*** dunny___ has joined #zope3-dev | 20:30 | |
*** rock1 has quit IRC | 20:33 | |
*** rock1 has joined #zope3-dev | 20:35 | |
*** gumpa has quit IRC | 20:39 | |
*** gump1 has joined #zope3-dev | 20:39 | |
*** rocky has quit IRC | 20:47 | |
*** svennhg has joined #zope3-dev | 20:49 | |
flox | hi again | 20:51 |
svennhg | hi | 20:52 |
*** rock1 has quit IRC | 20:52 | |
flox | previously, we need to extend interface IRegisterable in order to make a component registerable | 20:57 |
flox | what is the situation in Zope 3.3? every component is registerable, without such declaration? | 20:58 |
*** benji has quit IRC | 20:59 | |
*** baldtro1 has joined #zope3-dev | 21:03 | |
*** rocky has joined #zope3-dev | 21:04 | |
flox | hello rocky... maybe u can confirm | 21:06 |
flox | i try to figure out if we need to extend some interface to make a component 'registerable' | 21:06 |
flox | or if every component is registerable... | 21:07 |
flox | bec an (old) document states that we need to extend interface "IRegisterable" | 21:07 |
rocky | oh, i honestly don't know | 21:09 |
*** oferw has joined #zope3-dev | 21:11 | |
flox | rocky: ok thanks... | 21:13 |
flox | i see lots of deprecation ... about IRegisterable and ILocalUtility | 21:16 |
flox | i guess we do not need to extend such interface in recent Zope 3.3... but not sure | 21:16 |
*** flox is now known as flox|away | 21:18 | |
*** drzoltron has quit IRC | 21:26 | |
*** senra has joined #zope3-dev | 21:32 | |
*** oferw has quit IRC | 21:34 | |
*** senra has left #zope3-dev | 21:36 | |
*** flox|away is now known as flox | 21:42 | |
flox | <browser:tool> is gone... | 21:52 |
flox | :-( | 21:52 |
*** romanofski has joined #zope3-dev | 21:52 | |
flox | which directive we should use? | 21:53 |
*** mkerrin has quit IRC | 22:04 | |
philiKON | flox, none... | 22:23 |
philiKON | tools are stupid | 22:23 |
philiKON | flox, btw, yes, everything is now registerable | 22:24 |
philiKON | no need for ILocalUtility or IRegisterable | 22:24 |
* flox like to migrate to 3.3 | 22:27 | |
flox | i just hav to remove ILocalUtility, IRegisterable and <browser:tool>... | 22:28 |
flox | ... and chapter 17 is almost over (49 tests, 0 failures, 0 errors) | 22:29 |
flox | philiKON: good... easier to understand, now | 22:30 |
philiKON | :) | 22:30 |
flox | i will try VirtualHosting through LightTPD instead of Apache | 22:31 |
* flox is reading section 17.3 | 22:32 | |
*** sbj3 has joined #zope3-dev | 22:33 | |
baldtro1 | philiKON: i haven't seen srichter around for the last few days, had a question to ask him about his soap implementation. do you know if he's going to be back around anytime soon? | 22:38 |
*** sbj3 has quit IRC | 22:51 | |
*** alecm has joined #zope3-dev | 22:52 | |
philiKON | baldtro1, sorry, no | 22:53 |
baldtro1 | all good... relatedly, i've found the svn for zc et al projects before, but can't seem to currently. the web view points to svn locations that have moved... | 22:54 |
*** RaFromBRC has quit IRC | 23:00 | |
*** rocky has quit IRC | 23:24 | |
*** romanofs1i has joined #zope3-dev | 23:29 | |
*** RaFromBRC has joined #zope3-dev | 23:33 | |
*** romanofs1i has quit IRC | 23:34 | |
*** RaFromBRC has quit IRC | 23:35 | |
*** baldtro1 has left #zope3-dev | 23:44 | |
*** RaFromBRC has joined #zope3-dev | 23:44 | |
*** batlogg has joined #zope3-dev | 23:45 | |
*** romanofski has quit IRC | 23:45 | |
*** RaFromBRC has joined #zope3-dev | 23:46 | |
*** roym` has joined #zope3-dev | 23:53 | |
*** BjornT has quit IRC | 23:58 |
Generated by irclog2html.py 2.15.1 by Marius Gedminas - find it at mg.pov.lt!