*** alga has quit IRC | 00:15 | |
*** sashav has quit IRC | 00:33 | |
*** philiKON has joined #zope3-dev | 00:48 | |
*** d2m has quit IRC | 01:02 | |
*** gintas has quit IRC | 01:04 | |
*** RaFromBRC|sprint is now known as RaFromBRC|afk | 01:06 | |
*** srichter has quit IRC | 01:36 | |
*** RaFromBRC|afk is now known as RaFromBRC | 01:50 | |
*** RaFromBRC is now known as RaFromBRC|sprint | 01:50 | |
*** stub has joined #zope3-dev | 01:58 | |
*** stub has joined #zope3-dev | 01:58 | |
*** sashav has joined #zope3-dev | 02:10 | |
*** RaFromBRC|sprint has quit IRC | 02:12 | |
*** philiKON has quit IRC | 02:14 | |
*** RaFromBRC|sprint has joined #zope3-dev | 02:41 | |
*** GaryPoster has joined #zope3-dev | 02:57 | |
GaryPoster | hi y'all. Two related questions about datetimeutils. I needed something to localize a naive datetime.datetime (i.e., add a timezone) on the basis of system time. I decided to harden them using the approach in datetimeutils, so I leveraged some protected (_*) methods in datetimeutils and got something that does the job in five or six lines. My questions: does something like this exist already? If not, anyone mind if I check it into | 03:08 |
---|---|---|
*** bradb has quit IRC | 03:32 | |
*** GaryPoster has quit IRC | 03:39 | |
*** RaFromBRC|sprint is now known as RaFromBRC|afk | 04:55 | |
*** hazmat has quit IRC | 05:01 | |
*** `anthony has quit IRC | 05:01 | |
*** RaFromBRC|afk has quit IRC | 05:09 | |
*** sashav has quit IRC | 05:14 | |
*** bradb has joined #zope3-dev | 05:58 | |
*** stub has quit IRC | 06:08 | |
*** `anthony has joined #zope3-dev | 06:39 | |
*** bradb has quit IRC | 07:17 | |
*** SteveA has quit IRC | 07:17 | |
*** bradb has joined #zope3-dev | 07:19 | |
*** SteveA has joined #zope3-dev | 07:19 | |
*** stub has joined #zope3-dev | 08:25 | |
*** d2m has joined #zope3-dev | 08:52 | |
*** RaFromBRC|afk has joined #zope3-dev | 09:19 | |
*** Aiste has joined #zope3-dev | 09:36 | |
*** zagy has joined #zope3-dev | 09:42 | |
*** `anthony has quit IRC | 10:53 | |
*** mkerrin has joined #zope3-dev | 11:00 | |
*** dlk has joined #zope3-dev | 11:05 | |
*** RaFromBRC|afk is now known as RaFromBRC|zZz | 11:13 | |
*** __gotcha has joined #zope3-dev | 11:14 | |
*** `anthony has joined #zope3-dev | 11:16 | |
*** MalcolmC has joined #zope3-dev | 11:18 | |
*** __gotcha has quit IRC | 11:34 | |
*** __gotcha has joined #zope3-dev | 11:34 | |
*** mkerrin has left #zope3-dev | 11:41 | |
*** mkerrin has joined #zope3-dev | 11:42 | |
*** Aiste has quit IRC | 11:43 | |
*** mgedmin has joined #zope3-dev | 12:15 | |
*** J1m_ has joined #zope3-dev | 12:27 | |
*** `anthony has quit IRC | 12:49 | |
*** `anthony has joined #zope3-dev | 12:51 | |
*** srichter has joined #zope3-dev | 13:26 | |
*** ChanServ sets mode: +o srichter | 13:26 | |
*** J1m_ has quit IRC | 13:45 | |
*** vlado has joined #zope3-dev | 13:55 | |
*** __gotcha is now known as __gotchaway | 14:07 | |
*** srichter has quit IRC | 14:16 | |
*** mgedmin has quit IRC | 14:38 | |
*** niemeyer has joined #zope3-dev | 14:40 | |
*** faassen has joined #zope3-dev | 14:46 | |
*** dreamcatcher has joined #zope3-dev | 15:00 | |
dreamcatcher | niemeyer: ping | 15:01 |
niemeyer | Pong! | 15:01 |
dreamcatcher | niemeyer: trying to convince stephan to use your dateutil module for parsing dates on z3, care to pitch in? :) | 15:02 |
niemeyer | Sure! :) | 15:03 |
* niemeyer checks the mailing list | 15:03 | |
dreamcatcher | thank you | 15:03 |
*** bradb has quit IRC | 15:14 | |
*** __gotchaway has quit IRC | 15:14 | |
niemeyer | dreamcatcher: Got in the thread.. thanks for pointing it to me! | 15:20 |
dreamcatcher | np! | 15:20 |
*** srichter has joined #zope3-dev | 15:33 | |
*** ChanServ sets mode: +o srichter | 15:36 | |
*** stub has quit IRC | 16:17 | |
*** bradb has joined #zope3-dev | 16:18 | |
*** mgedmin has joined #zope3-dev | 16:24 | |
*** gintas has joined #zope3-dev | 16:27 | |
mgedmin | I have a question about menus and i18n | 16:37 |
mgedmin | are menu titles i18n message IDs? | 16:37 |
mgedmin | if so, do I need to explicitly say i18n:translate="" when I use tal:content="menuitem/title"? | 16:38 |
mgedmin | the rotterdam skin does so, and I'm not sure why | 16:38 |
srichter | I think they are message ids | 16:39 |
dreamcatcher | mgedmin: i think the rotterdam skin may predate message ids *wink* | 16:39 |
srichter | but just because you call menitem/title does not mean they get translated | 16:39 |
srichter | i18n:translate="" tells the title to be translated | 16:39 |
mgedmin | ah | 16:40 |
mgedmin | I recall a discussion on zope3-dev about automatic translation of message IDs when they are included in page templates | 16:40 |
mgedmin | at the time message IDs got translated even without i18n:translate="" | 16:41 |
mgedmin | was that changed? | 16:41 |
srichter | no, we never had this functionality | 16:41 |
* mgedmin blinks | 16:42 | |
srichter | it was proposed to do that | 16:42 |
mgedmin | I'll believe you ;-) | 16:42 |
srichter | but Jim vetoed this proposal | 16:42 |
J1m | explicit is better than implicit | 16:42 |
J1m | actually, I didn't veto the proposal | 16:43 |
J1m | because there never was a proposal | 16:43 |
J1m | When I sked for a proposal, the potential proposers ran out of steam | 16:43 |
srichter | because they saw no hope to get it passed ;-) | 16:44 |
J1m | When I asked for a proposal, the potential proposers ran out of steam | 16:44 |
srichter | which is good, I totally agree with you | 16:44 |
mgedmin | approach #12 from http://www.skirsch.com/humor/techarg.htm :-) | 16:45 |
* mgedmin changes the topic | 16:46 | |
J1m | I actually thought they were making some reasonable arguments | 16:46 |
dreamcatcher | i dont quite agree. i think it's moving explicitness the wrong way. explicitness in code should have precedence over explicitness in display, but im not too strong on that :) | 16:46 |
J1m | (I don't remember what they were) | 16:46 |
*** apoirier has joined #zope3-dev | 16:46 | |
mgedmin | if I get a 500 Internal Server Error in a functional doctest, what is the easiest way to get the traceback? | 16:46 |
J1m | I had (and still have) an open mind on the topic. | 16:46 |
J1m | ++skin++Debug | 16:46 |
J1m | If that doesn't work, or is insufficuent, then pass handle_errors=False to http | 16:47 |
J1m | Then you can do post-mortem debugging | 16:47 |
mgedmin | thanks | 16:50 |
*** Aiste has joined #zope3-dev | 16:54 | |
*** tvon has left #zope3-dev | 16:59 | |
*** SteveA has quit IRC | 17:01 | |
*** Aiste has quit IRC | 17:02 | |
*** SteveA has joined #zope3-dev | 17:05 | |
*** Aiste has joined #zope3-dev | 17:07 | |
faassen | <mgedmin> at the time message IDs got translated even without i18n:translate="" | 17:11 |
faassen | <mgedmin> was that changed? | 17:11 |
faassen | <srichter> no, we never had this functionality | 17:11 |
faassen | in Zope 2, it works that way right now. | 17:11 |
faassen | we're using this in Silva. | 17:11 |
faassen | as far as I know. | 17:11 |
*** alga has joined #zope3-dev | 17:38 | |
*** mohsen has joined #zope3-dev | 17:40 | |
*** tvon has joined #zope3-dev | 17:42 | |
*** tvon has quit IRC | 17:59 | |
*** SteveA has quit IRC | 17:59 | |
*** tvon has joined #zope3-dev | 18:02 | |
*** mohsen is now known as mohsen-away | 18:25 | |
*** SteveA has joined #zope3-dev | 18:30 | |
*** Aiste has quit IRC | 18:36 | |
*** regebro has joined #zope3-dev | 18:40 | |
regebro | Hi all! I just ran into a (mainly stylistic) problem: In CMF, when you want a form to do something, like remove attendees from a calendar event, you write a little method on the object, or make a python script. | 18:41 |
regebro | I guess in Zope3, you make a method on the view, and then configure that up as a page, right? And end the view with a redirect? | 18:42 |
regebro | Is that the "Zope3ish" way? | 18:42 |
*** bradb has quit IRC | 18:43 | |
mgedmin | I think the usual Zope 3 idiom is to have an 'update' method in the view | 18:44 |
*** bradb has joined #zope3-dev | 18:44 | |
mgedmin | that checks for various submit buttons in self.request and performs required actions | 18:45 |
mgedmin | usually you will include something like <tal:defs tal:define="dummy view/update" /> at the top of the page template | 18:45 |
mgedmin | and define a self-posting form inside | 18:45 |
*** Aiste has joined #zope3-dev | 18:46 | |
regebro | Ah, OK. Yeah, that gives a nice flexibility in how to build the forms. | 18:46 |
SteveA | mgedmin: I'd really like to get this dummy tal statement removed from page templates | 18:46 |
*** vlado has quit IRC | 18:46 | |
SteveA | mgedmin: and have the zcml page directive to have a pre-render attribute to say what attribute on the page's view's class is called | 18:47 |
SteveA | mgedmin: before the page is rendered | 18:47 |
regebro | Yeah, that would be a bit neater. | 18:48 |
regebro | OK, so I'll do the dummy thing, and I'm easily forward-updateable if we get the pre-render attribute. ;) | 18:48 |
regebro | Thanks. | 18:49 |
J1m | SteveA, I hope to propose something along those lines soon | 19:12 |
*** RaFromBRC|zZz has quit IRC | 19:15 | |
*** sashav has joined #zope3-dev | 19:16 | |
*** sm has joined #zope3-dev | 19:18 | |
*** SteveA is now known as SteveA|out | 19:20 | |
SteveA|out | J1m: I know that we talked about this a while ago. I originall proposed a magic attribute. You counter-proposed an explicit zcml attribute. I agreed, and said something about doing a proposal. | 19:21 |
*** SteveA_ has joined #zope3-dev | 19:22 | |
*** SteveA_ is now known as SteveA | 19:23 | |
J1m | Since then, I'v decided I also want to go after what CMFFormController does | 19:23 |
J1m | And Gary has done some interesting things along these lines. | 19:23 |
J1m | Which I need to review | 19:23 |
SteveA | forms isn't the only use-case for the pre-render attribute in zcml, but it is the main one. | 19:24 |
J1m | yup | 19:30 |
SteveA | so, are you still keen on a pre-render attribute, or will formcontroller-like stuff make a pre-render attribute unnecessary ? | 19:32 |
J1m | I don't know the details at the moment. :) | 19:33 |
J1m | I'm keen on a silution to the problem soon. | 19:33 |
J1m | I'm keen on a solution to the problem soon. | 19:33 |
SteveA | ok | 19:34 |
*** dlk has quit IRC | 19:38 | |
SteveA | >>> from zope.interface import Interface | 19:38 |
SteveA | >>> Interface.implementedBy({}) | 19:38 |
SteveA | Traceback (most recent call last): | 19:38 |
SteveA | File "<stdin>", line 1, in ? | 19:38 |
SteveA | File "/home/code/Launchpad/launchpad/lib/zope/interface/declarations.py", line 314, in implementedByFallback | 19:38 |
SteveA | spec = BuiltinImplementationSpecifications.get(cls) | 19:38 |
SteveA | TypeError: dict objects are unhashable | 19:38 |
SteveA | 19:39 | |
SteveA | should this raise a TypeError? Or should it just return False? | 19:39 |
*** RaFromBRC has joined #zope3-dev | 19:40 | |
J1m | It should raise a TypeError. | 19:41 |
J1m | But, later, I'm not so sure | 19:41 |
SteveA | >>> Interface.implementedBy(1) | 19:41 |
SteveA | False | 19:41 |
SteveA | 19:42 | |
SteveA | either {} and 1 should raise TypeError, or {} and 1 should return False | 19:42 |
J1m | Right. | 19:42 |
J1m | I'd say that a non-callable object should raise TypeError and that a callable object should return False | 19:42 |
*** __gotcha has joined #zope3-dev | 19:43 | |
*** SteveA|out has quit IRC | 19:43 | |
SteveA | makes sense for factories in general. | 19:43 |
SteveA | I don't think bool(something) ever fails | 19:44 |
SteveA | unless you maliciously make __nonzero__ or __len__ raise | 19:44 |
__gotcha | SteveA: hi | 19:45 |
SteveA | hi godefroid | 19:45 |
__gotcha | just a small question | 19:45 |
__gotcha | is it correct that views have been replaced by multiadapters ? | 19:45 |
__gotcha | or a wrong supposition ? | 19:45 |
SteveA | views are implemented using multiadapters | 19:45 |
SteveA | there's still the notion of presentation components | 19:46 |
SteveA | and a view is a kind of presentation component | 19:46 |
__gotcha | ok | 19:46 |
__gotcha | thanks | 19:46 |
SteveA | but at the implementation level, they're all adapters | 19:46 |
__gotcha | iam I correct if I think that vew being adapters is recent | 19:47 |
__gotcha | iam I correct if I think that views being adapters is recent | 19:47 |
SteveA | kind of | 19:47 |
__gotcha | ok | 19:47 |
__gotcha | just to put the pieces together | 19:47 |
SteveA | they were always very much adapters, but recently they were unified into a single registry | 19:47 |
__gotcha | thanks a lot | 19:47 |
__gotcha | that was what i thought I had understood | 19:47 |
__gotcha | cioa | 19:48 |
*** __gotcha has quit IRC | 19:48 | |
*** Theuni has quit IRC | 20:04 | |
*** MalcolmC has quit IRC | 20:05 | |
*** RaFromBRC has quit IRC | 20:20 | |
*** BjornT has quit IRC | 20:26 | |
*** gintas has quit IRC | 20:29 | |
*** sashav has quit IRC | 20:30 | |
*** regebro has quit IRC | 20:36 | |
*** philiKON has joined #zope3-dev | 20:44 | |
*** apoirier has quit IRC | 20:48 | |
*** Aiste has quit IRC | 20:53 | |
*** faassen has quit IRC | 20:53 | |
*** mkerrin has left #zope3-dev | 20:55 | |
*** BjornT has joined #zope3-dev | 20:59 | |
*** gintas has joined #zope3-dev | 21:18 | |
mgedmin | how do I extract the real object from a ContainedProxy? | 21:27 |
mgedmin | neither removeAllProxies nor getProxiedObject seem to work | 21:28 |
mgedmin | ah, there are (at least) two different functions called getProxiedObject | 21:30 |
mgedmin | if I import the one from zope.app.container.container (instead of zope.proxy), then it works | 21:30 |
J1m | Of course :) | 21:30 |
* mgedmin kan't spell | 21:32 | |
mgedmin | (I meant zope.app.container.contained and zope.security.proxy) | 21:32 |
*** upsidedown has joined #zope3-dev | 21:42 | |
upsidedown | hi all | 21:45 |
upsidedown | can one tell me how to run all tests in zope 3 | 21:46 |
upsidedown | I'm using windows XP | 21:46 |
alga | make python be on your path and then run 'python test.py' | 21:47 |
alga | ? | 21:47 |
upsidedown | from within zope directory ? | 21:47 |
alga | are you using a checkout or a release? | 21:48 |
upsidedown | release | 21:48 |
alga | ah | 21:48 |
*** dae has joined #zope3-dev | 21:49 | |
upsidedown | I see, there is a test.py in the trunk | 21:50 |
alga | then it should work | 21:51 |
upsidedown | thanks | 21:51 |
alga | no problem | 21:51 |
*** sashav has joined #zope3-dev | 21:56 | |
*** sashav has quit IRC | 22:04 | |
*** hazmat has joined #zope3-dev | 22:10 | |
upsidedown | test.py does not do any test in my release version ? | 22:14 |
*** sashav has joined #zope3-dev | 22:14 | |
*** tvon has quit IRC | 22:18 | |
alga | OK | 22:25 |
alga | I downloaded the release | 22:25 |
alga | unpacked it | 22:25 |
alga | ran ./configure | 22:25 |
alga | ran make | 22:26 |
alga | and now 'python test.py' is running the tests | 22:26 |
upsidedown | on linux ? | 22:26 |
alga | I don't know what the equivalents are in the Windows package | 22:26 |
alga | yes | 22:26 |
upsidedown | where is test.py on your release | 22:27 |
alga | configure.bat and make.bat? :-) | 22:27 |
alga | ZopeX3-3.0.0/test.py | 22:27 |
alga | but it did not work before ./configure && make | 22:27 |
alga | hope it helps ;-) | 22:27 |
upsidedown | on windows you don't need to do configure and make on the release version | 22:28 |
upsidedown | I copied test.py from the trunk and run it | 22:28 |
upsidedown | make on windows is not that easy | 22:29 |
upsidedown | but thanks for your help | 22:29 |
upsidedown | should change to linux ;) | 22:30 |
mgedmin | isn't there a bin/test in INSTANCE_HOME? | 22:33 |
*** mgedmin has quit IRC | 22:33 | |
upsidedown | right and it runs my tests in the instance | 22:38 |
upsidedown | when I try to run tests on zope with --dir option it get a traceback | 22:39 |
upsidedown | File "C:\PROGRA~1\python23\Lib\site-packages\zope\app\tests\test.py", line 541, in visit | 22:40 |
upsidedown | __import__(pkg) | 22:40 |
upsidedown | ValueError: Empty module name | 22:40 |
*** upsidedown has left #zope3-dev | 22:47 | |
*** bradb has quit IRC | 22:57 | |
*** niemeyer has quit IRC | 23:06 | |
*** zagy has quit IRC | 23:11 | |
*** gintas has quit IRC | 23:20 | |
*** mgedmin has joined #zope3-dev | 23:38 | |
*** d2m has quit IRC | 23:52 |
Generated by irclog2html.py 2.15.1 by Marius Gedminas - find it at mg.pov.lt!