Особенности статических методов
Основное отличие статических методов от методов экземпляра заключается в их привязке к классу, а не к отдельному объекту. Это означает, что их можно вызывать непосредственно через класс.
Статические методы не получают ссылку на экземпляр (self) или класс (cls) в качестве аргументов, что делает их независимыми от состояния объекта или класса. Следовательно, они не могут изменять состояние объекта или класса.
Существует дваосновных способа определения статического метода. Менее распространенный — назначение метода классу, используя функцию staticmethod для оборачивания исходного метода.
Однако более предпочтительным является использование staticmethod как декоратора, что упрощает объявление статических методов непосредственно внутри класса.
#python#staticmethod
#python
The Jelly Evolution Simulator is a program that lets you watch jelly-like creatures evolve over time. You can run it using a simple command in Python. The simulator allows you to control various features like closing the program, toggling markers, storing species, and changing colors. It also lets you scroll through different generations to see how the creatures change. This tool is useful for understanding how evolution works in a fun and interactive way. It helps users visualize how small changes can lead to different outcomes over time.
https://github.com/carykh/jes
Version 3.10 of the legendary programming language is now here: https://www.python.org/downloads/release/python-3100
No rush to update, though. #Python
#Python is the main language of data science, per this analysis on 10M Jupyter Notebooks: https://blog.jetbrains.com/datalore/2020/12/17/we-downloaded-10-000-000-jupyter-notebooks-from-github-this-is-what-we-learned/
📰 Feature freeze for Python 3.15 as first beta released
JIT compiler much improved, but no reinstatement for leaky incremental garbage collector.
🔗 Source: https://www.theregister.com/devops/2026/05/11/feature-freeze-for-python-315-as-first-beta-released/5237934
#python
📰 New Python Backdoor Uses Tunneling Service to Steal Browser and Cloud Credentials
Cybersecurity researchers have disclosed details of a stealthy Python-based backdoor framework called DEEP#DOOR that comes with capabilities to establish persistent access and harvest a wide range of sensitive information from compromised hosts."The intrusion chain begins with execution of a batch script ('install_obf.bat') that disables Windows security controls, dynamically extracts an.
🔗 Source: https://thehackernews.com/2026/04/new-python-backdoor-uses-tunneling.html
#python
📰 PyPI package with 1.1M monthly downloads hacked to push infostealer
An attacker pushed a malicious version of the popular elementary-data package Python Package Index (PyPI) to steal sensitive developer data and cryptocurrency wallets.
🔗 Source: https://www.bleepingcomputer.com/news/security/pypi-package-with-11m-monthly-downloads-hacked-to-push-infostealer/
#python