logue / pukiwiki_adv

PukiWiki Adv is the derivation version of PukiWiki. This distribution specializes in modern technology, such as ajax, HTML5+CSS3, and RIA.
http://pukiwiki.logue.be/
GNU General Public License v2.0
39 stars 19 forks source link

Declaration of Zend\Session\AbstractContainer::offsetGet($key) must be compatible with & Zend\Stdlib\ArrayObject::offsetGet($key) #55

Open mikoim opened 6 years ago

mikoim commented 6 years ago

PHP 7.2へのアップグレード(?)以降,一切動作しなくなりました. インタフェースの変更で動作しなくなったのでしょうか.

PHP message: PHP Fatal error:  Declaration of Zend\Session\AbstractContainer::offsetGet($key) must be compatible with & Zend\Stdlib\ArrayObject::offsetGet($key) in /x/vendor/zendframework/zend-session/src/AbstractContainer.php on line 27
# php -v
PHP 7.2.1 (cli) (built: Jan  3 2018 06:02:01) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2017 Zend Technologies
    with Zend OPcache v7.2.1, Copyright (c) 1999-2017, by Zend Technologies
mikoim commented 6 years ago

composer updateして依存ライブラリをアップデートすることで動作するようになりました. PHPでは,処理系のアップグレードでライブラリが動作しなくなることは頻繁にあるのでしょうか?

参考までに動作するようになった状態でのバージョンを報告します.

aferrandini/phpqrcode               1.0.1              PHPQRCode porting and changed for PHP 5.3 compatibility
container-interop/container-interop 1.2.0              Promoting the interoperability of container objects (DIC, SL, etc.)
logue/igo-php                       0.1.8              Morphological analysis engine 'Igo' porting and changed for PHP 5.3 and composer.
psr/container                       1.0.0              Common Container Interface (PHP FIG PSR-11)
zendframework/zend-cache            2.7.2              provides a generic way to cache any data
zendframework/zend-captcha          2.7.1
zendframework/zend-code             3.3.0              provides facilities to generate arbitrary code using an object oriented interface
zendframework/zend-config           3.1.0              provides a nested object property based user interface for accessing this configuration data within application code
zendframework/zend-crypt            2.6.0
zendframework/zend-db               2.9.2              Database abstraction layer, SQL abstraction, result set abstraction, and RowDataGateway and TableDataGateway implementations
zendframework/zend-debug            2.5.1
zendframework/zend-dom              2.6.0              provides tools for working with DOM documents and structures
zendframework/zend-escaper          2.5.2
zendframework/zend-eventmanager     2.6.4
zendframework/zend-feed             2.9.0              provides functionality for consuming RSS and Atom feeds
zendframework/zend-filter           2.7.2              provides a set of commonly needed data filters
zendframework/zend-http             2.7.0              provides an easy interface for performing Hyper-Text Transfer Protocol (HTTP) requests
zendframework/zend-hydrator         1.1.0
zendframework/zend-i18n             2.7.4
zendframework/zend-json             2.6.1              provides convenience methods for serializing native PHP to JSON and decoding JSON to native PHP
zendframework/zend-loader           2.5.1
zendframework/zend-mail             2.8.0              provides generalized functionality to compose and send both text and MIME-compliant multipart e-mail messages
zendframework/zend-math             2.7.0
zendframework/zend-mime             2.7.0              Create and parse MIME messages and parts
zendframework/zend-progressbar      2.5.2              component to create and update progressbars in different environments
zendframework/zend-serializer       2.8.1              provides an adapter based interface to simply generate storable representation of PHP types by different facilities, and recover
zendframework/zend-server           2.7.0
zendframework/zend-servicemanager   3.1.2
zendframework/zend-session          2.8.3              manage and preserve session data, a logical complement of cookie data, across multiple page requests by the same client
zendframework/zend-stdlib           2.7.7
zendframework/zend-uri              2.5.2              a component that aids in manipulating and validating » Uniform Resource Identifiers (URIs)
zendframework/zend-validator        2.10.1             provides a set of commonly needed validators
zendframework/zend-version          2.5.1
zendframework/zend-xmlrpc           2.6.1
zendframework/zendoauth             2.0.3
zendframework/zendopenid            2.0.2              provides a simple API for building OpenID-enabled sites and identity providers
zendframework/zendsearch            dev-master c8de250 a general purpose text search engine written entirely in PHP 5
zendframework/zendservice-akismet   2.0.2              OOP wrapper for the Akismet web service
zendframework/zendservice-recaptcha 2.0.1              OOP wrapper for the ReCaptcha web service
zendframework/zendservice-twitter   2.1.0              OOP wrapper for the Twitter web service
zendframework/zendxml               1.0.2              Utility library for XML usage, best practices, and security in PHP
logue commented 6 years ago

Zend側でエラーが起きているようなので調べたところ、Zend側のバグっぽいです。 https://github.com/zendframework/zend-session/issues/74 Pukiwiki側のキャッシュは削除しましたか?

現状ソースコードがライセンスを含めてカオス状態になっているので仕切り直しをしようか考えているところです。

mikoim commented 6 years ago

@logue 調査ありがとうございます.キャッシュは削除していませんが,zend-sessionも含めた依存ライブラリのアップデートで解消しました.

ghost commented 6 years ago

I put "&" at offsetGet function and found for me:

//Zend/Session/AbstractContainer.php line 425 public function &offsetGet($key)