[bug] Verba saves data in XDG_DATA_HOME (not ~/.local/share/weaviate)
Description
Basically what the title says.
Is this a bug or a feature?
- [x] Bug
- [ ] Feature
Steps to Reproduce
- Install Verba (https://github.com/weaviate/Verba#how-to-deploy-with-pip)
- Start Verba (it will download weaviate-embedded)
- Configure it to use Ollama
- Import a document
- Many files and directories with "verba" in their names, among other files, will be created ~/.local/share (i.e. XDG_DATA_HOME), there is no ~/.local/share/weaviate as shown in README
Additional context
First of all, thank you a lot for developing, maintaining and providing the nice too as Open Source.
Environment:
- ArchLinux
- Pyhton 3.12
- I actually have XDG_DATA_HOME defined in the login shell, maybe it makes some difference in your code
Please feel free to ask for more info if needed.
Regards
Nice catch! Thanks, I'll update the README
@thomashacker Thank you for your reply. Actually, wouldn't it better to actually create a folder in XDG_HOME_DATA (i.e. ~/.local/share) and to store the files there? This is the normal and expected behavior (and the main issue here is not documentation or a request to update the README).
Thanks again. Regards.
Verba is using Weaviate Embedded (https://weaviate.io/developers/weaviate/installation/embedded) per default, if no Weaviate Cluster is detected in the .env file. Weaviate automatically checks the XDG_HOME_DATA variable to save the data if not specified otherwise. I think, in this case, improving the documentation will make it clearer for users
Sure, agreed. But from what I recall reading it:
- I does state that it would use weaviate-embedded if there is no other setup available (but indeed also adding the info that it will then be downloaded and installed locally would make it clear, and also let the user known that something else will be downloaded and installed automatically beforehand, what is always a good thing IMHO);
- It is using XDG_DATA_HOME (which is ~/.local/share if not state otherwise), but it is not using its own folder inside it as expected (and recommended).
Again, the main problem that I meant to report here is that all the files and folders are created inside XDG_DATA_HOME (or ~/.local/share) instead of creating a new folder there and then saving the working files inside this folder.
Or, in other others, it should save the files in ~/.local/share/weaviate (or $XDG_DATA_HOME/weaviate) as shown in the README, but it actually doesn't do it, so all the files and folders are scattered inside ~/.local/share.
I am sorry if this wasn't cleat before. Thank you again. Regards.
Good point! I'll look into documenting it better and fix the issue with data scattered inside $XDG_DATA_HOME