-
-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Error message "Call to a member function getUID() on null" in cron #9953
Comments
GitMate.io thinks possibly related issues are #6706 (Call to a member function getUID() on null), #6803 (Nextcloud 12 throwing fatal error: cron - “Call to a member function getFileInfo() on null”), #3110 (PROPFIND causes Error: Call to a member function getCache() on null), #9476 (cron: Call to getLogger() on null in lib/public/Util.php:158), and #8047 (Call to a member function instanceOfStorage() on null in nextcloud/apps/files_sharing/lib/Cache.php:80). |
Weird - this looks like old logs, because there is no stack trace, but https://github.com/nextcloud/server/pull/7820/files was ported to stable13 already 🤔 Could you check the last 10 lines of |
These are the last 10 lines of
|
If I add the changes from https://github.com/nextcloud/server/pull/7820/files to my NextCloud instance, would this prevent future updates because of some integrity checks? |
Ok, I just applied #7820 to my instance. As soon as I get a more detailed log entry, I'll post it here. |
Now I got more details. It seems there is a problem with the "Deck" app:
The stack trace more readable:
|
After checking the database I think I understand what happened. First there was a user who created two boards. Later this user got deleted, but not the boards. So the boards became orphaned and the call of Is there a hook for apps to cleanup data of users when a user gets deleted? BTW: Allowing apps to create their own database tables is at least daring - nobody can guarantee that the table names are unique. Is there a formal process to register the names in a central registry so there will not be any conflicts? |
Note to self: RTFM ;-) https://docs.nextcloud.com/server/13/developer_manual/app/hooks.html It seems, Deck is lacking user deleting hooks and therefore it can happen, that orphaned boards remain in the database when deleting a user in Nextcloud. Since I cleaned up the database tables of the Deck app, the error did not occur again. So I can close this issue here. |
Steps to reproduce
*/15 * * * * php -f /<path to nextcloud>/cron.php
Expected behaviour
There is no error message from cron.
Actual behaviour
There is an error message from cron:
Call to a member function getUID() on null
This happens at least once a day (around 4:15 UTC or 4:30 UTC), sometimes also two or three times day.
Server configuration
Operating system: Ubuntu Linux 16.04
Web server: Apache 2.4
Database: MariaDB
PHP version: 7.0
Nextcloud version: 13.0.4
Updated from an older Nextcloud/ownCloud or fresh install: Updated
Where did you install Nextcloud from: nextcloud.com
Signing status:
Signing status
List of activated apps:
App list
Nextcloud configuration:
Config report
Are you using external storage, if yes which one: no
Are you using encryption: no
Are you using an external user-backend, if yes which one: no
Logs
Nextcloud log (data/nextcloud.log)
Nextcloud log
The text was updated successfully, but these errors were encountered: