2007-07-25T00:21:57  <CIA-27> moin: Thomas Waldmann <tw AT waldmann-edv DOT de> * 2207:bdc72820175b 1.6-docbook-mvirkill/MoinMoin/ (4 files in 3 dirs): fix send_page calls - it does not get a request param any more
2007-07-25T08:44:34  <ThomasWaldmann> moin
2007-07-25T09:00:03  <lanius> moin
2007-07-25T09:07:38  <ThomasWaldmann> hi lanius
2007-07-25T09:08:12  <ThomasWaldmann> lanius: http://hg.moinmo.in/moin/1.7-storage-hwendel/rev/638962ee399d there is a strange looking hunk for fs_moin16.py
2007-07-25T09:14:09  <ThomasWaldmann> lanius: ignore that, i guess it is just "textfile as iterator"
2007-07-25T09:15:31  <lanius> yeah
2007-07-25T09:18:36  <ThomasWaldmann> any plans for the not working "cache invalidating by events" stuff?
2007-07-25T09:23:47  <ThomasWaldmann> lanius: http://hg.moinmo.in/moin/1.7-storage-hwendel/rev/ac106da04e3c is unclean, it contains 2 unrelated changes (and it looks like you have to revert half of it)
2007-07-25T09:25:02  <ThomasWaldmann> except if we had some interprocess event system rsn :)
2007-07-25T10:40:07  <lanius> grzywacz: what about an interprocess event system rsn?
2007-07-25T10:44:49  <johill> I thought about adding a macro that documents macro parameters
2007-07-25T10:44:50  <johill> however
2007-07-25T10:45:01  <johill> I noticed that the table of contents macro is rather strange
2007-07-25T10:46:24  <johill> so this is what I came up with: http://johannes.sipsolutions.net/patches/moin/rewrite-toc2.patch
2007-07-25T10:46:28  <johill> thoughts?
2007-07-25T10:50:13  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2557:cc5a81bda460 1.7/MoinMoin/ (_tests/test_wikiutil.py wikiutil.py): allow the invoke_extension_function to invoke constructors too
2007-07-25T10:50:17  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2558:fb05ca2c0bdc 1.7/MoinMoin/ (_tests/test_wikiutil.py wikiutil.py): allow using complex datatype in macros
2007-07-25T10:50:19  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2559:ba76f4025416 1.7/MoinMoin/wikiutil.py: stricter argument checking for required_arg
2007-07-25T10:50:24  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2560:575541d1fdb4 1.7/MoinMoin/wikiutil.py: consolidate isinstance calls
2007-07-25T11:08:40  <ThomasWaldmann> johill: the TOC stuff is maybe a bit too invasive
2007-07-25T11:09:04  <johill> heh :)
2007-07-25T11:09:16  <ThomasWaldmann> e.g. iirc send_page has a parameter not to send http headers, so just use it
2007-07-25T11:10:09  <johill> ah, yeah there was content_only
2007-07-25T11:10:19  <ThomasWaldmann> then there is redirectedOutput
2007-07-25T11:11:09  <johill> oh
2007-07-25T11:13:01  <johill> good point
2007-07-25T11:13:31  <johill> that works well
2007-07-25T11:13:32  <johill> btw
2007-07-25T11:14:07  <johill> there is a strange caching bug
2007-07-25T11:14:15  <johill> if you have a page that is cached
2007-07-25T11:14:18  <johill> as bytecode
2007-07-25T11:14:23  <johill> and then you delete a macro
2007-07-25T11:14:45  <ThomasWaldmann> then you have a problem maybe
2007-07-25T11:15:07  <johill> then the page runs as bytecode, tries to load the macro and gives you an ImportError in the middle of the page
2007-07-25T11:16:50  <ThomasWaldmann> the workaround is to globally delete the cache
2007-07-25T11:17:51  <johill> it's quite hard to reproduce but very annoying
2007-07-25T11:17:54  <johill> no
2007-07-25T11:18:00  <johill> it's not a bug with this macro
2007-07-25T11:21:58  <johill> it happens with all macros that  have only page dependencies
2007-07-25T11:22:50  <ThomasWaldmann> i guess it happens with all macros that are dynamically executed
2007-07-25T11:24:13  <ThomasWaldmann> that rewrite-toc2 patch is a bit mixed: toc stuff and new arg parser stuff
2007-07-25T11:25:32  <ThomasWaldmann> +        if name == 'TableOfContents':
2007-07-25T11:25:33  <ThomasWaldmann> +            return ''
2007-07-25T11:25:53  <ThomasWaldmann> shouldnt that also happen in the respective formatter method?
2007-07-25T11:26:23  <ThomasWaldmann> (if generating_toc: return '' ?)
2007-07-25T11:27:15  <johill> ThomasWaldmann: yes
2007-07-25T11:27:20  <johill> well
2007-07-25T11:27:31  <johill> I decided that all macros that don't generate headings will be shortcutted so they don't do any work
2007-07-25T11:29:10  <johill> otherwise generating the toc takes forever since all the macros actually do things
2007-07-25T11:29:42  <ThomasWaldmann> yeah, that's why you introduced this generating_toc stuff
2007-07-25T11:30:47  <johill> oh wait I misread your comment
2007-07-25T11:31:01  <johill> what do you mean respective formamtter method?
2007-07-25T11:31:15  <ThomasWaldmann> why is TOCFormatter.macro dealing with saving/setting/restoring the formatter? isn't the old/new/restored formatter the TOCformatter anyway?
2007-07-25T11:31:58  <ThomasWaldmann> i mean not to check that in TOCformatter.macro, but in TableOfContents macro
2007-07-25T11:32:39  <johill> ?
2007-07-25T11:32:46  <ThomasWaldmann> (like you did for any other macro)
2007-07-25T11:32:53  <johill> ah
2007-07-25T11:33:39  <johill> you mean I should use macro.generating_toc to shortcut it
2007-07-25T11:33:58  <ThomasWaldmann> yes
2007-07-25T11:34:03  <johill> sure
2007-07-25T11:34:08  <johill> I had this shortcut before
2007-07-25T11:34:21  <johill> otherwise it would loop infinitely of course and crash with a stack overflow
2007-07-25T11:34:31  <johill> and then when it worked it was slow and I did this
2007-07-25T11:35:10  <ThomasWaldmann> it was slow?
2007-07-25T11:35:43  <johill> well when all macros were invoked twice
2007-07-25T11:35:52  <johill> the reason I wanted this btw is this: http://johannes.sipsolutions.net/patches/moin/macro-autodoc.patch
2007-07-25T11:36:54  <johill> check out http://131.234.73.245:8080/macrodoc
2007-07-25T11:37:33  <johill> (trailing is a local macro for testing)
2007-07-25T11:39:19  <johill> (as is test)
2007-07-25T11:40:59  <ThomasWaldmann> nice :)
2007-07-25T11:42:14  <ThomasWaldmann> but i18n will be difficult
2007-07-25T11:42:40  <johill> yeah
2007-07-25T11:42:51  <johill> I thought making it another module attribute
2007-07-25T11:42:54  <johill> instead of using the docstring
2007-07-25T11:43:51  <ThomasWaldmann> but maybe we can simply use one auto-generated english page and translators then do manually translate the rendered page
2007-07-25T11:45:37  <ThomasWaldmann> johill: about the TOC macro again. it will be invoked twice, like all other macros, too. i dont see why this is noticeable slower than it is anyways.
2007-07-25T11:46:05  <ThomasWaldmann> (so that specialcasing this gives some value)
2007-07-25T11:47:14  <johill> no no
2007-07-25T11:47:27  <johill> the thing is that if all macros are invoked and do work, then generating the toc is slow
2007-07-25T11:47:48  <johill> like getting a page count while we're only generating the toc
2007-07-25T11:48:09  <ThomasWaldmann> yeah, i dont tell you to remove the shortcutting
2007-07-25T11:48:43  <ThomasWaldmann> but to do it all in the macros
2007-07-25T11:48:46  <johill> yes
2007-07-25T11:48:48  <johill> I just updated the patch
2007-07-25T11:48:57  * ThomasWaldmann reloads
2007-07-25T11:48:59  <johill> well the macro doc macro does it differently because it actually generates headings
2007-07-25T11:49:41  <johill> sorry forgot to uploade, reload again
2007-07-25T11:50:24  <ThomasWaldmann> why is TOCFormatter.macro dealing with saving/setting/restoring the formatter? isn't the old/new/restored formatter the TOCformatter anyway?
2007-07-25T11:51:28  <johill> yeah
2007-07-25T11:51:32  * johill removes
2007-07-25T11:51:55  <ThomasWaldmann> a hack would be to use __getattr__ for everything returning empty X)
2007-07-25T11:52:27  <johill> hm. rather returning a lambda that takes anything and returns empty
2007-07-25T11:52:43  <johill> but that doesn't work because there are some functions I don't override
2007-07-25T11:52:45  <johill> like setPage
2007-07-25T11:53:08  <johill> oh btw
2007-07-25T11:53:15  <johill> never mind
2007-07-25T11:53:18  <johill> thought gone wrong ;)
2007-07-25T11:53:36  <johill> I wonder if I should parse pydoc tho
2007-07-25T11:53:43  <johill> instead of param:: use @param param:
2007-07-25T11:56:43  <ThomasWaldmann> would be nice because we generate docs by epydoc, too
2007-07-25T11:57:05  <johill> yeah
2007-07-25T11:57:15  <johill> I just didn't find docs about the pydoc module
2007-07-25T11:58:01  <ThomasWaldmann> btw, the new code looks much better than the old :D
2007-07-25T11:58:20  <johill> which?
2007-07-25T11:58:25  <ThomasWaldmann> toc
2007-07-25T11:58:49  <johill> ah
2007-07-25T11:58:50  <johill> :)
2007-07-25T11:58:50  <ThomasWaldmann> (the opposite would've been rather impossible, though :D)
2007-07-25T11:59:32  <johill> heh
2007-07-25T12:03:27  <ThomasWaldmann> btw, formatter/pagelinks does a similar approach
2007-07-25T12:04:17  <ThomasWaldmann> maybe we could put those 2 special formatters into 1 to save passes?
2007-07-25T12:07:26  <ThomasWaldmann> hmm, maybe no good idea. pagelinks only depends on page content of a single page, so we have to run it only after saving. but toc depends also on included pages...
2007-07-25T12:09:34  <ThomasWaldmann> (btw, before you start hacking Include macro, be aware that there is an alternative "Insert" macro in the 1.6-docbook branch that needs review)
2007-07-25T12:09:40  <johill> heh
2007-07-25T12:09:46  <johill> I don't think I would hack that thing ;)
2007-07-25T12:09:57  <johill> toc was easy. just replace it :P
2007-07-25T12:10:09  <ThomasWaldmann> it is similar ugly as toc :))
2007-07-25T12:10:25  <johill> yeah
2007-07-25T12:10:54  <johill> hm
2007-07-25T12:11:03  <johill> pydoc doesn't have any nice function for extracting that
2007-07-25T12:11:10  <johill> in fact, the code there looks in dire need of refactoring
2007-07-25T12:11:38  <johill> I suppose an RE would work though
2007-07-25T12:11:55  <ThomasWaldmann> btw, we use epydoc (not pydoc?)
2007-07-25T12:12:23  <johill> similar syntax though, no?
2007-07-25T12:13:17  <ThomasWaldmann> i never used pydoc, so I am not sure it is the same. but I guess similar, yes.
2007-07-25T12:13:41  <johill> well how about I just use an RE then, something like
2007-07-25T12:14:09  <johill> '@param ([^:]*):<something>'
2007-07-25T12:14:17  <johill> where something needs to go until the next @param or the end or something
2007-07-25T12:15:33  <johill> but that doesn't help with translations either
2007-07-25T12:15:58  <ThomasWaldmann> sounds ok
2007-07-25T12:16:59  <ThomasWaldmann> the docstring could go through the wiki parser X)
2007-07-25T12:17:05  <johill> it does actually right now
2007-07-25T12:17:09  <johill> I put it through getText
2007-07-25T12:17:44  <johill> which has problems too
2007-07-25T12:17:48  <johill> usually, docstrings are indented
2007-07-25T12:17:54  <johill> that makes it look rather weird
2007-07-25T12:18:27  <ThomasWaldmann> otoh if you dont indent them, the py src looks rather weird
2007-07-25T12:19:50  <ThomasWaldmann> a easy way would be to lstrip max(1stline, 2ndline) from all docstring lines
2007-07-25T12:20:13  <johill> that'd work, yeah, if you exclude the first line if it's empty
2007-07-25T12:20:17  <ThomasWaldmann> (amount of space I mean)
2007-07-25T12:20:34  <johill> yeah
2007-07-25T12:21:00  <ThomasWaldmann> you dont need to exclude 1st, if there is no space, max will choose 2nd line
2007-07-25T12:22:01  <ThomasWaldmann> hm, but you need to include 3rd line maybe
2007-07-25T12:22:09  <ThomasWaldmann> for cases like
2007-07-25T12:22:15  <ThomasWaldmann> """bla bla
2007-07-25T12:22:25  <ThomasWaldmann> <empty>
2007-07-25T12:22:33  <ThomasWaldmann>     more docs....
2007-07-25T12:22:36  <ThomasWaldmann> """
2007-07-25T12:24:19  <johill> I think I need to exclude all empty lines from the max
2007-07-25T12:25:52  <ThomasWaldmann> another approach would be to search for minimum indentation that is >= 4
2007-07-25T12:26:00  <ThomasWaldmann> (of all lines)
2007-07-25T12:35:32  <johill> hm
2007-07-25T12:35:41  <johill> why does request.getText not make paragraphs?
2007-07-25T12:37:40  <ThomasWaldmann> for empty lines in wiki markup?
2007-07-25T12:38:23  <johill> yes
2007-07-25T12:38:38  <ThomasWaldmann> dont remember
2007-07-25T12:40:40  <ThomasWaldmann> hmm, that formatter.page.page_name usage as "current page" seems to be broken
2007-07-25T12:41:55  <ThomasWaldmann> (this was a general commet, unrelated to johills code :)
2007-07-25T12:41:59  <ThomasWaldmann> +n
2007-07-25T12:43:45  <johill> use what else?
2007-07-25T12:44:51  <ThomasWaldmann> i have to debug that further, maybe request.page.page_name
2007-07-25T12:45:24  <zenhase> moin
2007-07-25T12:46:10  <ThomasWaldmann> the problem with formatter.page.page_name can be seen when there are multiple Insert macros including sub pages (docbook branch), maybe it is also broken for multiple Includes of sub pages
2007-07-25T12:46:28  <zenhase> should i pay attention to anything special when merging?
2007-07-25T12:46:34  <ThomasWaldmann> after rendering the first sub pages, formatter.page.page_name will be that sub page, not the original page
2007-07-25T12:47:04  <ThomasWaldmann> zenhase: that you merge correctly if there are conflicts :)
2007-07-25T12:47:48  <zenhase> ThomasWaldmann: hrhr, i thought that. :>
2007-07-25T12:47:59  <ThomasWaldmann> and that you just commit the merge after doing it (no further changes)
2007-07-25T12:48:20  <ThomasWaldmann> -m "merged main"
2007-07-25T12:48:26  <zenhase> ok
2007-07-25T12:49:04  <johill> so what's the solution?
2007-07-25T12:49:04  <zenhase> i still need to get aquainted with those diff3 tools or what those are
2007-07-25T12:49:14  <ThomasWaldmann> and after merging, use py.test and run all tests
2007-07-25T12:49:34  <ThomasWaldmann> there should be no failing test
2007-07-25T12:49:39  <zenhase> when i had conflicts on my macbook suddenly a graphical merge-tool popped up
2007-07-25T12:50:04  <ThomasWaldmann> hg can use different merge tools
2007-07-25T12:50:08  <zenhase> never used one of those, but it looked nice
2007-07-25T12:50:46  <ThomasWaldmann> (I personally don't use anything special, then it just puts <<<<<<<< ----- >>>>>>> into the code and shows your $EDITOR)
2007-07-25T12:52:00  <ThomasWaldmann> after you have fixed the failing tests, uninstall genshi package and run the tests again
2007-07-25T12:52:47  <ThomasWaldmann> btw, if you have lots of trailing whitespace errors: test_sourcecode.py can fix those automatically, just look into the src
2007-07-25T12:57:22  <ThomasWaldmann> bbl
2007-07-25T13:02:50  <zenhase> l8a thomas
2007-07-25T13:06:44  <vpv> I installed kdiff3 on my system and for some reason hg used it automatically as a merge tool
2007-07-25T13:07:46  <vpv> I couldn't figure out how to use it or how to disable it from hg, so I had to remove the package and now I have vim again, at least that's clear
2007-07-25T13:39:01  * xorAxAx sighs
2007-07-25T13:39:51  <xorAxAx> about a patch that went into 1.3
2007-07-25T13:39:53  <xorAxAx> by thomas :)
2007-07-25T13:42:16  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2561:d9c2701a0a5d 1.7/MoinMoin/macro/BR.py: 'port' BR macro to new system, document it
2007-07-25T13:42:17  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2562:b76d66ed0251 1.7/MoinMoin/macro/ (Include.py TableOfContents.py): new tableofcontents macro using a formatter
2007-07-25T13:47:20  <ThomasWaldmann> xorAxAx: which? there are quite a few :D
2007-07-25T13:47:36  <xorAxAx> ThomasWaldmann: the one that introduces request.page :)
2007-07-25T13:47:55  <grzywacz> johill, rsn?
2007-07-25T13:47:59  <grzywacz> moin everyone
2007-07-25T13:48:03  <xorAxAx> johannes (next to me) and i wondered why it exists at all
2007-07-25T13:48:15  <xorAxAx> hi my student
2007-07-25T13:48:23  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2563:389e427e5bfb 1.7/MoinMoin/macro/TableOfContents.py: fix slight bug with TOC macro vs. built-in macros
2007-07-25T13:48:39  <grzywacz> hello xorAxAx, how do you feel about your exam? ;)
2007-07-25T13:48:46  <xorAxAx> grzywacz: so so
2007-07-25T13:48:58  <ThomasWaldmann> johill: iirc, it was for optimization reasons, so you don't have to recreate it again and again
2007-07-25T13:49:00  <johill> grzywacz: ? rsn = real soon now but I don't think I said anything about that?
2007-07-25T13:49:09  <xorAxAx> ThomasWaldmann: there is formatter.page
2007-07-25T13:49:12  <grzywacz> johill, interprocess event system rsn :p
2007-07-25T13:49:31  <xorAxAx> grzywacz: that was thomas or reimar
2007-07-25T13:49:32  <ThomasWaldmann> xorAxAx: yeah, and that's just another problem as I found recently :)
2007-07-25T13:49:41  <xorAxAx> reimar usually uses weird abbreviations
2007-07-25T13:49:45  <grzywacz> argh
2007-07-25T13:49:47  <ThomasWaldmann> really soon now
2007-07-25T13:49:48  <grzywacz> it was lanius 8)
2007-07-25T13:49:51  <xorAxAx> or lanius
2007-07-25T13:49:59  <grzywacz> johill, sorry
2007-07-25T13:50:02  <johill> heh np
2007-07-25T13:50:10  <xorAxAx> ThomasWaldmann: why is that a problem?
2007-07-25T13:50:25  <grzywacz> ThomasWaldmann, lanius, how do you actually imagine that interprocess stuff to be done in a portable manner? over tcp/ip? :P
2007-07-25T13:50:27  <ThomasWaldmann> because it is mostly use as "current page"
2007-07-25T13:50:33  <ThomasWaldmann> but it is not
2007-07-25T13:51:04  <xorAxAx> well, formatter.page has less design issues that request.page
2007-07-25T13:51:13  <ThomasWaldmann> as soon as someone calls send_page (e.g. for an included page), it will change
2007-07-25T13:51:50  <ThomasWaldmann> which concrete issues are there with r.p?
2007-07-25T13:52:41  <xorAxAx> it is being set by request and in some contexts the request code isnt run
2007-07-25T13:52:45  <xorAxAx> e.g. in unittests
2007-07-25T13:52:57  <lanius> grzywacz: i have no idea
2007-07-25T13:53:03  <grzywacz> oh ;)
2007-07-25T13:53:11  <xorAxAx> we fixed it by using formatter.page instead of request.page
2007-07-25T13:53:30  <ThomasWaldmann> now fix formatter.page (and safe me work :))
2007-07-25T13:53:49  <ThomasWaldmann> (in 1.6 please :)
2007-07-25T13:53:58  <xorAxAx> well, whats broken?
2007-07-25T13:54:15  <ThomasWaldmann> (13:51) < ThomasWal> as soon as someone calls send_page (e.g. for an included page), it will change
2007-07-25T13:54:54  <ThomasWaldmann> that means [[Insert(/subpage1)]] [[Insert(/subpage2)]] will be broken
2007-07-25T13:55:21  <ThomasWaldmann> (I didnt try Include yet, but could have same problems)
2007-07-25T13:55:58  <grzywacz> lanius, I'm afraid the only way to let X processes communicate with each other in a portable manner requires a separate request router process
2007-07-25T13:56:13  <ThomasWaldmann> grzywacz: on disk
2007-07-25T13:56:14  <grzywacz> lanius, but I'll take a look at Django first, they have some clever, self-updating cache there
2007-07-25T13:56:36  <grzywacz> ThomasWaldmann, what about it?
2007-07-25T13:56:44  <grzywacz> ThomasWaldmann, aren
2007-07-25T13:56:46  <grzywacz> argh
2007-07-25T13:56:49  <ThomasWaldmann> (we still have cgi support)
2007-07-25T13:56:52  <xorAxAx> ThomasWaldmann: well, thats orthogonal to the issue we had :)
2007-07-25T13:57:07  <grzywacz> ThomasWaldmann, aren't we trying to support other storage backends anyway?
2007-07-25T13:57:15  <grzywacz> (other than flat file)
2007-07-25T13:57:18  <ThomasWaldmann> xorAxAx: maybe, but you might see more and new bugs now
2007-07-25T13:58:05  <ThomasWaldmann> grzywacz: you can use the storage backend to communicate
2007-07-25T13:58:32  <grzywacz> That's an abstract idea.
2007-07-25T13:58:41  <ThomasWaldmann> but we should not require some long running router process for running moin
2007-07-25T13:58:42  <lanius> grzywacz: sounds cool
2007-07-25T13:58:43  <xorAxAx> grzywacz: do we have a use case for that multistuff stuff?
2007-07-25T13:59:03  <grzywacz> xorAxAx, updating cache in separate, long-living processes?
2007-07-25T13:59:09  <xorAxAx> grzywacz: which caches?
2007-07-25T13:59:24  <grzywacz> No idea, some caches that are going to appear. ;-)
2007-07-25T13:59:27  <lanius> i tried to use it for the item cache in the backend
2007-07-25T13:59:28  <grzywacz> ThomasWaldmann, lanius.
2007-07-25T13:59:39  <lanius> after that i realized that it is not thread safe
2007-07-25T13:59:55  <ThomasWaldmann> s/thread/multiprocess/
2007-07-25T14:00:13  <lanius> not thread safe as well
2007-07-25T14:00:19  <xorAxAx> well, make a wiki page, describe requirements
2007-07-25T14:00:21  <xorAxAx> give me the URL
2007-07-25T14:00:54  <ThomasWaldmann> xorAxAx: you and johill are pair programming?
2007-07-25T14:01:04  <xorAxAx> yes
2007-07-25T14:01:39  <grzywacz> woot?
2007-07-25T14:06:36  <ThomasWaldmann> grzywacz: did you add some hint about multiprocess/multithreading not being supported by the current event system?
2007-07-25T14:06:54  <grzywacz> ThomasWaldmann, why would it be supported in the first place?
2007-07-25T14:08:28  <ThomasWaldmann> the problem is that it can be easily overlooked
2007-07-25T14:08:34  <grzywacz> The current solution is meant to make processing of one request simpler, by removing hard-coded solutions all around.
2007-07-25T14:09:00  <grzywacz> ThomasWaldmann, overlooked? Please explain what you mean.
2007-07-25T14:09:01  <ThomasWaldmann> sure (and that is fine), but we should avoid wrong usage of it
2007-07-25T14:09:27  <ThomasWaldmann> see lanius' recent refactoring of refresh()
2007-07-25T14:10:11  <lanius> so lets just port moinmoin to django ;)
2007-07-25T14:10:36  <grzywacz> lanius, I really did think about any good reason why we support so much custom code :P
2007-07-25T14:10:46  <grzywacz> ThomasWaldmann, can't find it, url?
2007-07-25T14:11:06  <xorAxAx> lanius: did you start the wiki page?
2007-07-25T14:11:20  <lanius> just listening to some unicode tutorials
2007-07-25T14:11:42  <ThomasWaldmann> http://hg.moinmo.in/moin/1.7-storage-hwendel/rev/ac106da04e3c
2007-07-25T14:11:44  <xorAxAx> without knowing what the goal is we cannot think about a solution
2007-07-25T14:11:57  <grzywacz> Obviously, and the goal is rather fuzzy atm.
2007-07-25T14:12:12  <ThomasWaldmann> interprocess events
2007-07-25T14:12:32  <lanius> right, that describes it in two words
2007-07-25T14:12:36  <xorAxAx> thats a useless requirement :)
2007-07-25T14:12:45  <xorAxAx> please write down what is cached, how it should be invalidated
2007-07-25T14:12:45  <lanius> sometimes its so simple
2007-07-25T14:13:04  <xorAxAx> and dont even think about how to solve it - that would be the second step
2007-07-25T14:14:06  <grzywacz> lanius, please rename storagenotify.py to something like cacheinvalidation.py, there's no notification (as via email or jabber or ...) going on in there. :)
2007-07-25T14:14:34  <lanius> sure there is notification, notification of the storage backend about a changed page/user
2007-07-25T14:15:16  <grzywacz> Following that train of thought every file should end with "notification", because function calls are notifications. ;-)
2007-07-25T14:16:08  <lanius> no, that's a different level of thinking
2007-07-25T14:16:46  <lanius> function call is a low level programming ting, notification is a design
2007-07-25T14:17:33  <xorAxAx> yes, thats a usual term in the context of the observer pattern
2007-07-25T14:18:04  <grzywacz> Yes, but in terms on events I'd rather see "notify" being left for real notifications.
2007-07-25T14:18:45  <lanius> no, notifications need not be passed to users
2007-07-25T14:18:51  <xorAxAx> grzywacz: yeah, makes sense
2007-07-25T14:19:27  <lanius> that's why there is something before notification "email" indicates it goes to a user "storage" indicates it goes to the storage system
2007-07-25T14:21:08  <xorAxAx> lanius: his point is that in the realm of the event system, notification should be restricted to user interaction because otherwise every module would be called foonotitifaction which is a redundant bit because of the package path MoinMoin.events
2007-07-25T14:22:15  <lanius> grzywacz: django seems to use a separate process which does tcp/ip with caching
2007-07-25T14:24:35  <ThomasWaldmann> not every user is allowed to install/run long running processes
2007-07-25T14:25:03  <ThomasWaldmann> so just forget that until we decide to drop support for cgi
2007-07-25T14:25:24  <lanius> go django, go
2007-07-25T14:25:27  <lanius> :D
2007-07-25T14:27:41  <ThomasWaldmann> how about using some special item $EVENTS$ and use its revision metadata for events? obviously we'll need some purge strategy for this, but we need that anyway sooner or later.
2007-07-25T14:28:13  <lanius> sounds like putting something onto something it wasn't designed for
2007-07-25T14:28:22  <xorAxAx> ThomasWaldmann: can we talk about this after the wiki page has been written?
2007-07-25T14:28:30  <xorAxAx> so we know what the problem is ?
2007-07-25T14:28:40  <lanius> thomas seems to know what the problem is
2007-07-25T14:28:48  <xorAxAx> then he should describe it
2007-07-25T14:29:03  <lanius> sometimes you just have to think simpler
2007-07-25T14:29:04  <ThomasWaldmann> (or just use the special global $editlog$ item for everything related to page changes)
2007-07-25T14:29:49  <lanius> interprocess cache for any kind of python object in memory
2007-07-25T14:29:57  <ThomasWaldmann> i have to go now anyway :) bbl
2007-07-25T14:30:50  * xorAxAx sighs loudly
2007-07-25T14:36:49  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2564:92a7f41c3cad 1.7/MoinMoin/macro/TableOfContents.py: don't overwrite rawHTML in toc macro
2007-07-25T14:36:50  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2565:7c400e439160 1.7/MoinMoin/macro/Include.py: fix bug in include macro: needs to use rawHTML
2007-07-25T14:56:32  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2566:d5ef57193ccb 1.7/MoinMoin/ (5 files in 4 dirs): (johill, xorAxAx) make formatter responsible for making heading IDs unique
2007-07-25T14:56:33  <johill> hah
2007-07-25T14:56:37  <johill> fixes the long-standing include bug too
2007-07-25T14:59:13  <xorAxAx> yep
2007-07-25T15:00:26  <grzywacz> lanius, really? Then it doesn't differ from my idea. Not that I'm surprised, 'cos I really think there's no other way ;]
2007-07-25T15:00:52  <lanius> to what are you referring now?
2007-07-25T15:01:24  <grzywacz> lanius, separate process in django
2007-07-25T15:01:37  <lanius> ah, ok, yes
2007-07-25T15:01:44  <lanius> http://www.djangoproject.com/documentation/cache/
2007-07-25T15:02:24  <xorAxAx> arrrrrrrgh
2007-07-25T15:02:33  <grzywacz> xorAxAx, ?
2007-07-25T15:04:29  <xorAxAx> grzywacz: well, a solution discussion without a list of problems or requirements
2007-07-25T15:04:52  <grzywacz> xorAxAx, ;-)))
2007-07-25T15:05:06  <lanius> problem: performance, requirement: be faster
2007-07-25T15:05:34  <xorAxAx> lanius: no, the caches are the problem
2007-07-25T15:05:45  <xorAxAx> which caches exist and when do they need to be invalidated
2007-07-25T15:05:51  <xorAxAx> which caches do you want to introduce
2007-07-25T15:06:21  <lanius> a cache for Items, invalidate when item changes
2007-07-25T15:08:49  <xorAxAx> what do you want to cache of the item?
2007-07-25T15:09:01  <lanius> the whole Item
2007-07-25T15:10:33  <lanius> as python object
2007-07-25T15:11:45  <xorAxAx> why do you think that this is cheaper than using the file system cache?
2007-07-25T15:11:54  <xorAxAx> e.g. its stupid to cache the data part of a revision
2007-07-25T15:12:20  <lanius> becaseu file systems are always slower then memory, that's nothing i have to proof
2007-07-25T15:12:54  <xorAxAx> the notification and synchronisation will make it much slower
2007-07-25T15:14:57  <lanius> writing to disk involves pickling
2007-07-25T15:14:59  <lanius> and unpickling
2007-07-25T15:15:13  <xorAxAx> lanius: so can you describe the current way caching works on a wiki page?
2007-07-25T15:15:26  <xorAxAx> (without any multiprocess considerations)
2007-07-25T15:16:16  <lanius> the caching module?
2007-07-25T15:16:30  <xorAxAx> no
2007-07-25T15:16:37  <xorAxAx> thats something else
2007-07-25T15:16:43  <xorAxAx> the cache you were talking aobut
2007-07-25T15:16:54  <lanius> ah wait, via the editlog
2007-07-25T15:17:41  <xorAxAx> which editlog?
2007-07-25T15:17:46  <lanius> global
2007-07-25T15:17:53  <xorAxAx> do we already have a new global editlog?
2007-07-25T15:18:01  <lanius> we still have the old one
2007-07-25T15:18:20  <xorAxAx> see, so you have 2 unresolved requirements that should be thought together :)
2007-07-25T15:18:27  * xorAxAx is gone to the bus
2007-07-25T15:18:27  <lanius> but the editlog does not contain user data
2007-07-25T15:18:57  <lanius> and with notifications it could just be solved on a different level
2007-07-25T15:33:43  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2567:b403a24f7c8f 1.7/MoinMoin/ (4 files in 4 dirs): (xorAxAx, johill) make saner looking anchors, no more sha hash
2007-07-25T15:34:16  <johill> lanius: ?
2007-07-25T15:34:28  <johill> the edit log has the user that did the eidt, of course
2007-07-25T15:36:44  <lanius> johill: yeah but not changes to the user
2007-07-25T15:37:38  <johill> ah
2007-07-25T15:41:14  <johill> finally we have sane looking anchors that even work across include :)
2007-07-25T15:42:16  <johill> ThomasWaldmann: want to backport those to 1.6? :)
2007-07-25T15:43:00  * ThomasWaldmann looks
2007-07-25T15:43:32  <ThomasWaldmann> +            (u'\xf6\xf6ll\xdf\xdf',   '.2BAPYA9g-ll.2BAN8A3w-'),  hehe
2007-07-25T15:43:39  <johill> yeah well
2007-07-25T15:43:43  <johill> it's utf7
2007-07-25T15:43:57  <johill> if you have just say Hallöchen
2007-07-25T15:43:58  <johill> you get
2007-07-25T15:44:13  <johill> Hall.2BAPY-chen
2007-07-25T15:44:43  <ThomasWaldmann> you remove the pagename from the calculation?
2007-07-25T15:45:00  <johill> yeah, why bother
2007-07-25T15:45:24  <ThomasWaldmann> because of uniqueness
2007-07-25T15:45:29  <johill> oh
2007-07-25T15:45:34  <johill> the formatter has to care about uniqueness now
2007-07-25T15:45:40  <ThomasWaldmann> imagine pages made from some template
2007-07-25T15:45:42  <johill> besides
2007-07-25T15:45:54  <johill> include had a bug anyway
2007-07-25T15:46:01  <ThomasWaldmann> tell news :)
2007-07-25T15:46:11  <johill> news: we fixed that
2007-07-25T15:46:54  <ThomasWaldmann> there were some attempts to fix that heading stuff, but all had the one or other problem (including giving duplicate ids)
2007-07-25T15:47:03  <johill> yeah well, we just fixed it
2007-07-25T15:47:11  * ThomasWaldmann reads on
2007-07-25T15:47:19  <johill> read a few patches back
2007-07-25T15:48:03  <ThomasWaldmann> anchor_name_from_text conforms to specs?
2007-07-25T15:48:15  <ThomasWaldmann> doesnt it have to begin with a letter?
2007-07-25T15:48:40  <johill> hm?
2007-07-25T15:48:58  <ThomasWaldmann> is 0815 a valid anchor id?
2007-07-25T15:49:14  <johill> oh you're right
2007-07-25T15:49:27  <johill> I guess I'll have to add a letter if there isn't one
2007-07-25T15:49:40  <ThomasWaldmann> yeah, or maybe _
2007-07-25T15:49:55  <johill> not even that is valid
2007-07-25T15:52:10  <CIA-27> moin: Johannes Berg <johannes AT sipsolutions DOT net> * 2568:80eac6fc152a 1.7/MoinMoin/ (_tests/test_wikiutil.py wikiutil.py): make anchor names always start with a letter
2007-07-25T15:52:18  <johill> in any case
2007-07-25T15:52:26  <johill> it now works even if you include the same page twice
2007-07-25T15:53:14  <ThomasWaldmann> if you do on page with include(page1) include(page2) and
2007-07-25T15:53:46  <ThomasWaldmann> another page with include(page2) include(page1), then you have to use different anchors to get to same heading, right?
2007-07-25T15:54:12  <ThomasWaldmann> (because it just counts at runtime)
2007-07-25T15:54:20  <johill> right
2007-07-25T15:54:44  <ThomasWaldmann> so what was wrong again with using the pagename? :)
2007-07-25T15:55:17  <johill> nothing, just seemed useless?
2007-07-25T15:55:42  <johill> but I found a bug now, if you actually include a page with a table of contents
2007-07-25T15:55:45  <ThomasWaldmann> well, it fixes this "problem"
2007-07-25T15:55:46  <johill> corner case :)
2007-07-25T15:55:50  <johill> there is no problem
2007-07-25T15:55:52  <johill> the toc knows about it
2007-07-25T15:56:45  <ThomasWaldmann> did you read about the heading problems in the wiki? there are some bug reports and some patches.
2007-07-25T15:56:46  <johill> xorAxAx: one remaining problem is if you include pages with a toc then the second included toc might link into the first page by accident
2007-07-25T15:57:17  <johill> ThomasWaldmann: yeah, it was pretty broken, but I'm telling you, it works now (except for the included toc corner case)
2007-07-25T15:58:09  <ThomasWaldmann> ok
2007-07-25T15:58:24  <ThomasWaldmann> +                    macro.formatter.rawHTML(link),   why not formatter.url ?
2007-07-25T15:58:50  <johill> dunno
2007-07-25T15:59:19  <johill> no particular reason, I think
2007-07-25T15:59:23  <johill> link was preformatted already
2007-07-25T15:59:27  <johill> that just fixed a bug that was there
2007-07-25T15:59:45  <ThomasWaldmann> i guess that would be nicer (except if there is some reason it is not usable)
2007-07-25T16:00:02  <johill> it should be using inc_page.url() then etc
2007-07-25T16:00:07  <johill> yeah, seems like it should work
2007-07-25T16:00:16  <johill> feel free to fix it ;) the include macro isn't really something I love hacking :P
2007-07-25T16:00:19  <johill> plus I have to go now
2007-07-25T16:00:37  * ThomasWaldmann neither :)
2007-07-25T16:11:17  <xorAxAx> johill: indeed
2007-07-25T16:12:35  <ThomasWaldmann> hehe, complex type support :)
2007-07-25T16:12:46  <ThomasWaldmann> I am curious if it will ever be used.
2007-07-25T16:13:10  <ThomasWaldmann> maybe some fractal drawing macro? :D
2007-07-25T16:16:27  <xorAxAx> johill: doesnt the clear operation destroy the TOC stuff completly?
2007-07-25T16:16:31  <xorAxAx> johill: of the inner TOC macro
2007-07-25T18:06:27  <CIA-27> moin: Ville-Pekka Vainio <vpivaini AT cs DOT helsinki DOT fi> * 2687:10a2e720e163 1.7-maninfo-vpv/MoinMoin/script/xmlrpc/manimport.py: fix a couple of bugs, add some more error checks
2007-07-25T18:06:31  <CIA-27> moin: Thomas Waldmann <tw AT waldmann-edv DOT de> * 2688:a40bcb6fce42 1.7-maninfo-vpv/.hgignore: remove some unused stuff from .hgignore
2007-07-25T18:06:32  <CIA-27> moin: Thomas Waldmann <tw AT waldmann-edv DOT de> * 2689:907c0ab79b15 1.7-maninfo-vpv/README: update README with new homepage url
2007-07-25T18:06:40  <CIA-27> moin: Ville-Pekka Vainio <vpivaini AT cs DOT helsinki DOT fi> * 2703:c666f1ee532b 1.7-maninfo-vpv/ (10 files in 7 dirs): merge from main
2007-07-25T18:15:01  <CIA-27> moin: Ville-Pekka Vainio <vpivaini AT cs DOT helsinki DOT fi> * 2704:ada0637ffad5 1.7-maninfo-vpv/MoinMoin/script/xmlrpc/manimport.py: remove one source of file handling bugs completely
2007-07-25T18:21:29  <ThomasWaldmann> BUG
2007-07-25T18:22:44  <ThomasWaldmann> ah, no, that changeset was before the dupe detection started working
2007-07-25T18:23:15  <ThomasWaldmann> 12 lines less :)
2007-07-25T18:27:20  <xorAxAx> development pace slowed down by the factor of 5 :-(
2007-07-25T18:45:57  <ThomasWaldmann> xorAxAx: moin stats at cia?
2007-07-25T18:46:44  <xorAxAx> yes :)
2007-07-25T18:47:38  <ThomasWaldmann> we can spam them when merging the student branches to 1.7 main after soc :))
2007-07-25T18:48:03  <ThomasWaldmann> the should be enough for 1st place that day
2007-07-25T19:04:17  * ThomasWaldmann plays with yslow
2007-07-25T19:05:48  <ThomasWaldmann> bbl
2007-07-25T22:45:51  <vpv> lol, I thought I had yet another bug, but it wasn't a bug, handling big XML files just takes a lot of time :D
2007-07-25T22:58:32  <vpv> ThomasWaldmann or anyone else with docbook branch experience, if I'm getting things like <listitem>
2007-07-25T22:58:56  <vpv> </listitem> in red in a docbook page, does that mean that some feature is not supported?
2007-07-25T22:59:19  <vpv> I think soon would be a could time to start testing the docbook branch
2007-07-25T23:14:44  <xorAxAx> vpv: yes, the parser generates empty lists
2007-07-25T23:15:49  <vpv> ok

MoinMoin: MoinMoinChat/Logs/moin-dev/2007-07-25 (last edited 2007-10-29 19:10:42 by localhost)