PictoPy icon indicating copy to clipboard operation
PictoPy copied to clipboard

BUG:Folder Deletion dosen't delete memories that were made from that folder.

Open Takitxt opened this issue 3 months ago • 10 comments

Is there an existing issue for this?

  • [x] I have searched the existing issues

What happened?

Problem Statement:

Deleting a folder from Settings, removes the folder's images from the library, but any auto-generated Memories built from those images are left behind as empty, broken tiles instead of being removed.

Video Proof:

https://github.com/user-attachments/assets/3aaa8815-32d3-46ed-9b1d-1bf18e0f4c2f

Steps to Reproduce:

  1. Add a folder that has photos in it.
  2. Go to Memories, memory cards were generated from that folder's photos.
  3. Go to Settings and delete the folder.
  4. Go back to Memories. The same memory cards are still there, now showing 0 photos and a broken cover.
  5. Click Regenerate — the memory cards remain instead of clearing out.

Expected Behaviour:

Once a memory has no images or videos left (because its source were deleted), it should stop appearing in the Memories list.

Current Behaviour:

  • The memory row is never cleaned up.
  • It keeps showing in the Memories grid indefinitely with "0 photos" and a broken cover image, even after manually clicking Regenerate.

Record

  • [x] I agree to follow this project's Code of Conduct

Takitxt avatar Aug 15 '26 17:08 Takitxt

👋 Thanks for opening this issue! The maintainers will review it shortly. Till then, do not open any PR. This is a strict rule we like to follow around here :)

github-actions[bot] avatar Aug 15 '26 17:08 github-actions[bot]

@rohan-pandeyy Can i please work on this issue?? ( i am done with my previous ones.)

Takitxt avatar Aug 15 '26 17:08 Takitxt

@rohan-pandeyy can i give this a try?

SinghAman21 avatar Aug 16 '26 13:08 SinghAman21

@Takitxt hi,

this actually appears to be a real bug 1st i though this might be due to SQlite sync issue but maybe its not i have started working on it and will soon open a PR

Aryan27-max avatar Aug 16 '26 17:08 Aryan27-max

Can i please work on this issue

tushar8232 avatar Aug 16 '26 17:08 tushar8232

@Takitxt more over i found out the deletion() exists but the real problem is a stale memory that the frontend retains i went through the schema and the DB layer and this feel like that folder deletion doesn't invalidate the Memories query, so even after fixing the backend, the UI could potentially retain a stale memory for up to the React Query stale period.

Aryan27-max avatar Aug 16 '26 17:08 Aryan27-max

@Aryan27-max I think you should wait for the maintainer for the assignment. because i also want to work on this issue, and the project follows strict rules that you should not be opening PR's before the maintainers assignment.

Takitxt avatar Aug 18 '26 07:08 Takitxt

@Takitxt i hadn't read through the code of conduct completely I had almost completed the fix and was testing it. 🥲

Hey, maintainers can you please assign me the issue.

Aryan27-max avatar Aug 18 '26 08:08 Aryan27-max

Since the issue was opened by @Takitxt, and he's asking for assignment as well, we'll follow the project's contribution workflow and assign it to him.

@Aryan27-max, please always wait for a maintainer's assignment before starting work or opening a PR.

rohan-pandeyy avatar Aug 18 '26 18:08 rohan-pandeyy

@rohan-pandeyy sure, i went through the code of conduct and contributing.md again, I've not opened any PRs, and will keep that in mind moving forward

Aryan27-max avatar Aug 18 '26 18:08 Aryan27-max