[BugFix] Skip checking thread when making sqlite connection (#978)
This commit is contained in:
@@ -2,7 +2,8 @@ from typing import Optional
|
|||||||
|
|
||||||
import yaml
|
import yaml
|
||||||
|
|
||||||
from embedchain.config import AppConfig, BaseEmbedderConfig, BaseLlmConfig, ChunkerConfig
|
from embedchain.config import (AppConfig, BaseEmbedderConfig, BaseLlmConfig,
|
||||||
|
ChunkerConfig)
|
||||||
from embedchain.config.vectordb.base import BaseVectorDbConfig
|
from embedchain.config.vectordb.base import BaseVectorDbConfig
|
||||||
from embedchain.embedchain import EmbedChain
|
from embedchain.embedchain import EmbedChain
|
||||||
from embedchain.embedder.base import BaseEmbedder
|
from embedchain.embedder.base import BaseEmbedder
|
||||||
|
|||||||
@@ -16,7 +16,8 @@ from embedchain.embedder.base import BaseEmbedder
|
|||||||
from embedchain.helpers.json_serializable import JSONSerializable
|
from embedchain.helpers.json_serializable import JSONSerializable
|
||||||
from embedchain.llm.base import BaseLlm
|
from embedchain.llm.base import BaseLlm
|
||||||
from embedchain.loaders.base_loader import BaseLoader
|
from embedchain.loaders.base_loader import BaseLoader
|
||||||
from embedchain.models.data_type import DataType, DirectDataType, IndirectDataType, SpecialDataType
|
from embedchain.models.data_type import (DataType, DirectDataType,
|
||||||
|
IndirectDataType, SpecialDataType)
|
||||||
from embedchain.telemetry.posthog import AnonymousTelemetry
|
from embedchain.telemetry.posthog import AnonymousTelemetry
|
||||||
from embedchain.utils import detect_datatype, is_valid_json_string
|
from embedchain.utils import detect_datatype, is_valid_json_string
|
||||||
from embedchain.vectordb.base import BaseVectorDB
|
from embedchain.vectordb.base import BaseVectorDB
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ CHAT_MESSAGE_CREATE_TABLE_QUERY = """
|
|||||||
|
|
||||||
class ECChatMemory:
|
class ECChatMemory:
|
||||||
def __init__(self) -> None:
|
def __init__(self) -> None:
|
||||||
with sqlite3.connect(SQLITE_PATH) as self.connection:
|
with sqlite3.connect(SQLITE_PATH, check_same_thread=False) as self.connection:
|
||||||
self.cursor = self.connection.cursor()
|
self.cursor = self.connection.cursor()
|
||||||
|
|
||||||
self.cursor.execute(CHAT_MESSAGE_CREATE_TABLE_QUERY)
|
self.cursor.execute(CHAT_MESSAGE_CREATE_TABLE_QUERY)
|
||||||
|
|||||||
@@ -23,7 +23,6 @@ from embedchain.utils import validate_yaml_config
|
|||||||
from embedchain.vectordb.base import BaseVectorDB
|
from embedchain.vectordb.base import BaseVectorDB
|
||||||
from embedchain.vectordb.chroma import ChromaDB
|
from embedchain.vectordb.chroma import ChromaDB
|
||||||
|
|
||||||
|
|
||||||
# Setup the user directory if doesn't exist already
|
# Setup the user directory if doesn't exist already
|
||||||
Client.setup_dir()
|
Client.setup_dir()
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "embedchain"
|
name = "embedchain"
|
||||||
version = "0.1.21"
|
version = "0.1.22"
|
||||||
description = "Data platform for LLMs - Load, index, retrieve and sync any unstructured data"
|
description = "Data platform for LLMs - Load, index, retrieve and sync any unstructured data"
|
||||||
authors = [
|
authors = [
|
||||||
"Taranjeet Singh <taranjeet@embedchain.ai>",
|
"Taranjeet Singh <taranjeet@embedchain.ai>",
|
||||||
|
|||||||
Reference in New Issue
Block a user