owncloud / client

🖥️ Desktop Syncing Client for ownCloud
GNU General Public License v2.0
1.4k stars 667 forks source link

[QA] No popup keep or delete date after all data are deleted on server #9360

Closed gabi18 closed 2 years ago

gabi18 commented 2 years ago

Seen with testpilotcloud 2.10.0-rc4 connected to demo.owncloud.org (10.9.0) on Win10 20H2 VFS ON

Steps to reproduce:

Result: data are downloaded from server and the newly created file is deleted locally without user confirmation

Sync protocol 2-10-0rc4_sync_activity

gabi18 commented 2 years ago

20220113_0834_owncloud.log.2.gz 20220113_0835_owncloud.log.0.gz

...
2022 08:03:15 GMT, Referrer-Policy: strict-origin-when-cross-origin, Strict-Transport-Security: max-age=315360000; preload, X-Content-Type-Options: nosniff, X-Frame-Options: SAMEORIGIN, X-Xss-Protection: 0, } Data: [<!DOCTYPE html>\n<html lang=\"en\">\n  <head>\n    <meta charset=\"utf-8\">\n    <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1, shrink-to-fit=no\">\n    <meta name=\"robots\" content=\"noindex, nofollow\">\n\n    <title>No worries! Setup in progress.</title>\n\n    <style>\n      html,\n      body {\n        height: 100%;\n        min-height: 100%;\n        margin: 0;\n        padding: 0;\n      }\n\n      body {\n        cursor: default;\n        font-family: -apple-system, system-ui, BlinkMacSystemFont, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif;\n        font-size: 0.875rem;\n        font-weight: normal;\n        line-height: 1.5;\n        color: #383e4b;\n        background-color: #f5f5f5;\n      }\n\n      h1 {\n        font-size: 4.5rem;\n        font-weight: 300;\n        line-height: 1.1;\n        float: left;\n        margin: 0 1.5rem;\n      }\n\n      h4 {\n        font-size: 1.5rem;\n        padding: 0.7rem 0 0 0;\n        margin: 0;\n      }\n\n      p {\n        font-weight: 500;\n        line-height: 1.1;\n        color: #9da0a8;\n        padding: 0;\n        margin: 0;\n      }\n\n      .wrapper {\n        position: relative;\n        top: 50%;\n        -webkit-transform: translateY(-60%);\n        -ms-transform: translateY(-60%);\n        transform: translateY(-60%);\n      }\n\n      .container {\n        width: 550px;\n        margin: 0 auto;\n      }\n    </style>\n  </head>\n  <body>\n    <div class=\"wrapper\">\n      <div class=\"container\">\n        <h1>\n          404\n        </h1>\n\n        <h4>\n          No worries! Setup in progress.\n        </h4>\n\n        <p>\n          A fresh demo server is being prepared and will be available soon.\n        </p>\n      </div>\n    </div>\n  </body>\n</html>\n]"
01-13 09:03:15:940 [ warning sync.networkjob ]: OCC::AvatarJob("https://demo.owncloud.org/remote.php/dav/avatars/demo/128.png", "76415e39-5f34-4604-a3b4-ef039ac132ad", "76415e39-5f34-4604-a3b4-ef039ac132ad", "Error transferring https://demo.owncloud.org/remote.php/dav/avatars/demo/128.png - server replied: Not Found") QNetworkReply::ContentNotFoundError "Server hat \"404 Not Found\" auf \"GET https://demo.owncloud.org/remote.php/dav/avatars/demo/128.png\" geantwortet" 404
01-13 09:03:15:940 [ info gui.account.state ]:  AccountState connection status change:  OCC::ConnectionValidator::StatusNotFound -> OCC::ConnectionValidator::Connected
01-13 09:03:15:940 [ info gui.account.state ]:  AccountState state change:  "Netzwerkfehler" -> "Verbunden"
01-13 09:03:15:940 [ info sync.accessmanager ]: 2 "" "https://demo.owncloud.org/ocs/v2.php/apps/notifications/api/v1/notifications?format=json" has X-Request-ID "926bb420-d614-4c0d-ad12-afb8faaf5cfb"
01-13 09:03:15:940 [ debug sync.cookiejar ] [ OCC::CookieJar::cookiesForUrl ]:  QUrl("https://demo.owncloud.org/ocs/v2.php/apps/notifications/api/v1/notifications?format=json") requests: (QNetworkCookie("oc_sessionPassphrase=4n3IKO8xzih%2FKbzHln6JF780Dsrxd89Qsq6%2Bv9TyJtwStfgF%2BwaTwECXQ0P1%2FNU%2BRshwafxPuwQBwqs%2BVLESaoCOQg11X9G7x%2BlpVGI3IBDZDqh2FjmvSv8Z4v15wiy7; secure; HttpOnly; domain=demo.owncloud.org; path=/"), QNetworkCookie("ocv89a9wk4wi=u5o1ig6db9m4vopobmmc4uq7p4; secure; HttpOnly; domain=demo.owncloud.org; path=/"), QNetworkCookie("ockh4xno3878=g1otevl5cscvscoj22hjqm3agf; secure; HttpOnly; domain=demo.owncloud.org; path=/"))
01-13 09:03:15:940 [ info sync.httplogger ]:    "926bb420-d614-4c0d-ad12-afb8faaf5cfb: Request: GET https://demo.owncloud.org/ocs/v2.php/apps/notifications/api/v1/notifications?format=json Header: { OCS-APIREQUEST: true, Authorization: Basic [redacted], User-Agent: Mozilla/5.0 (Windows) mirall/2.10.0rc4 (build 6487) (testpilotcloud, windows-10.0.19042 ClientArchitecture: x86_64 OsArchitecture: x86_64), Accept: */*, X-Request-ID: 926bb420-d614-4c0d-ad12-afb8faaf5cfb, Original-Request-ID: 926bb420-d614-4c0d-ad12-afb8faaf5cfb, Cookie: oc_sessionPassphrase=4n3IKO8xzih%2FKbzHln6JF780Dsrxd89Qsq6%2Bv9TyJtwStfgF%2BwaTwECXQ0P1%2FNU%2BRshwafxPuwQBwqs%2BVLESaoCOQg11X9G7x%2BlpVGI3IBDZDqh2FjmvSv8Z4v15wiy7; ocv89a9wk4wi=u5o1ig6db9m4vopobmmc4uq7p4; ockh4xno3878=g1otevl5cscvscoj22hjqm3agf, } Data: []"
01-13 09:03:15:957 [ info sync.networkjob ]:    Created OCC::JsonApiJob("https://demo.owncloud.org/ocs/v2.php/apps/notifications/api/v1/notifications?format=json", "926bb420-d614-4c0d-ad12-afb8faaf5cfb", "926bb420-d614-4c0d-ad12-afb8faaf5cfb") for OCC::ServerNotificationHandler(0x2136934e770)
01-13 09:03:15:957 [ info gui.socketapi ]:  Sending SocketAPI message --> "REGISTER_PATH:C:\\Users\\gabi\\testpilotcloud" to QLocalSocket(0x21365d81e30)
01-13 09:03:15:972 [ debug sync.database.sql ]  [ OCC::SqlQuery::bindValue ]:   SQL bind 1 3
01-13 09:03:15:972 [ debug sync.database.sql ]  [ OCC::SqlQuery::exec ]:    SQL exec "SELECT path FROM selectivesync WHERE type=?1"
01-13 09:03:15:989 [ info gui.folder.manager ]: Account "demo@demo.owncloud.org" connected, scheduling its folders
01-13 09:03:15:989 [ info gui.folder.manager ]: Schedule folder  "1"  to sync!
01-13 09:03:15:989 [ debug gui.socketapi ]  [ OCC::SocketApi::slotUpdateFolderView ]:   Not sending UPDATE_VIEW for "1" because status() is OCC::SyncResult::NotYetStarted
01-13 09:03:15:989 [ info gui.application ]:    Sync state changed for folder  "https://demo.owncloud.org/remote.php/dav/files/demo/" :  "Not yet Started"
...
TheOneRing commented 2 years ago

the popup only happens under certain conditions, in a normal scenario after the full hour the dir is reset to the template which could be identical to the local state.

Only if you have a certain amount of files that all vanish at the same time the pop up is show.

gabi18 commented 2 years ago

My local state wasn't identical to the template, I have created a new file. The popup isn't shown if only one file is affected and will disappear locally? What I have in mind is that the popup always appears when demo.owncloud.org is reset.

gabi18 commented 2 years ago

I get the popup on Linux with owncloud-client-2.10.0~rc3-6436.x86_64

2 10 0-rc3-linux

gabi18 commented 2 years ago

I have retested: also on Linux with 2.10.0-rc4 the popup doesn't appear sometimes.

@jw also has observed this behavior and we found an explanation: it's related to demo.owncloud.org: the skeleton files are immediately recreated and if the client doesn't poll exactly at time all files are deleted it's just a 'normal' server delete and no popup is needed.

gabi18 commented 2 years ago

Confirmed that the popup appears reliable when deleting all user data on server (remain deleted if not restored automatically).