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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #424 · 13 апр.

Стандартная библиотека asyncio это стандарт (начиная с Py3.4) для работы с асинхронным кодом. Но эта библиотека достаточно низкоуровневая, со своими проблемами, устаревшими подходами. Чтобы исправить это, были созданы разные обертки и альтернативы с реализацией популярных инструментов и паттернов асинхронного программирования. Это такие библиотеки как: - trio: улучшает корректность выполнения, не оставляя потерянных корутин при ошибках, то есть предлагает Structured Concurrency из коробки. - curio: упрощение синтаксиса и читаемости кода, больше похоже на работу с потоками. - anyio: универсальная обертка над asyncio или trio плюс множество вспомогательных инструментов. anyio используется в FastAPI как основная библиотека для работы с асинхронным кодом и вызовом синхронного кода из асинхронного. В общем, рекомендую почитать про возможности anyio, возможно вы более не будете использовать чистый asyncio в своих проектах) Это совсем не значит что дефолтный asyncio плох, он тоже даёт достаточный для работы функционал и продолжает развиваться. Например, в версии 3.11 появились TaskGroup, с похожим на trio функционалом. Так что он тоже актуален, просто придется больше написать кода самостоятельно. #libs#async

Hashtags

Резултати

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

Пребарај: #positivity

当前筛选 #positivity清除筛选
Quiet World 🍁

@QuietWorld · Post #6627 · 02.10.2019 г., 03:53

It's an absolutely naive to say or think that humans are perpetually happy. Even the most positive person will meet his own dark side. Everyone has a shadow; toxic positivity is the recipe to create thick, dense shadow – because you must always wear the mask of happiness to hide other negative emotions and kick them into unconsciousness until it rots and fester into a monster that will come to the surface when you least expect it. Remember that positivity is not about pretending and not about happiness – it's a mindset; it's about assessing the situation, accepting and understanding your feelings and looking to see if there's anything you can do to make the most of the situation. 🤗 Source: Einzelganger & Positively Present #positivity#selfreminder @quietworld🍃

Quiet World 🍁

@QuietWorld · Post #7241 · 29.03.2020 г., 08:12

Today, Tomorrow or Yesterday? You can't avoid conflicts or problems. In fact, they're ESSENTIAL parts of life. Live today. If you worry about what may go wrong in the future, it might not even happen anyway 🤷🏻‍♀. If you keep on thinking about the past, there's no way to bring you back to the past🙍🏻‍♀. It's okay to look into the future to plan, but not okay to simply worry. It's okay to look back in the past and reflect, but it's not okay to stay stucked in the past. Live. Today. 😊 #life#reminder#positivity @quietworld🍃

Quiet World 🍁

@QuietWorld · Post #6626 · 02.10.2019 г., 03:53

"Positive vibes only 🌸" - oh really? good luck with that! I've been using the word positivity and shared lots of positivity quotes – little that I know that the word 'positivity' can mean differently to different people. So, if you haven't heard it yet, let me introduce you to Toxic Positivity – in which I've also been guilty of at times too🥺 Toxic positivity encourages ignoring negative emotions, but true positivity is about accepting all emotions and doing whatever is possible to work through them, understand them and garner more self-awareness. Toxic positivity presents itself as something anyone can do at any time, but positivity is actually a mindset that doesn't often come easily & must be worked at for most people - IT'S A SKILL. In short, toxic positivity is an attempt to force happiness by rejecting any form of undesirable aspect of an event - but be aware that rejecting either good or bad is similar to rejecting 50% of the universe, because the world isn't good vibes only, it's just vibes. I hope these provide you with a clear understanding of what is toxic positivity and what's true positivity is - and in case you need more clarity, I'd post a few more quotes related in my next posts. 😉 Source: Positively Present & Einzelganger #positivity#afterthoughts#selfreminder @quietworld🍃

12
ПретходнаСтраница 1 од 2Следна