Если запустить 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
🇺🇸🇮🇱⚔🇮🇷🛩️The Watchful Eye Over the Gulf
✍🏽By Red Nile Media | Geopolitical Analysis
A U.S. Navy MQ-4C Triton spy drone has been conducting high-altitude surveillance over the Persian Gulf and Strait of Hormuz, flying out of the UAE—a subtle but powerful signal amid rising U.S.–Iran tensions. Far from routine, this deployment follows a familiar escalation playbook: persistent intelligence gathering, psychological pressure, and strategic positioning that often precede larger moves.
🔹 Why the shift from Qatar to the UAE? What message is being sent to Tehran? And how does this fit into past confrontation patterns in the region?
🔗Read the full analysis:
📡@rednile12
Geopolitics | Multipolarity | Sovereignty | Strategic Reality
#Iran#USA#UAE#Qatar#PersianGulf#Geopolitics#MilitaryIntelligence#MiddleEast#RedSea#ISR#MQ4C#RedNileMedia
🇺🇸🇮🇱⚔🇮🇷🛩️The Watchful Eye Over the Gulf
✍🏽By Red Nile Media | Geopolitical Analysis
A U.S. Navy MQ-4C Triton spy drone has been conducting high-altitude surveillance over the Persian Gulf and Strait of Hormuz, flying out of the UAE—a subtle but powerful signal amid rising U.S.–Iran tensions. Far from routine, this deployment follows a familiar escalation playbook: persistent intelligence gathering, psychological pressure, and strategic positioning that often precede larger moves.
🔹 Why the shift from Qatar to the UAE? What message is being sent to Tehran? And how does this fit into past confrontation patterns in the region?
🔗Read the full analysis:
📡@rednile12
Geopolitics | Multipolarity | Sovereignty | Strategic Reality
#Iran#USA#UAE#Qatar#PersianGulf#Geopolitics#MilitaryIntelligence#MiddleEast#RedSea#ISR#MQ4C#RedNileMedia