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

Viewer not loading for pictures from 'People' tab #1594

Closed
phil-lipp opened this issue Jan 18, 2023 · 4 comments · Fixed by #1606
Closed

Viewer not loading for pictures from 'People' tab #1594

phil-lipp opened this issue Jan 18, 2023 · 4 comments · Fixed by #1606
Labels
0. Needs triage Pending approval or rejection. This issue is pending approval. bug Something isn't working

Comments

@phil-lipp
Copy link

phil-lipp commented Jan 18, 2023

Describe the bug
The image viewer is not working when invoking it from the "People" subpage. It works fine when viewing photos from e.g. the "All Media" or "On This Day" subpage. This behaviour happens both on desktop and mobile.

To Reproduce
Steps to reproduce the behaviour:

  1. Go to 'Photos' app
  2. Click on 'People'
  3. Scroll down to any person and click on their cluster
  4. wait for cluster to load
  5. click on any photo in the cluster
  6. See error (indefinitely spinning circle, with the "X" and "Start Slideshow" buttons appearing in the top right corner, but no photo showing up)

Expected behaviour
View image the same way as opening via e.g. "All Media"

Screenshots
I don't think a screenshot is necessary and I don't feel confident sharing faces of other people here.

Desktop (please complete the following information):

  • OS: Debian 11
  • Browser: Firefox 64-bit
  • Version: 109

Smartphone (please complete the following information):

  • Device: iPhone 8
  • OS: iOS 16.2
  • Browser: Safari
  • Version: -

PHP:

  • Version: 8.1.14
  • Memory limit: 5,7 GB
  • Max execution time: 3600
  • Upload max size: 10 GB
  • Extensions: Core, date, libxml, openssl, pcre, zlib, filter, hash, json, Reflection, SPL, session, standard, sodium, cgi-fcgi, mysqlnd, PDO, xml, bcmath, bz2, calendar, ctype, curl, dom, mbstring, FFI, fileinfo, ftp, gd, gettext, gmp, iconv, igbinary, imagick, intl, ldap, exif, mysqli, pdo_mysql, pdo_sqlite, Phar, posix, readline, redis, shmop, SimpleXML, sockets, sqlite3, sysvmsg, sysvsem, sysvshm, tokenizer, xmlreader, xmlwriter, xsl, zip, Zend OPcache

Browser log

[DEBUG] photos: [FetchFacesMixin] Fetched 137 new faces:  
Object { 0: {…}, 1: {…}, 2: {…}, 3: {…}, 4: {…}, 5: {…}, 6: {…}, 7: {…}, 8: {…}, 9: {…}, … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 41 new files:  
Object { 0: "23799", 1: "24070", 2: "24089", 3: "24096", 4: "24107", 5: "24138", 6: "24168", 7: "24169", 8: "24222", 9: "24223", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 43 new files:  
Object { 0: "30860", 1: "30983", 2: "31512", 3: "33513", 4: "34424", 5: "41074", 6: "41076", 7: "41080", 8: "41091", 9: "41105", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 41 new files:  
Object { 0: "21510", 1: "21856", 2: "23632", 3: "23659", 4: "23841", 5: "24168", 6: "25481", 7: "25516", 8: "25519", 9: "25595", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 45 new files:  
Object { 0: "19151", 1: "19151", 2: "19151", 3: "19155", 4: "19155", 5: "19155", 6: "19162", 7: "19162", 8: "19162", 9: "19175", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 97 new files:  
Object { 0: "19173", 1: "19173", 2: "19173", 3: "20508", 4: "20603", 5: "20658", 6: "20891", 7: "20989", 8: "21039", 9: "21109", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 71 new files:  
Object { 0: "22960", 1: "22969", 2: "23118", 3: "23127", 4: "23159", 5: "23863", 6: "23908", 7: "23918", 8: "24064", 9: "24069", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 150 new files:  
Object { 0: "21084", 1: "23531", 2: "24034", 3: "24037", 4: "24041", 5: "24047", 6: "24069", 7: "24070", 8: "24136", 9: "24163", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 60 new files:  
Object { 0: "20646", 1: "21719", 2: "28105", 3: "28190", 4: "29801", 5: "30094", 6: "30365", 7: "33794", 8: "34298", 9: "35443", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 42 new files:  
Object { 0: "22070", 1: "22118", 2: "31500", 3: "31880", 4: "31899", 5: "32027", 6: "32092", 7: "32415", 8: "32479", 9: "32603", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 62 new files:  
Object { 0: "37923", 1: "38029", 2: "41069", 3: "41083", 4: "41099", 5: "41100", 6: "41101", 7: "41113", 8: "41137", 9: "41144", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 179 new files:  
Object { 0: "18996", 1: "18997", 2: "18998", 3: "19000", 4: "19001", 5: "19002", 6: "19003", 7: "19003", 8: "19004", 9: "19005", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 83 new files:  
Object { 0: "19212", 1: "19212", 2: "19212", 3: "19226", 4: "19226", 5: "19226", 6: "19243", 7: "19243", 8: "19243", 9: "19249", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 109 new files:  
Object { 0: "21409", 1: "21620", 2: "22006", 3: "22027", 4: "22068", 5: "22090", 6: "22504", 7: "23693", 8: "23854", 9: "23922", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 336 new files:  
Object { 0: "18993", 1: "18993", 2: "21516", 3: "23436", 4: "23470", 5: "23747", 6: "23882", 7: "24257", 8: "25666", 9: "26318", … }
ConsoleLogger.js:52:10
[DEBUG] photos: [FetchFacesMixin] Fetched 650 new files:  
Object { 0: "18995", 1: "18996", 2: "18997", 3: "18998", 4: "19000", 5: "19001", 6: "19002", 7: "19003", 8: "19004", 9: "19005", … }
ConsoleLogger.js:52:10
Firefox can’t establish a connection to the server at wss://nextcloudpi/push/ws. index.js:118:45
[DEBUG] photos: [TiledLayout] Computing rows 
Object { level: 0, app: "photos", uid: "user1", items: (650) […] }
ConsoleLogger.js:52:10
[DEBUG] photos: [VirtualScrolling] Computing visible rows 
Object { level: 0, app: "photos", uid: "user1" }
ConsoleLogger.js:52:10
[DEBUG] photos: [VirtualScrolling] Computing container 
Object { level: 0, app: "photos", uid: "user1" }
ConsoleLogger.js:52:10
[DEBUG] photos: [VirtualScrolling] Computing visible rows 
Object { level: 0, app: "photos", uid: "user1" }
ConsoleLogger.js:52:10
[DEBUG] photos: [TiledLayout] Computing rows 
Object { level: 0, app: "photos", uid: "user1", items: (650) […] }
ConsoleLogger.js:52:10
[DEBUG] photos: [VirtualScrolling] Computing visible rows 
Object { 0: {…}, 1: {…}, 2: {…}, 3: {…}, 4: {…}, 5: {…}, 6: {…}, 7: {…}, 8: {…}, 9: {…}, … }
ConsoleLogger.js:52:10
[INFO] viewer: Opening viewer for file  
Object { level: 0, app: "viewer", uid: "user1", path: "/files/user1/Photos & Videos/DSC07199.JPG" }
ConsoleLogger.js:56:18
XHRPROPFINDhttps://10.6.0.1/remote.php/dav/files/user1/files/user1/Photos & Videos/DSC07199.JPG
[HTTP/2 404 Not Found 149ms]

Could not open file /files/user1/Photos & Videos/DSC07199.JPG Error: Invalid response: 404 Not Found
    i response.js:10
    handleResponseCode response.js:21
    getStat stat.js:65
    s stat.js:33
    s stat.js:14
    a stat.js:5
    promise callback*l stat.js:7
    r stat.js:8
    r stat.js:4
    getStat stat.js:47
    stat factory.js:80
    e DavClient.js:38
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    cg FilesActionHandler.js:53
    a DavClient.js:37
    pg DavClient.js:38
    pg DavClient.js:33
    fg FileInfo.js:34
    dg DavClient.js:38
    n canDownload.js:26
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    Qm canDownload.js:26
    a CancelableRequest.js:40
    n CancelableRequest.js:40
    r CancelableRequest.js:40
    n CancelableRequest.js:43
    r Viewer.vue:486
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    Ig Pencil.vue:19
    a Pencil.vue:19
    Ng Pencil.vue:19
    Ng Pencil.vue:19
    openFile Viewer.vue:471
    file Viewer.vue:337
    VueJS 11
    value Viewer.js:229
    openViewer FaceContent.vue:288
    VueJS 4
    emitClick File.vue:185
    click File.vue:1
    VueJS 14
Viewer.vue:495:58
Error loading /files/user1/Photos & Videos/iPhone/2022/01/21-01-2022-19-38-59.mov 
error { target: div.plyr.plyr--full-ui.plyr--video.plyr--html5.plyr--fullscreen-enabled.plyr--paused.plyr--stopped, isTrusted: false, detail: {…}, srcElement: div.plyr.plyr--full-ui.plyr--video.plyr--html5.plyr--fullscreen-enabled.plyr--paused.plyr--stopped, currentTarget: div.viewer__file--hidden.viewer__file, eventPhase: 3, bubbles: true, cancelable: false, returnValue: true, defaultPrevented: false, … }
Mime.js:111:10
[DEBUG] viewer: Closing video stream 
Object { level: 0, app: "viewer", uid: "user1", filename: "/files/user1/Photos & Videos/iPhone/2022/01/21-01-2022-19-38-59.mov" }
ConsoleLogger.js:52:18
[INFO] viewer: Opening viewer for file  
Object { level: 0, app: "viewer", uid: "user1", path: "/files/user1/Photos & Videos/DSC07280.JPG" }
ConsoleLogger.js:56:18
XHRPROPFINDhttps://10.6.0.1/remote.php/dav/files/user1/files/user1/Photos & Videos/DSC07280.JPG
[HTTP/2 404 Not Found 188ms]

Could not open file /files/user1/Photos & Videos/DSC07280.JPG Error: Invalid response: 404 Not Found
    i response.js:10
    handleResponseCode response.js:21
    getStat stat.js:65
    s stat.js:33
    s stat.js:14
    a stat.js:5
    promise callback*l stat.js:7
    r stat.js:8
    r stat.js:4
    getStat stat.js:47
    stat factory.js:80
    e DavClient.js:38
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    cg FilesActionHandler.js:53
    a DavClient.js:37
    pg DavClient.js:38
    pg DavClient.js:33
    dg DavClient.js:38
    n canDownload.js:26
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    Qm canDownload.js:26
    a CancelableRequest.js:40
    n CancelableRequest.js:40
    r CancelableRequest.js:40
    n CancelableRequest.js:43
    r Viewer.vue:486
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    Ig Pencil.vue:19
    a Pencil.vue:19
    Ng Pencil.vue:19
    Ng Pencil.vue:19
    openFile Viewer.vue:471
    file Viewer.vue:337
    VueJS 11
    value Viewer.js:229
    openViewer FaceContent.vue:288
    VueJS 4
    emitClick File.vue:185
    click File.vue:1
    VueJS 14
Viewer.vue:495:58

Additional context
Viewing people/faces in the memories app works fine.

@phil-lipp phil-lipp added 0. Needs triage Pending approval or rejection. This issue is pending approval. bug Something isn't working labels Jan 18, 2023
@diego-treitos
Copy link

diego-treitos commented Jan 19, 2023

Also having the same problem. It appears like the generated links are wrong:

XHRPROPFIND https://10.6.0.1/remote.php/dav/files/user1/files/user1/photo.jpg`
                                            ^^^^^^^^^^^^^^^^^^^^^^^
                                              duplicated subpath

If you use nginx you can add this very ugly workaround...

  # UGLY FIX for https://github.com/nextcloud/photos/issues/1594
  rewrite ^/remote.php/dav/files/([^/]*)/files/([^/]*)/(.*) /remote.php/dav/files/$1/$3/ redirect;

@phil-lipp
Copy link
Author

@marcelklehr this doesnt seem to be fixed in 25.0.4 - at least for me

@phil-lipp
Copy link
Author

phil-lipp commented Feb 27, 2023

Here's the log. Note that I replaced the actual username with "user1" and the middle folders with "/path/to/". The first part "/Photos & Videos/" is the actual name of the first folder and the filename is also the actual filename.

[INFO] viewer: Opening viewer for file  
Object { level: 0, app: "viewer", uid: "user1", path: "/Photos & Videos/path/to/19-05-2014-11-4555.JPG" }
ConsoleLogger.js:56:18
XHRPROPFINDhttps://10.6.0.1/remote.php/dav/files/user1/Photos & Videos/path/to/19-05-2014-11-4555.JPG
[HTTP/2 404 Not Found 230ms]

GEThttps://10.6.0.1/apps/theming/image/background?v=7
[HTTP/2 404 Not Found 281ms]

Could not open file /Photos & Videos/path/to/19-05-2014-11-4555.JPG Error: Invalid response: 404 Not Found
    i response.js:10
    handleResponseCode response.js:21
    getStat stat.js:65
    s stat.js:33
    s stat.js:14
    a stat.js:5
    promise callback*l stat.js:7
    r stat.js:8
    r stat.js:4
    getStat stat.js:47
    stat factory.js:80
    e DavClient.js:38
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    cg FilesActionHandler.js:53
    a DavClient.js:37
    pg DavClient.js:38
    pg DavClient.js:33
    dg DavClient.js:38
    n canDownload.js:26
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    Qm canDownload.js:26
    a CancelableRequest.js:40
    n CancelableRequest.js:40
    r CancelableRequest.js:40
    n CancelableRequest.js:43
    r Viewer.vue:490
    u runtime.js:288
    _invoke runtime.js:262
    C runtime.js:83
    Ig Pencil.vue:19
    a Pencil.vue:19
    Ng Pencil.vue:19
    Ng Pencil.vue:19
    openFile Viewer.vue:475
    file Viewer.vue:341
    VueJS 11
    value Viewer.js:230
    openViewer FaceContent.vue:288
    VueJS 4
    emitClick File.vue:185
    click File.vue:1
    VueJS 33
Viewer.vue:499:58

@marcelklehr
Copy link
Member

Photos & Videos

Ah, that's a different bug then. Quickfix is to rename the folder to a name without &. This was fixed in #1645 and will land in v25.0.5 then.

rkben pushed a commit to rkben/photos that referenced this issue Mar 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending approval or rejection. This issue is pending approval. bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants