gturri / nspages

Plugin for dokuwiki - Display tables of content
http://www.dokuwiki.org/plugin:nspages
GNU General Public License v2.0
25 stars 23 forks source link

action.php is deprecated #131

Closed fiwswe closed 2 years ago

fiwswe commented 2 years ago

…/data/log/deprecated/*.log shows entries such as this: 2022-09-06 13:16:39 action.php is deprecated. It was called from require_once() in /dokuwiki-test/lib/plugins/action.php:3 Do not require() files yourself. Autoloading should be used instead!

A grep over the plugins folder turned up this which I suspect is one of the causes of the message: /var/www/dokuwiki-test/lib/plugins/nspages/action.php:require_once(DOKU_PLUGIN.'action.php'); See: https://github.com/gturri/nspages/blob/master/action.php#L2

fiwswe

fiwswe commented 2 years ago

Commenting https://github.com/gturri/nspages/blob/master/action.php#L2 seems to help.

fiwswe

gturri commented 2 years ago

Thanks for this heads up!

Do you know with which version of dokuwiki this deprecation appears? (I'm wondering to which extent this change could break compatibility with old instances of Dokuwiki)

fiwswe commented 2 years ago

At least back to Hogfather. That's the oldest one I'm running currently. But a commit history on https://github.com/splitbrain/dokuwiki/blob/master/lib/plugins/action.php should show this: https://github.com/splitbrain/dokuwiki/commit/e1d9dcc8b460b6f029ac9c8d5d3b8d23b6e73402#diff-9836109668925b22a752ed34fd5eef92044cb1750213b8648c36164cea2223ae in PR https://github.com/splitbrain/dokuwiki/pull/2757 seems to be the commit that introduced this. This was for Hogfather.

gturri commented 2 years ago

it should be fixed in the last version of nspages (version 2022-09-08). (I just hope I did not break compatibility with too many old instances of Dokuwiki).

Thanks for the heads-up!