Function imagedestroy() is deprecated since 8.5

Đang mở
#209 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
Nửa ngày
Mức phù hợp với người mới
60/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
php
Lĩnh vực
testing-qa

Hướng nghiên cứu

Start by reproducing the linked PHPStan example with PHP 8.5 and the listed phpstan-deprecation-rules version. Trace how the rules determine which PHP version’s deprecations apply, including the project’s Composer PHP constraint. Done means the example reports imagedestroy() as deprecated when analyzed for PHP 8.5 while respecting the project’s supported-version configuration.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Hi,

I hope I found the right repo to report this issue.

I'm not so much into phpstan internals, so I'm just leaving it here:

The following exception has been thrown in my code:

Function imagedestroy() is deprecated since 8.5, as it has no effect since PHP 8.0

But the phpstan didn't report anything. But it think it should.

https://phpstan.org/r/44a6cfca-c740-4641-8e03-34222efda24c

But as you can see it works in the above example. So I must have done something wrong. What did I miss? I'm using PHP 8.5.

Does it look into composer required php version? If so, I got here:

     "require": {
        "php": "^8.1",

But my project supports PHP 8.1 up to 8.5

I've installed both phpstan + deprecation-rules:

    "require-dev": {
        "phpstan/phpstan": "^2.0",
        "phpstan/phpstan-deprecation-rules": "^2.0"
    },
Image
Ngôn ngữ chính
PHP
Star
465
Fork
26
Merge trung bình
17 giờ 27 phút
Pull request đã merge (30 ngày)
8

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của phpstan/phpstan-deprecation-rules

Tất cả issue của phpstan/phpstan-deprecation-rules

Issue tương tự

Thêm issue về PHP

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.