[prev in list] [next in list] [prev in thread] [next in thread]
List: wikitech-l
Subject: Re: [Wikitech-l] Editing module in the wiki editor lead to overloading resouces of processor
From: Bartosz_Dziewoński <matma.rex () gmail ! com>
Date: 2017-10-31 1:03:55
Message-ID: 3f927d62-23c9-977c-5759-e5dc5242274a () gmail ! com
[Download RAW message or body]
When you next experience the issue, you can try to debug it:
0. You should be viewing the page using MediaWiki's debug mode to make
the results easier to interpret (add &debug=1 to the page address). Note
that this will make pages load slower.
1. Open the Firefox developer tools (Ctrl+Shift+I, or Tools → Web
Developer → Toggle Tools).
2. Switch to the "Debugger" tab.
3. Click the "Pause" button.
Screenshot: https://phabricator.wikimedia.org/F10524704 (this is Firefox
57 on Windows 10, but the layout should be similar everywhere)
This will pause the execution of JavaScript on the page and reveal the
script that was executing (if nothing is currently executing, it will
pause at the beginning of the next function to execute). You can
right-click the file name to copy/reveal the full path of the script.
For example, in this screenshot the execution paused inside the code to
toggle the blinking cursor in the CodeMirror editor:
https://phabricator.wikimedia.org/F10524713
(Please also take a screenshot of the entire debugger when filing a task
about this, the "Call stack" on the right is very useful if the script
itself is large.)
Afterwards click the "Resume" button (in the same location as "Pause")
to let the page continue executing. Try doing this a few times, in case
multiple scripts are running, to increase the chance of seeing each one.
--
Bartosz Dziewoński
_______________________________________________
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic