Skip to content

Conversation

@SomeMWDev
Copy link
Contributor

@SomeMWDev SomeMWDev commented Jul 22, 2025

Fixes compatibility with MW 1.44.
Raise MW requirement to 1.40 accordingly.

Summary by CodeRabbit

  • Documentation
    • Updated minimum required MediaWiki version in documentation to 1.43.x and PHP version to 8.1.
    • Added release notes entry for version 4.0.0.
  • Chores
    • Increased minimum required MediaWiki version in extension configuration to 1.43.0.
    • Cleaned up workflow files and removed support for older MediaWiki/PHP versions; added support for MediaWiki 1.44 with PHP 8.3.
    • Updated PHP version requirement in composer configuration to 8.1.
  • Style
    • Updated import statements to use fully qualified MediaWiki class namespaces.
  • Tests
    • Improved parsing test flow to include output pipeline processing and consistent parser options.

@coderabbitai
Copy link

coderabbitai bot commented Jul 22, 2025

📝 Walkthrough

Walkthrough

The changes update MediaWiki and PHP version requirements in documentation and configuration files, adjust import statements for the Html and Title classes to use their fully qualified MediaWiki namespaces in PHP source files, and refine the parsing method in a test class. Minor whitespace adjustments are made in the CI workflow file. No logic, control flow, or functionality is altered.

Changes

Files/Paths Change Summary
.github/workflows/ci.yml Removed REL1_39 through REL1_42 from test matrix; added REL1_44 with PHP 8.3; whitespace cleanup.
README.md, extension.json, composer.json Raised minimum MediaWiki version from 1.39.x/1.39.0 to 1.43.x/1.43.0; updated PHP minimum to 8.1; added release note for v4.0.0.
src/EntryPoints/NetworkFunction.php Changed Title import to fully qualified MediaWiki\Title\Title.
src/EntryPoints/SpecialNetwork.php Changed Html and Title imports to fully qualified MediaWiki\Html\Html and MediaWiki\Title\Title.
src/NetworkFunction/AbstractNetworkPresenter.php Changed Html import to fully qualified MediaWiki\Html\Html.
tests/php/NetworkFunctionIntegrationTest.php Modified parse method to instantiate ParserOptions once with system user, use imported Title, run output pipeline, and retrieve text via content holder.

Estimated code review effort

1 (~7 minutes)


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2d9143b and e8362a2.

📒 Files selected for processing (1)
  • README.md (2 hunks)
✅ Files skipped from review due to trivial changes (1)
  • README.md

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
.github/workflows/ci.yml (1)

20-35: Consider adding a job that exercises the lowest supported PHP/MW combo.

The matrix now starts with REL1_40 on PHP 8.0.
Because the README still promises support for PHP 7.4, CI no longer protects that floor.
Adding one entry such as

- mw: 'REL1_40'
  php: 7.4
  experimental: false

would ensure you don’t accidentally introduce 8.x-only syntax.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5964874 and 70c6a5b.

📒 Files selected for processing (6)
  • .github/workflows/ci.yml (3 hunks)
  • README.md (1 hunks)
  • extension.json (1 hunks)
  • src/EntryPoints/NetworkFunction.php (1 hunks)
  • src/EntryPoints/SpecialNetwork.php (1 hunks)
  • src/NetworkFunction/AbstractNetworkPresenter.php (1 hunks)
🔇 Additional comments (4)
src/EntryPoints/NetworkFunction.php (1)

12-12: LGTM: Correct namespace import update for Title class.

The import statement correctly updates from the global Title class to the namespaced MediaWiki\Title\Title, which aligns with MediaWiki's namespace migration for version 1.44 compatibility.

src/NetworkFunction/AbstractNetworkPresenter.php (1)

7-7: LGTM: Correct namespace import update for Html class.

The import statement correctly updates from the global Html class to the namespaced MediaWiki\Html\Html, maintaining compatibility with MediaWiki 1.44 requirements.

src/EntryPoints/SpecialNetwork.php (1)

13-13: LGTM: Correct namespace import updates for Html and Title classes.

Both import statements correctly update from global classes to their namespaced MediaWiki equivalents:

  • HtmlMediaWiki\Html\Html
  • TitleMediaWiki\Title\Title

These changes maintain compatibility with MediaWiki 1.44 requirements while preserving existing functionality.

Also applies to: 15-15

extension.json (1)

19-21: Version bump looks correct; please cross-check other metadata.

The minimum MediaWiki requirement is now >= 1.40.0, which matches the PR intent.
Double-check that:

  1. Any composer.json (if present) also lists the same constraint.
  2. All user-facing docs (README, release notes) are updated consistently.

If those are already aligned, no further action needed.

@JeroenDeDauw
Copy link
Member

We need to raise the version to 4.x as per semver, due to dropping MW version support. Worth going to MW 43 right away, and then we can also fix the Title class failure for MW master

Fixes compatibility with MW 1.44.
Raise MW requirement to 1.43.
Run CI on 1.44.
Bump version to 4.0.0.
Use runOutputPipeline instead (available since 1.43), as getText
is being removed in MW 1.45.
Also use namespaced imports for ParserOptions and User.
@SomeMWDev
Copy link
Contributor Author

Done. The second commit should also fix the tests on master/1.45.

@JeroenDeDauw JeroenDeDauw merged commit 4efa5d7 into ProfessionalWiki:master Jul 22, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants