Rarity

Rarity

17M Downloads

At least one Export String that was generated by Rarity cannot be imported again

rdw-software opened this issue ยท 0 comments

commented

While writing some documentation for the export system, I noticed something peculiar:

I originally imported a string from wowhead comments. This worked perfectly and I was able to use it ingame. However, I now used the same item for the documentation example, but after exporting it the generated string was very different.

Import String:

AzX7Af8CagrZJmU2qXITSH4BqW9Q7RTtRbsF9gPxk1QYBhlHaSgFDZaK4YIOkpKOSc4ptVCqLCWlWkxKWS5VPSSVPFX1GKjnKk0kBVNJTFZiOtVFUqnfSrpMdJ1CbYTSYcBmKD5LpY+kxHlS1DTFaZKWgZ4RRpOqxpOKTlLULYpcE7pHgZWkyFpS6LaKWVT4qstzqTCLCt81h5JvVnSD4h/p+uvCT0NdfKkzXPvOHl91ecwLs3BU1vID4Eh+D+gH/wJYTy4gnR7QBemsGJCOlnVdLt/VI4mdCK1oMeI4EkiIRoxJbH4Qgi8VZjErwinBhMyKAjbBFMyKcKoxh1kRThUzMivCqWE2Zo0Vu5g4syaKaUzLrLFiQ+ZmVoRTkM5f/wKXlwoTotrIIkGF7+qRxFpkmyjb7KCGkIDEmAbxAXd5Qr9MYSOdCVFtZNFQ4bt6JLE43gTcG28IoVgQEWMawQfc5Qn9Mvem0/lgfSD/AkvmbpZ/5b3qGlDhu3oksTiKMyUsxGGEEA4xphk+4C5P6Jc5RecD7vKEfpljh07nX7Ub/wJu3Jd87VgzNNQwRjqMNKEMvGsOwKA1ajUw4GszVvUWZtuITgI=

Export String:

AzWcBP8CalFkG1WzQdVNKiW/qFT6pspOlb1ot6j2q0p+igLDSOMEQ0VRg1VFwyk6CArHlM4JLQSVpaLEYgosp6CHVCqeAsskz6FMpFJqKhWTKTSduEil6DeVPBO5ripslKppis1SeQxKH6lUOS8KfQZF16RchhwGGa0qNZ5KVSdFqVuq6jRU90RJK6kU1oqCblOaS4f/AhdkMTq8pUOA3DddhkI4AngIExgiyJqC8ZRAcIvYv6CzQZ9uSO+lYvenSJCbsBgd3vK21WziFW9bKp94ibetZj1veNtqdnmNt61mh+d5OyHF5T3eTkvjeYG3E1IsXuRtq9miEMB+Qzks4kUfCCARZE3BeKkVAcohA3hkJByBZDQRQbbjplsEKIcM4BGMPHd95LDIolwwwhHg1nQZCg0IOtdHbqQBQQ5ZRP8CBxnmECw8Mn59wkEwvz5d3deney6XESPABdlsI2+fbggEFsm3y0hwmd0h+HbB40YoYxZk8dyIDAlHYIQEYXR4paU6unQIBLeIfdOYNGltCGniNHb/ARQBJIKsKRivAoVXWqqzjw6B4BaxD61FbS3qm2kzyu6fRP8CiSBrCsZrkcIr3ahBEx0CwS1iHzT4tMGHUa+ait0/Sv8CiSBrCsZLoVF4pRs16NAhENwi9u/5VDE+r6ptS9n9kwggEWRNwXgxUnilpTrr6RAIbhF7Xy/upBd0/KZddv8BNAJIBFlTMN4WhVdaqiktHQLBLWLvN8QN+1LU570+dv8BFAEkgqwpGO9FCq+0VEc9HQLBLeItASSCrCkYbyi80lIdDXQIBLeIfWi+vMZWUSt4Dez+eQSQCLKmYLz1FF5pqY4OHQLBLWIfXr3S0lrfgq/E7p8hgESQNQXjzVJ4paU6q3QIBLeI/fMtpVjtPR/XT2D3zxBAIsiagvG2UXilpTpbdAgEt4i9b6Vb22ZCfN43dv8BNAJIBFlTMN5GCq+0VGcTHQLBLWLv1/uduD5OfDEMu38SASSCrCkYbwKFV1qqU0uHQHCL2Ps0aWKL8elu9I/dP0P/AokgawrGq0DhlZZqUE+HQHCLeEX/AokgawrGSxQKhUKA4TBzSD4MEUGWPrsyuz2ZMsjkhl4uMLNzWHczhJE1K4HBBw5v5CmFBA==

It's obvious both aren't the same. And what's worse, the second one - the one I actually exported ingame - is apparently invalid, or at least it can't be imported again. I deleted the original item to make sure it's not just a misleading error message, to no effect.

I remember that when Allara was still maintaining the addon, I encountered an issue with the export system that would basically render it broken. IIRC Allara used Lua's "#" operator to count the number of contained items and it would always return nil since it can only count the array part of a table. This should have been fixed, however. Also, it wouldn't explain why the Export String is much larger. I suspect too much or invalid data is being encoded instead.

To be determined:

  • Is this the same issue cropping up again, or something completely different? (Review SVN history from 2016 or so?)
  • Can it be reproduced with arbitrary items? (Have to test ingame)
  • Maybe the Export String includes data that it shouldn't, possibly some that we added retroactively and that wasn't originally there when the export system was first designed? (Refactor the export/import logic and unit test it?)