Activating the Activity app prevents deleting/moving of files in groupfolders
Steps to reproduce
- Create a file in a groupfolder
- Try to delete it -> produces an error
- deactivate activity app
- try again to delete the file -> works
Expected behaviour
I'd expect the file to be deletable when the activity app is active.
Actual behaviour
The file can't be moved or deleted.
Server configuration
Operating system: Linux / Ubuntu 22.04.3
Web server: nginx/1.24.0
Database: MariaDB 10.11.6
PHP version: 8.2.15
Nextcloud version: (see Nextcloud admin page) 28.0.3
Where did you install Nextcloud from: Tarball
Signing status:
No errors have been found.
List of activated apps:
Enabled:
- admin_audit: 1.18.0
- bruteforcesettings: 2.8.0
- calendar: 4.6.5
- calendar_resource_management: 0.6.0
- camerarawpreviews: 0.8.4
- circles: 28.0.0-dev
- cloud_federation_api: 1.11.0
- collectives: 2.9.2
- contacts: 5.5.2
- contactsinteraction: 1.9.0
- dav: 1.29.1
- deck: 1.12.2
- event_update_notification: 2.3.0
- federatedfilesharing: 1.18.0
- files: 2.0.0
- files_pdfviewer: 2.9.0
- files_reminders: 1.1.0
- files_sharing: 1.20.0
- files_trashbin: 1.18.0
- files_versions: 1.21.0
- forms: 4.1.1
- groupfolders: 16.0.4
- impersonate: 1.15.0
- logreader: 2.13.0
- lookup_server_connector: 1.16.0
- mail: 3.5.7
- notes: 4.9.2
- notifications: 2.16.0
- oauth2: 1.16.3
- password_policy: 1.18.0
- polls: 6.1.6
- privacy: 1.12.0
- provisioning_api: 1.18.0
- richdocuments: 8.3.1
- serverinfo: 1.18.0
- settings: 1.10.1
- sharebymail: 1.18.0
- spreed: 18.0.3
- support: 1.11.0
- survey_client: 1.16.0
- suspicious_login: 6.0.0
- systemtags: 1.18.0
- tasks: 0.15.0
- text: 3.9.1
- theming: 2.3.0
- timetracker: 0.0.82
- twofactor_backupcodes: 1.17.0
- updatenotification: 1.18.0
- user_status: 1.8.1
- viewer: 2.2.0
- workflowengine: 2.10.0
Nextcloud configuration:
{
"system": {
"instanceid": "***REMOVED SENSITIVE VALUE***",
"passwordsalt": "***REMOVED SENSITIVE VALUE***",
"secret": "***REMOVED SENSITIVE VALUE***",
"trusted_domains": [
"subdomain.domain.org"
],
"datadirectory": "***REMOVED SENSITIVE VALUE***",
"dbtype": "mysql",
"version": "28.0.3.2",
"overwrite.cli.url": "https:\/\/subdomain.domain.org\/",
"dbname": "***REMOVED SENSITIVE VALUE***",
"dbhost": "***REMOVED SENSITIVE VALUE***",
"dbtableprefix": "oc_",
"mysql.utf8mb4": true,
"dbuser": "***REMOVED SENSITIVE VALUE***",
"dbpassword": "***REMOVED SENSITIVE VALUE***",
"installed": true,
"htaccess.RewriteBase": "\/",
"memcache.local": "\\OC\\Memcache\\APCu",
"memcache.distributed": "\\OC\\Memcache\\Redis",
"redis": {
"host": "***REMOVED SENSITIVE VALUE***",
"port": 0
},
"filelocking.enabled": true,
"memcache.locking": "\\OC\\Memcache\\Redis",
"mail_smtpmode": "smtp",
"mail_smtpsecure": "ssl",
"mail_sendmailmode": "smtp",
"mail_from_address": "***REMOVED SENSITIVE VALUE***",
"mail_domain": "***REMOVED SENSITIVE VALUE***",
"mail_smtpauthtype": "LOGIN",
"mail_smtpauth": 1,
"mail_smtphost": "***REMOVED SENSITIVE VALUE***",
"mail_smtpport": "465",
"mail_smtpname": "***REMOVED SENSITIVE VALUE***",
"mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
"mail_smtptimeout": 30,
"maintenance": false,
"maintenance_window_start": 21,
"theme": "",
"loglevel": 2,
"updater.release.channel": "stable",
"activity_use_cached_mountpoints": "true",
"activity_expire_days": 62,
"default_phone_region": "DE",
"app_install_overwrite": [
"bbb",
"bruteforcesettings",
"polls",
"camerarawpreviews",
"suspicious_login",
"apporder",
"impersonate",
"event_update_notification",
"approval",
"timetracker",
"issuetemplate"
],
"trashbin_retention_obligation": "auto, 121",
"minimum.supported.desktop.version": "3.3.6",
"preview_max_memory": 512,
"bulkupload.enabled": true,
"defaultapp": ""
}
}
Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/... no
Client configuration
Browser: Firefox 121.0.1 (64-Bit)
Operating system: MacOS 13.6.3
Logs
Nextcloud log (data/nextcloud.log)
{
"reqId": "WuGDv1KYFxCh5rXIXwhv",
"level": 3,
"time": "2024-03-01T11:42:24+00:00",
"remoteAddr": "95.90.97.25",
"user": "cloudadmin",
"app": "webdav",
"method": "DELETE",
"url": "/remote.php/dav/files/cloudadmin/01_International%20Programmes/01_Countries/Global%20Project/Neue%20Textdatei.md",
"message": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/cloud/nextcloud/lib/private/Files/Node/Node.php on line 344",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:121.0) Gecko/20100101 Firefox/121.0",
"version": "28.0.3.2",
"exception": {
"Exception": "TypeError",
"Message": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/cloud/nextcloud/lib/private/Files/Node/Node.php on line 344",
"Code": 0,
"Trace": [
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/Node/Node.php",
"line": 344,
"function": "normalizePath",
"class": "OC\\Files\\Utils\\PathHelper",
"type": "::"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/Node/Folder.php",
"line": 70,
"function": "normalizePath",
"class": "OC\\Files\\Node\\Node",
"type": "->"
},
{
"function": "getFullPath",
"class": "OC\\Files\\Node\\Folder",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/Node/LazyFolder.php",
"line": 84,
"function": "call_user_func_array"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/Node/LazyFolder.php",
"line": 428,
"function": "__call",
"class": "OC\\Files\\Node\\LazyFolder",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/Node/LazyFolder.php",
"line": 161,
"function": "getFullPath",
"class": "OC\\Files\\Node\\LazyFolder",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/activity/lib/FilesHooks.php",
"line": 1333,
"function": "get",
"class": "OC\\Files\\Node\\LazyFolder",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/activity/lib/FilesHooks.php",
"line": 1203,
"function": "getUnrelatedUsers",
"class": "OCA\\Activity\\FilesHooks",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/activity/lib/FilesHooks.php",
"line": 176,
"function": "getAffectedUsersFromCachedMounts",
"class": "OCA\\Activity\\FilesHooks",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/activity/lib/FilesHooks.php",
"line": 117,
"function": "addNotificationsForFileAction",
"class": "OCA\\Activity\\FilesHooks",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/activity/lib/FilesHooksStatic.php",
"line": 59,
"function": "fileDelete",
"class": "OCA\\Activity\\FilesHooks",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/legacy/OC_Hook.php",
"line": 105,
"function": "fileDelete",
"class": "OCA\\Activity\\FilesHooksStatic",
"type": "::"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/View.php",
"line": 1270,
"function": "emit",
"class": "OC_Hook",
"type": "::"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/View.php",
"line": 1144,
"function": "runHooks",
"class": "OC\\Files\\View",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/lib/private/Files/View.php",
"line": 702,
"function": "basicOperation",
"class": "OC\\Files\\View",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/dav/lib/Connector/Sabre/File.php",
"line": 543,
"function": "unlink",
"class": "OC\\Files\\View",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/3rdparty/sabre/dav/lib/DAV/Tree.php",
"line": 197,
"function": "delete",
"class": "OCA\\DAV\\Connector\\Sabre\\File",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php",
"line": 281,
"function": "delete",
"class": "Sabre\\DAV\\Tree",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/3rdparty/sabre/event/lib/WildcardEmitterTrait.php",
"line": 89,
"function": "httpDelete",
"class": "Sabre\\DAV\\CorePlugin",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 472,
"function": "emit",
"class": "Sabre\\DAV\\Server",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 253,
"function": "invokeMethod",
"class": "Sabre\\DAV\\Server",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 321,
"function": "start",
"class": "Sabre\\DAV\\Server",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/dav/lib/Server.php",
"line": 373,
"function": "exec",
"class": "Sabre\\DAV\\Server",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/apps/dav/appinfo/v2/remote.php",
"line": 35,
"function": "exec",
"class": "OCA\\DAV\\Server",
"type": "->"
},
{
"file": "/var/www/cloud/nextcloud/remote.php",
"line": 172,
"args": [
"/var/www/cloud/nextcloud/apps/dav/appinfo/v2/remote.php"
],
"function": "require_once"
}
],
"File": "/var/www/cloud/nextcloud/lib/private/Files/Utils/PathHelper.php",
"Line": 52,
"message": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/cloud/nextcloud/lib/private/Files/Node/Node.php on line 344",
"exception": {},
"CustomMessage": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/cloud/nextcloud/lib/private/Files/Node/Node.php on line 344"
}
}
Browser log
Request:
{
"DELETE": {
"scheme": "https",
"host": "subdomain.domain.org",
"filename": "/remote.php/dav/files/cloudadmin/01_International%20Programmes/01_Countries/Global%20Project/Neue%20Textdatei.md",
"remote": {
"Adresse": "144.76.91.54:443"
}
}
}
Response:
<?xml version="1.0" encoding="utf-8"?>
<d:error xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns">
<s:exception>TypeError</s:exception>
<s:message>OC\Files\Utils\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/cloud/nextcloud/lib/private/Files/Node/Node.php on line 344</s:message>
</d:error>
Console:
[ERROR] files: Error while deleting a file
Object { app: "files", uid: "cloudadmin", level: 2, error: {…}, source: "https://subdomain.domain.org/remote.php/dav/files/cloudadmin/01_International Programmes/01_Countries/Global Project/Neue Textdatei.md", node: {…} }
ConsoleLogger.js:74:18
value ConsoleLogger.js:74
value ConsoleLogger.js:100
exec deleteAction.ts:119
onActionClick FileEntryActions.vue:171
click FileEntryActions.vue:4
VueJS 4
onClick actionText-bMy_49i8.mjs:118
handleClick NcActionButton.mjs:113
VueJS 33
The behavior seems to be somewhat dependant on the folder containing the file. In the example here, further up the directory structure it's working.
As I am working in the same cloud, I can confirm the issue. Anyone can reproduce the issue? It is sadly limiting our ability to use Activities quite substantially.
Hello, I have a related issue, with almost the same stack trace, but it's on a PUT request and not a DELETE. It looks like the file is still uploaded, but there is plenty of ugly errors shown in the front-end. Maybe my logs can help to identify something?
The logs
{
"reqId": "cZ14Faxe8m6vU2TtWMx8",
"level": 3,
"time": "2024-06-28T14:45:37+02:00",
"remoteAddr": "x.x.x.x",
"user": "user4",
"app": "webdav",
"method": "PUT",
"url": "/remote.php/dav/files/user4/A%20GROUPFOLDER/1-%20Subfolder/a-%20subfolder2/file.xlsx",
"message": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/Node.php on line 344",
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0",
"version": "28.0.7.4",
"exception": {
"Exception": "TypeError",
"Message": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/Node.php on line 344",
"Code": 0,
"Trace": [
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/Node.php",
"line": 344,
"function": "normalizePath",
"class": "OC\\Files\\Utils\\PathHelper",
"type": "::",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/Folder.php",
"line": 70,
"function": "normalizePath",
"class": "OC\\Files\\Node\\Node",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"function": "getFullPath",
"class": "OC\\Files\\Node\\Folder",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/LazyFolder.php",
"line": 84,
"function": "call_user_func_array",
"args": [
[
[
"OC\\Files\\Node\\Root"
],
"getFullPath"
],
[
"*** sensitive parameters replaced ***"
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/LazyFolder.php",
"line": 428,
"function": "__call",
"class": "OC\\Files\\Node\\LazyFolder",
"type": "->",
"args": [
"getFullPath",
[
"*** sensitive parameters replaced ***"
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/LazyFolder.php",
"line": 161,
"function": "getFullPath",
"class": "OC\\Files\\Node\\LazyFolder",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/activity/lib/FilesHooks.php",
"line": 1333,
"function": "get",
"class": "OC\\Files\\Node\\LazyFolder",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/activity/lib/FilesHooks.php",
"line": 1203,
"function": "getUnrelatedUsers",
"class": "OCA\\Activity\\FilesHooks",
"type": "->",
"args": [
1098,
[
[
"user2",
"OCA\\GroupFolders\\Mount\\MountProvider",
"/user2/files/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
2
],
[
"user3",
"OCA\\GroupFolders\\Mount\\MountProvider",
"/user3/files/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
2
],
[
"user4",
"OCA\\GroupFolders\\Mount\\MountProvider",
"/user4/files/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
2
],
[
"user5",
"OCA\\GroupFolders\\Mount\\MountProvider",
"/user5/files/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
2
]
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/activity/lib/FilesHooks.php",
"line": 176,
"function": "getAffectedUsersFromCachedMounts",
"class": "OCA\\Activity\\FilesHooks",
"type": "->",
"args": [
1098
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/activity/lib/FilesHooks.php",
"line": 96,
"function": "addNotificationsForFileAction",
"class": "OCA\\Activity\\FilesHooks",
"type": "->",
"args": [
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx",
"file_created",
"created_self",
"created_by"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/activity/lib/FilesHooksStatic.php",
"line": 43,
"function": "fileCreate",
"class": "OCA\\Activity\\FilesHooks",
"type": "->",
"args": [
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/lib/private/legacy/OC_Hook.php",
"line": 105,
"function": "fileCreate",
"class": "OCA\\Activity\\FilesHooksStatic",
"type": "::",
"args": [
[
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx"
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/dav/lib/Connector/Sabre/File.php",
"line": 471,
"function": "emit",
"class": "OC_Hook",
"type": "::",
"args": [
"OC_Filesystem",
"post_create",
[
"/A GROUPFOLDER/1- Subfolder/a- subfolder2/file.xlsx"
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/dav/lib/Connector/Sabre/File.php",
"line": 404,
"function": "emitPostHooks",
"class": "OCA\\DAV\\Connector\\Sabre\\File",
"type": "->",
"args": [
false
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/dav/lib/Connector/Sabre/Directory.php",
"line": 148,
"function": "put",
"class": "OCA\\DAV\\Connector\\Sabre\\File",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 1098,
"function": "createFile",
"class": "OCA\\DAV\\Connector\\Sabre\\Directory",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/3rdparty/sabre/dav/lib/DAV/CorePlugin.php",
"line": 504,
"function": "createFile",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
"*** sensitive parameters replaced ***"
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/3rdparty/sabre/event/lib/WildcardEmitterTrait.php",
"line": 89,
"function": "httpPut",
"class": "Sabre\\DAV\\CorePlugin",
"type": "->",
"args": [
[
"Sabre\\HTTP\\Request"
],
[
"Sabre\\HTTP\\Response"
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 472,
"function": "emit",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
"method:PUT",
[
[
"Sabre\\HTTP\\Request"
],
[
"Sabre\\HTTP\\Response"
]
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 253,
"function": "invokeMethod",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
[
"Sabre\\HTTP\\Request"
],
[
"Sabre\\HTTP\\Response"
]
]
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 321,
"function": "start",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/dav/lib/Server.php",
"line": 378,
"function": "exec",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/apps/dav/appinfo/v2/remote.php",
"line": 35,
"function": "exec",
"class": "OCA\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/nextcloud/nextcloud.example.com/remote.php",
"line": 172,
"args": [
"/var/www/html/nextcloud/nextcloud.example.com/apps/dav/appinfo/v2/remote.php"
],
"function": "require_once"
}
],
"File": "/var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Utils/PathHelper.php",
"Line": 52,
"message": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/Node.php on line 344",
"exception": {},
"CustomMessage": "OC\\Files\\Utils\\PathHelper::normalizePath(): Argument #1 ($path) must be of type string, null given, called in /var/www/html/nextcloud/nextcloud.example.com/lib/private/Files/Node/Node.php on line 344"
}
}
Regards,