18 lines
374 B
Python
18 lines
374 B
Python
import aiohttp
|
|
import pytz
|
|
import datetime
|
|
|
|
from settings import TIMEZONE, ORDER_TIME
|
|
|
|
def make_session():
|
|
return aiohttp.ClientSession()
|
|
|
|
def order_time():
|
|
tz = pytz.timezone(TIMEZONE)
|
|
|
|
order_time_arr = list(map(int, ORDER_TIME.split(':')))
|
|
return datetime.time(
|
|
hour=order_time_arr[0],
|
|
minute=order_time_arr[1],
|
|
tzinfo=tz
|
|
)
|