TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #401 · 15 дек.

Функция asyncio.wait() это еще один способ вызвать множество асинхронных задач. Она работает в нескольких режимах. 1. Самый простой - ждем завершения всех задач async def main(): tasks = [asyncio.create_task(do_it(i)) for i in range(10)] done, pending = await asyncio.wait( tasks, return_when=asyncio.ALL_COMPLETED ) for task in done: try: print(task.result()) except Exception as e: print(e) Очень похоже на gather, но работает не так. ▫️возвращает не результаты, а два сета с объектами Task у которых можно забрать результат через task.result() если они в списке done ▫️не гарантирует порядок результатов так как оба объекта это set ▫️не выбрасывает исключение когда оно появляется, а сохраняет его в Task. Исключение появится когда попробуете забрать резултьтат. 2. Ждем завершения первой задачи, даже если там ошибка. async def main(): tasks = [asyncio.create_task(do_it(i)) for i in range(3)] done, pending = await asyncio.wait( tasks, return_when=asyncio.FIRST_COMPLETED ) # в done может быть несколько задач! for task in done: try: print(task.result()) except Exception as e: print(f"Fail: {e}") # Оставшиеся задачи в pending, как правило, нужно отменить, иначе они будут продолжать работать for task in pending: task.cancel() В сете done будут таски которые успели завершится, причем как успешно так и нет. 3. До первой ошибки. Тоже самое, но с аргументом FIRST_EXCEPTION done, pending = await asyncio.wait( tasks, return_when=asyncio.FIRST_EXCEPTION ) Функция завершается как только первая задача упадет с ошибкой. Учтите, что в любом случае done вы можете обранужить несколько задач, как с ошибками так и успешные. ↗️ Полный листинг примеров здесь #async

Hashtags

Резултати

Пронајдени 5 слични објави

Пребарај: #cannabis

当前筛选 #cannabis清除筛选
Il valore della giustizia⚖️

@giurisprudentia · Post #354 · 23.11.2021 г., 13:01

#CANNABIS Il Parlamento israeliano ha approvato nella lettura preliminare una proposta di legge (presentata da Sharren Haskel, di New Hope) volta a riformare l’industria della cannabis medica, estendendo le possibilità di un suo utilizzo. Nello specifico, in assenza della maggioranza sufficiente per poter approvare una normativa finalizzata alla de-penalizzazione del suo utilizzo a scopo ricreativo, si ambisce a realizzare alcune innovazioni in materia: chi otterrà la licenza da parte del Ministero della Salute sarà legalmente autorizzato a coltivare, distribuire e possedere la cannabis a scopi medici. Adesso, la proposta sarà sottoposta ad una Commissione parlamentare, che la preparerà per la prima lettura nello Knesset. 👉@giurisprudentia

Hashtags

America 🇺🇸 News & Politics

@America · Post #10545 · 23.04.2026 г., 16:04

🌿🇺🇸TRUMP FAST-TRACKS MEDICAL MARIJUANA RESCHEDULING 🔹 Executive order directs Attorney General to expedite rescheduling from dangerous Schedule I to Schedule III classification 📋⚡ 🔹 Over $30,000 in criminal penalties reduced to civil fines for possession under 1 ounce 💰 🔹 $43,000 average savings per patient annually on medical cannabis costs with insurance coverage 💊💸 🔹 38 states already have medical programs — federal reform finally catching up to reality 🗺️ This policy shift could reshape American healthcare and criminal justice forever 🔥 #USNews#cannabis ✨ More breaking stories coming soon 🚀 @america

Ultimora.net - POLITICS

@ULTIMORAPOLITICS · Post #41988 · 26.10.2022 г., 12:04

#Germania ❗️ Via libera del governo federale tedesco al documento con le linee guida sulla legalizzazione della #cannabis. Il piano, che deve ancora essere trasformato in proposta di legge e votato dal Parlamento, punta a regolare il consumo e la produzione di cannabis, depenalizzando anche l’uso personale ricreativo entro i 30 grammi @UltimoraPolitics

Venture Village Wall 🦄

@venturevillagewall · Post #3397 · 18.12.2024 г., 12:10

Standard Wellness Secures $10M Funding Standard Wellness has successfully raised $10 million in funding as of December 17, 2024. The company is dedicated to enhancing quality of life by providing safe and easy access to cannabis. #Funding#Cannabis#Healthcare#QualityOfLife#Investment#StandardWellness#Capital#Access#Wellness#Health

Venture Village Wall 🦄

@venturevillagewall · Post #3704 · 24.12.2024 г., 14:37

Latest Funding Rounds News Recent funding highlights include: - Universal Matter: $20M raised on Dec 16, 2024. Visit - InterCure: $18.20M on Dec 20, 2024. A leading cannabis company. Visit - Atmo: $17.58M on Dec 20, 2024, developing AI-based meteorology systems. Visit - Sitemate: $17.20M on Dec 23, 2024, simplifying industrial workflows. Visit - Meddipay: $15M on Dec 17, 2024, in health and wellness payment facilitation. Visit - SignalRank Corporation: $11.55M on Dec 21, 2024, focusing on private market investments. Visit - Usual Labs: $10M on Dec 23, 2024, transforming tokenized assets into stablecoins. Visit - Tracer Biotechnologies: $10M on Dec 12, 2024, innovating in ctDNA assays. Visit - Stipple Bio: $9.48M on Dec 20, 2024, enhancing cellular profiling. Visit - Mindgard: $8M on Dec 20, 2024, securing AI systems. Visit #Funding#UniversalMatter#InterCure#Atmo#Sitemate#Meddipay#SignalRank#UsualLabs#TracerBiotechnologies#StippleBio#Mindgard#Cannabis#AI#Technology#Health#Wellness#Software#Investments#Startups#Finance#Innovation