-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
ownCloud 8.1: php-error Array to string conversion #17468
Comments
It would be good if you could find out which app triggers that error. |
This error occurs everytime the admin-panel is shown in the web-frontend. Calendar and Contacts are not involved. If I open the admin panel 5 times, you can find 5 error-entries in the log. |
Exactly same issue here, but with additional line on log (every time with the same time):
|
Same error here when accessing admin settings panel. |
confirmed! Comes from the updater section this line is to check btw that function about version:
|
Do you all have open_basedir ? Or is it something different ? |
I only have
No open_basedir errors on my side. |
Does anyone have the full stack trace ? It might appear if you have xdebug enabled. |
I changed the loglevel to debug, but then I only get this:
What do you mean with "xdebug enabled"? |
There is a PHP module called XDebug. It is usually used for debugging but also expands error messages to full stack traces instead of just one line. I tried going to the admin page on my server and don't see any message. I also have OC 8.1, calendar, contacts and encryption. But don't have the updater app. @libasys pointed out that it might come from the updater app. @BenS89 do you have it enabled ? @VicDeo any idea ? |
Since I use an embedded QNAP Linux, I only can install PHP modules explicitely compiled for my NAS. Therefore, I am not able to use XDebug. |
@libasys Since you can reproduce this, could you provide a full stacktrace? |
it seems that the error go's away if you do not have any Security & setup warnings. hope it helps, |
Ok, I have two security & setup warnings which cannot be fixed so easy because of this here: #17449 The other one states that I have no php memory cache configured. Therefore, I cannot validate your post. But indeed, it seems like this is caused by the security-check component. |
Indeed, this error does not occur if all warnings are fixed. |
Ben, take a look here. https://doc.owncloud.org/server/8.1/admin_manual/installation/source_installation.html and read the section about Apache Web Server Configuration. take care |
So it seems like this error is produced by the security & setup warning component. Is it planned to fix this error message? |
From #17782 : |
I am getting the same consistent error since upgrading to 8.1.. I have also fixed all my security and setup warnings and yet I am still getting the error upon every refresh of the admin page Error PHP Array to string conversion at /var/www/html/owncloud/lib/private/template/functions.php#36 |
I can confirm this. |
I had to use |
...which is not a solution. |
If i disable the updater app it does go away but I would like the updater app to run.. anyway to fix this |
cc @VicDeo |
@LukasReschke It doesn't really accept arrays: #8188 |
@boyan-sharic I've resolved adding this lines: Fixes: Error PHP Array to string conversion at .../oc/lib/private/template/functions.php#36 #18921 |
I can confirm that @boyan-sharic 's fix above fixed the bug for me, I applied the changes to my install of ownCloud 8.2.2 (stable) in functions.php |
That was a workaround that I wrote that doesn't fix the underlying bug - only the symptoms. The real problem is not the function I fixed breaking, the real problem is the function getting wrong input in the first place. It could be argued that both could be changed: make the function anticipate faulty input and serialise it - and fix the original problem. On the other hand: why bog down code with exception handling that shouldn't be necessary in the first place? Either way: I really wish the problem would be fixed soon. |
@jamesfawcett Which app do you have enabled? |
I'm still seeing this in 8.2.2 - All setup errors are fixed, except Memory Caching (a limitation of my host's capabilities), but the error is persisting when I refresh the admin page. |
Fixed for me in ownCloud 9.0 |
@GJSchaller 8.2.3 is out, maybe more luck there ? 😉 |
As soon as the updater finds it, I'll test it and report back. Thank you!
|
if you do not have any setup errors / warnings on the admin page make sure the users have an email address set in the personal section of the admin panel. |
Error is still there in 8.2.3. I worked around it with the script from here: #17468 (comment) |
I am not 100% positive what causes the error disabling the updater app is one way to make it stop. even with OC 9.0 I get allot of errors in the logs until the admin page is setup correctly. after a completed configuration all errors stop for me. so I would say double check all the admin page settings and see if it helps before editing code. just a thought. |
I keep seeing this error even in OC 8.2.3. |
Seeing this in OC 8.2.3, too. |
Since I updated from OC 8.2.2 to 8.2.3 I have the same issue. Before the update all works fine for me - no errors. |
Looks like owncloud/updater#109 is still open @VicDeo @VicDeo you mention a fix required in core ? |
Is this still happening in 8.2.5 or 9.0.2 ? |
It appears fixed in 8.2.5. I am not on 9.0.2 yet. |
Ok thanks. I'm closing this now. If anyone still sees this in a recent version, feel free to reopen. Thanks! |
Steps to reproduce:
Expected behaviour:
No errors
Actual behaviour:
You can see the following error everytime the admin-panel is requested:
Error PHP Array to string conversion at /share/MD0_DATA/Web/owncloud/lib/private/template/functions.php#36
Enabled apps:
Calendar 0.7.0
Contacts 0.4.0.0
PHP-Version: 5.5.25
OS: Embedded QNAP-Linux
The text was updated successfully, but these errors were encountered: