style: format code with linter

This commit is contained in:
Paul Gauthier (aider) 2024-08-22 09:42:05 -07:00
parent 905cbc377d
commit f2fa99b79f

View file

@ -7,6 +7,7 @@ import sys
from aider.coders.base_coder import all_fences from aider.coders.base_coder import all_fences
from aider.coders.editblock_coder import find_original_update_blocks from aider.coders.editblock_coder import find_original_update_blocks
def process_markdown(filename, fh): def process_markdown(filename, fh):
try: try:
with open(filename, "r") as file: with open(filename, "r") as file:
@ -60,6 +61,10 @@ def process_markdown(filename, fh):
if __name__ == "__main__": if __name__ == "__main__":
if len(sys.argv) != 2: if len(sys.argv) != 2:
print(json.dumps({"error": "Usage: python testsr.py <markdown_filename>"}, indent=4), file=sys.stdout, flush=True) print(
json.dumps({"error": "Usage: python testsr.py <markdown_filename>"}, indent=4),
file=sys.stdout,
flush=True,
)
else: else:
process_markdown(sys.argv[1], sys.stdout) process_markdown(sys.argv[1], sys.stdout)