Bug 445817 - "Ignored" under "People" can be deleted, can't be restored
Summary: "Ignored" under "People" can be deleted, can't be restored
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Faces-Workflow (other bugs)
Version First Reported In: 7.3.0
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-20 15:45 UTC by Jonathan Kamens
Modified: 2021-11-20 18:01 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 7.4.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Kamens 2021-11-20 15:45:29 UTC
I was under the apparently mistaken impression that tagging faces with the label "Ignored" would cause them to be ignored. That didn't work, though, all it apparently did was create a person named "Ignored" over and above the actual "Ignored" category listed under people (FYI: the reason I was trying to do this is because there's no way to tag a face as ignored when looking at unconfirmed faces under a person, which is a significant UX issue in and of itself). I needed to clean this up, i.e., to remove the "Ignored" person, so I went to delete that tag in the tag manager, but somehow managed to delete both it and the _actual_, correct, "Ignored" tag that actually causes faces to be ignored. Now I can't find any way to get it back. I am able to mark faces as ignored by clicking the appropriate button when looking at Unknown faces, but I can't see which faces have been ignored because there's no "Ignored" under people and I can't find a way to restore it.

I guess this is actually lots of different workflow issues all wrapped up in one:

1. There should be a way to mark faces ignored from any people view, not just from the Unknown view.
2. It should not be possible to delete the canonical "Ignored" tag.
3. It should be possible to restore the canonical "Ignored" tag if it somehow gets deleted.
Comment 1 Maik Qualmann 2021-11-20 15:54:40 UTC
1.) There are already bug reports on this.
2.) Already fixed in the pre-release of digiKam-7.4.0
3.) If you ignore a face, the tag will be generated again. For the DB it is still not good that the old tag was deleted.

Maik
Comment 2 Maik Qualmann 2021-11-20 16:06:28 UTC
I have just tested it again, even in digiKam-7.3.0 the ignored tag could no longer be deleted.

Maik
Comment 3 Jonathan Kamens 2021-11-20 16:19:10 UTC
I searched and did not find other bugs before filing this one.

When I ignore a face in 7.3.0 the tag does not get recreated.

You claim that it was impossible to delete the tag in 7.3.0 and yet I assure you that I deleted it and it is not there, so there is presumably a way to delete it of which you are unaware. I believe it happened to me in the tag manager, if that helps.
Comment 4 Jonathan Kamens 2021-11-20 16:20:52 UTC
I will leave it to you whether to reopen this bug or just ignore the fact that the claims you made about it are directly at odds with my actual experience in the app. Whether you choose to actually listen to one of your users who has been developing open-source software for more than 30 years and therefore probably knows how to accurately describe a bug is your choice. :shrug:
Comment 5 Maik Qualmann 2021-11-20 16:58:16 UTC
The tag is actually created when it doesn't exist, neither is it on a new database and is automatically created the first time a face is ignored. It is possible to rename the ignored tag (is by design), maybe you did.

Maik
Comment 6 Maik Qualmann 2021-11-20 17:06:03 UTC
If you have renamed it, it will still remain on the 3rd tag position from the top in the People view.

Maik
Comment 7 Jonathan Kamens 2021-11-20 17:12:55 UTC
Digging into the database, as far as I can tell it exists but has the correct name but is not visible in the UI:

```
MariaDB [digikam]> select * from TagProperties where property='ignoredPerson';
+-------+---------------+-------+
| tagid | property      | value |
+-------+---------------+-------+
|   668 | ignoredPerson | NULL  |
+-------+---------------+-------+
1 row in set (0.004 sec)

MariaDB [digikam]> select * from Tags where id=668;
+-----+------+---------+------+---------+
| id  | pid  | name    | icon | iconkde |
+-----+------+---------+------+---------+
| 668 |    4 | Ignored | NULL | NULL    |
+-----+------+---------+------+---------+
1 row in set (0.000 sec)
```

It does not show up _at all_ in the people view, in the third position or anywhere else. When I enter "Ignored" in the search box underneath the people view there are no results. When I search for "Ignored" in the tag manager it _is_ visible there. Just not visible in the people view.
Comment 8 Jonathan Kamens 2021-11-20 17:20:46 UTC
Also, I don't know if this is relevant, but despite the fact that I have marked faces as ignored in the Unknown person view, there don't appear to be any entries for tag ID 668 (the tag ID in the DB for the Ignored tag, as shown above) in the ImageTags table:

```
MariaDB [digikam]> select count(*) from ImageTags where tagid=668;
+----------+
| count(*) |
+----------+
|        0 |
+----------+
1 row in set (0.001 sec)
```
Comment 9 Maik Qualmann 2021-11-20 17:35:14 UTC
The ignored tag is virtual, there are no faces assigned, so the count is null. The information is stored differently. You canceled the face marking on the ignored tag, so it can no longer be seen (filtered) in the People view. Go to the normal tag view and mark it as a face again using the right mouse context menu. I will fix that the virtual tags can be unmarked as face tags.

Maik
Comment 10 Jonathan Kamens 2021-11-20 17:38:13 UTC
Yup, that fixed it. I have no idea how I "canceled the face marking on the ignored tag," but :shrug:. Thank you for troubleshooting with me.
Comment 11 Maik Qualmann 2021-11-20 18:01:16 UTC
Git commit 488f621c739b69c39c9f0e7314b3d53fa66e9908 by Maik Qualmann.
Committed on 20/11/2021 at 18:00.
Pushed by mqualmann into branch 'master'.

prevent unmark as face for the system face tags
FIXED-IN: 7.4.0

M  +10   -1    core/libs/tags/engine/tagmodificationhelper.cpp

https://invent.kde.org/graphics/digikam/commit/488f621c739b69c39c9f0e7314b3d53fa66e9908