android icon indicating copy to clipboard operation
android copied to clipboard

Modification times not preserved when loading files from other apps

Open plumbeo opened this issue 8 years ago • 3 comments

Actual behaviour

When files are loaded into Nextcloud from another app (Gallery, Camera, browsing for specific filetypes, etc.) their modification times aren't preserved and the files are saved in the Nextcloud server with their upload times as modification times. If files are loaded into Nextcloud by directly browsing the phone's filesystem the modification times are preserved.

Expected behaviour

Files' modification times should always be preserved and displayed in the Nextcloud web interface and in the apps.

Steps to reproduce

  1. open the Nextcloud app and add a file from another app
  2. wait for the upload to end
  3. check the file's modification time

Environment data

Android version: 6.0

Device model: Huawei P8 Lite 2015 ALE-L21

Stock or customized system: Default Huawei EMUI 4.1.3

Nextcloud app version: 3.3.2

Nextcloud server version: 14.0.3

Logs

Web server error log

wrong modification time
$IPADDRESS - plumbeo [14/Nov/2018:10:45:32 +0100] "HEAD /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4 HTTP/1.1" 404 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:10:45:33 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-0 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:10:45:33 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-1 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:10:45:34 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-2 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:10:45:34 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-3 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
...
$IPADDRESS - plumbeo [14/Nov/2018:10:45:45 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-31 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:10:45:45 +0100] "PROPFIND /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4 HTTP/1.1" 207 839 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"


correct modification time
$IPADDRESS - plumbeo [14/Nov/2018:12:23:35 +0100] "HEAD /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4 HTTP/1.1" 404 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:12:23:37 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-0 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:12:23:38 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-1 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:12:23:38 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-2 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:12:23:39 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-3 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:12:23:40 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-4 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
...
$IPADDRESS - plumbeo [14/Nov/2018:12:23:50 +0100] "PUT /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4-chunking-2089990416-32-31 HTTP/1.1" 201 0 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"
$IPADDRESS - plumbeo [14/Nov/2018:12:23:50 +0100] "PROPFIND /remote.php/webdav/Smartphone%20Videos/VID_20181114_103855.mp4 HTTP/1.1" 207 839 "-" "Mozilla/5.0 (Android) ownCloud-android/3.3.2"

Nextcloud log (data/nextcloud.log)

Nothing relevant in this file.

plumbeo avatar Nov 14 '18 11:11 plumbeo

GitMate.io thinks possibly related issues are https://github.com/nextcloud/android/issues/724 (Can't share files deftly to other apps), https://github.com/nextcloud/android/issues/3212 (Crash when loading "Deleted files"), https://github.com/nextcloud/android/issues/2515 (Crash at files loading), https://github.com/nextcloud/android/issues/1285 (Can't open files with 3rd party apps), and https://github.com/nextcloud/android/issues/834 (Entering folder first time dont show files).

nextcloud-android-bot avatar Nov 14 '18 11:11 nextcloud-android-bot

@plumbeo thanks for the report. We will have to investigate this since I don't know if this can be achieved easily since we need to look into the meta data / file meta data available when files are shared with the Android app.

AndyScherzinger avatar Nov 14 '18 12:11 AndyScherzinger

This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

stale[bot] avatar May 09 '19 23:05 stale[bot]