7.09.2025 состоялся релизPithon 3.14!
На фоне хайпа про NoGIL всё позабыли про другие фичи. Особенно про Multiple Interpreters, который обещает изоляцию процессов но с эффективностью потоков! На сколько действительно это будет эффективно мы узнаем позже, потому что сейчас это лишь первый релиз с ограничениями и недоработками.
Но что там про NoGIL? Теперь этот режим не экспериментальный, а официально поддерживаемый, но опциональный.
Чтобы запустить без GIL нужна специальная сборка. И перед стартом нужно объявить переменную PYTHON_GIL=0
Для вас я собрал готовый репозиторий где достаточно запустить скрпит, который всё сделает:
▫️ соберет релизный Python 3.14 в новый Docker-образ
▫️ запустит тесты в контейнере (GIL, NoGIL, MultiInterpreter)
▫️ распечатает результаты
Тест очень простой, усложняйте сами)
Вот какие результаты у меня:
=== Running ThreadPoolExecutor GIL ON
TOTAL TIME: 45.48 seconds
=== Running ThreadPoolExecutor GIL OFF
TOTAL TIME: 6.14 seconds
=== Running basic Thread GIL ON
TOTAL TIME: 45.54 seconds
=== Running basic Thread GIL OFF
TOTAL TIME: 4.74 seconds
=== Running with Multi Interpreter
TOTAL TIME: 18.30 seconds
Если сравнивать GIL и NoGIL, то на мои 32 ядра прирост х7-x10 (почему не х32? 🤷). При этом нам обещают что скорости будут расти с новыми релизами.
Режим без GIL похож (визуально) на async, тоже параллельно, тоже не по порядку. Но это не IO! и от того некоторый диссонанс в голове 😵💫, нас учили не так!
Интересно, что чистый Thread работает быстрей чем ThreadPoolExecutor без GIL.
Ну и где-то плачет один адепт мульти-интерпретаторов😭 Теперь нужно искать где они могут пригодиться с такой-то скоростью. Скорее всего своя область применения найдется.
Отдельно я затестил память и вот что вышло на 32 потока:
ThreadPoolExecutor GIL ON
305.228 MB
ThreadPoolExecutor GIL OFF
500.176 MB
basic Thread GIL ON
90.668 MB
basic Thread GIL OFF
472.444 MB
with Multi Interpreter
1267.788 MB
Пока не знаю как к этому относиться)
В целом - радует направление развития!
#release
#npm#nodejs#dasturlash_hayoti
NPM — paketlar, package.json va oddiy qo‘llanma
NPM — Node.js ekotizimidagi paketlar ombori va paket menejeri. package.json loyihaning “pasporti”.
Boshlash:
npm init -y # package.json yaratadi
npm install express # express o'rnatish (dependencies)
npm install -D nodemon # ishlab chiqishda dev dependency
package.json skript misoli:
"scripts": {
"start": "node index.js",
"dev": "nodemon index.js",
"test": "jest"
}
Eslatma:
◾️package-lock.json loyihaning qat’iy versiyalarini saqlaydi — uni gitga qo‘yish kerak.
◾️node_modules/➡️.gitignore ga qo‘ying (reponing ichiga kiritmang).
◾️npm audit bilan xavfsizlik tekshiruvini bajaring.
Maslahat:
◾️Kichik loyihalarda ham scripts dan foydalaning — bir buyruq bilan test, build va start qilinadi.
◾️Global o‘rniga lokal paketlarni afzal ko‘ring (-g dan saqlaning).
NPM bilan ishlashni o‘rganish — Node ekosistemida samarali bo‘lishning asosiy sharti.
Oramizda 📱Node.js ni biladiganlar bo'lsa reaksiya qoldiring 🔥
💻@dasturlash_hayoti— xatosiz kod bo‘lmaydi😅
THE COMPOSITION OF THE COORDINATING COUNCIL OF THE NPM AGAINST TORTURE UNDER THE COMMISSIONER FOR HUMAN RIGHTS IN THE REPUBLIC OF KAZAKHSTAN HAS BEEN UPDATED
July 26, 2022 – The next online meeting of the updated composition of the Coordinating Council of the National Preventive Mechanism against Torture (NPM) was held under the chairmanship of the Commissioner for Human Rights in the Republic of Kazakhstan Elvira Azimova.
The members of the Coordinating Council discussed issues of strengthening independent monitoring on the ground, interacting with the regional representative offices of the Commissioner, as well as participating in the discussion of draft laws on improving criminal and criminal procedure legislation, taking into account the recommendations of the NPM participants. Within two months, the presentation and discussion of the consolidated NPM report on the results of visits to social institutions, institutions where citizens are located by court decision or based on a verdict will take place. The presentation will be held with the invitation of local self-government bodies and central bodies, including the Prosecutor General's Office, which oversees compliance with the rule of law, representatives of public councils, and boards of trustees of institutions. During the presentation of the report, the participants will talk about the violations identified on the ground.
Updated composition of the Coordinating Council By the link: https://www.gov.kz/memleket/entities/ombudsman/press/news/details/401234?lang=ru
#Ombudsman#HumanRights#CoordinatingCouncil#NPM
https://www.gov.kz/memleket/entities/ombudsman/press/news/details/405528?lang=en
NEW MEMBERS OF THE COORDINATING COUNCIL OF THE NATIONAL PREVENTIVE MECHANISM HAVE BEEN ELECTED
On July 5, 2022, a meeting of the commission for the election of members of the Coordinating Council for the activities of the National Preventive Mechanism (NPM) was held.
The Commission under the Commissioner for Human Rights included: Deputy of the Senate of the Parliament of the Republic of Kazakhstan Nurlan Beknazarov, Deputy Prosecutor General of the Republic of Kazakhstan Asset Chindaliev, Head of the National Center for Human Rights Zere Utebayeva, Secretary of the Human Rights Commission under the President of the Republic of Kazakhstan Tastemir Abishev, Executive Director of the Charter for Human Rights Public Foundation Zhemis Turmagambetova, Director Kazakhstan International Bureau for Human Rights and Rule of Law Yevgeny Zhovtis, Commissioner for Children's Rights in Kazakhstan Aruzhan Sayn, Head of the Department of Effective Governance and Territorial Development of the United Nations Development Program in Kazakhstan Ainur Baymyrza, Director of the Center for Applied Research TALAP Rahim Oshakbayev.
According to the results of a secret ballot, 10 citizens of Kazakhstan were elected from among the citizens who submitted their applications for participation in the activities of the NPM for the prevention of torture and ill-treatment.
The updated list of members of the Coordinating Council will be available on the website of the Commissioner for Human Rights in the Republic of Kazakhstan at the link: https://www.gov.kz/memleket/entities/ombudsman/activities/1030?lang=ru.
#Ombudsman#HumanRights#CoordinatingCouncil#NPM
ОМБУДСМЕН И ПРАВОЗАЩИТНИКИ ОБСУДИЛИ КОНСТИТУЦИОННЫЕ ПОПРАВКИ, ВЫНОСИМЫЕ НА РЕСПУБЛИКАНСКИЙ РЕФЕРЕНДУМ
2 июня в формате онлайн состоялась дискуссия с участием Омбудсмена и участников Национального превентивного механизма в связи с конституционными поправками, выносимыми на республиканский референдум. Он пройдёт 5 июня 2022 года. Участники встречи обменялись мнениями по предлагаемым поправкам и предстоящей законотворческой работе по их реализации. Напомним, что принятие поправок в Конституцию повлечёт внесение изменений в действующие законы и принятие новых трёх конституционных законов - о Конституционном суде, прокуратуре и Уполномоченном по правам человека.
В ходе обсуждения правозащитники озвучили рекомендации по обеспечению эффективности предстоящего законотворческого процесса, широком обсуждении проектов законов, которые будут разработаны в реализацию конституционных поправок. Правозащитники обозначили основные моменты, на которые должны обратить внимание разработчики проектов законов, чтобы не допустить превышение полномочий со стороны государственных органов при реализации новых конституционных механизмов.
Участники встречи обменялись мнениями относительно принятого второго плана Правительства о дальнейших мерах в области прав человека и верховенства закона. Правозащитники предложили алгоритм действий, усиливающий новый механизм защиты конституционных прав и свобод граждан и выразили готовность участвовать в его разработке и обсуждении.
#ОмбудсменKZ#ПраваЧеловека#NPM#НПМ