Skip to content

Commit

Permalink
Merge pull request #459 from parea-ai/fix-formatting-target
Browse files Browse the repository at this point in the history
fix: prettify json dumps
  • Loading branch information
joschkabraun committed Feb 14, 2024
2 parents fbb7979 + 8a4ebf8 commit ed51034
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions parea/utils/universal_encoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,5 +78,5 @@ def default(self, obj: Any):
return super().default(obj)


def json_dumps(obj, **kwargs):
return json.dumps(obj, cls=UniversalEncoder, **kwargs)
def json_dumps(obj, **kwargs) -> str:
return json.dumps(obj, cls=UniversalEncoder, **kwargs) if not isinstance(obj, str) else obj
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "parea-ai"
packages = [{ include = "parea" }]
version = "0.2.71"
version = "0.2.72"
description = "Parea python sdk"
readme = "README.md"
authors = ["joel-parea-ai <[email protected]>"]
Expand Down

0 comments on commit ed51034

Please sign in to comment.