Skip to content
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

OC\User\NoUserException: Backends provided no user object #19647

Closed
tigernero79 opened this issue Feb 25, 2020 · 48 comments · Fixed by #25274
Closed

OC\User\NoUserException: Backends provided no user object #19647

tigernero79 opened this issue Feb 25, 2020 · 48 comments · Fixed by #25274
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 27-feedback bug

Comments

@tigernero79
Copy link

I use two nextcloud updated to version 18.0.1 and I have problem in deleting files from a shared federated folder. while nextcloud user who shared my folder with me you can safely operate the files I who received the federated folder I can upload the images but not delete them although on another instance I have permissions on the folder for editing. I get this error "OC \ User \ NoUserException: Backends provided no user object" how can I solve?

Attach complete error:

[webdav] Fatal: OC\User\NoUserException: Backends provided no user object at <<closure>>

 0. <<closure>>
    OC\Files\Node\Root->getUserFolder("[email protected]/")
 1. /var/www/Pensierando/nx/lib/private/Files/Node/LazyRoot.php line 65
    call_user_func_array([OC\Files\Node\Root {},"getUserFolder"], ["[email protected]/"])
 2. /var/www/Pensierando/nx/lib/private/Files/Node/LazyRoot.php line 282
    OC\Files\Node\LazyRoot->__call("getUserFolder", ["[email protected]/"])
 3. /var/www/Pensierando/nx/apps/files_trashbin/lib/Storage.php line 142
    OC\Files\Node\LazyRoot->getUserFolder("[email protected]/")
 4. /var/www/Pensierando/nx/apps/files_trashbin/lib/Storage.php line 182
    OCA\Files_Trashbin\Storage->shouldMoveToTrash("2020-02-23_161848.jpg")
 5. /var/www/Pensierando/nx/apps/files_trashbin/lib/Storage.php line 100
    OCA\Files_Trashbin\Storage->doDelete("2020-02-23_161848.jpg", "unlink")
 6. /var/www/Pensierando/nx/apps/files_accesscontrol/lib/StorageWrapper.php line 287
    OCA\Files_Trashbin\Storage->unlink("2020-02-23_161848.jpg")
 7. /var/www/Pensierando/nx/lib/private/Files/View.php line 1162
    OCA\FilesAccessControl\StorageWrapper->unlink("2020-02-23_161848.jpg")
 8. /var/www/Pensierando/nx/lib/private/Files/View.php line 716
    OC\Files\View->basicOperation("unlink", "/Cartella Con T ... g", ["delete"])
 9. /var/www/Pensierando/nx/apps/dav/lib/Connector/Sabre/File.php line 448
    OC\Files\View->unlink("/Cartella Con T ... g")
10. /var/www/Pensierando/nx/3rdparty/sabre/dav/lib/DAV/Tree.php line 179
    OCA\DAV\Connector\Sabre\File->delete()
11. /var/www/Pensierando/nx/3rdparty/sabre/dav/lib/DAV/CorePlugin.php line 287
    Sabre\DAV\Tree->delete("files/Tiger/Car ... g")
12. <<closure>>
    Sabre\DAV\CorePlugin->httpDelete(Sabre\HTTP\Reque ... "}, Sabre\HTTP\Response {})
13. /var/www/Pensierando/nx/3rdparty/sabre/event/lib/EventEmitterTrait.php line 105
    call_user_func_array([Sabre\DAV\CorePlugin {},"httpDelete"], [Sabre\HTTP\Requ ... }])
14. /var/www/Pensierando/nx/3rdparty/sabre/dav/lib/DAV/Server.php line 479
    Sabre\Event\EventEmitter->emit("method:DELETE", [Sabre\HTTP\Requ ... }])
15. /var/www/Pensierando/nx/3rdparty/sabre/dav/lib/DAV/Server.php line 254
    Sabre\DAV\Server->invokeMethod(Sabre\HTTP\Reque ... "}, Sabre\HTTP\Response {})
16. /var/www/Pensierando/nx/apps/dav/lib/Server.php line 319
    Sabre\DAV\Server->exec()
17. /var/www/Pensierando/nx/apps/dav/appinfo/v2/remote.php line 35
    OCA\DAV\Server->exec()
18. /var/www/Pensierando/nx/remote.php line 165
    require_once("/var/www/Pensie ... p")

DELETE /remote.php/dav/files/Tiger/Cartella%20Con%20Tiger/2020-02-23_161848.jpg
from 37.160.88.102 by Tiger at 2020-02-25T21:10:45+00:00
@tigernero79 tigernero79 added 0. Needs triage Pending check for reproducibility or if it fits our roadmap bug labels Feb 25, 2020
@tigernero79
Copy link
Author

in practice, those who receive the federated folder from another nextcloud despite having the permissions to delete, cannot delete files that only the one who shared the federated folder puts in that folder, while I, who received the shared folder in my nextcloud, can only files but don't delete them as well if other has given me the permissions.

@tigernero79
Copy link
Author

@nickvergessen I read that you committed to the problem that I have on nextcloud 12,

nextcloud/files_downloadactivity#8

but now I run on instance nextcloud 18.0.1 and I still have that error on the federated shared folders where those who shared can delete the files and those who receive the federated folder it cannot delete the files inside despite having received the permissions. how to solve?

@pilsetnieks

This comment has been minimized.

@arjan-s

This comment has been minimized.

@aimotrens

This comment has been minimized.

@arjan-s

This comment has been minimized.

@uPvtkBlpiucvDUf
Copy link

uPvtkBlpiucvDUf commented Jul 29, 2020

I jus had a look at the stacktrace from #19647 (comment) and the code. The problem seems to be this in the trashbin app (OCA\Files_Trashbin\Storage::shouldMoveToTrash):

// check if there is a app which want to disable the trash bin for this file
$fileId = $this->storage->getCache()->getId($path);
$owner = $this->storage->getOwner($path);
if ($owner === false) {
	$nodes = $this->rootFolder->getById($fileId);
} else {
	$nodes = $this->rootFolder->getUserFolder($owner)->getById($fileId);
}

This assumes $owner is either false or a user. However, for federated shares, $owner is something like [email protected]/, which is neither false nor a user. As a result, $this->rootFolder->getUserFolder($owner) raises an exception and the delete operation fails.

The problem seems to have been introduced in this commit: 8e7c287. I think the trashbin behavior needs to be adjusted to work with federated shares. Unfortunately, I don't know enough about nextcloud internals to know how the trashbin should be correctly handled in this case.

@rullzer Can you help?

Fwiw: I can reproduce this issue on 19.0.1 and when it occurs I can also reproduce this other issue: nextcloud/desktop#853 regarding high CPU usage of the desktop client. This high CPU usage occurs precisely after I receive a federated share and then try to delete a file in this share (which fails as described above). If I remove the federated share, also the desktop client syncing issue is gone. The reason seems to be that the server always sends a new Etag to the client for the federated share so that the client is constantly syncing (according to logs recorded with nextcloud --logdebug). I will write a more detailed comment about this when I find the time.

@fettfoen

This comment has been minimized.

@khlschrnk
Copy link

I also got this problem since a a long time. Now, with 19.0.3 it's still appearing in my log at every run of cron.

@kiplingw
Copy link

I am experiencing the same problem on 19.0.3. Remote user shared a folder with me. They have given me full permissions to create, edit, and delete. I am able to do all of but the latter. The logs show the following stack trace:

{"reqId":"X2Z8DISIBkpZi3KVwiBabgAAAA0",
"level":3,
"time":"2020-09-19T21:45:53+00:00",
"remoteAddr":"<redacted>",
"user":"kip",
"app":"files",
"method":"DELETE",
"url":"/remote.php/dav/files/<redacted>/test.md",
"message":"Backends provided no user object for <redacted>@nextcloud.<redacted>.com/",
"userAgent":"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:80.0) Gecko/20100101 Firefox/80.0",
"version":"19.0.3.1"}
{
    "reqId":"X2Z8DISIBkpZi3KVwiBabgAAAA0",

    "level":4,

    "time":"2020-09-19T21:45:53+00:00",

    "remoteAddr":"<redacted>",

    "user":"kip",

    "app":"webdav",

    "method":"DELETE",

    "url":"/remote.php/dav/files/<redacted>/test.md",

    "message":
    {
        "Exception":"OC\\User\\NoUserException",

        "Message":"Backends provided no user object",

        "Code":0,

        "Trace":
        [
            {
                "function":"getUserFolder",

                "class":"OC\\Files\\Node\\Root",

                "type":"->",

                "args":
                [
                    "<redacted>@nextcloud.<redacted>.com/"
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/lib/private/Files/Node/LazyRoot.php",

                "line":66,

                "function":"call_user_func_array",

                "args":
                [
                    [
                        {
                            "__class__":"OC\\Files\\Node\\Root"
                        },

                        "getUserFolder"
                    ],

                    [
                        "<redacted>@nextcloud.<redacted>.com/"
                    ]
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/lib/private/Files/Node/LazyRoot.php",

                "line":283,

                "function":"__call",

                "class":"OC\\Files\\Node\\LazyRoot",

                "type":"->",

                "args":
                [
                    "getUserFolder",

                    [
                        "<redacted>@nextcloud.<redacted>.com/"
                    ]
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/apps/files_trashbin/lib/Storage.php",

                "line":141,

                "function":"getUserFolder",

                "class":"OC\\Files\\Node\\LazyRoot",

                "type":"->",

                "args":
                [
                    "<redacted>@nextcloud.<redacted>.com/"
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/apps/files_trashbin/lib/Storage.php",

                "line":181,

                "function":"shouldMoveToTrash",

                "class":"OCA\\Files_Trashbin\\Storage",

                "type":"->",

                "args":
                [
                    "test.md"
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/apps/files_trashbin/lib/Storage.php",

                "line":99,

                "function":"doDelete",

                "class":"OCA\\Files_Trashbin\\Storage",

                "type":"->",

                "args":
                [
                    "test.md",

                    "unlink"
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/lib/private/Files/View.php",

                "line":1161,

                "function":"unlink",

                "class":"OCA\\Files_Trashbin\\Storage",

                "type":"->",

                "args":
                [
                    "test.md"
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/lib/private/Files/View.php",

                "line":718,

                "function":"basicOperation",

                "class":"OC\\Files\\View",

                "type":"->",

                "args":
                [
                    "unlink",

                    "/<redacted>/test.md",

                    [
                        "delete"
                    ]
                ]
            },

            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/apps/dav/lib/Connector/Sabre/File.php",

                "line":458,
                "function":"unlink",
                "class":"OC\\Files\\View",
                "type":"->",
                "args":
                [
                    "/<redacted>/test.md"
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/3rdparty/sabre/dav/lib/DAV/Tree.php",
                "line":183,
                "function":"delete",
                "class":"OCA\\DAV\\Connector\\Sabre\\File",
                "type":"->",
                "args":[]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/3rdparty/sabre/dav/lib/DAV/CorePlugin.php",
                "line":295,
                "function":"delete",
                "class":"Sabre\\DAV\\Tree",
                "type":"->",
                "args":
                [
                    "files/kip/<redacted>/test.md"
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/3rdparty/sabre/event/lib/WildcardEmitterTrait.php",
                "line":89,
                "function":"httpDelete",
                "class":"Sabre\\DAV\\CorePlugin",
                "type":"->",
                "args":
                [
                    {
                        "__class__":"Sabre\\HTTP\\Request"
                    },
                    {
                        "__class__":"Sabre\\HTTP\\Response"
                    }
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/3rdparty/sabre/dav/lib/DAV/Server.php",
                "line":474,
                "function":"emit",
                "class":"Sabre\\DAV\\Server",
                "type":"->",
                "args":
                [
                    "method:DELETE",
                    [
                        {
                            "__class__":"Sabre\\HTTP\\Request"
                        },
                        {
                            "__class__":"Sabre\\HTTP\\Response"
                        }
                    ]
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/3rdparty/sabre/dav/lib/DAV/Server.php",
                "line":251,
                "function":"invokeMethod",
                "class":"Sabre\\DAV\\Server",
                "type":"->",
                "args":
                [
                    {
                        "__class__":"Sabre\\HTTP\\Request"
                    },
                    {
                        "__class__":"Sabre\\HTTP\\Response"
                    }
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/3rdparty/sabre/dav/lib/DAV/Server.php",
                "line":319,
                "function":"start",
                "class":"Sabre\\DAV\\Server",
                "type":"->",
                "args":
                [
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/apps/dav/lib/Server.php",
                "line":320,
                "function":"exec",
                "class":"Sabre\\DAV\\Server",
                "type":"->",
                "args":
                [
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/apps/dav/appinfo/v2/remote.php",
                "line":35,
                "function":"exec",
                "class":"OCA\\DAV\\Server",
                "type":"->",
                "args":
                [
                ]
            },
            {
                "file":"/home/ct_nextcloud/nextcloud.<redacted>.com/remote.php",
                "line":167,
                "args":
                [
                    "/home/ct_nextcloud/nextcloud.<redacted>.com/apps/dav/appinfo/v2/remote.php"
                ],
                "function":"require_once"
            }
        ],
        "File":"/home/ct_nextcloud/nextcloud.<redacted>.com/lib/private/Files/Node/Root.php",
        "Line":373,
        "CustomMessage":"--"
    },
    "userAgent":"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:80.0) Gecko/20100101 Firefox/80.0",
    "version":"19.0.3.1"
}

@andyboeh
Copy link
Contributor

andyboeh commented Oct 5, 2020

I have the same problem. Since in #19647 (comment) it was mentioned that files_trashbin could be the problem, I disabled the "Deleted Files" app on the receiving cloud (it's still enabled on the sharing server). I could then delete the shared folder without a problem.

@arjan-s
Copy link

arjan-s commented Oct 5, 2020

I didn't want to disable the trashbin app, so I wrote a small patch for it that is a bit of an ugly workaround for this issue. But hey, it works for me. :)

---  apps/files_trashbin/lib/Storage-original-19.0.3.php	2020-10-05 13:50:52.910970135 +0200
+++  apps/files_trashbin/lib/Storage.php	2020-10-05 13:52:05.097636210 +0200
@@ -137,6 +137,8 @@
 		$owner = $this->storage->getOwner($path);
 		if ($owner === false) {
 			$nodes = $this->rootFolder->getById($fileId);
+		} elseif (is_string($owner) && strpos($owner, '@') !== false) {
+			return false;
 		} else {
 			$nodes = $this->rootFolder->getUserFolder($owner)->getById($fileId);
 		}

@andyboeh
Copy link
Contributor

andyboeh commented Oct 5, 2020

Yeah, this won't work for me: I use E-Mail addresses as usernames...

@arjan-s
Copy link

arjan-s commented Oct 5, 2020

You could also remove the strpos() call and only do the is_string() call, that would work too.

@fettfoen
Copy link

fettfoen commented Oct 5, 2020

I guess this should be fixed as soon as possible. Or give an easy way to disable trash for remote shares (federated shares). In my opinion this is not a small problem. I hope the enterprise version is not affected.

@nidamanx
Copy link

nidamanx commented Nov 4, 2020

Issue still present on Nextcloud 20.0.1 (dafault install/update)

Issued resolved with this Fix:
#19647 (comment)

Worked perfectly when installed on the Nextcloud guest
The host didn't need fixes

@paulkernstock
Copy link

From what I read here, it seems I'm seeing the same error. I can read from and write to a shared folder that comes from a federated NC v20 instance on my NC v20 instance, but deletion fails with OC\User\NoUserException: Backends provided no user object.

@loelkes
Copy link

loelkes commented May 15, 2021

I get this error wenn I generate previews with the "Preview Generator" app (in connection to OnlyOffice). It seems that the preview generator triggers only office to download the file for preview generation, then the download request fails because of getUserFolder.

Is this an issue related to the preview app or to the server?

{
  "reqId": "[...]",
  "level": 3,
  "time": "2021-05-15T21:20:33+02:00",
  "remoteAddr": "[...]",
  "user": "--",
  "app": "onlyoffice",
  "method": "GET",
  "url": "/index.php/apps/onlyoffice/download?doc=[...]",
  "message": {
    "Exception": "OC\\User\\NoUserException",
    "Message": "Backends provided no user object",
    "Code": 0,
    "Trace": [
      {
        "function": "getUserFolder",
        "class": "OC\\Files\\Node\\Root",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/lib/private/Files/Node/LazyFolder.php",
        "line": 66,
        "function": "call_user_func_array"
      },
      {
        "file": "/srv/nextcloud/www/lib/private/Files/Node/LazyRoot.php",
        "line": 41,
        "function": "__call",
        "class": "OC\\Files\\Node\\LazyFolder",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/apps/onlyoffice/controller/callbackcontroller.php",
        "line": 582,
        "function": "getUserFolder",
        "class": "OC\\Files\\Node\\LazyRoot",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/apps/onlyoffice/controller/callbackcontroller.php",
        "line": 246,
        "function": "getFile",
        "class": "OCA\\Onlyoffice\\Controller\\CallbackController",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/lib/private/AppFramework/Http/Dispatcher.php",
        "line": 218,
        "function": "download",
        "class": "OCA\\Onlyoffice\\Controller\\CallbackController",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/lib/private/AppFramework/Http/Dispatcher.php",
        "line": 127,
        "function": "executeController",
        "class": "OC\\AppFramework\\Http\\Dispatcher",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/lib/private/AppFramework/App.php",
        "line": 157,
        "function": "dispatch",
        "class": "OC\\AppFramework\\Http\\Dispatcher",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/lib/private/Route/Router.php",
        "line": 302,
        "function": "main",
        "class": "OC\\AppFramework\\App",
        "type": "::"
      },
      {
        "file": "/srv/nextcloud/www/lib/base.php",
        "line": 993,
        "function": "match",
        "class": "OC\\Route\\Router",
        "type": "->"
      },
      {
        "file": "/srv/nextcloud/www/index.php",
        "line": 37,
        "function": "handleRequest",
        "class": "OC",
        "type": "::"
      }
    ],
    "File": "/srv/nextcloud/www/lib/private/Files/Node/Root.php",
    "Line": 373,
    "CustomMessage": "getFile: [...]"
  },
  "userAgent": "Node.js/6.13",
  "version": "21.0.1.1",
  "id": "[...]"
}
{
  "reqId": "[...]",
  "level": 3,
  "time": "2021-05-15T21:20:33+02:00",
  "remoteAddr": "[...]",
  "user": "--",
  "app": "files",
  "method": "GET",
  "url": "/index.php/apps/onlyoffice/download?doc=[...]",
  "message": "Backends provided no user object for ",
  "userAgent": "Node.js/6.13",
  "version": "21.0.1.1",
  "id": "[...]"
}

@punkyard
Copy link

punkyard commented Oct 7, 2023

same on AiO 27.1.0 - I get a log every minute or more

[core] Error: OC\User\NoUserException: Backends provided no user object at <<closure>>

 0. <<closure>>
    OC\Files\Node\Root->getUserFolder("")
 1. /var/www/html/lib/private/Files/Node/LazyFolder.php line 74
    call_user_func_array([["OC\\Files\\No ... "], [""])
 2. /var/www/html/lib/private/Files/Node/LazyRoot.php line 40
    OC\Files\Node\LazyFolder->__call("getUserFolder", [""])
 3. /var/www/html/custom_apps/groupfolders/lib/Versions/VersionsBackend.php line 73
    OC\Files\Node\LazyRoot->getUserFolder("")
 4. /var/www/html/custom_apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 72
    OCA\GroupFolders\Versions\VersionsBackend->getVersionsForFile(["OC\\User\\User"], ["OC\\Files\\FileInfo"])
 5. /var/www/html/custom_apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 59
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireFolder([3,"ENGLISH ... "])
 6. /var/www/html/custom_apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php line 43
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireAll()
 7. /var/www/html/lib/public/BackgroundJob/Job.php line 81
    OCA\GroupFolders\BackgroundJob\ExpireGroupVersions->run(null)
 8. /var/www/html/lib/public/BackgroundJob/TimedJob.php line 103
    OCP\BackgroundJob\Job->start(["OC\\BackgroundJob\\JobList"])
 9. /var/www/html/lib/public/BackgroundJob/TimedJob.php line 93
    OCP\BackgroundJob\TimedJob->start(["OC\\BackgroundJob\\JobList"])
10. /var/www/html/cron.php line 152
    OCP\BackgroundJob\TimedJob->execute(["OC\\BackgroundJob\\JobList"], ["OC\\Log"])

at 2023-10-07T20:57:54+00:00

@RailsViceRoads
Copy link

RailsViceRoads commented Oct 13, 2023

I can confirm that. I get this log entry on every cron run (every 5 minutes) on my two NC instances.
The NC version of both is 27.1.2.1.

@dgsiegel
Copy link

I get this error accessing a public share with read&write permissions enabled. I'm accessing that folder via curl and rclone and using the share's id as well as a password to upload and edit files in that folder.

@ostasevych
Copy link

Getting this error on 27.1.3

@faxotherapy
Copy link

faxotherapy commented Nov 18, 2023

Me too on 27.1.3, got this in the log:

[core] Error: OC\User\NoUserException: Backends provided no user object at <<closure>>

 0. <<closure>>
    OC\Files\Node\Root->getUserFolder()
 1. /snap/nextcloud/38457/htdocs/lib/private/Files/Node/LazyFolder.php line 74
    call_user_func_array()
 2. /snap/nextcloud/38457/htdocs/lib/private/Files/Node/LazyRoot.php line 40
    OC\Files\Node\LazyFolder->__call()
 3. /var/snap/nextcloud/38457/nextcloud/extra-apps/groupfolders/lib/Versions/VersionsBackend.php line 73
    OC\Files\Node\LazyRoot->getUserFolder()
 4. /var/snap/nextcloud/38457/nextcloud/extra-apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 72
    OCA\GroupFolders\Versions\VersionsBackend->getVersionsForFile()
 5. /var/snap/nextcloud/38457/nextcloud/extra-apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 59
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireFolder()
 6. /var/snap/nextcloud/38457/nextcloud/extra-apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php line 43
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireAll()
 7. /snap/nextcloud/38457/htdocs/lib/public/BackgroundJob/Job.php line 81
    OCA\GroupFolders\BackgroundJob\ExpireGroupVersions->run()
 8. /snap/nextcloud/38457/htdocs/lib/public/BackgroundJob/TimedJob.php line 103
    OCP\BackgroundJob\Job->start()
 9. /snap/nextcloud/38457/htdocs/lib/public/BackgroundJob/TimedJob.php line 93
    OCP\BackgroundJob\TimedJob->start()
10. /snap/nextcloud/38457/htdocs/cron.php line 152
    OCP\BackgroundJob\TimedJob->execute()

It seems that I got this since I use “group folder” app.

❗ I get this message EVERY minute.

@enoch85
Copy link
Member

enoch85 commented Nov 18, 2023

@nickvergessen Latest version used so I'm reopening.

Please close if you disagree.

@ostasevych
Copy link

ostasevych commented Nov 19, 2023

I am getting these errors each an hour in average:

{
	"reqId":"****",
	"level":3,
	"time":"2023-11-19T11:16:03+02:00",
	"remoteAddr":"",
	"user":"--",
	"app":"core",
	"method":"","url":"--",
	"message":"Error while running background job (class: OCA\\GroupFolders\\BackgroundJob\\ExpireGroupVersions, arguments: )",
	"userAgent":"--",
	"version":"27.1.3.2",
	"exception":{
		"Exception":"OC\\User\\NoUserException",
		"Message":"Backends provided no user object","Code":0,
		"Trace":[{
			"function":"getUserFolder",
			"class":"OC\\Files\\Node\\Root",
			"type":"->"},
			{
			"file":"/var/www/html/nextcloud/lib/private/Files/Node/LazyFolder.php",
			"line":74,
			"function":"call_user_func_array"},{
				"file":"/var/www/html/nextcloud/lib/private/Files/Node/LazyRoot.php",
				"line":40,"function":"__call","class":"OC\\Files\\Node\\LazyFolder",
				"type":"->" },
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/Versions/VersionsBackend.php",
				"line":73,
				"function":"getUserFolder",
				"class":"OC\\Files\\Node\\LazyRoot",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php",
				"line":72,
				"function":"getVersionsForFile",
				"class":"OCA\\GroupFolders\\Versions\\VersionsBackend",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php",
				"line":59,
				"function":"expireFolder",
				"class":"OCA\\GroupFolders\\Versions\\GroupVersionsExpireManager",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php",
				"line":43,
				"function":"expireAll",
				"class":"OCA\\GroupFolders\\Versions\\GroupVersionsExpireManager",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/lib/public/BackgroundJob/Job.php",
				"line":81,
				"function":"run",
				"class":"OCA\\GroupFolders\\BackgroundJob\\ExpireGroupVersions",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php",
				"line":103,
				"function":"start",
				"class":"OCP\\BackgroundJob\\Job",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php",
				"line":93,
				"function":"start",
				"class":"OCP\\BackgroundJob\\TimedJob",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/cron.php",
				"line":152,
				"function":"execute",
				"class":"OCP\\BackgroundJob\\TimedJob",
				"type":"->"}],
		"File":"/var/www/html/nextcloud/lib/private/Files/Node/Root.php",
		"Line":364,
		"message":"Error while running background job (class: OCA\\GroupFolders\\BackgroundJob\\ExpireGroupVersions, arguments: )",
		"exception":[],
		"CustomMessage":"Error while running background job (class: OCA\\GroupFolders\\BackgroundJob\\ExpireGroupVersions, arguments: )"},
	"id":"6559d55f7df4b"}

...

{
	"reqId":"6QiC7lkbmLuSCMGF3rq3",
	"level":3,
	"time":"2023-11-19T11:16:03+02:00",
	"remoteAddr":"",
	"user":"--",
	"app":"files",
	"method":"",
	"url":"--",
	"message":"Backends provided no user object for ",
	"userAgent":"--",
	"version":"27.1.3.2",
	"exception":{
		"Exception":"OC\\User\\NoUserException",
		"Message":"Backends provided no user object",
		"Code":0,"Trace":[{
			"function":"getUserFolder",
			"class":"OC\\Files\\Node\\Root",
			"type":"->"},
			{
				"file":"/var/www/html/nextcloud/lib/private/Files/Node/LazyFolder.php",
				"line":74,
				"function":"call_user_func_array"},
			{
				"file":"/var/www/html/nextcloud/lib/private/Files/Node/LazyRoot.php",
				"line":40,
				"function":"__call",
				"class":"OC\\Files\\Node\\LazyFolder",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/Versions/VersionsBackend.php",
				"line":73,
				"function":"getUserFolder",
				"class":"OC\\Files\\Node\\LazyRoot",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php",
				"line":72,
				"function":"getVersionsForFile",
				"class":"OCA\\GroupFolders\\Versions\\VersionsBackend",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php",
				"line":59,
				"function":"expireFolder",
				"class":"OCA\\GroupFolders\\Versions\\GroupVersionsExpireManager",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php",
				"line":43,
				"function":"expireAll",
				"class":"OCA\\GroupFolders\\Versions\\GroupVersionsExpireManager",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/lib/public/BackgroundJob/Job.php",
				"line":81,
				"function":"run",
				"class":"OCA\\GroupFolders\\BackgroundJob\\ExpireGroupVersions",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php",
				"line":103,
				"function":"start",
				"class":"OCP\\BackgroundJob\\Job",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php",
				"line":93,
				"function":"start",
				"class":"OCP\\BackgroundJob\\TimedJob",
				"type":"->"},
			{
				"file":"/var/www/html/nextcloud/cron.php",
				"line":152,
				"function":"execute",
				"class":"OCP\\BackgroundJob\\TimedJob",
				"type":"->"}],
		"File":"/var/www/html/nextcloud/lib/private/Files/Node/Root.php",
		"Line":364,
		"message":"Backends provided no user object for ",
		"exception":[],
		"CustomMessage":"Backends provided no user object for "},
	"id":"6559d55f7e015"}

In the logreader I see:

Error | core | OC\User\NoUserException: Backends provided no user object |   | 23 minutes ago
Error | files | OC\User\NoUserException: Backends provided no user object |   | 23 minutes ago
Error | core | OC\User\NoUserException: Backends provided no user object |   | hour ago
Error | files | OC\User\NoUserException: Backends provided no user object |   | hour ago
Error | core | OC\User\NoUserException: Backends provided no user object |   | 2 hours ago
Error | files | OC\User\NoUserException: Backends provided no user object |   | 2 hours ago
Error | core | OC\User\NoUserException: Backends provided no user object |   | 3 hours ago
Error | files | OC\User\NoUserException: Backends provided no user object |   | 3 hours ago
Error | core | OC\User\NoUserException: Backends provided no user object |   | 4 hours ago
Error | files | OC\User\NoUserException: Backends provided no user object |   | 4 hours ago

As you can see the errors both in files and core apps are the same.

Related to bug nextcloud/groupfolders#2559

@Gerri1
Copy link

Gerri1 commented Dec 9, 2023

I also have these error messages during my installation.

core - OC\User\NoUserException: Backends provided no user object
file - OC\User\NoUserException: Backends provided no user object

`

Fehler core OC\User\NoUserException: Backends provided no user object<>OC\Files\Node\Root->getUserFolder()/var/www/html/nextcloud/lib/private/Files/Node/LazyFolder.php - line 74: call_user_func_array()/var/www/html/nextcloud/lib/private/Files/Node/LazyRoot.php - line 40: OC\Files\Node\LazyFolder->__call()/var/www/html/nextcloud/apps/groupfolders/lib/Versions/VersionsBackend.php - line 73: OC\Files\Node\LazyRoot->getUserFolder()/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php - line 72: OCA\GroupFolders\Versions\VersionsBackend->getVersionsForFile()/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php - line 59: OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireFolder()/var/www/html/nextcloud/apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php - line 43: OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireAll()/var/www/html/nextcloud/lib/public/BackgroundJob/Job.php - line 81: OCA\GroupFolders\BackgroundJob\ExpireGroupVersions->run()/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php - line 103: OCP\BackgroundJob\Job->start()/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php - line 93: OCP\BackgroundJob\TimedJob->start()/var/www/html/nextcloud/cron.php - line 152: OCP\BackgroundJob\TimedJob->execute()

`

Fehler files OC\User\NoUserException: Backends provided no user object<>OC\Files\Node\Root->getUserFolder()/var/www/html/nextcloud/lib/private/Files/Node/LazyFolder.php - line 74: call_user_func_array()/var/www/html/nextcloud/lib/private/Files/Node/LazyRoot.php - line 40: OC\Files\Node\LazyFolder->__call()/var/www/html/nextcloud/apps/groupfolders/lib/Versions/VersionsBackend.php - line 73: OC\Files\Node\LazyRoot->getUserFolder()/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php - line 72: OCA\GroupFolders\Versions\VersionsBackend->getVersionsForFile()/var/www/html/nextcloud/apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php - line 59: OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireFolder()/var/www/html/nextcloud/apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php - line 43: OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireAll()/var/www/html/nextcloud/lib/public/BackgroundJob/Job.php - line 81: OCA\GroupFolders\BackgroundJob\ExpireGroupVersions->run()/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php - line 103: OCP\BackgroundJob\Job->start()/var/www/html/nextcloud/lib/public/BackgroundJob/TimedJob.php - line 93: OCP\BackgroundJob\TimedJob->start()/var/www/html/nextcloud/cron.php - line 152: OCP\BackgroundJob\TimedJob->execute()
`

@solracsf
Copy link
Member

solracsf commented Dec 13, 2023

There is a fix undergoing here : nextcloud/groupfolders#2640

@solracsf
Copy link
Member

Reports are a duplicate of nextcloud/groupfolders#2559 so closing gere.

@solracsf solracsf closed this as not planned Won't fix, can't repro, duplicate, stale Dec 13, 2023
@k00ni
Copy link
Contributor

k00ni commented Dec 13, 2023

I am confused why this is a duplicate of nextcloud/groupfolders#2559, when this one is over 2 years older than the linked issue. This issue also contains more information about the problem and tested configurations. It was closed in the meantime but reopened. It seems there is some confusion around here.

@solracsf
Copy link
Member

No there isn't. Problem is that people see "Backends provided no user object" in the error log and thinks "this is the same issue" while it is not the same issue. All recents reports (this year reports) on this issue are related to GroupFolders app, not Server.

So, it is a duplicate since the issue must be tracked on GroupFolders repo, not here.

@dgsiegel
Copy link

So, it is a duplicate since the issue must be tracked on GroupFolders repo, not here.

I don't think this is the case, as we don't have the GroupFolders app installed. It only happens with public shares in our instance, see my comment (#19647 (comment)) above.

@adriangalbincea
Copy link

So, it is a duplicate since the issue must be tracked on GroupFolders repo, not here.

I don't think this is the case, as we don't have the GroupFolders app installed. It only happens with public shares in our instance, see my comment (#19647 (comment)) above.

I agree. I don't have that app either and I get the same error.

@solracsf
Copy link
Member

solracsf commented Dec 13, 2023

Where are your logs backtrace?

Because "Me too I have the same problem/error/wathever..." means nothing unfortunately...

@dgsiegel
Copy link

Where are your logs backtrace?

There are plenty of log backtraces already in this issue, but here you go:

[files] Error: OC\User\NoUserException: Backends provided no user object at <<closure>>

 0. <<closure>>
    OC\Files\Node\Root->getUserFolder()
 1. /var/www/<redacted>/lib/private/Files/Node/LazyFolder.php line 74
    call_user_func_array()
 2. /var/www/<redacted>/lib/private/Files/Node/LazyRoot.php line 40
    OC\Files\Node\LazyFolder->__call()
 3. /var/www/<redacted>/apps/files_versions/lib/Listener/FileEventsListener.php line 359
    OC\Files\Node\LazyRoot->getUserFolder()
 4. /var/www/<redacted>/apps/files_versions/lib/Listener/FileEventsListener.php line 295
    OCA\Files_Versions\Listener\FileEventsListener->getPathForNode()
 5. /var/www/<redacted>/apps/files_versions/lib/Listener/FileEventsListener.php line 116
    OCA\Files_Versions\Listener\FileEventsListener->pre_remove_hook()
 6. /var/www/<redacted>/lib/private/EventDispatcher/ServiceEventListener.php line 86
    OCA\Files_Versions\Listener\FileEventsListener->handle()
 7. /var/www/<redacted>/3rdparty/symfony/event-dispatcher/EventDispatcher.php line 251
    OC\EventDispatcher\ServiceEventListener->__invoke()
 8. /var/www/<redacted>/3rdparty/symfony/event-dispatcher/EventDispatcher.php line 73
    Symfony\Component\EventDispatcher\EventDispatcher->callListeners()
 9. /var/www/<redacted>/lib/private/EventDispatcher/EventDispatcher.php line 94
    Symfony\Component\EventDispatcher\EventDispatcher->dispatch()
10. /var/www/<redacted>/lib/private/EventDispatcher/EventDispatcher.php line 106
    OC\EventDispatcher\EventDispatcher->dispatch()
11. /var/www/<redacted>/lib/private/Files/Node/HookConnector.php line 149
    OC\EventDispatcher\EventDispatcher->dispatchTyped()
12. /var/www/<redacted>/lib/private/legacy/OC_Hook.php line 105
    OC\Files\Node\HookConnector->delete()
13. /var/www/<redacted>/lib/private/Files/View.php line 1270
    OC_Hook::emit()
14. /var/www/<redacted>/lib/private/Files/View.php line 1144
    OC\Files\View->runHooks()
15. /var/www/<redacted>/lib/private/Files/View.php line 702
    OC\Files\View->basicOperation()
16. /var/www/<redacted>/apps/dav/lib/Connector/Sabre/File.php line 536
    OC\Files\View->unlink()
17. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Tree.php line 179
    OCA\DAV\Connector\Sabre\File->delete()
18. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/CorePlugin.php line 281
    Sabre\DAV\Tree->delete()
19. /var/www/<redacted>/3rdparty/sabre/event/lib/WildcardEmitterTrait.php line 89
    Sabre\DAV\CorePlugin->httpDelete()
20. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Server.php line 472
    Sabre\DAV\Server->emit()
21. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Server.php line 253
    Sabre\DAV\Server->invokeMethod()
22. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Server.php line 321
    Sabre\DAV\Server->start()
23. /var/www/<redacted>/apps/dav/appinfo/v1/publicwebdav.php line 123
    Sabre\DAV\Server->exec()
24. /var/www/<redacted>/public.php line 81
    require_once("/var/www/<redacted>. ... p")

DELETE /public.php/webdav/<redacted>.pdf
from <redacted> at 2023-12-13T23:10:38+00:00
[files] Error: OC\User\NoUserException: Backends provided no user object at <<closure>>

 0. <<closure>>
    OC\Files\Node\Root->getUserFolder()
 1. /var/www/<redacted>/lib/private/Files/Node/LazyFolder.php line 74
    call_user_func_array()
 2. /var/www/<redacted>/lib/private/Files/Node/LazyRoot.php line 40
    OC\Files\Node\LazyFolder->__call()
 3. /var/www/<redacted>/apps/files_versions/lib/Listener/FileEventsListener.php line 359
    OC\Files\Node\LazyRoot->getUserFolder()
 4. /var/www/<redacted>/apps/files_versions/lib/Listener/FileEventsListener.php line 281
    OCA\Files_Versions\Listener\FileEventsListener->getPathForNode()
 5. /var/www/<redacted>/apps/files_versions/lib/Listener/FileEventsListener.php line 120
    OCA\Files_Versions\Listener\FileEventsListener->remove_hook()
 6. /var/www/<redacted>/lib/private/EventDispatcher/ServiceEventListener.php line 86
    OCA\Files_Versions\Listener\FileEventsListener->handle()
 7. /var/www/<redacted>/3rdparty/symfony/event-dispatcher/EventDispatcher.php line 251
    OC\EventDispatcher\ServiceEventListener->__invoke()
 8. /var/www/<redacted>/3rdparty/symfony/event-dispatcher/EventDispatcher.php line 73
    Symfony\Component\EventDispatcher\EventDispatcher->callListeners()
 9. /var/www/<redacted>/lib/private/EventDispatcher/EventDispatcher.php line 94
    Symfony\Component\EventDispatcher\EventDispatcher->dispatch()
10. /var/www/<redacted>/lib/private/EventDispatcher/EventDispatcher.php line 106
    OC\EventDispatcher\EventDispatcher->dispatch()
11. /var/www/<redacted>/lib/private/Files/Node/HookConnector.php line 159
    OC\EventDispatcher\EventDispatcher->dispatchTyped()
12. /var/www/<redacted>/lib/private/legacy/OC_Hook.php line 105
    OC\Files\Node\HookConnector->postDelete()
13. /var/www/<redacted>/lib/private/Files/View.php line 1270
    OC_Hook::emit()
14. /var/www/<redacted>/lib/private/Files/View.php line 1202
    OC\Files\View->runHooks()
15. /var/www/<redacted>/lib/private/Files/View.php line 702
    OC\Files\View->basicOperation()
16. /var/www/<redacted>/apps/dav/lib/Connector/Sabre/File.php line 536
    OC\Files\View->unlink()
17. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Tree.php line 179
    OCA\DAV\Connector\Sabre\File->delete()
18. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/CorePlugin.php line 281
    Sabre\DAV\Tree->delete()
19. /var/www/<redacted>/3rdparty/sabre/event/lib/WildcardEmitterTrait.php line 89
    Sabre\DAV\CorePlugin->httpDelete()
20. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Server.php line 472
    Sabre\DAV\Server->emit()
21. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Server.php line 253
    Sabre\DAV\Server->invokeMethod()
22. /var/www/<redacted>/3rdparty/sabre/dav/lib/DAV/Server.php line 321
    Sabre\DAV\Server->start()
23. /var/www/<redacted>/apps/dav/appinfo/v1/publicwebdav.php line 123
    Sabre\DAV\Server->exec()
24. /var/www/<redacted>/public.php line 81
    require_once("/var/www/<redacted>. ... p")

DELETE /public.php/webdav/<redacted>.pdf
from <redacted> at 2023-12-13T23:10:38+00:00

I get this error accessing a public share with read&write permissions enabled. I'm accessing that folder via curl and rclone and using the share's id as well as a password to upload and edit files in that folder.

@solracsf
Copy link
Member

solracsf commented Dec 14, 2023

Good.

#41786 has been shipped with v27.1.5 (or v28), released today, it can help in this case.

Can you test and report back?
If this does not help, please provide a JSON backtrace.

@dgsiegel
Copy link

#41786 has been shipped with v27.1.5 (or v28), released today, it can help in this case.

Can you test and report back? If this does not help, please provide a JSON backtrace.

Can't find the error anymore in our logs. Thanks!

@Marcus1Pierce
Copy link

Marcus1Pierce commented Dec 17, 2023

After update to Nextcloud v27.1.5 i still have this error in my logs

[core] Error: OC\User\NoUserException: Backends provided no user object at <<closure>>

 0. <<closure>>
    OC\Files\Node\Root->getUserFolder("")
 1. /var/www/html/lib/private/Files/Node/LazyFolder.php line 74
    call_user_func_array([["OC\\Files\\No ... "], [""])
 2. /var/www/html/lib/private/Files/Node/LazyRoot.php line 40
    OC\Files\Node\LazyFolder->__call("getUserFolder", [""])
 3. /var/www/html/custom_apps/groupfolders/lib/Versions/VersionsBackend.php line 73
    OC\Files\Node\LazyRoot->getUserFolder("")
 4. /var/www/html/custom_apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 72
    OCA\GroupFolders\Versions\VersionsBackend->getVersionsForFile(["OC\\User\\User"], ["OC\\Files\\FileInfo"])
 5. /var/www/html/custom_apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 59
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireFolder([52,"Pusat/Accou ... "])
 6. /var/www/html/custom_apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php line 43
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireAll()
 7. /var/www/html/lib/public/BackgroundJob/Job.php line 81
    OCA\GroupFolders\BackgroundJob\ExpireGroupVersions->run(null)
 8. /var/www/html/lib/public/BackgroundJob/TimedJob.php line 103
    OCP\BackgroundJob\Job->start(["OC\\BackgroundJob\\JobList"])
 9. /var/www/html/lib/public/BackgroundJob/TimedJob.php line 93
    OCP\BackgroundJob\TimedJob->start(["OC\\BackgroundJob\\JobList"])
10. /var/www/html/cron.php line 152
    OCP\BackgroundJob\TimedJob->execute(["OC\\BackgroundJob\\JobList"], ["OC\\Log"])

at 2023-12-17T00:30:01+00:00
[files] Error: OC\User\NoUserException: Backends provided no user object at <<closure>>

 0. <<closure>>
    OC\Files\Node\Root->getUserFolder("")
 1. /var/www/html/lib/private/Files/Node/LazyFolder.php line 74
    call_user_func_array([["OC\\Files\\No ... "], [""])
 2. /var/www/html/lib/private/Files/Node/LazyRoot.php line 40
    OC\Files\Node\LazyFolder->__call("getUserFolder", [""])
 3. /var/www/html/custom_apps/groupfolders/lib/Versions/VersionsBackend.php line 73
    OC\Files\Node\LazyRoot->getUserFolder("")
 4. /var/www/html/custom_apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 72
    OCA\GroupFolders\Versions\VersionsBackend->getVersionsForFile(["OC\\User\\User"], ["OC\\Files\\FileInfo"])
 5. /var/www/html/custom_apps/groupfolders/lib/Versions/GroupVersionsExpireManager.php line 59
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireFolder([52,"Pusat/Accou ... "])
 6. /var/www/html/custom_apps/groupfolders/lib/BackgroundJob/ExpireGroupVersions.php line 43
    OCA\GroupFolders\Versions\GroupVersionsExpireManager->expireAll()
 7. /var/www/html/lib/public/BackgroundJob/Job.php line 81
    OCA\GroupFolders\BackgroundJob\ExpireGroupVersions->run(null)
 8. /var/www/html/lib/public/BackgroundJob/TimedJob.php line 103
    OCP\BackgroundJob\Job->start(["OC\\BackgroundJob\\JobList"])
 9. /var/www/html/lib/public/BackgroundJob/TimedJob.php line 93
    OCP\BackgroundJob\TimedJob->start(["OC\\BackgroundJob\\JobList"])
10. /var/www/html/cron.php line 152
    OCP\BackgroundJob\TimedJob->execute(["OC\\BackgroundJob\\JobList"], ["OC\\Log"])

at 2023-12-17T00:30:01+00:00

Using Nextcloud 27-fpm Docker with latest pull
All Nextcloud Apps up to date

@solracsf
Copy link
Member

solracsf commented Dec 17, 2023

@Marcus1Pierce your error is a duplicate of nextcloud/groupfolders#2559

Keep it simple:

  1. if the line /groupfolders/lib/Versions/VersionsBackend.php is present in the backtrace, it is a duplicate of Backends provided no user object / Duplicate entry for key 'gf_versions_uniq_index' groupfolders#2559 in this case please also make sure you're using Group Folders app version v16.0.1. If these 2 conditions are met (line is present and app is v16.0.1) report on groupfolders repo.
  2. if the line is not in the logs, and you are using 28 or 27.1.5, report a new issue here. If line is not present and you're using v26 or v27.1.4 or less, upgrade to v27.1.5.

@Marcus1Pierce
Copy link

@Marcus1Pierce your error is a duplicate of nextcloud/groupfolders#2559

@solracsf Sorry i though it the same think. I didn't read your comment before.

  1. if the line /groupfolders/lib/Versions/VersionsBackend.php is present in the backtrace, it is a duplicate of Logs filled with cron errors "Backends provided no user object" groupfolders#2559 in this case please also make sure you're using Group Folders app version v16.0.1. If these 2 conditions are met (line is present and app is v16.0.1) report on groupfolders repo.
  2. if the line is not in the logs, and you are using 28 or 27.1.5, report a new issue here. If line is not present and you're using v26 or v27.1.4 or less, upgrade to v27.1.5.

If i check groupfolders v16.0.1 is available in Nextcloud v28. I think i can't upgarde to Nextcloud 28 for now. And for Nextcloud v27.1.5, latest version of groupfolders is 15.3.1.

@thompol
Copy link

thompol commented Sep 15, 2024

if the line is not in the logs, and you are using 28 or 27.1.5, report a new issue here. If line is not present and you're using v26 or v27.1.4 or less, upgrade to v27.1.5.

I'm seeing this issue on Nextcloud Hub 8 - version 29.0.2. The error is shown for a user that is deleted.

Backtrace:

{"reqId":"VDrCRUWF8Ocic19ty6gl","level":3,"time":"2024-09-15T09:37:00+00:00","remoteAddr":"","user":"--","app":"files","method":"","url":"--","message":"Backends provided no user object for auth.examle.com-663","userAgent":"--","version":"29.0.2.2","exception":{"Exception":"OC\\User\\NoUserException","Message":"Backends provided no user object","Code":0,"Trace":[{"function":"getUserFolder","class":"OC\\Files\\Node\\Root","type":"->","args":["auth.examle.com-663"]},{"file":"/var/www/html/lib/private/Files/Node/LazyFolder.php","line":84,"function":"call_user_func_array","args":[[["OC\\Files\\Node\\Root"],"getUserFolder"],["auth.examle.com-663"]]},{"file":"/var/www/html/lib/private/Files/Node/LazyRoot.php","line":53,"function":"__call","class":"OC\\Files\\Node\\LazyFolder","type":"->","args":["getUserFolder",["auth.examle.com-663"]]},{"file":"/var/www/html/custom_apps/files_fulltextsearch/lib/Service/FilesService.php","line":558,"function":"getUserFolder","class":"OC\\Files\\Node\\LazyRoot","type":"->","args":["auth.examle.com-663"]},{"file":"/var/www/html/custom_apps/files_fulltextsearch/lib/Service/FilesService.php","line":577,"function":"getFileFromId","class":"OCA\\Files_FullTextSearch\\Service\\FilesService","type":"->","args":["auth.examle.com-663",577]},{"file":"/var/www/html/custom_apps/files_fulltextsearch/lib/Service/FilesService.php","line":1288,"function":"getFileFromIndex","class":"OCA\\Files_FullTextSearch\\Service\\FilesService","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/custom_apps/files_fulltextsearch/lib/Service/FilesService.php","line":707,"function":"updateDirectoryContentIndex","class":"OCA\\Files_FullTextSearch\\Service\\FilesService","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/custom_apps/files_fulltextsearch/lib/Provider/FilesProvider.php","line":314,"function":"updateDocument","class":"OCA\\Files_FullTextSearch\\Service\\FilesService","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/custom_apps/fulltextsearch/lib/Service/IndexService.php","line":409,"function":"updateDocument","class":"OCA\\Files_FullTextSearch\\Provider\\FilesProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/custom_apps/fulltextsearch/lib/Cron/Index.php","line":109,"function":"updateDocument","class":"OCA\\FullTextSearch\\Service\\IndexService","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/custom_apps/fulltextsearch/lib/Cron/Index.php","line":77,"function":"liveCycle","class":"OCA\\FullTextSearch\\Cron\\Index","type":"->","args":[]},{"file":"/var/www/html/lib/public/BackgroundJob/Job.php","line":80,"function":"run","class":"OCA\\FullTextSearch\\Cron\\Index","type":"->","args":[null]},{"file":"/var/www/html/lib/public/BackgroundJob/TimedJob.php","line":102,"function":"start","class":"OCP\\BackgroundJob\\Job","type":"->","args":[["OC\\BackgroundJob\\JobList"]]},{"file":"/var/www/html/lib/public/BackgroundJob/TimedJob.php","line":92,"function":"start","class":"OCP\\BackgroundJob\\TimedJob","type":"->","args":[["OC\\BackgroundJob\\JobList"]]},{"file":"/var/www/html/cron.php","line":176,"function":"execute","class":"OCP\\BackgroundJob\\TimedJob","type":"->","args":[["OC\\BackgroundJob\\JobList"]]}],"File":"/var/www/html/lib/private/Files/Node/Root.php","Line":370,"message":"Backends provided no user object for auth.examle.com-663","exception":[],"CustomMessage":"Backends provided no user object for auth.examle.com-663"},"id":"66e6aabe0a7d7"}

@thompol
Copy link

thompol commented Sep 15, 2024

Seems to be fixed after upgrading my AIO containers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 27-feedback bug
Projects
None yet