Skip to content

Commit

Permalink
minor(_io): lint format
Browse files Browse the repository at this point in the history
  • Loading branch information
atomiechen committed Aug 5, 2024
1 parent e63c426 commit 4b0fdff
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/handyllm/_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,26 +25,31 @@ def yaml_dump(*args, **kwargs):
kwargs.setdefault("allow_unicode", True)
return yaml.dump(*args, **kwargs)


@wraps(yaml.safe_load)
def yaml_load(*args, **kwargs):
return yaml.safe_load(*args, **kwargs)


@wraps(json.dump)
def json_dump(*args, **kwargs):
kwargs.setdefault("ensure_ascii", False)
kwargs.setdefault("indent", 2)
return json.dump(*args, **kwargs)


@wraps(json.dumps)
def json_dumps(*args, **kwargs):
kwargs.setdefault("ensure_ascii", False)
kwargs.setdefault("indent", 2)
return json.dumps(*args, **kwargs)


@wraps(json.load)
def json_load(*args, **kwargs):
return json.load(*args, **kwargs)


@wraps(json.loads)
def json_loads(*args, **kwargs):
return json.loads(*args, **kwargs)

0 comments on commit 4b0fdff

Please sign in to comment.