Follow-up of #201: We found out that fs.touch() will not work for any lakeFS server <1.3.1, since the backend had trouble with missing MIME types (see also https://github.com/treeverse/lakeFS/issues/7127).
We should raise an informative error in case any file system functionality is broken/unsupported for a backend version.
Motivation
Follow-up of #201: We found out that
fs.touch()
will not work for any lakeFS server <1.3.1, since the backend had trouble with missing MIME types (see also https://github.com/treeverse/lakeFS/issues/7127).We should raise an informative error in case any file system functionality is broken/unsupported for a backend version.
Requested solution
Load the client's
VersionConfig
(https://pydocs-sdk.lakefs.io/docs/InternalApi.html#get_lake_fs_version), parse it out, check against a minimum version and maybe raiseNotImplementedError
s if the server version is too old.Bonus: Cache the API response by host, so that multiple client requests can reuse the obtained value.