See the warning below. Also: - The code does work regardless. - A non-static method within the same class didn't generate such a warning. - System info: PyCharm 2024.1.3, python 3.12, Win10 