laravel/pint

[BUG] Extension shows "Formatting completed" but silently fails when host PHP version is incompatible

クローズ

#388 opened on 2025/08/05

 (2 件のコメント) (1 件のリアクション) (0 人の担当者)PHP (189 件のフォーク)user submission
help wanted

Repository metrics

Stars
 (3,127 個のスター)
PR merge metrics
 (平均マージ 2d 1h) (30d で 12 merged PRs)

説明

Pint Version

1.24

PHP Version

7.4

Description

Host PHP: php -v 8.1

  • Project PHP: docker exec [container] php -v 8.2
  • OS: Ubuntu 22.04

Expected Behavior:

  • Extension should warn about PHP version mismatch
  • Formatting should fail visibly (not silently)

Additional Context:

  • Works when manually running ./vendor/bin/pint in the container
  • No errors in VS Code's "Laravel Pint" output panel

Steps To Reproduce

Proposed Fixes:

  1. Add PHP version validation before running Pint
  2. Show explicit errors when:
    • Host PHP < project's required version
    • No PHP binary is found

コントリビューターガイド