Skip to content

Commit

Permalink
fix jsonalyze query engine
Browse files Browse the repository at this point in the history
  • Loading branch information
logan-markewich committed Mar 1, 2024
1 parent 45801ac commit 0b4b6c3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def default_jsonalyzer(
try:
# Load list of dictionaries into SQLite database
db[table_name].insert_all(list_of_dict)
except sqlite_utils.db_exceptions.IntegrityError as exc:
except sqlite_utils.utils.sqlite3.IntegrityError as exc:
print_text(f"Error inserting into table {table_name}, expected format:")
print_text("[{col1: val1, col2: val2, ...}, ...]")
raise ValueError("Invalid list_of_dict") from exc
Expand All @@ -105,7 +105,7 @@ def default_jsonalyzer(
try:
# Execute the SQL query
results = list(db.query(sql_query))
except sqlite_utils.db_exceptions.OperationalError as exc:
except sqlite_utils.utils.sqlite3.OperationalError as exc:
print_text(f"Error executing query: {sql_query}")
raise ValueError("Invalid query") from exc

Expand Down Expand Up @@ -148,7 +148,7 @@ async def async_default_jsonalyzer(
try:
# Load list of dictionaries into SQLite database
db[table_name].insert_all(list_of_dict)
except sqlite_utils.db_exceptions.IntegrityError as exc:
except sqlite_utils.utils.sqlite3.IntegrityError as exc:
print_text(f"Error inserting into table {table_name}, expected format:")
print_text("[{col1: val1, col2: val2, ...}, ...]")
raise ValueError("Invalid list_of_dict") from exc
Expand All @@ -173,7 +173,7 @@ async def async_default_jsonalyzer(
try:
# Execute the SQL query
results = list(db.query(sql_query))
except sqlite_utils.db_exceptions.OperationalError as exc:
except sqlite_utils.utils.sqlite3.OperationalError as exc:
print_text(f"Error executing query: {sql_query}")
raise ValueError("Invalid query") from exc

Expand Down
2 changes: 1 addition & 1 deletion llama-index-core/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ name = "llama-index-core"
packages = [{include = "llama_index"}]
readme = "README.md"
repository = "https://github.com/run-llama/llama_index"
version = "0.10.14"
version = "0.10.14.post1"

[tool.poetry.dependencies]
SQLAlchemy = {extras = ["asyncio"], version = ">=1.4.49"}
Expand Down

0 comments on commit 0b4b6c3

Please sign in to comment.