From fc855490cfa0a82386c931877c9094c3d87e6d90 Mon Sep 17 00:00:00 2001 From: Luke Murphy Date: Tue, 21 Jan 2020 00:30:04 +0100 Subject: [PATCH] Async create this directory too --- etherpump/commands/pull.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/etherpump/commands/pull.py b/etherpump/commands/pull.py index edbb2de..63325a4 100644 --- a/etherpump/commands/pull.py +++ b/etherpump/commands/pull.py @@ -284,7 +284,8 @@ async def handle_pad(args, padid, data, info, session): if args.all or (args.meta or args.text or args.html or args.dhtml): try: - os.makedirs(os.path.split(metapath)[0]) + path = trio.Path(os.path.split(metapath)[0]) + await path.mkdir() except OSError: pass