{"action":"created","issue":{"url":"https://api.github.com/repos/nextcloud/server/issues/9690","repository_url":"https://api.github.com/repos/nextcloud/server","labels_url":"https://api.github.com/repos/nextcloud/server/issues/9690/labels{/name}","comments_url":"https://api.github.com/repos/nextcloud/server/issues/9690/comments","events_url":"https://api.github.com/repos/nextcloud/server/issues/9690/events","html_url":"https://github.com/nextcloud/server/issues/9690","id":327681255,"node_id":"MDU6SXNzdWUzMjc2ODEyNTU=","number":9690,"title":"occ user:delete does not remove storage and files where using Swift as primary store","user":{"login":"vpecinka","id":18662973,"node_id":"MDQ6VXNlcjE4NjYyOTcz","avatar_url":"https://avatars1.githubusercontent.com/u/18662973?v=4","gravatar_id":"","url":"https://api.github.com/users/vpecinka","html_url":"https://github.com/vpecinka","followers_url":"https://api.github.com/users/vpecinka/followers","following_url":"https://api.github.com/users/vpecinka/following{/other_user}","gists_url":"https://api.github.com/users/vpecinka/gists{/gist_id}","starred_url":"https://api.github.com/users/vpecinka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vpecinka/subscriptions","organizations_url":"https://api.github.com/users/vpecinka/orgs","repos_url":"https://api.github.com/users/vpecinka/repos","events_url":"https://api.github.com/users/vpecinka/events{/privacy}","received_events_url":"https://api.github.com/users/vpecinka/received_events","type":"User","site_admin":false},"labels":[{"id":386379231,"node_id":"MDU6TGFiZWwzODYzNzkyMzE=","url":"https://api.github.com/repos/nextcloud/server/labels/bug","name":"bug","color":"ee0701","default":true},{"id":389033016,"node_id":"MDU6TGFiZWwzODkwMzMwMTY=","url":"https://api.github.com/repos/nextcloud/server/labels/feature:%20filesystem","name":"feature: filesystem","color":"c2e0c6","default":false},{"id":451348066,"node_id":"MDU6TGFiZWw0NTEzNDgwNjY=","url":"https://api.github.com/repos/nextcloud/server/labels/feature:%20users%20and%20groups","name":"feature: users and groups","color":"c2e0c6","default":false},{"id":389004952,"node_id":"MDU6TGFiZWwzODkwMDQ5NTI=","url":"https://api.github.com/repos/nextcloud/server/labels/high","name":"high","color":"c5def5","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/nextcloud/server/milestones/48","html_url":"https://github.com/nextcloud/server/milestone/48","labels_url":"https://api.github.com/repos/nextcloud/server/milestones/48/labels","id":3436010,"node_id":"MDk6TWlsZXN0b25lMzQzNjAxMA==","number":48,"title":"Nextcloud 15","description":"","creator":{"login":"skjnldsv","id":14975046,"node_id":"MDQ6VXNlcjE0OTc1MDQ2","avatar_url":"https://avatars0.githubusercontent.com/u/14975046?v=4","gravatar_id":"","url":"https://api.github.com/users/skjnldsv","html_url":"https://github.com/skjnldsv","followers_url":"https://api.github.com/users/skjnldsv/followers","following_url":"https://api.github.com/users/skjnldsv/following{/other_user}","gists_url":"https://api.github.com/users/skjnldsv/gists{/gist_id}","starred_url":"https://api.github.com/users/skjnldsv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/skjnldsv/subscriptions","organizations_url":"https://api.github.com/users/skjnldsv/orgs","repos_url":"https://api.github.com/users/skjnldsv/repos","events_url":"https://api.github.com/users/skjnldsv/events{/privacy}","received_events_url":"https://api.github.com/users/skjnldsv/received_events","type":"User","site_admin":false},"open_issues":171,"closed_issues":79,"state":"open","created_at":"2018-06-19T13:57:28Z","updated_at":"2018-09-27T15:18:02Z","due_on":"2018-12-06T08:00:00Z","closed_at":null},"comments":5,"created_at":"2018-05-30T11:04:35Z","updated_at":"2018-09-27T15:18:11Z","closed_at":null,"author_association":"NONE","body":"### Steps to reproduce\r\n1. Set up Nextcloud using Swift as a primary storage\r\n2. Login as admin and create user (e.g. tester)\r\n3. Login as tester and add some files (for sure, there are the default ones)\r\n4. As www-data user run cmd: php occ user:delete tester\r\n\r\n\r\n### Expected behaviour\r\nThe user and its oc_storage and oc_filecache should be deleted\r\n\r\n### Actual behaviour\r\nThe users is deleted, however the oc_storages and oc_filecache stil remain, together with files in the object storage.\r\n\r\nPre conditions:\r\n```\r\nMySQL [nextcloud_v13]> select * from oc_storages;\r\n+------------+---------------------------------------------------+-----------+--------------+\r\n| numeric_id | id                                                | available | last_checked |\r\n+------------+---------------------------------------------------+-----------+--------------+\r\n|          1 | object::store:nc0                                 |         1 |         NULL |\r\n|          2 | object::user:admin                                |         1 |         NULL |\r\n|          4 | object::user:775DA7E6-9157-48EE-92AD-DE87D45E22F1 |         1 |         NULL |\r\n|          5 | object::user:tester                               |         1 |         NULL |\r\n+------------+---------------------------------------------------+-----------+--------------+\r\n5 rows in set (0.01 sec)\r\n```\r\n\r\nDelete user:\r\n\r\n```\r\nwww-data@9264da61a860:/www/nextcloud$ php occ user:delete tester\r\nThe specified user was deleted\r\n```\r\n\r\nAfter delete:\r\n```\r\nMySQL [nextcloud_v13]> select * from oc_storages;\r\n+------------+---------------------------------------------------+-----------+--------------+\r\n| numeric_id | id                                                | available | last_checked |\r\n+------------+---------------------------------------------------+-----------+--------------+\r\n|          1 | object::store:nc0                                 |         1 |         NULL |\r\n|          2 | object::user:admin                                |         1 |         NULL |\r\n|          4 | object::user:775DA7E6-9157-48EE-92AD-DE87D45E22F1 |         1 |         NULL |\r\n|          5 | object::user:tester                               |         1 |         NULL |\r\n+------------+---------------------------------------------------+-----------+--------------+\r\n5 rows in set (0.00 sec)\r\n\r\nMySQL [nextcloud_v13]> select count(*) from oc_filecache where storage=5;\r\n+----------+\r\n| count(*) |\r\n+----------+\r\n|       22 |\r\n+----------+\r\n1 row in set (0.00 sec)\r\n```\r\n\r\n### Server configuration\r\n\r\n**Operating system**: Linux Debian 9.4\r\n**Web server:** Nginx 1.10.3\r\n**Database:** MySQL\r\n**PHP version:** 7.0\r\n**Nextcloud version:** (see Nextcloud admin page) 13.0.1.1\r\n**Updated from an older Nextcloud/ownCloud or fresh install:** either\r\n**Where did you install Nextcloud from:** tarfile from nextcloud.com\r\n**Are you using external storage, if yes which one:** Swift as primary\r\n**Are you using encryption:** no\r\n**Are you using an external user-backend, if yes which one:** LDAP but same problem with local user\r\n\r\n#### Nextcloud log (data/nextcloud.log)\r\n<details>\r\n<summary>Nextcloud log</summary>\r\n\r\n```\r\n{\"reqId\":\"6RvewTtNcUFNNlCSEPaR\",\"level\":3,\"time\":\"2018-05-28T14:35:45+00:00\",\"remoteAddr\":\"\",\"user\":\"--\",\"app\":\"PHP\",\"method\":\"--\",\"url\":\"--\",\"message\":\"Undefined offset: 1 at \\/www\\/nextcloud\\/apps\\/admin_audit\\/lib\\/Actions\\/Console.php#32\",\"userAgent\":\"--\",\"version\":\"13.0.1.1\"}\r\n```\r\n</details>\r\n"},"comment":{"url":"https://api.github.com/repos/nextcloud/server/issues/comments/425132892","html_url":"https://github.com/nextcloud/server/issues/9690#issuecomment-425132892","issue_url":"https://api.github.com/repos/nextcloud/server/issues/9690","id":425132892,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNTEzMjg5Mg==","user":{"login":"MorrisJobke","id":245432,"node_id":"MDQ6VXNlcjI0NTQzMg==","avatar_url":"https://avatars3.githubusercontent.com/u/245432?v=4","gravatar_id":"","url":"https://api.github.com/users/MorrisJobke","html_url":"https://github.com/MorrisJobke","followers_url":"https://api.github.com/users/MorrisJobke/followers","following_url":"https://api.github.com/users/MorrisJobke/following{/other_user}","gists_url":"https://api.github.com/users/MorrisJobke/gists{/gist_id}","starred_url":"https://api.github.com/users/MorrisJobke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MorrisJobke/subscriptions","organizations_url":"https://api.github.com/users/MorrisJobke/orgs","repos_url":"https://api.github.com/users/MorrisJobke/repos","events_url":"https://api.github.com/users/MorrisJobke/events{/privacy}","received_events_url":"https://api.github.com/users/MorrisJobke/received_events","type":"User","site_admin":false},"created_at":"2018-09-27T15:18:11Z","updated_at":"2018-09-27T15:18:11Z","author_association":"MEMBER","body":"> Looks like files are only actually removed when using local storage(!)\r\n\r\ncc @icewind1991 @rullzer @blizzz "}}
{"actor":{"display_login":"MorrisJobke"}}