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

Резултати

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

Пребарај: #democratic

当前筛选 #democratic清除筛选
Embassy of Russia in Singapore

@rusembsg · Post #3846 · 10.02.2025 г., 03:34

On the occasion of the Russian #DiplomatsDay (February 10) we would like to tell you about the Contribution of Soviet Diplomacy to the Establishment of the #UN Key points: - At the #Moscow Conference of the Ministers of Foreign Affairs of the USSR, USA, Great Britain and China in October 1943, the #Soviet delegation put forward a proposal to establish a universal international organization. - The first draft of the #UNCharter was developed at a conference convened at the suggestion of the #USSR in Dumbarton Oaks (#USA) from September 21 to October 7, 1944. At this forum, representatives of the USSR, the USA, #GreatBritain and #China agreed on the goals, structure and functions of the world organization. The Soviet delegation consistently and resolutely advocated that the activities of this organization be based on democratic principles. - At the #Crimea (Yalta) Conference of the leaders of the great powers, which took place from 4 to 11 February 1945, participants agreed upon the issues of the initial members of the organization and the voting procedure in the Security Council, as well as on issues related to the maintenance of international peace and security, the development of economic relations, cooperation in the social, technical and other areas of interstate relations. - On April 25 – June 26, 1945, the founding conference of the United Nations was held in #SanFrancisco. The Soviet delegation sought to ensure that the #democratic principles of the structure and activities of the UN were enshrined in the Charter. - Based on Soviet amendments, important new provisions were included in the chapter on the purposes and principles of the UN, stating that peaceful settlement of international disputes should be carried out "in accordance with the principles of justice and international law"; that friendly relations between nations should develop "on the basis of respect for the principle of equal rights and self-determination of peoples"; that international cooperation in resolving international problems of an economic, social, cultural and humanitarian nature should be carried out "and in promoting and encouraging respect for human rights and for fundamental freedoms for all without distinction as to race, sex, language or religion...". - On June 26, 1945, the UN Charter was signed by A.A. Gromyko, then the Soviet Ambassador to the USA, thanks to whose personal participation and persistence the final documents related to the creation of the UN recorded positions largely corresponding to the interests of the Soviet Union. Full article: https://telegra.ph/te4st-02-10