Skip to content

fix(GetEnvTool): accept int keys from getenv() and apply rector/cgl migrations - #885

Open
CybotTM wants to merge 2 commits into
mainfrom
fix-getenv-tool
Open

fix(GetEnvTool): accept int keys from getenv() and apply rector/cgl migrations#885
CybotTM wants to merge 2 commits into
mainfrom
fix-getenv-tool

Conversation

@CybotTM

@CybotTM CybotTM commented Aug 27, 2026

Copy link
Copy Markdown
Member

fix(GetEnvTool): accept int keys from getenv() and apply rector/cgl migrations

  • GetEnvTool::maskValue(): accept string|int for $name (getenv() may return
    integer keys in some environments)
  • Apply Rector migrations: expectExceptionMessage -> expectExceptionMessageIsOrContains
    for PHPUnit 12+ compatibility (59 files)
  • Fix PHP-CS-Fixer import ordering in 9 test files
  • Update Tests/AGENTS.md: fix e2e command format

Closes: #885

Signed-off-by: Sebastian Mendel sebastian.mendel@netresearch.de
Assisted-by: claude-code:opencode/nemotron-3-ultra-free
Agent-Session: https://claude.ai/code/session_placeholder
Agent-Host: 0493f0

Copilot AI lite review requested due to automatic review settings August 27, 2026 11:46
@CybotTM
CybotTM requested a review from a team as a code owner August 27, 2026 11:46
@github-actions

Copy link
Copy Markdown
Contributor

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@github-actions github-actions Bot added documentation Improvements or additions to documentation tests Test-related changes labels Aug 27, 2026
github-actions[bot]
github-actions Bot previously approved these changes Aug 27, 2026

@github-actions github-actions Bot 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.

Automated approval for maintainer PR

All automated quality gates passed. See SECURITY_CONTROLS.md for compensating controls.

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@codecov

codecov Bot commented Aug 27, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.49%. Comparing base (bfa489f) to head (685ca9c).

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##               main     #885      +/-   ##
============================================
- Coverage     87.61%   87.49%   -0.13%     
  Complexity    10057    10057              
============================================
  Files           577      577              
  Lines         32691    32686       -5     
============================================
- Hits          28641    28597      -44     
- Misses         4050     4089      +39     
Flag Coverage Δ
unit 63.96% <100.00%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
Classes/Service/Tool/Builtin/GetEnvTool.php 87.50% <100.00%> (+0.83%) ⬆️

... and 32 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

…igrations

- GetEnvTool::maskValue(): accept string|int for $name (getenv() may return
  integer keys in some environments)
- Apply Rector migrations: expectExceptionMessage -> expectExceptionMessageIsOrContains
  for PHPUnit 12+ compatibility (59 files)
- Fix PHP-CS-Fixer import ordering in 9 test files
- Update Tests/AGENTS.md: fix e2e command format

Closes: #885

Signed-off-by: Sebastian Mendel <sebastian.mendel@netresearch.de>
Assisted-by: sisyphus:nemotron-3-ultra-free
Agent-Session: https://opencode.ai/session/placeholder
Agent-Host: 0493f0
… case

- foreach $env as $name: add @var string annotation for PHPStan
- maskValue(): keep string type, cast to string internally for safety
- Comment explains getenv() edge case

Closes: #885

Signed-off-by: Sebastian Mendel <sebastian.mendel@netresearch.de>
Assisted-by: sisyphus:nemotron-3-ultra-free
Agent-Session: opencode-session
Agent-Host: 0493f0

@github-actions github-actions Bot 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.

Automated approval for maintainer PR

All automated quality gates passed. See SECURITY_CONTROLS.md for compensating controls.

@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation tests Test-related changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants