#Asyncio

2025-06-11

Школы программирования против репетиторов и самообучения

Решил написать этот пост, т.к. несмотря на некоторое падение интереса к онлайн-обучению, каждый, кто решает освоить для себя новую профессию, сталкивается с выбором, куда направить усилия, а заодно и средства, чтобы это было с максимальной отдачей и не привело к выгоранию.

habr.com/ru/articles/917476/

#степик #онлайнкурсы #репетитор #django #fastapi #flask #aiogram #asyncio #основы_python #ооп_программирование

Rui Carmorcarmo
2025-05-30

Oh $DIVINITY, I wrote (ok, ported) a "plain" stdio to barebones , because, well, I was bored: github.com/rcarmo/umcp. (does sync and )

2025-05-26

Разработка Telegram-бота для мониторинга цен на Авито: пошаговое руководство

Привет, Хабр! Сегодня я расскажу о том, как я разработал Telegram-бота для мониторинга цен на Авито. Бот умеет отслеживать изменения цен в объявлениях и уведомлять пользователей об изменениях. В статье я поделюсь всеми этапами разработки, от проектирования до финальной реализации.

habr.com/ru/articles/912836/

#python #telegram #bot #авито #парсинг #мониторинг #asyncio

2025-05-16

One of the early asyncio implementations. #pyconus #asyncio

MC68B50S IC and a handwritten label reading asyncio
2025-05-01

HTTP/2 / HTTP/3 и gRPC на Rust: пишем учебный Mini-Transport

Статья-практикум показывает, как устроены HTTP/2, HTTP/3 (QUIC) и gRPC на самом низком уровне. Вместо толстых библиотек мы пишем минимальный учебный фреймворк «Mini-Transport» на Rust (~600 строк): реализуем кодек HTTP/2-фреймов, упрощённый gRPC-протокол и базовую обёртку над QUIC. В результате получаем рабочий echo-клиент и сервер, которые пересылают «hello ↔ world» через собственноручно собранные фреймы. Разбор сопровождается поясняющими схемами, ссылками на RFC, вариантами дальнейшего развития (HPACK, flow-control, TLS/ALPN) и готовым репозиторием для самостоятельных экспериментов. Материал рассчитан на разработчиков, желающих понять «как всё крутится под капотом» и прокачать навыки низкоуровневой сетевой работы в Rust.

habr.com/ru/articles/906324/

#http2 #rust #http3 #quic #grpc #asyncio #tokio

OmarEbnElKhattab Hosneyhosney@me.dm
2025-04-23

🚀 Boost Python Efficiency with asyncio

Synchronous: Toast 🥪 → wait → Coffee ☕ → wait → Eat.

Asynchronous: Start Toast 🍞 & Coffee ☕ → Fry Eggs 🍳 → Eat sooner!

Python's asyncio lets you run tasks concurrently, reducing wait times.

Key Terms:

Event Loop: Task scheduler.

await: Pause & switch tasks.

Coroutines: Async functions.

#Python #Asyncio #AsynchronousProgramming

medium.com/@omkamal/a-beginner

2025-04-17

Thanks to months of consistent contributions by
@lysnikolaou, all of the mandatory @aio_libs dependencies of #aiohttp now ship free-threaded variants of #wheels!

This unblocks doing the same in aiohttp eventually!

Find a minute to thank him, will you?

#aio_libs #Python #Packaging #asyncio

2025-04-08

kitfucoda.medium.com/concurren

Concurrency and parallelism are often confused in async programming discussions. Go's goroutines highlighted the difference: concurrency is doing many things at once, while parallelism is doing many things at the same time.

AsyncIO handles concurrency well for I/O, but CPU-bound tasks need parallelism. Python uses AsyncIO for concurrency, and ProcessPoolExecutor for parallelism, distributing work across CPU cores.

Process communication is harder than thread communication. AsyncIO's task cancellation differs from ProcessPoolExecutor's, requiring workarounds like event objects for reliable cancellation and shutdown.

Essentially, ProcessPoolExecutor enables parallelism for CPU-bound tasks, scaling them across multiple cores, while AsyncIO handles I/O concurrently.

#python #asyncio #concurrency #parallelism #multiprocessing #opentowork #getfedihired #fedihire #opentowork

2025-04-01

kitfucoda.medium.com/asyncio-t

Just finished a deep dive into AsyncIO, building an asynchronous task scheduler! It's been a fascinating exploration of tasks, futures, and how to manage both I/O and CPU-bound operations. Real-world examples like API data fetching and complex calculations were used to demonstrate its capabilities.

Covered task management essentials: cancellation, graceful shutdowns, and building a CLI for interactive control. Tackled tricky AsyncIO parts like error and signal handling, ensuring the scheduler's robustness.

A key focus was on asyncio.create_task() vs. await, and strategies for managing background tasks and uncaught exceptions. It was a great learning experience.

If you're into Python and asynchronous programming, this might be of interest! #Python #AsyncIO #AsynchronousProgramming #TaskScheduling #getfedihired #fedihire #opentowork

2025-03-31

Параллельные вычисления, конкурентность и асинхронное программирование в Python: обзор для начинающих

Однопоточные приложения на Python ограничены в производительности: они выполняют задачи последовательно и не используют преимущества многоядерных процессоров. Кроме того, такие программы не справляются с обработкой множества операций одновременно, особенно если речь идет о задачах, связанных с вводом-выводом, например сетевыми запросами или чтением файлов. Производительность можно значительно улучшить, внедрив в код параллельные вычисления, конкурентность или асинхронное программирование. Для этого Python предлагает такие инструменты, как multiprocessing, threading и asyncio.

habr.com/ru/companies/skillfac

#python #multiprocessing #asyncio #threading

2025-03-31

Как нам удалось упростить жизнь инженера-сметчика и сократить время на разработку сметы в 20 раз

Если вы инженер-сметчик, то наверняка знаете, что такое ежедневная работа с огромными таблицами и бесконечными спецификациями. Кто-то, возможно, уже смирился с монотонностью, а кто-то разработал свои лайфхаки для ускорения обработки данных. Но сегодня расскажем о новом подходе, который помог нам упростить процесс составления сметы на монтаж системы вентиляции. С чего все начиналось: с типичного дня сметчика Однажды мне поставили задачу — подготовить сметы для нового объекта, включая раздел вентиляции. Как многие сметчики знают, вентиляция — это один из самых трудоемких разделов.

habr.com/ru/articles/896046/

#process_tasks #pandas #asyncio #math

2025-03-25

kitfucoda.medium.com/understan

Diving deep into Python's AsyncIO this week. Awaitables are the heart of it - coroutines, tasks, and futures. Coroutines, defined with async def, need the event loop to run. Tasks give us control over coroutine execution. Futures hold the results of async operations.

Interestingly, while Python uses coroutines, JavaScript relies on Promises. Yet, both leverage await to manage asynchronous flow. Understanding await across these languages provides valuable insights into the core principles of asynchronous programming.

#python #asyncio #programming #softwaredevelopment #opentowork #getfedihired

2025-03-10

Под чешуёй асинхронности: from yield to await

В данной статье мы рассмотрим основы асинхронного программирования в python, фокусируясь на ключевых концепциях и их практическом применении. Мы начнем с изучения генераторов и итераторов — фундаментальных механизмов, лежащих в основе асинхронности python. Затем поговорим о потоках и процессах, чтобы понять, как они соотносятся с асинхронным подходом. Основная цель статьи — создание собственной упрощенной реализации asyncio, включая цикл событий, задачи и примитивы синхронизации. Это позволит глубже понять внутреннее устройство асинхронной разработки в python.

habr.com/ru/articles/889490/

#асинхронность #генераторы #итераторы #python #cpython #gaio #asyncio

2025-03-05

kitfucoda.medium.com/writing-a

I've just finished writing up a deep dive into building a Telegram bot with a FastAPI web application, and it was quite the journey into asynchronous Python! 🐍

The project started with a desire to run chatbots across multiple platforms, but quickly evolved into a focused exploration of asyncio. I found myself wrestling with event loops, queues, and the nuances of asyncio.create_task vs. asyncio.to_thread. It became very clear that understanding the difference between concurrency and parallelism is absolutely crucial in this space. Clever scheduling can mitigate blocking, but over-scheduling will inevitably lead to performance issues.

Architectural considerations became a major focus. I learned firsthand that cramming everything into a single process, while tempting, isn't always the best approach. Separating processes for scalability and future enhancements is something I'll definitely keep in mind for future projects.

This project was a great learning experience, and I'm looking forward to applying these lessons to future projects. If you're interested in asyncio, webhooks, or building chatbots, I'd love to hear your thoughts!
#python #asyncio #telegrambot #fastapi #webdevelopment #programming #opentowork #fedihire

Augier (fr & en) 🇵🇸🇺🇦☭🏴AugierLe42e@diaspodon.fr
2025-02-24

Does someone knows a good #Python #asyncio shutil alternative? I want to be able to copy entire filesystem trees while tracking and displaying progress and not code this by hand.

Edit: I'll also accept D-Bus APIs like Udisks2, but Udisks2 doesn't seem to provide this feature.

Edit 2: anything like an easy-to-use wrapper around something like rsync is fine too, as long as I still get to track and report progress.

2025-02-11

To me it seems that user-level threads (like async in C#) and system-level threads are mostly an implementation distinction, a distinction that shouldn't permeate the language as it tends to do.

Isn't his whole 'blocking vs async' duality is ridiculous if you think about it? In both cases, you wait for something to happen. For a high-level language, by what mechanism that waiting happens can be a runtime concern and exposed through common abstractions (e.g. for futures).

#programming #asyncio

2025-02-05

Как оптимизировать производительность API при высокой нагрузке

В статье мы рассмотрим основные подходы и практики для оптимизации производительности API, применяемые в

habr.com/ru/companies/exolve/a

#zabbix_мониторинг #производительность #logstash #микросервисная_архитектура #redis #rabbitmq #оптимизация_кода #асинхронность #asyncio #nosql

2025-02-03

Phenomenal article about Python's long trek from generators to async/await, with examples.
tenthousandmeters.com/blog/pyt

#Python #asyncio

2025-01-28

Concurrency testing — отлавливаем состояния гонки

В статье разберём некоторые техники обнаружения плавающих багов, вызванных конкурентностью. Сделаем подход к автоматическому тестированию устойчивости веб-сервисов к различным race condition. Примеры будут на python + asyncio + sqlalchemy, но эти подходы применимы к любым моделям конкурентности, которые подвержены состояниям гонки.

habr.com/ru/companies/tochka/a

#race_condition #python #asyncio #fuzzing #testing

Client Info

Server: https://mastodon.social
Version: 2025.04
Repository: https://github.com/cyevgeniy/lmst