Если запустить REPL с модулем asyncio, то вы входите в особый асинхронный REPL.
user@host:~$ python -m asyncio
asyncio REPL 3.12.7 ...
Use "await" directly instead of "asyncio.run()".
>>> import asyncio
>>>
В этом режиме
- создаётся и настраивается event loop
- уже импортирован asyncio
- работает await на верхнем уровне
То есть такая команда сработает без ошибок!
await asyncio.sleep(3)
Удобно для тестирования асинхронных функций без создания ивентлупов и остальной обвязки.
Работает в: 3.8+
#tricks#async
🔥#Coinbase secretly submitted documents to the #CFTC for listing of futures regulated in the USA for #Dogecoin, #Litecoin and #BitcoinCash
It's already April 1st!! 🚀
The first step towards launching futures ETFs for these altcoins
📌 CFTC approval is not required for listing commodity futures for $LTC, $DOGE and $BCH — as the "self-certification" method is used (paragraph 40.2A)
📰#iXDailyBrief
STAT
⚡️ Think consumers are apathetic to data misuse? Think again. 56% of people say they would stop buying from a business that mishandles their data, and 79% of people say they would tell friends and family to boycott an organisation based on data misuse (Source: Veritas)
INSIGHT
📱 A majority of Americans use #Facebook and #YouTube, but young adults are especially heavy users of #Snapchat and #Instagram: prs.pctvix.co/2KPK3Is
OTHER NEWS
💵#Revolut adds #Ripple and #BitcoinCash support: prs.pctvix.co/2GLXDKr
🐦#Twitter looks to woo smaller, Facebook-frustrated publishers with new site: prs.pctvix.co/2KRewFY
😂 Federal judge rules that #Trump can't block Twitter users: t.me/iXNews/25922
🚙#Apple reportedly partnering with Volkswagen to make self-driving employee shuttles: t.me/iXNews/25952
—
Do you have a #Telegram channel? Check this out: prs.pctvix.co/2kkLaVq
Have a great Thursday!
Ben, @iXNews