[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Page MenuHomePhabricator

Deprecate not passing a user to ParserOptions::__construct and ::newCanonical
Closed, ResolvedPublic

Description

If a user isn't provided, it uses global $wgUser

Details

SubjectRepoBranchLines +/-
mediawiki/coremaster+57 -18
mediawiki/extensions/Flowmaster+6 -3
mediawiki/extensions/Wikibasemaster+9 -1
mediawiki/extensions/Jademaster+1 -1
mediawiki/extensions/EntitySchemamaster+4 -1
mediawiki/extensions/Flowmaster+1 -1
mediawiki/extensions/Quizmaster+2 -2
mediawiki/extensions/EventLoggingmaster+3 -2
mediawiki/coremaster+25 -16
mediawiki/extensions/ProofreadPagemaster+1 -1
mediawiki/extensions/AbuseFiltermaster+13 -4
mediawiki/extensions/ParserMigrationmaster+1 -1
mediawiki/extensions/MultiBoilerplatemaster+3 -1
mediawiki/extensions/SecurePollmaster+4 -1
mediawiki/extensions/Wikibasemaster+2 -2
mediawiki/extensions/PhpTagsStoragemaster+1 -1
mediawiki/extensions/MintyDocsmaster+5 -1
mediawiki/extensions/GrowthExperimentsmaster+1 -1
mediawiki/extensions/ProofreadPagemaster+3 -1
mediawiki/extensions/BlueSpiceRSSFeedermaster+2 -2
mediawiki/extensions/TEImaster+1 -1
mediawiki/extensions/CollaborationKitmaster+5 -5
mediawiki/extensions/MassMessageEmailmaster+1 -1
mediawiki/extensions/Wikibasemaster+9 -9
mediawiki/extensions/NewUserMessagemaster+6 -2
mediawiki/extensions/LiquidThreadsmaster+2 -2
mediawiki/extensions/Mathmaster+1 -1
mediawiki/extensions/Newsmaster+4 -3
mediawiki/extensions/MediaWikiChatmaster+1 -1
mediawiki/extensions/Scribuntomaster+9 -4
mediawiki/extensions/Babelmaster+1 -1
mediawiki/coremaster+1 -1
mediawiki/extensions/Kartographermaster+3 -3
mediawiki/extensions/MassMessagemaster+1 -1
mediawiki/extensions/Flowmaster+11 -4
mediawiki/extensions/FeaturedFeedsmaster+23 -12
mediawiki/extensions/Echomaster+4 -4
mediawiki/extensions/intersectionmaster+1 -1
mediawiki/extensions/Commentsmaster+1 -1
mediawiki/extensions/FileImportermaster+13 -5
mediawiki/extensions/ConfirmEditmaster+1 -1
mediawiki/extensions/Graphmaster+1 -1
mediawiki/extensions/NewsTickermaster+1 -1
mediawiki/extensions/DocBookExportmaster+1 -1
mediawiki/extensions/TwoColConflictmaster+1 -1
mediawiki/extensions/VisualEditormaster+1 -1
mediawiki/skins/eruditemaster+1 -1
mediawiki/extensions/VEForAllmaster+1 -1
Show related patches Customize query in gerrit

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes

Change 577406 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/FeaturedFeeds@master] Pass a user when creating a new ParserOptions

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

Change 577406 merged by jenkins-bot:
[mediawiki/extensions/FeaturedFeeds@master] Pass a user when creating a new ParserOptions

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

Change 577710 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Math@master] User ParserOptions::newFromAnon instead of relying on wgUser

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

Change 577711 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/MediaWikiChat@master] Pass a user when creating a new ParserOptions

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

Change 577712 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/MultiBoilerplate@master] Pass a user when creating a new ParserOptions

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

Change 577713 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/News@master] Pass a user when creating a new ParserOptions

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

Change 577714 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/NewUserMessage@master] Pass a user when creating a new ParserOptions

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

Change 577716 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/ProofreadPage@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577717 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Scribunto@master] Don't fall back to global $wgUser when creating ParserOptions

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

Change 577718 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/MintyDocs@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577719 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/MassMessage@master] Pass a user when creating a new ParserOptions

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

Change 576914 merged by jenkins-bot:
[mediawiki/extensions/Flow@master] Pass a user when creating a new ParserOptions

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

Change 577720 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/LiquidThreads@master] Pass a user when creating a new ParserOptions

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

Change 577721 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/core@master] MessageCache: Pass a user when creating a new ParserOptions

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

Change 577722 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Wikibase@master] Don't fall back to global $wgUser when creating ParserOptions

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

Change 577723 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Kartographer@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577724 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Babel@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577719 merged by jenkins-bot:
[mediawiki/extensions/MassMessage@master] Pass a user when creating a new ParserOptions

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

Change 577721 merged by jenkins-bot:
[mediawiki/core@master] MessageCache: Pass a user when creating a new ParserOptions

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

Change 577723 merged by jenkins-bot:
[mediawiki/extensions/Kartographer@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577724 merged by jenkins-bot:
[mediawiki/extensions/Babel@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577717 merged by jenkins-bot:
[mediawiki/extensions/Scribunto@master] Don't fall back to global $wgUser when creating ParserOptions

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

Change 577710 merged by jenkins-bot:
[mediawiki/extensions/Math@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577711 merged by jenkins-bot:
[mediawiki/extensions/MediaWikiChat@master] Pass a user when creating a new ParserOptions

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

Change 577713 merged by jenkins-bot:
[mediawiki/extensions/News@master] Pass a user when creating a new ParserOptions

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

Change 577921 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/BlueSpiceRSSFeeder@master] Don't fall back to global $wgUser when creating ParserOptions

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

Change 577925 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/CollaborationKit@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577927 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/SecurePoll@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577930 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/PhpTagsStorage@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577931 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/MassMessageEmail@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 578043 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/TEI@master] Pass a user to ParserOptions::newCanonical

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

Change 577720 merged by jenkins-bot:
[mediawiki/extensions/LiquidThreads@master] Pass a user when creating a new ParserOptions

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

Change 577714 merged by jenkins-bot:
[mediawiki/extensions/NewUserMessage@master] Pass a user when creating a new ParserOptions

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

Change 577722 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577925 merged by jenkins-bot:
[mediawiki/extensions/CollaborationKit@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577931 merged by jenkins-bot:
[mediawiki/extensions/MassMessageEmail@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 578043 merged by jenkins-bot:
[mediawiki/extensions/TEI@master] Replace ParserOptions::newCanonical with ::newFromUser, pass a user

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

Change 579111 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Wikibase@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 579112 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/ParserMigration@master] Pass a user when creating a new ParserOptions

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

Change 579113 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/GrowthExperiments@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577921 merged by jenkins-bot:
[mediawiki/extensions/BlueSpiceRSSFeeder@master] Don't fall back to global $wgUser when creating ParserOptions

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

Change 577716 merged by jenkins-bot:
[mediawiki/extensions/ProofreadPage@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 579113 merged by jenkins-bot:
[mediawiki/extensions/GrowthExperiments@master] Pass 'canonical' for creating ParserOptions instead of using on $wgUser

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

Uses of new ParserOptions in deployed extensions that still need to be updated:

  • SecurePoll
  • EventLogging
  • EntitySchema
  • CollaborationKit
  • AbuseFilter
  • Quiz
  • Flow
  • Wikibase

Also: core, vendor

Uses of ParserOptions::newCanonical in deployed extensions that still need to be updated:

  • Wikibase
  • ProofreadPage

Also: parsoid, vendor, core

Change 577718 merged by jenkins-bot:
[mediawiki/extensions/MintyDocs@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 577930 merged by Umherirrender:
[mediawiki/extensions/PhpTagsStorage@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 579111 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Don’t rely on $wgUser when creating ParserOptions in test

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

Change 577927 merged by jenkins-bot:
[mediawiki/extensions/SecurePoll@master] Use ParserOptions::newFromUser with conext user

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

Change 577712 merged by jenkins-bot:
[mediawiki/extensions/MultiBoilerplate@master] Pass a user when creating a new ParserOptions

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

Change 579112 merged by jenkins-bot:
[mediawiki/extensions/ParserMigration@master] Pass a user when creating a new ParserOptions

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

Huji subscribed.

All associated patches have been merged.

All associated patches have been merged.

There are more replacements left that I haven't sent patches for :)

Oops. Shortsighted action on my part. Thank you for all the hard work!

And here I was just trying to set up my Vagrant env to review this. Oh well. Thanks, guys!

Change 595541 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/ProofreadPage@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 576916 merged by jenkins-bot:
[mediawiki/extensions/AbuseFilter@master] Use ParserOptions::newFromUser() instead of relying on global $wgUser

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

Change 595541 merged by jenkins-bot:
[mediawiki/extensions/ProofreadPage@master] Use ParserOptions::newFromAnon() instead of relying on global $wgUser

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

Change 605694 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/core@master] Hard deprecate calling ParserOptions::newCanonical with no parameters

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

Change 605694 merged by jenkins-bot:
[mediawiki/core@master] Hard deprecate calling ParserOptions::newCanonical with no parameters

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

Change 606787 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/EventLogging@master] JsonSchemaTest: Pass a user when creating ParserOptions

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

Change 606788 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Quiz@master] Tests: Pass a user when creating ParserOptions objects

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

Change 606787 merged by jenkins-bot:
[mediawiki/extensions/EventLogging@master] JsonSchemaTest: Pass a user when creating ParserOptions

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

Change 626900 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/EntitySchema@master] Pass a user when creating ParserOptions

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

Change 626901 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Flow@master] convertToText - use ParserOptions::newFromAnon

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

Change 606788 merged by jenkins-bot:
[mediawiki/extensions/Quiz@master] Tests: Pass a user when creating ParserOptions objects

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

Change 626901 merged by jenkins-bot:
[mediawiki/extensions/Flow@master] convertToText - use ParserOptions::newFromAnon

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

Status update:
ParserOptions::newCanonical emits deprecation warnings if the first parameter is null, which results in a fallback to $wgUser in the constructor

Constructor does not yet emit deprecation warnings if called without a user.

Remaining uses without a user:
Wikibase: CachingKartographerEmbeddingHandler (the other uses of ParserOptions in wikibase generally refer to ValueParsers\ParserOptions)
EntitySchema: EntitySchemaContentTest - https://gerrit.wikimedia.org/r/c/mediawiki/extensions/EntitySchema/+/626900/
Jade: EntityBuilder
a bunch in core

Change 626900 merged by jenkins-bot:
[mediawiki/extensions/EntitySchema@master] Pass a user when creating ParserOptions

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

Change 627220 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Wikibase@master] CachingKartographerEmbeddingHandler: Pass a user to ParserOptions

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

Change 627221 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Jade@master] EntityBuilder: Pass a user to ParserOptions

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

Change 627221 merged by jenkins-bot:
[mediawiki/extensions/Jade@master] EntityBuilder: Pass a user to ParserOptions

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

Status update:
ParserOptions::newCanonical emits deprecation warnings if the first parameter is null, which results in a fallback to $wgUser in the constructor

Constructor does not yet emit deprecation warnings if called without a user.

Remaining uses without a user:
Wikibase: CachingKartographerEmbeddingHandler (the other uses of ParserOptions in wikibase generally refer to ValueParsers\ParserOptions)
EntitySchema: EntitySchemaContentTest - https://gerrit.wikimedia.org/r/c/mediawiki/extensions/EntitySchema/+/626900/
Jade: EntityBuilder
a bunch in core

Jade and EntitySchema done, Wikibase patch pending at https://gerrit.wikimedia.org/r/627220

Change 627220 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] CachingKartographerEmbeddingHandler: Pass a user to ParserOptions

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

daniel triaged this task as Medium priority.Sep 18 2020, 12:58 PM

Change 628220 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/core@master] ParserOptions: Deprecate fallback to $wgUser

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

Change 628367 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Flow@master] Utils: Pass a user to ParserOptions

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

Change 628367 merged by jenkins-bot:
[mediawiki/extensions/Flow@master] Use ParserOptions::newFromAnon()

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

Change 628220 merged by jenkins-bot:
[mediawiki/core@master] ParserOptions: Deprecate fallback to $wgUser

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