rti / gbnc

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Bug]: [EmbeddingDE] docker run produces ImportError: 'send_event' & 'haystack.telemetry'

exowanderer opened this issue · comments

In Branch: feature/EmbeddingDE

After introducing the new FAISSDoctumentStore (for sqlite) and jina.ai embedding for DE+EN embedding, the docker run began to flag the error:

ImportError: cannot import name 'send_event' from 'haystack.telemetry'

This error started early in the process, but could not discover how or why.

Following the guidance from deepset-ai/haystack#6652, I began to turn off farm-haystack features and/or haystack-ai in the Dockerfile.

Later, I attempted to forcibly install Python3.8 or Python.3.9 -- both suggest by the Haystack:Issue:6652 above.

These solutions may still exist, but my implementation did not fix the error.

I have been communicating with the devs about the send_message in haystack.telemetry bug Haystack's GitHub Issues.

After I gave them the relevant section of our Dockerfile, they realised that we are simultaneously using Haystack 1.x and Haystack 2.0 Beta, causing ImportErrors.

In particular, haystack-ai is Haystack 2.0-beta and farm-haystack is Haystack 1.x. I think that ollama-haystack is also Haystack 2.0 Beta.

For testing, I removed haystack-ai completely from the Dockerfile. I am now working through the usual bugs related to changing import versions. Haystack 2.0 does not seem to have an EmbeddingDocumentStore,. From what I can tell, 2.0Beta only has InMemoryDocumentStore.

Solved via Deepset.ai GitHub Issue: ImportError: cannot import name 'send_event' from 'haystack.telemetry' #6652.

We were blending Haystack 1.x and 2.0beta. We had to re-write a few things and only use Haystack 2.0beta with ollama.

As a result of that issue, we can now only use InMemoryDocumentStore instead of FAISSDocumentStore. As such, we don't see the option to store the embeddings in an SQL db or FAISS index.

All the same, the code works and follows our requirements. Maybe we don't need to the other bells and whistles.