[00:00:57] Krinkle: so here is my code: http://pastebin.com/raw.php?i=19c1SSdJ [00:01:39] and I noticed that if in getPreviewHTML method I would have a call to not existing method it wouldn't throw an exception in the browser [00:01:48] when it is called from onPreviewClick method [00:02:10] and I don't know where is that exception going, I don't have any unnecessary try...catches [00:02:27] 10VisualEditor, 7Epic, 15User-JAufrecht: Negotiate Service Levels between VE and Stakeholders and identify underlying contradictory needs - https://phabricator.wikimedia.org/T102571#1790336 (10JAufrecht) [00:02:35] 10VisualEditor, 15User-JAufrecht: Measure and document results of changes to VE team processes - https://phabricator.wikimedia.org/T103197#1790339 (10JAufrecht) [00:02:39] 10VisualEditor, 15User-JAufrecht: Align all VE tasks with higher-level Goals and Epics - https://phabricator.wikimedia.org/T102267#1790340 (10JAufrecht) [00:03:15] InezK: What version of jQuery is this running inside of? [00:03:21] 2.1.4 [00:04:37] InezK: Firstly, there is a lot of manual wrapping going on, which makes it fragile. Use .then() instead of Deferred(), done() .. fail( reject ) etc. [00:05:02] e.g. in getPreviewHTML, return $.when.apply( $, promises ).then( function () { return call(args); }) [00:05:06] then the fail is automatically forwarded [00:05:47] then() means like pipe in bash. whereas done() is afterwards, and is not considered part of the pipeline, so when it throws, it's ignored or thrown asynchronously outside your stack [00:05:54] InezK: Do you see the exception in the console? [00:06:29] no, not at all [00:07:13] try a try/catch in onPreviewClick around everything inside [00:07:20] and catch, log ex to console [00:07:41] and first change getPreviewHTML as described above [00:08:04] call(arguments); right? [00:10:48] I tried try..catch, it does not go inside the catch [00:13:05] oh, just return $.when.apply( $, promises ).then( function () { return arguments; } ); [00:13:13] but yeah, still not throwing exception in the console :( [00:14:32] Krinkle: any ideas? [00:15:24] Well, I assume you can keep Array.prototype.slice.call(arguments) the way it was as the return value [00:15:40] I'd say, set a debugger; breakpoint and step through to see what happens [00:17:08] do you have idea how getPreviewData could be optimized? [00:17:34] yeah, with debugger I can't find the problem, if I step into line which causes a call to not existing function nothing happens [00:17:45] I guess I will look more into call stack and see if jquery is wrapping it in some try catch [00:28:48] I got it! [00:43:11] Krinkle: it was caused by try..catch around call to resolve in other place [00:47:04] Aha [00:47:41] InezK: The debugger should take you from the bad call to where it is caught [00:47:50] maybe you accidentally use the step over button instead of step in button? [00:48:04] well, it was try catch around other resolve [00:48:48] and that resolve was and of one promise and later on it caused other promises to be processed, but when they failed it was still in scope of that try catch [00:49:03] anyways, would you have idea how I can optimize InfoboxPreview.prototype.getPreviewData? [00:49:16] I mean - not necessary optmize but write in a better way [00:50:22] it seems that from 'then' I can only return result, but I can't return error, if I figure out data is incorrect [00:56:12] 10VisualEditor: In VE, a long element does not size properly on open - https://phabricator.wikimedia.org/T117926#1790434 (10Esanders) Can you link to an example? [01:00:31] 10VisualEditor: In VE, a long element does not size properly on open - https://phabricator.wikimedia.org/T117926#1790441 (10Yurik) https://www.mediawiki.org/wiki/Extension:Kartographer#Combining_Data_.28for_Wikivoyage_.26_Lists.29 Edit the very long code example [01:36:16] 10VisualEditor, 10MediaWiki-Configuration: Enable Visual Editor in draft namespace in Persian Wikipedia - https://phabricator.wikimedia.org/T118060#1790512 (10Ladsgroup) 3NEW a:3Ladsgroup [01:39:42] 10Citoid: Citoid picks up a 'pl-pl' language for a page - https://phabricator.wikimedia.org/T118045#1790524 (10tarlocesilion) [01:41:12] 10VisualEditor, 10MediaWiki-Configuration, 5Patch-For-Review: Enable Visual Editor in draft namespace in Persian Wikipedia - https://phabricator.wikimedia.org/T118060#1790529 (10Krenair) Please don't put these in #MediaWiki-Configuration. [01:41:24] 10VisualEditor, 10Wikimedia-Site-Requests, 5Patch-For-Review: Enable Visual Editor in draft namespace in Persian Wikipedia - https://phabricator.wikimedia.org/T118060#1790530 (10Krenair) [01:52:17] 10VisualEditor, 10Wikimedia-Site-Requests, 5Patch-For-Review: Enable Visual Editor in draft namespace in Persian Wikipedia - https://phabricator.wikimedia.org/T118060#1790554 (10Jdforrester-WMF) p:5Triage>3Normal [02:16:11] (03PS1) 10Krinkle: Remove unused jquery.visibleText library [VisualEditor/VisualEditor] - 10https://gerrit.wikimedia.org/r/251680 [02:21:48] InezK: then() returns the value, or another promise. [02:22:09] InezK: So, if your error becomes a value, or your value becomes an error after a pipe, return a separate deferred inline (not pre-created [02:22:21] ok [02:22:25] so e.g. foo().then( function () { return $.Deferred().reject(); }) [02:22:36] I see, clever trick [02:22:42] thank you [02:22:46] yw [02:22:50] still trying to figure out exact difference between then and done [02:22:54] when should I use which [02:23:03] InezK: done/fail is a flag callback, then is a pipe [02:23:07] actually when should I use done, because then works well in all my use cases [02:23:15] Yes [02:23:20] done/fail are essentially obsolete [02:23:22] (03CR) 10Jforrester: [C: 032] "I was going to -1 that you didn't remove the reference from AUTHORS.txt where we list each of our libraries… except apparently we didn't l" [VisualEditor/VisualEditor] - 10https://gerrit.wikimedia.org/r/251680 (owner: 10Krinkle) [02:23:26] 10VisualEditor, 10VisualEditor-MediaWiki, 6Editing-Analysis: Review Schema:Edit now that VE allows WE->VE switching - https://phabricator.wikimedia.org/T118063#1790572 (10Krenair) 3NEW [02:23:28] oh, ok [02:23:29] The standardised Promise only has then() [02:23:39] they dropped done/fail as part of standarisation with the browser vendors [02:23:43] jQuery will keep done/fail of course [02:24:13] The main difference is that if you have getValue() that returns a promise, and you do getValue().done(something) and somewhere else getValue().then(function () { something; }). [02:24:27] then the consumer of the second one, will get its value after the callback has run [02:24:39] the consumer of code using done() willbecome a sibling instead of a child [02:24:49] the return value of done() is === the same promise [02:24:56] the return value of then() is a proxy. [02:25:23] at the end of the chain, and if the chain is not returned to someting else, then it doesn't matter [02:25:27] in all other cases, you probably want then() [02:25:44] InezK: Makes sense? [02:32:02] (03PS1) 10Jforrester: lib: Add AUTHORS, LICENSE and README files for libraries missing them [VisualEditor/VisualEditor] - 10https://gerrit.wikimedia.org/r/251682 [03:03:52] 10VisualEditor, 10VisualEditor-MediaWiki: Switching from WE to VE and saving, then navigating a different page causes an unsaved changes warning - https://phabricator.wikimedia.org/T117769#1790619 (10Krenair) [03:59:06] (03PS1) 10Alex Monk: Drop any beforeunload handlers when loading from existing wikitext [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251684 (https://phabricator.wikimedia.org/T117769) [03:59:22] 10VisualEditor, 10VisualEditor-MediaWiki, 5Patch-For-Review: Switching from WE to VE and saving, then navigating a different page causes an unsaved changes warning - https://phabricator.wikimedia.org/T117769#1790644 (10Krenair) a:3Krenair [04:15:42] (03PS1) 10Alex Monk: WikiEditor integration: Fix dependencies for switch button [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251687 [04:17:46] 10VisualEditor, 10VisualEditor-MediaWiki: [Regression wmf.5] The text "Editing" is appearing before the article title when I switch to VisualEditor and it also stays after saving the page - https://phabricator.wikimedia.org/T117643#1790665 (10Krenair) a:3Krenair Maybe we can have the server parse the displa... [05:35:48] 10VisualEditor, 10Parsoid, 10RESTBase: Reports of 400 and 500 errors with Parsoid - https://phabricator.wikimedia.org/T112286#1790669 (10ori) 1) Go to https://en.wikipedia.org/wiki/Jonathan_Mendelsohn. 2) Click on the redlink labeled '[[ https://en.wikipedia.org/w/index.php?title=Nicola_Mendelsohn&action=edi... [07:33:41] 10VisualEditor, 10Parsoid, 10RESTBase: Reports of 400 and 500 errors with Parsoid - https://phabricator.wikimedia.org/T112286#1631006 (10GWicke) @ori, it looks like VE has started to use the new stash API when switching from wikitext to visual editing. That API mode did not exist at the time of the original... [07:58:24] 10VisualEditor, 10VisualEditor-MediaWiki, 10RESTBase, 6Services, 7RESTBase-API: VE should send If-Match header to the VRS to send on to RESTbase - https://phabricator.wikimedia.org/T113728#1790966 (10GWicke) @krenair, is this being resolved as part of the HTML <-> Wikitext switch work? [07:59:20] 10VisualEditor, 10Parsoid, 10RESTBase: Reports of 400 and 500 errors with Parsoid - https://phabricator.wikimedia.org/T112286#1790967 (10GWicke) 5stalled>3Resolved There have been no reports for the original issue since September. The Flow post issue sounds like new content & likely a Parsoid issue. I th... [11:52:24] (03CR) 10Esanders: [C: 032] WikiEditor integration: Fix dependencies for switch button [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251687 (owner: 10Alex Monk) [11:55:23] (03Merged) 10jenkins-bot: WikiEditor integration: Fix dependencies for switch button [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251687 (owner: 10Alex Monk) [13:02:15] 10VisualEditor: “Switch to visual editing” button displayed on non-VE namespaces - https://phabricator.wikimedia.org/T118077#1791097 (10Ltrlg) 3NEW [16:04:42] 10VisualEditor: “Switch to visual editing” button displayed on non-VE namespaces - https://phabricator.wikimedia.org/T118077#1791188 (10Jdforrester-PERSONAL) [16:04:44] 10VisualEditor, 10VisualEditor-MediaWiki, 10WikiEditor, 5Patch-For-Review, 5WMF-deploy-2015-11-10_(1.27.0-wmf.6): Switch to VE button visible in namespaces where VE is not available - https://phabricator.wikimedia.org/T117968#1791189 (10Jdforrester-PERSONAL) [16:05:11] (03CR) 10Jforrester: [C: 032] Drop any beforeunload handlers when loading from existing wikitext [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251684 (https://phabricator.wikimedia.org/T117769) (owner: 10Alex Monk) [16:09:52] (03Merged) 10jenkins-bot: Drop any beforeunload handlers when loading from existing wikitext [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251684 (https://phabricator.wikimedia.org/T117769) (owner: 10Alex Monk) [16:14:56] (03PS1) 10Jforrester: Drop any beforeunload handlers when loading from existing wikitext [extensions/VisualEditor] (wmf/1.27.0-wmf.5) - 10https://gerrit.wikimedia.org/r/251717 (https://phabricator.wikimedia.org/T117769) [16:44:03] 10VisualEditor: Create a method for moving columns/rows in tables in Visual Editor - https://phabricator.wikimedia.org/T117865#1791213 (10Krenair) [16:44:05] 10VisualEditor, 10VisualEditor-Tables, 7notice, 7user-notice: Be able to re-order the columns or rows of a table by dragging them to another position in VisualEditor - https://phabricator.wikimedia.org/T88694#1791214 (10Krenair) [16:46:04] 10TemplateData, 10VisualEditor: VisualEditor thinks there's no templatedata for my template with /doc subpage - https://phabricator.wikimedia.org/T117164#1791218 (10Krenair) @Spage: ping [16:48:31] 10TemplateData, 10VisualEditor: VisualEditor thinks there's no templatedata for my template with /doc subpage - https://phabricator.wikimedia.org/T117164#1791219 (10Krenair) 5stalled>3Invalid a:3Krenair I just made a null edit and it worked. [16:48:40] 10TemplateData: VisualEditor thinks there's no templatedata for my template with /doc subpage - https://phabricator.wikimedia.org/T117164#1791222 (10Krenair) [16:49:42] 10VisualEditor, 10VisualEditor-Tables: VisualEditor closes a table after the categories - https://phabricator.wikimedia.org/T116554#1791224 (10Krenair) [16:55:30] 10VisualEditor: an unnecessary warning is shown when saving a page in mobile VisualEditor - https://phabricator.wikimedia.org/T116537#1791228 (10Krenair) cannot reproduce [17:57:29] 10VisualEditor, 10VisualEditor-MediaWiki, 5Patch-For-Review, 5WMF-deploy-2015-11-10_(1.27.0-wmf.6): Switching from WE to VE and saving, then navigating a different page causes an unsaved changes warning - https://phabricator.wikimedia.org/T117769#1791278 (10Florian) 5Open>3Resolved [18:23:38] (03PS1) 10Ori.livneh: Revert "Use mw.loader.using instead of weird hacks to load OOjs UI on action=edit" [extensions/VisualEditor] (wmf/1.27.0-wmf.5) - 10https://gerrit.wikimedia.org/r/251733 [18:23:56] (03CR) 10jenkins-bot: [V: 04-1] Revert "Use mw.loader.using instead of weird hacks to load OOjs UI on action=edit" [extensions/VisualEditor] (wmf/1.27.0-wmf.5) - 10https://gerrit.wikimedia.org/r/251733 (owner: 10Ori.livneh) [18:24:26] Krenair, fyi ^ [18:29:07] (03CR) 10Ori.livneh: "Non-trivial to rebase this. Leaving it for Krenair." [extensions/VisualEditor] (wmf/1.27.0-wmf.5) - 10https://gerrit.wikimedia.org/r/251733 (owner: 10Ori.livneh) [18:31:16] ori: removing the mw.loader.load line should probably do this, but will result in non-instant response to user action upon clicking the "Edit source" button [18:31:57] "Edit" button* [18:33:54] although, hm, i am a bit lost [18:35:11] ori, why are you reverting that? [18:35:21] i'm not [18:35:39] Krenair: T112401 [18:35:59] september? [18:36:17] ugh, reopened [18:36:35] yeah maybe MatmaRex was right that it should have gone into a new task [18:36:46] 'ext.visualEditor.switching' has only ve.init.MWVESwitchConfirmDialog [18:36:55] (03PS4) 10Paladox: Revert "Revert "Update jQuery Client to v2.0.0"" [VisualEditor/VisualEditor] - 10https://gerrit.wikimedia.org/r/221171 [18:36:56] and i never actually get that dialog when switching from WT to VE [18:37:06] you need to make a change for it to appear [18:37:51] (03PS5) 10Paladox: BREAKING CHANGE: Update jQuery Client to v2.0.0 [VisualEditor/VisualEditor] - 10https://gerrit.wikimedia.org/r/221171 [18:37:54] it didn't appear even when i did. but i refreshed the page and it worked this time. [18:38:53] oh, i see. if i switch WT->VE without making changes, then back, then make changes to wikitext, then try switching WT->VE, i don't get the dialog. [18:40:10] oh, i see more. the "then back" part has to be done by pressing Escape. [18:40:16] ... what? [18:40:23] which gives me the WT edit form back, and changes the URL to "https://en.wikipedia.org/wiki/Heavenly_Bodies_(film)"… [18:40:29] (random page) [18:40:38] anyway. that's secondary. i'll file a bug [18:42:00] ori, so ext.visualEditor.switching is only loaded by mw.loader.load, it's not a dependency of any modules loaded on page view [18:42:37] why is it necessary at all? [18:42:57] read the code [18:43:14] can't you just explain it? [18:45:58] if ( !isViewPage && ( mw.config.get( 'wgAction' ) === 'submit' || wikitextModified ) ) [18:46:02] why is this evaluating to true? [18:46:13] var wikitextModified = $( '#wpTextbox1' ).val() !== initialWikitext; [18:47:46] so: [18:47:55] if ( currentUri.query.action === 'edit' && $( '#wpTextbox1' ).length ) { initialWikitext = $( '#wpTextbox1' ).val(); } [18:47:58] That code is only being run when you press a button [18:47:59] otherwise initialWikitext is undefined [18:48:42] it's the mw.loader.load that's causing the module to be loaded on view pages [18:49:07] I think we can avoid loading it on page view though [18:49:18] not sure why it doesn't already check that... [18:53:52] Is this really blocking render though, ori? [18:54:17] no, it's not [18:56:40] this is still bad though? [18:57:43] yes, it is [18:59:55] please open a separate bug for it [19:03:20] i will. please fix it. [19:07:02] 10VisualEditor, 7Performance: Half a megabyte of JavaScript / CSS loading on view pages - https://phabricator.wikimedia.org/T118088#1791323 (10ori) 3NEW a:3Krenair [19:07:38] thanks [19:10:42] (03PS1) 10Alex Monk: Only load switching module (depending on OOUI etc.) on edit pages [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251736 (https://phabricator.wikimedia.org/T118088) [19:12:10] do you want to deploy this now ori [19:12:11] ? [19:12:53] 10VisualEditor, 10VisualEditor-MediaWiki, 5Patch-For-Review, 7Performance: Half a megabyte of JavaScript / CSS loading on view pages - https://phabricator.wikimedia.org/T118088#1791342 (10Krenair) [19:15:20] it depends [19:15:29] it's not worth breaking VE to fix this [19:15:36] so it depends on how risky you think it would be [19:15:40] i haven't looked at the patch yet [19:15:43] I did just test this [19:16:07] I think it's safe [19:16:27] this code is only supposed to be useful when you're on action=edit/action=submit, and that's exactly what we're adding a check for [19:16:36] makes sense [19:16:41] and we can revert quickly if there's an issue [19:16:45] yes [19:17:07] ok. i can +2 a cherry-pick, but should probably leave the master one for someone on the ve team to review [19:17:16] sure [19:21:10] i have to run. MatmaRex, could you +2 the cherry-pick? (or Krenair, i think you could just self-+2) [19:21:31] ori: i literally can't [19:21:51] I'll do it [19:22:00] i can +2 the change, don't have permissions for wmf branches [19:22:13] thanks guys [19:22:16] thanks for the quick response [19:22:20] see you later [19:22:57] (03CR) 10Bartosz Dziewoński: [C: 032] Only load switching module (depending on OOUI etc.) on edit pages [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251736 (https://phabricator.wikimedia.org/T118088) (owner: 10Alex Monk) [19:25:41] (03PS1) 10Alex Monk: Only load switching module (depending on OOUI etc.) on edit pages [extensions/VisualEditor] (wmf/1.27.0-wmf.5) - 10https://gerrit.wikimedia.org/r/251737 (https://phabricator.wikimedia.org/T118088) [19:26:18] (03Merged) 10jenkins-bot: Only load switching module (depending on OOUI etc.) on edit pages [extensions/VisualEditor] - 10https://gerrit.wikimedia.org/r/251736 (https://phabricator.wikimedia.org/T118088) (owner: 10Alex Monk) [19:26:30] (03CR) 10Alex Monk: [C: 032] Only load switching module (depending on OOUI etc.) on edit pages [extensions/VisualEditor] (wmf/1.27.0-wmf.5) - 10https://gerrit.wikimedia.org/r/251737 (https://phabricator.wikimedia.org/T118088) (owner: 10Alex Monk) [19:29:33] (03Merged) 10jenkins-bot: Only load switching module (depending on OOUI etc.) on edit pages [extensions/VisualEditor] (wmf/1.27.0-wmf.5) - 10https://gerrit.wikimedia.org/r/251737 (https://phabricator.wikimedia.org/T118088) (owner: 10Alex Monk) [19:47:48] 10VisualEditor, 6Collaboration-Team-Backlog, 10Flow: VE preview on Flow pages take too long (1min+) to load in debug mode - https://phabricator.wikimedia.org/T118090#1791387 (10He7d3r) [19:55:55] 10VisualEditor, 10VisualEditor-MediaWiki, 5Patch-For-Review, 7Performance: Half a megabyte of JavaScript / CSS loading on view pages - https://phabricator.wikimedia.org/T118088#1791396 (10Krenair) This was deployed, but I'm having trouble confirming that it fixed the issue. Please check. [20:02:40] 10VisualEditor, 10VisualEditor-MediaWiki, 5Patch-For-Review, 7Performance, and 2 others: Half a megabyte of JavaScript / CSS loading on view pages - https://phabricator.wikimedia.org/T118088#1791402 (10Krenair) 5Open>3Resolved ```krenair@tin:/srv/mediawiki-staging (master)$ echo 'https://www.wikimedia.... [20:13:24] 10VisualEditor, 10VisualEditor-EditingTools: VE dialogs become pretty confusing with the insert symbol panel open - https://phabricator.wikimedia.org/T118092#1791404 (10TheDJ) 3NEW [20:58:35] 10VisualEditor, 10VisualEditor-Tables, 7notice, 7user-notice: Be able to re-order the columns or rows of a table by dragging them to another position in VisualEditor - https://phabricator.wikimedia.org/T88694#1791426 (10Timeshifter) Here are some ideas: *https://commons.wikimedia.org/wiki/Commons:Convert_t...