Commit 3f2513ec authored by Eliot Berriot's avatar Eliot Berriot 💬

Revert "Faster CLI startup time by moving aiohttp import to runtime"

This reverts commit fe55ed80.
parent fe55ed80
Pipeline #4595 passed with stages
in 2 minutes and 16 seconds
import aiohttp
from . import exceptions
from . import schemas
from . import settings
def get_session_kwargs():
import aiohttp
headers = {"User-Agent": settings.USER_AGENT}
return {
"timeout": aiohttp.ClientTimeout(total=settings.TIMEOUT),
......@@ -14,8 +14,6 @@ def get_session_kwargs():
def get_session():
import aiohttp
kwargs = get_session_kwargs()
return aiohttp.ClientSession(**kwargs)
import asyncio
import aiohttp
import click
import click_log
import dotenv
......@@ -109,7 +110,6 @@ def env_file(v):
def async_command(f):
def wrapper(*args, **kwargs):
import aiohttp
loop = asyncio.get_event_loop()
_async_reraise = kwargs.pop("_async_reraise", False)
import os
import pathlib
import aiohttp
import click
import tqdm
......@@ -69,8 +70,6 @@ async def get_track_download_url(id, remote, format=None):
async def track_download(
ctx, id, format, directory, template, overwrite, ignore_errors, skip_existing
import aiohttp
async with ctx.obj["remote"]:
progressbar = tqdm.tqdm(id, unit="Files")
for i in progressbar:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment