Open DanielWTQ opened 3 weeks ago
It seems like OpenCSP's latest supported version is 1.39 and that the prior supported version was 1.35. This points to an ltsrel compatibility policy. Is that correct? And does that policy also apply to WSSlots? If so, I suggest noting this in the documentation. Thanks!
I was looking to use this extension in 1.42, and it seems like the extension is broken due to the use of
WikiPage::factory()
in bothWSSlotsHooksonBeforeDataUpdateComplete()
https://github.com/Open-CSP/WSSlots/blob/dfdcd6adea3fae512c4469704ef93accff83937f/src/WSSlotsHooks.php#L137 and theWikiPageTrait
trait https://github.com/Open-CSP/WSSlots/blob/dfdcd6adea3fae512c4469704ef93accff83937f/src/WikiPageTrait.php#L33-L35This method was removed in MediaWiki 1.41, see https://github.com/wikimedia/mediawiki/commit/f3885d455e6b8bcc0308453e1f375b5e77915226 and https://phabricator.wikimedia.org/T297688.
The extension currently requires 1.35+, but the replacement for this method, using the
WikiPageFactory
service, is only available since 1.36 - given that 1.35 is no longer supported, rather than adding some version-conditional logic I suggest bumping the minimum version to 1.39 (the oldest still-supported version) and then just always using the factory - this would also allow simplifying things like the conditional logic inWSSlots::editSlots()
for handling the watchlist: https://github.com/Open-CSP/WSSlots/blob/dfdcd6adea3fae512c4469704ef93accff83937f/src/WSSlots.php#L241-L255Note: I have not actually tested this extension with 1.42 yet, so there might be other places that are broken - it might be useful to add some CI