typescript-client
typescript-client copied to clipboard
Warn when weaviate and/or client are outdated
Some users use very old versions of weaviate and client. We should warn them if it the minor version is 3 or more versions behind the last release.
Eg currently the last Weaviate version is 1.18.3, so we would warn users of 1.15 or below. We could do the same for the client versions.
Hi @dirkkul . Is this issue still open. If it is open, can i work on this issue ?
Hi, yes this is still open!
Here are the python PRs that implemeted that functionality: https://github.com/weaviate/weaviate-python-client/pull/343 https://github.com/weaviate/weaviate-python-client/pull/299
Please review
https://github.com/weaviate/typescript-client/pull/81
@Abhijithchintu, thanks for the contribution! https://github.com/weaviate/typescript-client/pull/81 is now merged, which covers warning for outdated Weaviate. Warning for an outdated client is still open, would you like to open a PR for that also?
Yes , i will work on warning for an outdated client. I have few doubts in that.
- how to fetch typescript client version
- Should we show the warning for client version (if applicable ) at the same time as weaviate version warning.
In the Python client, the version of the package is obtained here, this is then used here when instantiating a Connection object alongside the check for the Weaviate server version.
I would say we follow a similar logic for the TypeScript client so warn of outdated client in the same place as warning for outdated server. For retrieving the version, there are concerns in TypeScript around revealing the entire package.json file to the browser when this client is used in frontend apps. As such, the recommendation here should be followed.
This prebuild script will be used within other build, test, and package scripts to ensure the version is always up-to-date without compromising the security of the package.json file.