1 2013-06-18T04:29:56 <ReimarBauer> TheSheep: sharkyraj_ have you looked on http://code.google.com/p/svg-edit/source/browse/#svn%2Fbranches%2F2.6%2Feditor%2Flocale
2 2013-06-18T04:35:02 <ReimarBauer> ana_ananasova: a smaller example is http://hg.moinmo.in/moin/2.0/file/ad303592c64c/MoinMoin/script/maint/set_meta.py
3 2013-06-18T05:16:57 <ReimarBauer> spy_: see my comments
4 2013-06-18T05:26:50 *** ashutosh1461
5 2013-06-18T06:29:56 *** sharky93
6 2013-06-18T06:50:49 <sharky93> ReimarBauer, i saw the svg-edit content now, i dont think we need to use much of that. Our target is to just eliminate the templates from the main JS so as to use the linter.
7 2013-06-18T07:16:16 <sharky93> moin :)
8 2013-06-18T08:02:13 <sharky93> TheSheep, is it advisable to use JSONP ?
9 2013-06-18T08:03:18 <sharky93> TheSheep, i'll start with the linter meanwhile .. please have a look @ https://codereview.appspot.com/10330044
10 2013-06-18T08:12:25 <TheSheep> sharky93: reviewed
11 2013-06-18T08:46:12 *** ana-balica
12 2013-06-18T08:49:50 *** ana_ananasova
13 2013-06-18T09:09:59 <ashutosh1461> moin
14 2013-06-18T09:15:56 <ana_ananasova> moin
15 2013-06-18T09:19:23 *** greg_f
16 2013-06-18T09:26:22 <ThomasWaldmann> moin
17 2013-06-18T09:47:00 <ThomasWaldmann> sharky93: please do clean changesets. separate topics.
18 2013-06-18T09:47:34 <TheSheep> sharky93: also, can we use the bitbucket's review mechanism?
19 2013-06-18T09:47:52 <ThomasWaldmann> e.g. do not mix fixes wanted by the linter with stuff needed for de-templating main js.
20 2013-06-18T09:48:16 <sharky93> ThomasWaldmann, yep okay.
21 2013-06-18T09:48:46 <sharky93> TheSheep, i've not used bitbucket's mechanism yet.
22 2013-06-18T09:48:51 * sharky93 looks up
23 2013-06-18T09:49:00 <TheSheep> sharky93: basically you would do a pull request
24 2013-06-18T09:49:17 <TheSheep> ThomasWaldmann: would it be good if sharky93 cloned my fork of moin2 and did pull requests there?
25 2013-06-18T09:49:26 <TheSheep> s/cloned/forked
26 2013-06-18T09:50:54 <sharky93> TheSheep, till now i've been using the codereview and i somehow like it :) .. but if its really a problem for you we can change..
27 2013-06-18T09:51:11 <TheSheep> sharky93: if you like it, then we can keep it
28 2013-06-18T09:51:47 <TheSheep> sharky93: the bitbucket pull requests just seem more comfortable, but I guess that's a matter of preference
29 2013-06-18T09:53:54 *** H0arry
30 2013-06-18T09:54:05 <H0arry> Hi.
31 2013-06-18T09:54:46 <sharky93> TheSheep, by static files on the comment on the cr do you mean we insert the HTML directly ?
32 2013-06-18T09:55:01 <TheSheep> sharky93: no, I mean the files served from the static/ directory
33 2013-06-18T09:55:57 <sharky93> TheSheep, so it helps the caching system?
34 2013-06-18T09:56:10 <TheSheep> among other things
35 2013-06-18T09:58:19 <sharky93> we should add "Not to define a global function without a need" to ui-practices
36 2013-06-18T09:58:55 *** ashutosh1461
37 2013-06-18T10:00:26 <TheSheep> sure
38 2013-06-18T10:00:42 <TheSheep> functions nor variables
39 2013-06-18T10:15:59 *** ashutosh1461
40 2013-06-18T10:26:39 <sharky93> TheSheep, but we can keep the i18n_dict variable global along with the global _()
41 2013-06-18T10:38:35 <TheSheep> sharky93: what for?
42 2013-06-18T11:05:28 <ashutosh1461> ThomasWaldmann, a basic template on how we should proceed https://codereview.appspot.com/10368045
43 2013-06-18T11:06:15 <ThomasWaldmann> ashutosh1461: if you have short questions just ask, no time right now for longer stuff (I am handling an emergency right now)
44 2013-06-18T11:07:13 <ashutosh1461> no problems we will talk when you are free
45 2013-06-18T11:29:29 <ThomasWaldmann> ashutosh1461: please read and follow the todo list for coding phase
46 2013-06-18T11:34:04 <ashutosh1461> ThomasWaldmann, i have already read it, is there something i am missing ?
47 2013-06-18T11:40:25 <ThomasWaldmann> yes, first make a plan, then code
48 2013-06-18T11:48:20 <ashutosh1461> The cr i gave is just a very basic template does not involve any code, also updated etherpad with new namespace ideas http://etherpad.osuosl.org/moin-itemid
49 2013-06-18T11:52:03 <ReimarBauer> sharky93: have you looked how they solved the i18n issue?
50 2013-06-18T11:55:30 * ReimarBauer looks at the macro EventCalendar. Have a request at work for it
51 2013-06-18T12:00:05 <ThomasWaldmann> ashutosh1461: left a note on EP, must go, bbl
52 2013-06-18T12:18:11 <sharky93> ReimarBauer, yes i had a look at it. That is a better method which involves complete use of JSON. We have a smaller target of just getting the main JS in Moin to be linted
53 2013-06-18T12:19:43 <sharky93> TheSheep, i was facing a severe blocker with JS Syntax Errors as pointed out by Firebug, but after some sane attempts at fixing it appears that the problem is due to the serving from the 'Static' folder.. when i serve the JS files from the template folder itself, everything works fine.
54 2013-06-18T12:20:22 <sharky93> TheSheep, any clue ?
55 2013-06-18T12:22:04 <TheSheep> sharky93: leftover {{ }} somewhere?
56 2013-06-18T12:22:24 <TheSheep> sharky93: only the dictionary.js should be served from templates
57 2013-06-18T12:26:37 *** dave_largo
58 2013-06-18T12:27:01 *** ashutosh1461
59 2013-06-18T12:49:51 <sharky93> TheSheep, nope, no {{ }} leftovers. Currently i am serving dictionary.js from the template, jquery is handled by the XStatic package, common.js and jquery.i18n.js from the Static folder.
60 2013-06-18T12:51:12 <TheSheep> sharky93: run jslint on it?
61 2013-06-18T12:51:33 <sharky93> TheSheep, the problem is fixed now.
62 2013-06-18T12:51:35 <sharky93> TheSheep, the previous issue might be related to the order in which files are loaded by JS .. if now I serve i18n library from the template folder i'll get syntax errors in common.js which may be due the library not available
63 2013-06-18T12:52:03 <sharky93> although everything is under a document.ready event.
64 2013-06-18T12:54:18 <TheSheep> sharky93: is it commited in your repo?
65 2013-06-18T12:54:27 <TheSheep> sharky93: link?
66 2013-06-18T12:56:08 <sharky93> TheSheep, i can upload a patch on cr, you could import it. I haven't made the commit yet
67 2013-06-18T12:58:03 <TheSheep> sharky93: do you have an account on bitbucket?
68 2013-06-18T12:58:39 <sharky93> TheSheep, yes @ https://bitbucket.org/sharky93/
69 2013-06-18T13:12:28 <sharky93> TheSheep, Patch Set 2 @ https://codereview.appspot.com/10330044/
70 2013-06-18T13:12:51 <sharky93> please have a look, we could commit this changeset then
71 2013-06-18T13:23:16 <TheSheep> sharky93: nothing pops at me immediately, what's the error exactly?
72 2013-06-18T13:24:39 <TheSheep> sharky93: by the way, in dictionary.js, instead of "{{ _("...") }}" you probably want {{ _("...")|jsonify }}
73 2013-06-18T13:25:05 <TheSheep> sharky93: so that it escapes the quotation marks inside the strings properly
74 2013-06-18T13:25:48 <sharky93> TheSheep, patch set 2 @ https://codereview.appspot.com/10330044/ runs without any error
75 2013-06-18T13:26:56 <sharky93> TheSheep, the problem occurs when i serve dictionary.js from the static folder and common.js from the template directory.
76 2013-06-18T13:28:22 <TheSheep> sharky93: that's expected, because dictionary.js is supposed to be a template
77 2013-06-18T13:28:34 <TheSheep> sharky93: all other js files should be static
78 2013-06-18T13:28:58 <sharky93> TheSheep, hmm, i understand now.
79 2013-06-18T13:29:45 <sharky93> TheSheep, so commit Patch Set 2?
80 2013-06-18T13:30:05 <sharky93> Ah i see the comment
81 2013-06-18T13:30:36 <TheSheep> the comments are just an aside
82 2013-06-18T13:33:10 <sharky93> TheSheep, ^, i did not understand?
83 2013-06-18T13:33:51 <TheSheep> sharky93: the comments that I left will not solve your problem
84 2013-06-18T13:34:45 <sharky93> TheSheep, but which problem? .. we anyways will be serving dictionary.js from the template .. so that works out fine.
85 2013-06-18T13:35:18 <TheSheep> yeah
86 2013-06-18T13:36:43 <sharky93> TheSheep, so we should commit this changeset and start working with the linter ?
87 2013-06-18T13:38:00 <TheSheep> yes
88 2013-06-18T13:40:32 <sharky93> I am not so sure with how file tracking is done with hg when we move a file to a new location - ( Use case - shifting js files to static ) .. I just move them.. and use "hg add" with the new location?
89 2013-06-18T13:42:18 <ana_ananasova> i think there is a hg mv for that
90 2013-06-18T13:44:45 <ana_ananasova> waldi: pleare review https://codereview.appspot.com/10386044/
91 2013-06-18T13:45:26 <ana_ananasova> please*
92 2013-06-18T13:48:47 *** dave_largo
93 2013-06-18T13:50:03 *** dave_largo
94 2013-06-18T14:06:54 <TheSheep> sharky93: yup, hg mv
95 2013-06-18T14:24:15 *** sharkyraj_
96 2013-06-18T14:24:47 *** sharky93_
97 2013-06-18T15:11:03 <ReimarBauer> bbl
98 2013-06-18T15:17:14 <sharky93> TheSheep, the use of "var _ = $.i18n._;" gives an error on line 54 @ https://github.com/recurser/jquery-i18n/blob/master/jquery.i18n.js
99 2013-06-18T15:18:17 <sharky93> TheSheep, the error being "this.printf" is not a function.
100 2013-06-18T15:22:14 <sharky93> TheSheep, the global variable '_' interferes with the declaration somehow.. but i still dont understand the error message being returned.
101 2013-06-18T15:23:28 <sharky93> TheSheep, use of "function _(test) { return $.i18n._(test); }" works fine, so it has got to something with the global variable we declare.
102 2013-06-18T15:27:40 <sharky93> TheSheep, i believe this has something to do with the top answer @ http://stackoverflow.com/questions/336859/javascript-var-functionname-function-vs-function-functionname
103 2013-06-18T16:27:04 *** ashutosh1461
104 2013-06-18T17:04:37 *** ashutosh1461
105 2013-06-18T17:05:01 *** ashutosh1461
106 2013-06-18T17:17:58 <ashutosh1461> ThomasWaldmann, should we concentrate on namespaces + default wiki behaviour before moving on to interwiki stuff ?
107 2013-06-18T17:21:14 *** brunomartin
108 2013-06-18T17:40:49 <ana_ananasova> is there a special reason why method `is_subscribed_to` receives a list of pagenames as parameter? so after all the occurences of this method usage were smth like that `u.is_subscribed_to([pagename])`.
109 2013-06-18T17:41:56 <ana_ananasova> can we change the interface of method to receive an item obj (and update all occurences respectivelly) ?
110 2013-06-18T17:48:32 <ThomasWaldmann> re
111 2013-06-18T17:53:00 <ThomasWaldmann> ashutosh1461: i point you to interwiki because interwiki has semantic overlap with namespaces, and even handles parsing n -> interwikiname / namespace / itemname
112 2013-06-18T17:54:36 <ThomasWaldmann> in the url, you won't have the interwiki part, but there is not much reason to do namespace / itemname different from what you see in the interwiki tests (and even use that code for splitting it)
113 2013-06-18T17:56:08 <ashutosh1461> yes, i just saw the interwiki code
114 2013-06-18T17:56:33 <ashutosh1461> lots of work has already been done
115 2013-06-18T17:57:25 <ashutosh1461> ThomasWaldmann, and one more thing how is userprofile namespace different from user namespace ?
116 2013-06-18T18:09:37 <ThomasWaldmann> there is not much used yet. userprofile is for userprofiles (doh :), user could be for user homepages (but is not really used yet iirc)
117 2013-06-18T18:11:54 <ThomasWaldmann> if you look at TitleIndex of moinmo.in for example, you see a lot of user pages between the thematic pages. would be cleaner to separate them
118 2013-06-18T18:13:21 <ashutosh1461> how is user profile thing finally going to look like ? :D
119 2013-06-18T18:16:05 <ThomasWaldmann> 2 options: not visible at all. OR: will get rendered for the user only (and admin maybe) so one can see the settings and edit them.
120 2013-06-18T18:22:11 <sharky93> TheSheep, ThomasWaldmann there are some unused variables in moin's JS code .. how should we deal with those?
121 2013-06-18T18:23:26 <sharky93> For ex - https://bitbucket.org/thomaswaldmann/moin-2.0/src/ad303592c64c1743ac218d42835493cb9d97440b/MoinMoin/templates/common.js?at=default#cl-66
122 2013-06-18T18:27:45 <ReimarBauer> ana_ananasova: an item can have more than one name. (if there is still the word pagename used, that is wrong too). What is the benefit of this change?
123 2013-06-18T18:36:35 <ashutosh1461> ThomasWaldmann, so namespaces required right now are (default, user, itemid, revid, user_profiles) any other ?
124 2013-06-18T18:37:00 <ThomasWaldmann> sharky93: cleanup such stuff in a separate commit and make sure the linter is correct (== manually check it)
125 2013-06-18T18:37:17 <ana_ananasova> ReimarBauer: no specific benefit. i was searching for a use case in the codebase and didn't find one that would use a list of names.
126 2013-06-18T18:38:23 <ana_ananasova> btw where are stored the other names? name_old? are those taken into consideration when matching for a regexp?
127 2013-06-18T18:40:03 <ThomasWaldmann> ashutosh1461: not now
128 2013-06-18T18:42:57 <ana_ananasova> waldi: could you please review my EP section 1.4 http://etherpad.osuosl.org/moin-mail
129 2013-06-18T18:50:28 <ReimarBauer> ana_ananasova: the meta entry with the name itselfs is a list
130 2013-06-18T18:51:23 <ana_ananasova> indeed. then it's clear why
131 2013-06-18T18:51:38 <ReimarBauer> and yes we have not much code yet handling multiple names currently
132 2013-06-18T18:52:27 <ReimarBauer> this is part of ashutosh1461 project
133 2013-06-18T18:52:38 <ashutosh1461> that is why i am here :D
134 2013-06-18T18:53:04 <ana_ananasova> go go ashutosh1461 :D
135 2013-06-18T18:53:36 <TheSheep> sharky93: we will clean them up eventually
136 2013-06-18T18:53:42 <TheSheep> sharky93: but one step at a time
137 2013-06-18T18:54:36 <sharky93> TheSheep, i already cleaned that up :P
138 2013-06-18T18:54:43 * ReimarBauer next time before I agree to refactor a macro of the market place I should count its lines
139 2013-06-18T18:55:11 <TheSheep> sharky93: in a separate commit, I hope
140 2013-06-18T18:55:17 <sharky93> TheSheep, yes.
141 2013-06-18T18:55:33 *** greg_f
142 2013-06-18T18:56:14 <sharky93> TheSheep, for the previous issue i went with "function _(test) { return $.i18n._(test); }" instead of "var _ = $.i18n._;"
143 2013-06-18T18:56:36 <TheSheep> sharky93: why?
144 2013-06-18T18:56:49 <sharky93> TheSheep, the use of "var _ = $.i18n._;" gives an error on line 54 @ https://github.com/recurser/jquery-i18n/blob/master/jquery.i18n.js
145 2013-06-18T18:56:56 <TheSheep> ah, this
146 2013-06-18T18:57:08 <TheSheep> ok, didnt't think about it, sorry
147 2013-06-18T18:57:26 * TheSheep sometimes has problems switching from python to js
148 2013-06-18T18:57:38 <TheSheep> python binds methods to objects automatically
149 2013-06-18T19:00:13 <sharky93> and i dont wonder about this http://goo.gl/V464K ..
150 2013-06-18T19:17:25 <TheSheep> ~
151 2013-06-18T19:20:12 <TheSheep> don't worry, we are only going to use the thin book
152 2013-06-18T19:20:27 <TheSheep> that's why we need jslint -- to tell us when we go outside of that book
153 2013-06-18T19:27:24 <ashutosh1461> ThomasWaldmann, updated http://etherpad.osuosl.org/moin-itemid
154 2013-06-18T20:06:24 *** ashutosh1461
155 2013-06-18T20:22:47 <sharky93> TheSheep, i think we'll be done with the linter stuff today. There's not much errors
156 2013-06-18T20:23:11 <sharky93> cr coming up in a while.
157 2013-06-18T20:23:15 <TheSheep> that's nice
158 2013-06-18T20:23:37 <TheSheep> that means you can start removing the global functions and variables tomorrow :)
159 2013-06-18T20:23:59 <ThomasWaldmann> sharky93: i could fire pycharm's code-inspection at it afterwards.
160 2013-06-18T20:24:13 <ThomasWaldmann> (or you do it yourself, if you use pycharm)
161 2013-06-18T20:24:34 <sharky93> ThomasWaldmann, have not been using it since i lost my swap :( ..
162 2013-06-18T20:24:56 <ThomasWaldmann> lost your swap?
163 2013-06-18T20:25:15 <sharky93> the swap partition .. pycharm as i felt was quite resource intensive.
164 2013-06-18T20:25:53 <ThomasWaldmann> you have less than 1GB RAM?
165 2013-06-18T20:26:47 <sharky93> no, actually 2GB .. but the browser eats way too much.. which i feel i need open all the time :)
166 2013-06-18T20:26:49 <TheSheep> sharky93: you can create a swap file
167 2013-06-18T20:27:01 <TheSheep> sharky93: since 3.x it's as fast as swap partition
168 2013-06-18T20:27:19 <sharky93> oh, I was not aware of that!
169 2013-06-18T20:27:49 <ThomasWaldmann> and then put it on a ramdisk!!1
170 2013-06-18T20:28:06 <TheSheep> on a virtual machine!
171 2013-06-18T20:28:17 <TheSheep> mounted through nfs from another computer
172 2013-06-18T20:28:32 <TheSheep> running windows
173 2013-06-18T20:28:51 <ThomasWaldmann> perf tips from bofh :)
174 2013-06-18T20:28:59 <sharky93> :D
175 2013-06-18T20:35:18 <sharky93> TheSheep, https://codereview.appspot.com/10396044 .. there are two errors for common.js which I'm not so sure how to handle @ http://pastebin.com/JVNFssyi
176 2013-06-18T20:38:25 *** ana_ananasova
177 2013-06-18T20:47:43 <TheSheep> sharky93: the first error is that jslint wants you to declare all variables at the topmost indentation in a function, because they are in the function scope anyways, and declaring them inside an if makes it look as if they only exist inside that if, which is not true
178 2013-06-18T20:47:59 <TheSheep> sharky93: I think so, at least
179 2013-06-18T20:48:25 <TheSheep> sharky93: so it wants you to declare that 'tab' variable at the beginning of the function
180 2013-06-18T20:51:50 <sharky93> TheSheep, hmm, function scopes .. i see. and we leave the "TODO" comment as it is .. no harm in that i guess
181 2013-06-18T20:52:14 <TheSheep> sharky93: well, it should be fixed at some point too :)
182 2013-06-18T20:52:35 <TheSheep> isn't that exciting :P
183 2013-06-18T20:52:35 <sharky93> surely :)
184 2013-06-18T20:56:56 <sharky93> this is interesting.. http://pastebin.com/xHDDwyw6
185 2013-06-18T20:59:15 <TheSheep> what's interesting in that?
186 2013-06-18T20:59:55 <TheSheep> so they spammed their mailboxes and checked which e-mails bounced and which didn't
187 2013-06-18T21:01:36 <sharky93> but how does one get the initial list for spamming?
188 2013-06-18T21:05:49 *** dave_largo
189 2013-06-18T21:08:37 <sharky93> TheSheep, btw patch set 2 @ https://codereview.appspot.com/10396044/ .. fix with the scoping of the tab variable. If its okay i'll commit
190 2013-06-18T21:13:19 <TheSheep> looks good
191 2013-06-18T21:13:33 <TheSheep> I'm heading for the bed
192 2013-06-18T21:17:48 <sharky93> TheSheep, if you're still there .. what exactly would be the next steps
193 2013-06-18T22:06:28 <sharky93> gn
194 2013-06-18T22:09:20 * sharky93 pushes changes to his local repo .. and heads off to bed
195 2013-06-18T22:12:44 *** sharky93
196 2013-06-18T22:12:44 *** sharky93_
197 2013-06-18T23:20:55 *** brunomartin
198