Open EddieDover opened 1 month ago
After speaking with the user, the issue stemmed from them manually modifying the export JSON then reimporting it, to add their own achievements faster than manual entry. The cause of the bug was from blank ID fields during import.
Fix for this issue is to make sure import IDs are correct/exist, and generate uniques if they are not/do not.
What happened?
A user said that during the import/export process, they suddenly got a duplicate key issue that caused the entire plugin to be nonfunctional.
This needs a multi-step resolution:1) No user should ever be soft-locked from using the module because of this issue. Duplicate keys need to be gracefully handled somehow. Most likely through deletion of either the latest in the array or the oldest.
2) Investigate the export and creation to make sure we're not getting duplicate IDs somehow.
3) Possibly add more unit tests to simulate creation and id generation to assure this isn't a more common issue than expected.
Resolution: Modify import to validate IDs and not allow blank IDs. Generate a new ID if necessary.
What type of foundry hosting were you using?
No response
Relevant console log output
Contact Details
No response