[Discussion] New Photo App in Nextcloud 18

Empty screen :frowning:

Oh. It seems to me that DOMPurify is shipped in a very old version and the global one is not longer available: https://github.com/nextcloud/server/pull/17130

What worked for me:

cd apps/gallery/js/vendor/dompurify/src
wget https://raw.githubusercontent.com/cure53/DOMPurify/1.0.11/dist/purify.js -O purify.js

And make sure to run maintenance:repair and clean the cache.

2 Likes

Still the same empty screen. Only the sort, share and info icons in the top right corner.
What do you exactly mean by “clear the cache”? occ maintenance:repair already cleares it.

Your browser cache (a force reload of the tab).

Did it, of course. Even tried from another browser. Same :frowning:

Daniel512, for you, it is working? So NC18 with the gallery downloaded from github?

Hi together.

The “old” gallery app is running on my NC 18 :smiley:

What i did:

cd /var/www/nextcloud/apps
git clone https://github.com/nextcloud/gallery.git
cd gallery/js/vendor/dompurify/src
wget https://raw.githubusercontent.com/cure53/DOMPurify/1.0.11/dist/purify.js -O purify.js 
sudo -u www-data php /var/www/nextcloud/occ   app:enable gallery

After that the gallery is working. No cache cleaning or “occ maintenance:repair”

Edit: It takes 2-4 seconds before the main gallery view is shown. But then everything is fine.

Cheers,
Andreas

25 Likes

Great, thanks!! Now it is working OK!
Btw, I don’t know what was the difference, that made it work, but the important is, that it’s working now :slight_smile:
Fyi: I did have to force reload the page!

Brilliant, thank you. The commands were a little different for an unraid dockerised version but i worked it out haha :slight_smile: Thanks

uhhh it works… been looking for exactly this for weeks… thx a million :slight_smile:

Interesting “hack”. Hopefully it will survive the next update :slight_smile:

1 Like

That sounds awesome! What was the difference in the commands? I use NC18 also as a Docker on my Unraid server and since it is the first contact with Nextcloud, I was really a bit confused about the Gallery App.

When i to Your Albums i get an Error, all other works. I can nit access to Albums and can nit create some albums.

cant find some information the log. Could someone help me please?

Seens it is using any folder with pictures in it as albums, even among my music collection. Pressing the “your albums” leads to a looooong wait or crash.

Instead you can change the url to your real library folders.
For me that is :
https://domain.com/apps/photos/albums/PhotoLibrary/2020


Mobile view does look rather silly, doesn’t it? :slight_smile:

The photo app should have a settings panel where we can choose what folders and paths that should be considered. Similar to the Audio player app.

4 Likes

well it’s not so much that the commands are different but more where they are issued in the terminal as I am not familiar with linux and bump my way around whilst trying not to break anything :slight_smile: This is what I typed line by line after entering the nextcloud console mode in unraid by clicking on the nextcloud docker icon and selecting console. Hopefully i haven’t messed up and it works for you.

cd /config/www/nextcloud/apps
git clone https://github.com/nextcloud/gallery.git
cd gallery/js/vendor/dompurify/src/
wget https://raw.githubusercontent.com/cure53/DOMPurify/1.0.11/dist/purify.js -O purify.js
cd /config/www/nextcloud/
sudo -u abc php occ app:enable gallery

1 Like

Thanks, but i cant find any Albums But i have thousands Photos. Where are the Library located?
Sorry but the app is unfinished…

Edit, found it. I had mount External Webdav Storage. If i unmount it it works. Very strange

Thank you very much! This helped me a lot!! I also have a UnRaid Server with an NC instance running and this will tidy up things extremely. Both thumbs up your help :slight_smile:

P.S.: Everything works like expected! Thank you again! Have a nice weekend!

1 Like

Hi all,

Sorry that many of you experienced some issues and regressions with the Photos app. Let me first say: we really wanted to avoid regressions, this was explicitly discussed on our last meeting where we decided to move forward with Photos. It was meant to be an upgrade for 95% of the users. So as far as it isn’t, we intend to fix that!

Let me address our current understanding of the 3 major issues people face with the Photos app that are regressions from Gallery (of course there’s a lot more we can improve, and we already did, but those are new features!).

As a TL;DR: most of this should be fixed in 18.0.2.

Performance.

So there are two things to know about the performance of Gallery and Photos.

Gallery used to be designed to look into all folders on your Nextcloud and only show the folders with images. This was a very slow process, explaining why the app was so slow. A major motivation for Photos was to improve performance, which we did in party by the left sidebar showing ‘my photos’ primarily. That can show ‘your images’ (those not shared with you) pretty much immediately. And that covers many use cases, of course.

But not all, so ‘shared albums’ was added to show what is shared with you. And, last but not least, you can see images on external storage (showing of which takes quite some work) when you use the Your Albums view.

Now at least one person (who started this thread) noted that the performance is MUCH slower than the previous Gallery app when in the Your Albums view… That really shouldn’t be the case: the new Your Albums code that shows all images in folders (External storage or not) should be much more efficient. So John tries find out what’s happening. It could be related to the preview generation which can cause a storm of preview-generation-threads on the server, causing a slowdown. I recommend everyone to use the preview generator app!

TL;DR: performance should always be better than Gallery, we haven’t found a regression yet.

Folder structure not shown

Now the second issue about folder structure.

So if you have a structure like this (from a comment by adi2k5):

/root_folder
   |_Photos
       |_2010
       |      |_Album1
       |      |       |_SomeOtherFolderBelow_Album1
       |      |...
       |      |_AlbumN
       |_2011
       |      |_Album1
       |      |...
       |      |_AlbumN
       | ...
       |_2020
             |_Album1
             |...
             |_AlbumN

Our current Photos app flattens it to this, removing the year info:

/root_foder
    |_Photos
    |      |_Album1
    |      |_Album2
    |      |...
    |      |_AlbumN
    |_Folder_with_icons1
    |_Folder_with_icons2
    | ...
    |_Folder_N

We just made a mistake there, and consider this a bug which will be fixed! A pull request is already here.

TL;DR: fix coming soon.

Public link view

The public link view has two changes.

First, and this was so rare most users probably didn’t know, but the Gallery app had a specific share link view: you could share a link that would show the Gallery app view, not the file view. We would like to bring this back, but it is technically hard and while less nice, the grid view of files is quite OK too, so it is lower priority than the second issue.

That second issue is: if you click a photo on a public link, you used to get the slideshow preview! Today, it just downloads the image. This slideshow was provided by the Gallery app and, yes, we basically forgot about it. It seems that even during the testing phases in Beta and RC, this was not noticed by anyone so it came out only now - and we’re working on fixing it.

When

Now I’ve said we’ll fix everything so you might wonder when. Well, actually most of these are not that hard and already work-in-progress. We hope they’ll be done in time for the upcoming 18.0.2, which is scheduled for March 12 - so that’s in 2 weeks! The viewer is a bit harder, it might take a bit longer, we’re not 100% sure yet - but we are working on it (and as always, help is welcome).

A note I want to add about the discussion itself. As I said, our goal was never to take away features. Yes, there are some regressions and those are due to mistakes - we are human, too. Most people who asked about it or discussed this have been very polite, and thank you for that! Sadly, some were not, and that is not very motivating at all. Please, keep in mind that we’re talking online (where negative emotions tend to get amplified) and also, please assume we want the same thing: make Nextcloud better. With that in mind, you would assume that we made a mistake, not intentionally made your life worse… And that leads to better, more motivating and ultimately more productive conversations!

I’d also like to point out that you’re not just talking to people who get paid to work on Nextcloud (not like that’s an excuse) but also to the hundreds of amazing community volunteers who make Nextcloud awesome, like Corentin who recently wrote a great blog about his experiences contributing to Nextcloud. Consider participating in such a positive way: you can join our conference or other events or help code online and make Nextcloud better,

Thanks for reading!

38 Likes

Hj @jospoortvliet,

thanks for the posting and the clear answers :grinning: :ok_hand:

Keep up the great work.

Cheers,
Andreas

3 Likes