llama-index-llms-openai 0.3.29__tar.gz → 0.3.30__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: llama-index-llms-openai
3
- Version: 0.3.29
3
+ Version: 0.3.30
4
4
  Summary: llama-index llms openai integration
5
5
  License: MIT
6
6
  Author: llama-index
@@ -1,4 +1,5 @@
1
1
  import functools
2
+ from json.decoder import JSONDecodeError
2
3
  from typing import (
3
4
  TYPE_CHECKING,
4
5
  Any,
@@ -979,7 +980,7 @@ class OpenAI(FunctionCallingLLM):
979
980
  # this should handle both complete and partial jsons
980
981
  try:
981
982
  argument_dict = parse_partial_json(tool_call.function.arguments)
982
- except ValueError:
983
+ except (ValueError, TypeError, JSONDecodeError):
983
984
  argument_dict = {}
984
985
 
985
986
  tool_selections.append(
@@ -28,7 +28,7 @@ exclude = ["**/BUILD"]
28
28
  license = "MIT"
29
29
  name = "llama-index-llms-openai"
30
30
  readme = "README.md"
31
- version = "0.3.29"
31
+ version = "0.3.30"
32
32
 
33
33
  [tool.poetry.dependencies]
34
34
  python = ">=3.9,<4.0"