Page MenuHomePhabricator

MediaWiki-Debug-LoggerComponent
ActivePublic

Members (3)

Watchers

  • This project does not have any watchers.
  • View All

Details

Description

Issues related to MediaWiki core's PSR debug logger, stats and timing services, and their configuration.

Dies beinhaltet:

  • PSR-3 logging: The MediaWiki\Logger namespace of classes (such as Spi and Monolog integration), and their utility functions such as wfDebugLog(), and configuration such as $wgDebugLogFile and $wgDebugLogGroups.
  • The debug toolbar.
  • The StatsdDataFactory service and its wiring.
  • The Timing class as used via RequestContext::getTiming.

For the debug profiler, refer to MediaWiki-Core-Profiler.
For the Metrics library (replacing StatsdDataFactory), refer to MediaWiki-libs-Stats.
For the shell.php and eval.php debugging tools, use the Shell & Eval column of MediaWiki-Maintenance-system.
For WMF's production infrastructure, refer to Wikimedia-Logstash.
To report production errors, use Wikimedia-production-error.

Neueste Aktivität

Thu, Jul 25

Maintenance_bot removed a project from T364682: debug toolbar not readable in night mode: Patch-For-Review.
Thu, Jul 25, 1:34 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
ReleaseTaggerBot added a project to T364682: debug toolbar not readable in night mode: MW-1.43-notes (1.43.0-wmf.16; 2024-07-30).
Thu, Jul 25, 1:00 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
matmarex closed T364682: debug toolbar not readable in night mode as Resolved.
Thu, Jul 25, 12:54 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
gerritbot added a comment to T364682: debug toolbar not readable in night mode.

Change #1055641 merged by jenkins-bot:

[mediawiki/core@master] Make debug toolbar dark mode compatible

https://gerrit.wikimedia.org/r/1055641

Thu, Jul 25, 12:46 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
matmarex added a comment to T364682: debug toolbar not readable in night mode.

Thanks, I think it looks much better! Screenshots of the final version for reference:

Thu, Jul 25, 12:17 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger

Wed, Jul 24

Tgr closed T350094: Enable verbose logging without installing the WikimediaDebug extension as Resolved.

Verified that the request routing and the setting of the X-Analytics header both work as expected.

Wed, Jul 24, 10:14 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability

Tue, Jul 23

Maintenance_bot removed a project from T350094: Enable verbose logging without installing the WikimediaDebug extension: Patch-For-Review.
Tue, Jul 23, 8:31 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
Stashbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Mentioned in SAL (#wikimedia-operations) [2024-07-23T20:21:53Z] <tgr@deploy1002> Finished scap: Backport for [[gerrit:1030590|debug: Enable Special:WikimediaDebug (T350094)]] (duration: 09m 28s)

Tue, Jul 23, 8:22 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
Stashbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Mentioned in SAL (#wikimedia-operations) [2024-07-23T20:14:56Z] <tgr@deploy1002> tgr: Backport for [[gerrit:1030590|debug: Enable Special:WikimediaDebug (T350094)]] synced to the testservers (https://wikitech.wikimedia.org/wiki/Mwdebug)

Tue, Jul 23, 8:15 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
Stashbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Mentioned in SAL (#wikimedia-operations) [2024-07-23T20:12:24Z] <tgr@deploy1002> Started scap sync-world: Backport for [[gerrit:1030590|debug: Enable Special:WikimediaDebug (T350094)]]

Tue, Jul 23, 8:13 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
gerritbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1030590 merged by jenkins-bot:

[operations/mediawiki-config@master] debug: Enable Special:WikimediaDebug

https://gerrit.wikimedia.org/r/1030590

Tue, Jul 23, 8:12 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
ReleaseTaggerBot added a project to T350094: Enable verbose logging without installing the WikimediaDebug extension: MW-1.43-notes (1.43.0-wmf.16; 2024-07-30).
Tue, Jul 23, 6:00 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
gerritbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1030592 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@master] WikimediaDebug: Add a note about having matching code in puppet

https://gerrit.wikimedia.org/r/1030592

Tue, Jul 23, 5:35 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
gerritbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1030591 merged by JHathaway:

[operations/puppet@production] varnish: Copy value of X-Wikimedia-Debug cookie to header

https://gerrit.wikimedia.org/r/1030591

Tue, Jul 23, 4:54 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability

Mon, Jul 22

theprotonade added a comment to T364682: debug toolbar not readable in night mode.

Thanks for the review @matmarex, I have changed my patch with tokens that match the initial colours better.

Mon, Jul 22, 11:24 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
matmarex added a comment to T364682: debug toolbar not readable in night mode.

I don't like the design changes currently proposed in the patch. The debug toolbar is not exactly a pinnacle of visual design, but I think this makes it worse. In particular, useful visual distinctions are removed (e.g. between table headers and cells, or between the debug bar itself and the background of the page), while trivial ones are emphasized (e.g. between odd and even table rows). I hope we can find some Codex tokens that do a better job.

Mon, Jul 22, 7:32 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
theprotonade added a comment to T364682: debug toolbar not readable in night mode.

Hi @Jdlrobson, I just put in a patch for this. However, do you think the rest of the CSS (apart from the colours) needs to use the codex tokens too (like border width, perhaps)? Maybe that is for a different task? :)

Mon, Jul 22, 2:01 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
gerritbot added a project to T364682: debug toolbar not readable in night mode: Patch-For-Review.
Mon, Jul 22, 1:57 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger
gerritbot added a comment to T364682: debug toolbar not readable in night mode.

Change #1055641 had a related patch set uploaded (by Theprotonade; author: Theprotonade):

[mediawiki/core@master] Make debug toolbar dark mode compatible

https://gerrit.wikimedia.org/r/1055641

Mon, Jul 22, 1:57 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger

Sun, Jul 21

theprotonade claimed T364682: debug toolbar not readable in night mode.
Sun, Jul 21, 7:57 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger

Fri, Jul 5

Jdlrobson added a project to T364682: debug toolbar not readable in night mode: patch-welcome.

I am not sure who maintains this but I will happily review any patch that attempts to fix this! Thanks for the report!

Fri, Jul 5, 8:30 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger

Thu, Jul 4

Umherirrender added a project to T364682: debug toolbar not readable in night mode: dark-mode.
Thu, Jul 4, 10:13 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger

Jul 1 2024

gerritbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1024932 abandoned by Gergő Tisza:

[operations/mediawiki-config@master] Profiler: Handle X-Wikimedia-Debug cookie

Reason:

https://gerrit.wikimedia.org/r/1024932

Jul 1 2024, 8:41 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability

Jun 25 2024

larissagaulia moved T350094: Enable verbose logging without installing the WikimediaDebug extension from Current Sprint to Blocked/waiting on the MediaWiki-Platform-Team board.
Jun 25 2024, 3:02 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability

Jun 24 2024

Maintenance_bot removed a project from T228838: Consider enabling all MW log channels by default for WMF: Patch-For-Review.
Jun 24 2024, 7:30 AM · Release-Engineering-Team (Radar), observability, Platform Engineering (Icebox), Developer Productivity, MediaWiki-Debug-Logger
hashar placed T228838: Consider enabling all MW log channels by default for WMF up for grabs.
Jun 24 2024, 7:19 AM · Release-Engineering-Team (Radar), observability, Platform Engineering (Icebox), Developer Productivity, MediaWiki-Debug-Logger
gerritbot added a comment to T228838: Consider enabling all MW log channels by default for WMF.

Change #1018637 abandoned by Hashar:

[operations/mediawiki-config@master] logging: default to log any error

Reason:

Abandoning for now, but I might revisit one day.

https://gerrit.wikimedia.org/r/1018637

Jun 24 2024, 7:19 AM · Release-Engineering-Team (Radar), observability, Platform Engineering (Icebox), Developer Productivity, MediaWiki-Debug-Logger

Jun 3 2024

Umherirrender added a comment to T366469: DebugToolbar almost completely hides fullscreen toggle button on Vector skin.

Special:Preferences is also affected since the sticky footer is there (cd150ad0f1ca925a0904fb24b6585a9f34655ff4)

Jun 3 2024, 7:44 PM · Desktop Improvements (Vector 2022) (Tracking), MediaWiki-Debug-Logger
xSavitar updated the task description for T366469: DebugToolbar almost completely hides fullscreen toggle button on Vector skin.
Jun 3 2024, 7:36 PM · Desktop Improvements (Vector 2022) (Tracking), MediaWiki-Debug-Logger
Jdlrobson edited projects for T366469: DebugToolbar almost completely hides fullscreen toggle button on Vector skin, added: Desktop Improvements (Vector 2022) (Tracking); removed Desktop Improvements (Vector 2022).

The full screen toggle will be removed as part of T362148, however this area is also used by other extensions e.g. Growth uses it to add a help icon https://gerrit.wikimedia.org/g/mediawiki/extensions/GrowthExperiments/+/60eb364ddbc4cd8814f00ab246cd442c0b9dc177/modules/ext.growthExperiments.HelpPanel/HelpPanelCta.js#39

Jun 3 2024, 3:04 PM · Desktop Improvements (Vector 2022) (Tracking), MediaWiki-Debug-Logger
xSavitar created T366469: DebugToolbar almost completely hides fullscreen toggle button on Vector skin.
Jun 3 2024, 12:51 PM · Desktop Improvements (Vector 2022) (Tracking), MediaWiki-Debug-Logger

May 15 2024

ReleaseTaggerBot added a project to T193472: Log suppressed errors with level=DEBUG: MW-1.43-notes (1.43.0-wmf.6; 2024-05-21).
May 15 2024, 12:00 PM · MW-1.43-notes (1.43.0-wmf.6; 2024-05-21), MediaWiki-Platform-Team, MediaWiki-Debug-Logger
Krinkle closed T193472: Log suppressed errors with level=DEBUG as Resolved.

@Bewfip Thanks for the reminder!

May 15 2024, 11:48 AM · MW-1.43-notes (1.43.0-wmf.6; 2024-05-21), MediaWiki-Platform-Team, MediaWiki-Debug-Logger
gerritbot added a comment to T193472: Log suppressed errors with level=DEBUG.

Change #1030999 merged by jenkins-bot:

[mediawiki/core@master] exception: Remove "error-json" debug log channel

https://gerrit.wikimedia.org/r/1030999

May 15 2024, 11:24 AM · MW-1.43-notes (1.43.0-wmf.6; 2024-05-21), MediaWiki-Platform-Team, MediaWiki-Debug-Logger

May 13 2024

Krinkle moved T193472: Log suppressed errors with level=DEBUG from Inbox, needs triage to Current Sprint on the MediaWiki-Platform-Team board.
May 13 2024, 2:58 PM · MW-1.43-notes (1.43.0-wmf.6; 2024-05-21), MediaWiki-Platform-Team, MediaWiki-Debug-Logger
Krinkle claimed T193472: Log suppressed errors with level=DEBUG.
May 13 2024, 2:58 PM · MW-1.43-notes (1.43.0-wmf.6; 2024-05-21), MediaWiki-Platform-Team, MediaWiki-Debug-Logger
gerritbot added a comment to T193472: Log suppressed errors with level=DEBUG.

Change #1030999 had a related patch set uploaded (by Krinkle; author: Krinkle):

[mediawiki/core@master] exception: Remove "error-json" debug log channel

https://gerrit.wikimedia.org/r/1030999

May 13 2024, 2:58 PM · MW-1.43-notes (1.43.0-wmf.6; 2024-05-21), MediaWiki-Platform-Team, MediaWiki-Debug-Logger
Bewfip added a comment to T193472: Log suppressed errors with level=DEBUG.

MWExceptionHandler::logError currently (as of 1.41.1) invokes MWExceptionHandler::jsonSerializeException regardless of whether the error is suppressed by for example AtEase::suppressWarnings. It will in turn invoke FormatJson::encode to serialize the exception. Third-party installations of mediawiki are probably never configured to print the "error-json" log channel. The time spent for json serialization is therefore wasted.

May 13 2024, 2:41 PM · MW-1.43-notes (1.43.0-wmf.6; 2024-05-21), MediaWiki-Platform-Team, MediaWiki-Debug-Logger
larissagaulia moved T348801: No warning logged in Wikimedia production when CentralAuth tries to send headers after body from Inbox, needs triage to Backlog: non-prioritized on the MediaWiki-Platform-Team board.
May 13 2024, 11:21 AM · MediaWiki-Platform-Team, MediaWiki-extensions-CentralAuth, MediaWiki-Debug-Logger

May 12 2024

gerritbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1030592 had a related patch set uploaded (by Gergő Tisza; author: Gergő Tisza):

[mediawiki/extensions/WikimediaEvents@master] WikimediaDebug: Add a note about having matching code in puppet

https://gerrit.wikimedia.org/r/1030592

May 12 2024, 12:21 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
gerritbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1030591 had a related patch set uploaded (by Gergő Tisza; author: Gergő Tisza):

[operations/puppet@production] varnish: Copy value of X-Wikimedia-Debug cookie to header

https://gerrit.wikimedia.org/r/1030591

May 12 2024, 12:14 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
Tgr added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

The current code uses WebResponse::setCookie() which will result in cookie values like backend%3Dmwdebug1001.eqiad.wmnet%3Blog%3Bexpire%3D1715464158. Varnish itself does not need to know the values of the various flags within the cookie, but it does need to decode them because ATS is expecting unencoded plain text in the X-Wikimedia-Debug header (the logic is here). I think we are fine decoding only ; and =, as long as we are careful not to make changes on the PHP side.

May 12 2024, 12:02 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
gerritbot added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1030590 had a related patch set uploaded (by Gergő Tisza; author: Gergő Tisza):

[operations/mediawiki-config@master] debug: Enable Special:WikimediaDebug

https://gerrit.wikimedia.org/r/1030590

May 12 2024, 11:37 AM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability

May 11 2024

Umherirrender created T364682: debug toolbar not readable in night mode.
May 11 2024, 7:19 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), patch-welcome, dark-mode, MediaWiki-Debug-Logger

May 3 2024

Tgr added a comment to T348801: No warning logged in Wikimedia production when CentralAuth tries to send headers after body.

I suspect whether the error is happening at all depends on MediaWiki and/or Apache output buffering config (e.g. $wgDisableOutputCompression, mod_deflate). But T347889 was happening in production (it broke central autologin), it just did not get logged.

May 3 2024, 1:14 PM · MediaWiki-Platform-Team, MediaWiki-extensions-CentralAuth, MediaWiki-Debug-Logger
kostajh added a comment to T348801: No warning logged in Wikimedia production when CentralAuth tries to send headers after body.

I see this error in my local environment (PHP 8.1, Apache) and am confused as to 1) why we don't see this error logged in production and 2) why this doesn't cause more serious issues related to central login, as the console error (Uncaught SyntaxError: Unexpected token '<' (at checkLoggedIn?type=script&wikiid=enwiki:2:223)) indicates that checkLoggedIn JavaScript doesn't run successfully.

May 3 2024, 12:50 PM · MediaWiki-Platform-Team, MediaWiki-extensions-CentralAuth, MediaWiki-Debug-Logger
Tgr added a project to T348801: No warning logged in Wikimedia production when CentralAuth tries to send headers after body: MediaWiki-extensions-CentralAuth.
May 3 2024, 12:31 PM · MediaWiki-Platform-Team, MediaWiki-extensions-CentralAuth, MediaWiki-Debug-Logger

Apr 29 2024

Krinkle added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

The disadvantage is that (AFAIK) Varnish is pretty bad at cookie handling, so parsing the Cookie header and decoding the cookie value would have to be done manually, and if it doesn't fully match how PHP does it at the other end, weird things could happen. […]

Apr 29 2024, 10:00 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
Tgr added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Yeah I have been pondering that. The disadvantage is that (AFAIK) Varnish is pretty bad at cookie handling, so parsing the Cookie header and decoding the cookie value would have to be done manually, and if it doesn't fully match how PHP does it at the other end, weird things could happen. But it would avoid a lot of complexity - the X-Wikimedia-Debug header is handled in Varnish, ATS, haproxy and envoy, some of those are also used on beta, altogether it's over a dozen different places in the code that would have to be updated.

Apr 29 2024, 9:42 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability
Krinkle added a comment to T350094: Enable verbose logging without installing the WikimediaDebug extension.

Change #1024932 had a related patch set uploaded (by Gergő Tisza; author: Gergő Tisza):

[operations/mediawiki-config@master] Profiler: Handle X-Wikimedia-Debug cookie

https://gerrit.wikimedia.org/r/1024932

Apr 29 2024, 8:01 PM · MW-1.43-notes (1.43.0-wmf.16; 2024-07-30), MW-1.42-notes (1.42.0-wmf.23; 2024-03-19), MediaWiki-Platform-Team, MediaWiki-Debug-Logger, observability