SessionInterfaceHandler is throwing a deprecation notice as a warning instead of a deprecation
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
研究方向
issue 指向 ext/session/session.c 中的 session_handler_interface_gets_implemented()。閱讀兩處缺少方法的檢查,並尋找附近類似的 deprecation 層級診斷,以遵循專案慣例。變更這些通知的警告層級,接著執行相關的 session 測試,並確認缺少 create_sid() 和 validateId() 時會產生 deprecation 通知。
由索引模型根據 Issue 內容生成。
描述
Description
static void session_handler_interface_gets_implemented(zend_class_entry *self, zend_class_entry *class) {
if (!zend_hash_str_exists(&class->function_table, ZEND_STRL("create_sid"))
&& !session_interfaces_include(class, php_session_id_iface_entry)) {
zend_error(E_WARNING,
"Class %s implementing SessionHandlerInterface is missing the create_sid() method which will be required in PHP 9.0",
ZSTR_VAL(class->name));
}
if (!zend_hash_str_exists(&class->function_table, ZEND_STRL("validateid"))
&& !session_interfaces_include(class, php_session_update_timestamp_iface_entry)) {
zend_error(E_WARNING,
"Class %s implementing SessionHandlerInterface is missing the validateId() method which will be required in PHP 9.0",
ZSTR_VAL(class->name));
}
}
Found this after a PHP 8.5 -> 8.6 upgrade with 3rd party software - tried to filter out deprecation notices but this is coming up as an E_WARNING instead - and it should not be
Simply changing the E_WARNING to a deprecation level should fix the issue - it's annoying!
PHP Version
PHP 8.6.0 (cli) (built: Nov 20 2026 15:07:19) (NTS)
Copyright © The PHP Group and Contributors
Built by Ubuntu
Zend Engine v4.6.0, Copyright © Zend by Perforce
with Zend OPcache v8.6.0, Copyright ©, by Zend by Perforce
Operating System
No response
- 主要語言
- C
- 星號
- 41.9k
- 分支
- 8.5k
- 平均合併
- 2 天 16 小時
- 30 天內合併 PR
- 116
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
php/php-src 的其他 Issue
-
getimagesize(): WebP VP8 dimensions are accepted with an invalid start code可能已有人在做 @lazerg 今天認領。 未關閉Bug Status: Needs Triage
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
-
Bug Status: Needs Triage
難度 2/5 1-3 小時 新手友好度 76/100
維護者通常 1 天內回覆
-
Bug Status: Needs Triage
難度 2/5 1-3 小時 新手友好度 82/100
維護者通常 1 天內回覆
-
Bug Status: Needs Triage
難度 2/5 1-3 小時 新手友好度 75/100
維護者通常 1 天內回覆
-
BMP width above INT_MAX is published as a negative HTML attribute可能已有人在做 關聯的 PR 仍在進行中或已合併。 未關閉Bug Status: Needs Triage
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 68/100
shinyquagsire23/OpenJKDF2#540 ·
維護者通常 12 天內回覆
-
Prison work hall: laundry and kitchen stations stand at bare walls, the hatch has no counter or sign未關閉
難度 2/5 1-3 小時 新手友好度 78/100
Life-Framework/Life-Framework#5939 ·
維護者通常 1 天內回覆
-
autoconf failes to find libsodium even when present due to implicit function declaration可能已有人在做 @coderjoe 今天認領。 未關閉bug
難度 2/5 1-3 小時 新手友好度 68/100
維護者通常 13 天內回覆
-
bug python
難度 2/5 1-3 小時 新手友好度 87/100
Jstar269/nakagawa-recomp#3521 ·
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 72/100