kuzudb / explorer

Browser-based user interface for Kùzu graph database
https://hub.docker.com/r/kuzudb/explorer
MIT License
29 stars 5 forks source link

Display better error message when DB storage version doesn't align with Explorer's expectations #166

Closed prrao87 closed 1 month ago

prrao87 commented 1 month ago

If a user is trying to access a dev version of a Kùzu database whose storage version isn't compatible with the release build of Kùzu Explorer, the UI doesn't show a helpful error message. AN example is shown below:

[21:26:57.994] INFO (1): Access mode: READ_WRITE [21:26:58.019] ERROR (1): Error getting version of Kùzu: Error: std::bad_alloc

We should show a more helpful error message, similar to how we do in our CLI to inform the user that they should use a format of Kùzu that's compatible with the database storage version.

mewim commented 1 month ago

Explorer itself has the correct infrastructure to handle a storage version mismatch, as shown below:

Screenshot 2024-07-08 at 8 52 12 AM

However, I think the issue was that the dev builds do not actively maintain the storage version number. The storage version number is defined at: https://github.com/kuzudb/kuzu/blob/9df0a994535829df598dbfdf135795513554850c/src/include/storage/storage_version_info.h#L15-L20

For each stable release, we manually update this dictionary to add the version number of kuzu and storage. But since each dev build is automatically built and deployed, it does not get its own storage version number. Instead, it simply assumes that it has the latest storage version number in the dictionary.

prrao87 commented 1 month ago

BTW, Paco faced the exact same issue yesterday, so it's clear that we have to document this on our Kùzu Explorer page so that people know that the dev build doesn't have version numbers. I'll track this as an issue there.