-
-
Notifications
You must be signed in to change notification settings - Fork 840
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong variable type in css.php for $less->importDir[] #1777
Comments
I am not sure why, but the linked docker file replaces lib/exe/css.php with their own version. That's probably the reason why it behaves differently only in docker. |
That's the fix for the dockerfile. I simply added a corrected version of the css.php so that the container will actually work as intended. |
I didn't notice that this seems to be your Docker image. lessc.inc.php declares $importDir as However I guess the problem might be that it is never initialized as an array. Though I wonder why this doesn't throw any problems outside your docker image. Actually I think this should be a notice not an error... |
Yeah that's quite interesting indeed. We also use a non-docker productive dokuwiki and there is no issue with that as well. 😲 |
http://i.imgur.com/s9JTJSX.png that's what i see btw. with the |
I pushed a fix. Could it be that the PHP image you use for some reason sets a config option or something that converts warnings to exceptions? |
That is highly unlikely i guess. The base image is the offical php:7.1-apache image but i cannot find weird stuff there right now nor can i say anything definite about config options that would convert warnings. It's pretty basic afaik. |
I think this should be pushed as a hotfix, since the stable release with PHP7 is crashing like the imgur picture @ununseptium provided. |
Iam using PHP 7.1.1 and [] worked for me as well. |
I am testing Dokuwiki with Apache 2.4.25 and PHP 7.1.1 and I had to change:
to
to get stylesheets to work. |
Can verify that this is indeed an issue on Ubuntu 18.04.1 LTS as well, importDir[] should be importDir for templates to work (otherwise there's a 500 error thrown by apache and : [Fri Aug 17 10:23:07.956448 2018] [php7:error] [pid 20149] [client 157.157.42.1:41810] PHP Fatal error: Uncaught Error: [] operator not supported for strings in /usr/share/dokuwiki/lib/exe/css.php:169\nStack trace:\n#0 /usr/share/dokuwiki/lib/exe/css.php(140): css_parseless('@ini_text: #333...')\n#1 /usr/share/dokuwiki/lib/exe/css.php(18): css_out()\n#2 {main}\n thrown in /usr/share/dokuwiki/lib/exe/css.php on line 169, referer: https://localhost/doku.php |
This has been fixed since years! Update your DokuWiki. |
This is in the latest version that installs with Ubuntu 18.04 LTS. Me complaining to Canonical does nothing. If someone authoritative for the software points it out, it might help. |
Don't install the debian package. It's notoriously outdated. Just download the official package and follow the installation instructions. |
Hi there,
i think a found a
bug
(i absolutely cannot reproduce this on non docker environments, but it is definitely there) related to the used type of $less->importDir[]...i don't think it should be an array.
This causes my css.php to fail: output of the file is just
Removing
[]
made it work for me.I tested this with
Apache/2.4.10 (Debian) PHP/7.1.0
Apache/2.4.10 (Debian) PHP/7.0
Apache/2.4.10 (Debian) PHP/5.6
I had the issue on every containerized environment.
(I'm using this dockerfile)
The text was updated successfully, but these errors were encountered: