Skip to content

Recognize the upstream VarDumper fix in 3.8.1. - #24

Open
mambax7 wants to merge 2 commits into
XoopsModules27x:mainfrom
mambax7:main
Open

mambax7 wants to merge 2 commits into
XoopsModules27x:mainfrom
mambax7:main

Conversation

@mambax7

@mambax7 mambax7 commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

Summary by Sourcery

Update vendor asset patching to handle the upstream VarDumper fix in version 3.8.1.

Bug Fixes:

  • Make vendor-asset patching recognize the upstream VarDumper 3.8.1 fix and remain compatible with both fixed and older assets.

Build:

  • Allow PHPUnit 11 or PHPUnit 13.4.6 and later in the development dependencies.

Tests:

  • Add unit coverage for patching both 3.8.0 and upstream-fixed 3.8.1 vendor asset layouts, including repeated patch calls.

Summary by CodeRabbit

  • Bug Fixes

    • Improved escaping of string previews in the debug bar and corrected how request details and template parameters are displayed.
    • Vendor asset patching now handles assets that already contain the expected changes, including layouts with the upstream fix.
  • Chores

    • Updated the supported PHPUnit development dependency versions.

Copilot AI balanced review requested due to automatic review settings December 2, 2026 18:28

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues remain for the vendor asset patching update.

No open issues 🎉

What changed in this PR

Updates vendor asset patching to recognize php-debugbar 3.8.1’s upstream VarDumper fix while preserving compatibility with 3.8.0.

Changes:

  • Accepts the upstream VarDumper fix and updated HTTP/template widget calls.
  • Adds tests for both vendor layouts and repeated patching.
File Description
tests/​Unit/​InstallAssetsTest.php Tests compatibility and idempotent asset patching.
include/​install.php Recognizes upstream fixes and patches both widget call formats.

Review effort: Balanced

@mambax7

mambax7 commented Dec 2, 2026

Copy link
Copy Markdown
Contributor Author

@coderabbitai full review

@mambax7

mambax7 commented Dec 2, 2026

Copy link
Copy Markdown
Contributor Author

@sourcery-ai review 

@sourcery-ai

sourcery-ai Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Reviewer's Guide

Implementation

Update the vendor-asset patcher to recognize the upstream VarDumper fix and avoid replacing widget calls that already include the upstream HTML-flag argument.

  • include/install.php L427-430, L440-443, L468-476 (+1 small edits)

Configuration

Allow PHPUnit 11 as well as PHPUnit 13.4.6 to satisfy the development dependency.

  • composer.json L33

Tests

Cover patching both the older vendor assets and the 3.8.1 assets that already contain the upstream fix, including repeated patching.

  • tests/Unit/InstallAssetsTest.php L1-96

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!

Sourcery assessment

Approved.


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

@greptile-apps

greptile-apps Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Confidence Score: 5/5RetriggerView in Greptile

[Medium impact] The PR appears safe to merge.

Summary

Recognizes php-debugbar 3.8.1’s escaped VarDumper preview without changing it.

  • The installer patches Debugbar assets from php-debugbar 3.8.0 and 3.8.1.
  • Developer setups can use PHPUnit 11 or 13.4.6 and later.

No actionable issues were found. Tests were not run.

Reviews (1) · Last reviewed commit: "allow PHPUnit ^11.0 || ^13.4." · Reviewed by Greptile

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!

Sourcery assessment

Approved.


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

@coderabbitai

coderabbitai Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Explain Change →

Warning

Review limit reached

CodeRabbit couldn't verify your organization's usage billing state, so no usage-priced review was started. Retry after the billing service recovers.

Next included review available in 53 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 99f0c199-c52a-4215-b62f-9ed88a4bad15
Commits

Reviewing files that changed from the base of the PR and between b559f69 and b31f9ac.

Files selected for processing: 3

  • composer.json
  • include/install.php
  • tests/Unit/InstallAssetsTest.php

No actionable comments were generated in the recent review.

Walkthrough

Changes

The installer changes vendor asset patch replacements and matching. New unit tests cover layouts with and without the upstream fix. The PHPUnit development dependency now accepts versions ^11.0 or ^13.4.6.

Vendor asset patching

Layer / File(s) Summary
Asset replacements and patch matching
include/install.php
The VarDumper replacement escapes string previews and uses an empty preview for non-string values. The HTTP and templates widgets pass their HTML metadata to renderValueInto. Patch application accepts a matched replacement, a replacement already present, or an optional upstream replacement.
Asset patch tests and PHPUnit compatibility
composer.json, tests/Unit/InstallAssetsTest.php
The test covers vendor layouts with and without the upstream fix, invokes the patcher twice, checks the resulting asset contents, and removes temporary files. The PHPUnit development constraint accepts versions ^11.0 or ^13.4.6.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Merge Risk: Minimal · up to b31f9

The change makes vendor asset patching recognize the upstream VarDumper fix in 3.8.1 and adds tests for it. No concrete merge-blocking risk was found.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title names the main change: the vendor-asset patching logic now recognizes the upstream VarDumper fix in version 3.8.1. The raw summary and PR objectives both describe this change as the primary …
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the main change: the vendor-asset patching logic now recognizes the upstream VarDumper fix in version 3.8.1. The raw summary and PR objectives both describe this change as the primary purpose. The title is specific and concise, and it is a single sentence. The PHPUnit constraint change is a minor secondary item and does not need to appear in the title.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 986fe814-360b-4c7b-988a-2950b94df38b
Commits

Reviewing files that changed from the base of the PR and between b559f69 and b31f9ac.

Files selected for processing: 3

  • composer.json
  • include/install.php
  • tests/Unit/InstallAssetsTest.php

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

@coderabbitai

coderabbitai Bot commented Dec 2, 2026 •

Copy link
Copy Markdown
Action not completed

Review rate limited.


Your included review limit is currently reached under our Fair Usage Limits Policy. This review may still proceed through usage-based billing if eligible. Your next included review will be available in 54 minutes.

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.

2 participants