[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 Tobias Leupold changed: What|Removed |Added Status|CONFIRMED |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #11 from Johannes Zarl-Zierl --- Git commit 1d32f069207ddbf044f379f057ac51405b3b016e by Johannes Zarl-Zierl. Committed on 08/03/2016 at 22:53. Pushed by johanneszarl into branch 'master'. Prevent duplication of special categories. Take care that a category in the index.xml file cannot have the same name as the "Folder" or "Media type" category. This prevents the creation of an ill-formed xml file in these cases. M +8-2XMLDB/FileReader.cpp http://commits.kde.org/kphotoalbum/1d32f069207ddbf044f379f057ac51405b3b016e -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #10 from Tobias Leupold --- Just for the moment: A workaround would be: open the v6 database with KPA 4.7.1. You get doubled "Folder" and "Media Type" categories, one is the real one one is empty for each. Delete the empty ones (the "real" ones are not shown in the category settings and can't be deleted). Save the database. Doing so, the read error does not occur anymore here. -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 Tobias Leupold changed: What|Removed |Added Ever confirmed|0 |1 Status|UNCONFIRMED |CONFIRMED --- Comment #9 from Tobias Leupold --- Thanks for posting the database. This makes it much easier to see what's going on here. I can reproduce it when I use the C locale. I get a doubled "Folder" and "Media Type" category and the read error you described appears after saving. When using my (German) locale, I also get the doubled categories, but one is called "Folder" and one "Ordner", which is the translation. Same for the "Media Type" one. The translated one is the "real" special category, the other one is empty. When saving the database using a non-C locale, no reading error occurs, probably due to the different names. -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #8 from dper...@gmail.com --- Created attachment 97770 --> https://bugs.kde.org/attachment.cgi?id=97770&action=edit database file that worked (0128) and stopped working after saving -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #7 from Tobias Leupold --- Could you try taking the latest v6 database (index.xml~0128~.zip), open it with KPA 4.7.1, save it (it will be v7 afterwards) and see what happens? Probably, it wouldn't be a bad idea if you saved your backups somewhere else, not that KPA will finally overwrite then while we are tracking this down … -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #6 from Johannes Zarl-Zierl --- Thanks for the detailed info! > By the way, is it safe to delete all the duplicated attributes from my last > database in order not to lose changes? Yes, this is safe. You can remove both the "Folder" and the "Media Type" attributes from the file without data loss. -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #5 from dper...@gmail.com --- (In reply to Tobias Leupold from comment #3) > Can you reproduce this with an older version of your index.xml? KPA stores > backups of it automatically, they are named like index.xml~~.zip, where > is a number. It would be very interesting if you could tell us which > version messed it up, and under which circumstances (is this reproducable? > Did you switch locales? Doing so was actually a problem before KPA 4.7). > > As Johannes said, those categories shouldn't be found in index.xml at all … Yes, sure, I have done some more tests and tried all the previous backups (unzipped and renamed to index.xml to make sure is the one used by KPhotoAlbum): index.xml~0126~.zip: no problem. Line#2: index.xml~0127~.zip: no problem. Line#2: index.xml~0128~.zip: no problem. Line#2: index.xml~0129~.zip: crash. Line#2: index.xml~0130~.zip: crash. Line#2: So the problem appears to have arrived from version 7 onwards, but if backup 0129 was wrong... how the database was opened correctly and then saved again wrongly? Is the backup written on every save operation but the error arises only on KPhotoAlbum startup? Maybe I switched locales (en_US > es_ES), but can't remember. I think the locale change was long before the problem, but I can't remember. I don't know any other relevant circumstances, just doing basic stuff like tagging Photos, save, and on next run... Crash! My basic system info: Linux WS-MANJARO 3.18.27-1-MANJARO #1 SMP PREEMPT Tue Feb 16 22:53:23 UTC 2016 x86_64 GNU/Linux By the way, is it safe to delete all the duplicated attributes from my last database in order not to lose changes? -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #4 from dper...@gmail.com --- (In reply to Johannes Zarl-Zierl from comment #2) > The snippet from your index.xml file shows more problems: > > Not only the "Media Type", but also the "Folder" attribute is written twice. > The bigger problem, however, is that these two categories are saved at all. > These two categories are computed from the file name and should not be > stored in index.xml by KPhotoAlbum. > > I take it that this error occurred after an upgrade to KPhotoAlbum? Do you > know which version you used before? > > Which language settings / locale are you using? Yes, you're right, also "Folder" attribute is found twice. AFAIK the problem began after upgrading from 4.7 to 4.7.1, but not sure if it was after first execution or a couple of them. I've also tried to downgrade KPhotoAlbum to 4.6 or 4.5 but using the same database leads to the same error. At last I tried to use different databases from the backup files, and only the latest is wrong, so I guess the new attributes where written by the last version: 4.7.1 -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 Tobias Leupold changed: What|Removed |Added CC||tobias.leup...@web.de --- Comment #3 from Tobias Leupold --- Can you reproduce this with an older version of your index.xml? KPA stores backups of it automatically, they are named like index.xml~~.zip, where is a number. It would be very interesting if you could tell us which version messed it up, and under which circumstances (is this reproducable? Did you switch locales? Doing so was actually a problem before KPA 4.7). As Johannes said, those categories shouldn't be found in index.xml at all … -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 Johannes Zarl-Zierl changed: What|Removed |Added CC||johan...@zarl-zierl.at --- Comment #2 from Johannes Zarl-Zierl --- The snippet from your index.xml file shows more problems: Not only the "Media Type", but also the "Folder" attribute is written twice. The bigger problem, however, is that these two categories are saved at all. These two categories are computed from the file name and should not be stored in index.xml by KPhotoAlbum. I take it that this error occurred after an upgrade to KPhotoAlbum? Do you know which version you used before? Which language settings / locale are you using? -- You are receiving this mail because: You are watching all bug changes.
[kphotoalbum] [Bug 360196] can't open Kphotoalbum ("error reading next element"): found duplicate attributes in tags in index.xml photos database
https://bugs.kde.org/show_bug.cgi?id=360196 --- Comment #1 from dper...@gmail.com --- Created attachment 97735 --> https://bugs.kde.org/attachment.cgi?id=97735&action=edit Screenshot of the error. -- You are receiving this mail because: You are watching all bug changes.