A limit of three replies to a post does seem very strange. Did it give any reason? Unfortunately, the KMM team has no control over discuss.kde.org, so that would have to be addressed with a new post targetted at the platform itself.
I’m a little confused. Your problem was created long ago when you imported data (from gnucash?) which created an invalid id for the category, which was not tested for by KMM. Fortunately, that id did not cause any problems. In 5.2.0, the routine which opens the data file checks for invalid syntax, and now refuses to open that file.
Some of your attempts to open the file give an error about it already being open in another process. The first thing to do is look for a lock file in the same folder as the data file. If you find one, and are absolutely certain nothing else has the file open, you can just delete the lock file. If that happens consistently, let us know, as it might be a new bug. It might also be a left over lock file from when you were perviously using dropbox, although that doesn’t seem likely.
When you say you couldn’t find anything using my suggestions, please be more specific. what command(s) did you use, and what was the result?
You also say you can now edit the file in 5.2.1, but how, if it complains about the problem category? If you can actually edit the file in 5.2.1, something in the data has changed.
In terms of finding the offending Category, I think you need to use grep or zgrep (grep works for plain text (including xml) files, but zgrep works for compressed files, such as .kmy. You can simply ‘zgrep 254-category your-date-file.kmy’ but that will show you not only the <ACCOUNT …..> line which defines the account for that category (and the “name” attribute on that line shows you the Category you need to replace) but will also list every transaction that uses it. “zgrep 254-category your-data-file.kmy | grep ACCOUNT” should limit it to the one line you need. Once you have the category name, you can open your file (most likely in 5.1.3, create a new category (use a name different from the old one so you can distinguish, and you can change it later) and the delete the old category, telling KMM to use the new category as a replacement.