[Bug Fix] Fix FileExistsError when using Embedchain in multithreading setting (#1056)
This commit is contained in:
@@ -356,7 +356,7 @@ def deploy_render():
|
|||||||
console.print(f"❌ [bold red]An error occurred: {e}[/bold red]")
|
console.print(f"❌ [bold red]An error occurred: {e}[/bold red]")
|
||||||
except FileNotFoundError:
|
except FileNotFoundError:
|
||||||
console.print(
|
console.print(
|
||||||
"❌ [bold red]'render' command not found. Please ensure Render CLI is installed and in your PATH.[/bold red]"
|
"❌ [bold red]'render' command not found. Please ensure Render CLI is installed and in your PATH.[/bold red]" # noqa:E501
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -371,7 +371,7 @@ def deploy_gradio_app():
|
|||||||
console.print(f"❌ [bold red]An error occurred: {e}[/bold red]")
|
console.print(f"❌ [bold red]An error occurred: {e}[/bold red]")
|
||||||
except FileNotFoundError:
|
except FileNotFoundError:
|
||||||
console.print(
|
console.print(
|
||||||
"❌ [bold red]'gradio' command not found. Please ensure Gradio CLI is installed and in your PATH.[/bold red]"
|
"❌ [bold red]'gradio' command not found. Please ensure Gradio CLI is installed and in your PATH.[/bold red]" # noqa:E501
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -39,9 +39,7 @@ class Client:
|
|||||||
:return: user id
|
:return: user id
|
||||||
:rtype: str
|
:rtype: str
|
||||||
"""
|
"""
|
||||||
if not os.path.exists(CONFIG_DIR):
|
os.makedirs(CONFIG_DIR, exist_ok=True)
|
||||||
os.makedirs(CONFIG_DIR)
|
|
||||||
|
|
||||||
if os.path.exists(CONFIG_FILE):
|
if os.path.exists(CONFIG_FILE):
|
||||||
with open(CONFIG_FILE, "r") as f:
|
with open(CONFIG_FILE, "r") as f:
|
||||||
data = json.load(f)
|
data = json.load(f)
|
||||||
|
|||||||
@@ -39,9 +39,7 @@ class AnonymousTelemetry:
|
|||||||
posthog_logger.disabled = True
|
posthog_logger.disabled = True
|
||||||
|
|
||||||
def _get_user_id(self):
|
def _get_user_id(self):
|
||||||
if not os.path.exists(CONFIG_DIR):
|
os.makedirs(CONFIG_DIR, exist_ok=True)
|
||||||
os.makedirs(CONFIG_DIR)
|
|
||||||
|
|
||||||
if os.path.exists(CONFIG_FILE):
|
if os.path.exists(CONFIG_FILE):
|
||||||
with open(CONFIG_FILE, "r") as f:
|
with open(CONFIG_FILE, "r") as f:
|
||||||
data = json.load(f)
|
data = json.load(f)
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "embedchain"
|
name = "embedchain"
|
||||||
version = "0.1.42"
|
version = "0.1.43"
|
||||||
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