You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using Minisearch in my app, which was published about a year or two ago. I just made an update of the app a few days ago, updating Minisearch to version 5.0.0, everything works fine however, I notice users get this error...
Fatal Exception: com.facebook.react.common.JavascriptException: Error: MiniSearch: cannot deserialize an index created with an incompatible version
...when using the old index from the old version of my app, in the updated version of my app. Is there a way I can obtain the version of Minisearch from it's instance, so that I can make a new index when the conditions require it. Or maybe you have a better solution? Thank you for your time and help!
The text was updated successfully, but these errors were encountered:
Hi @oiver555 ,
MiniSearch follows semantic versioning: breaking changes are only introduced with major releases. In other words, as long as the first version number does not change (the x in x.y.z), you can safely upgrade. A common strategy to avoid bad surprises when updating is to pin the major version of the library in your package.json, by specifying your dependency as "minisearch": "^6.3.0". This will update MiniSearch automatically to any new minor or patch version, but not if the major version changes (so you can perform the major updates manually when you are ready, checking the CHANGELOG for breaking changes and how to deal with them).
MiniSearch also tries to avoid breaking changes to the serialization format, even upon major version changes. So far, version 4.0.0 is the only one that introduced a breaking change in the serialization format.
That said, it might be useful to obtain the current version from the MiniSearch instance, as you propose. I will look into it for the next update.
I'm using Minisearch in my app, which was published about a year or two ago. I just made an update of the app a few days ago, updating Minisearch to version 5.0.0, everything works fine however, I notice users get this error...
Fatal Exception: com.facebook.react.common.JavascriptException: Error: MiniSearch: cannot deserialize an index created with an incompatible version
...when using the old index from the old version of my app, in the updated version of my app. Is there a way I can obtain the version of Minisearch from it's instance, so that I can make a new index when the conditions require it. Or maybe you have a better solution? Thank you for your time and help!
The text was updated successfully, but these errors were encountered: