薄片 8 和 "old style class declaration"

flake8 and "old style class declaration"

我使用 flake8 检查我的 python3 脚本的格式。当我这样声明 类 时...

class MyClass:

...我收到警告 "H238 -- old style class declaration, use new style (inherit from object)"。

然而,文档显然有这样的声明:https://docs.python.org/3/tutorial/classes.html#class-definition-syntax

我认为从 object 继承看起来不必要地混乱。它在功能上有什么不同吗?该文档没有说明从 object.

继承的任何内容

这是 flake8 的错误,还是我只是遗漏了一些明显的东西?

documentation says:

It is very important to install Flake8 on the correct version of Python for your needs. If you want Flake8 to properly parse new language features in Python 3.5 (for example), you need it to be installed on 3.5 for Flake8 to understand those features. In many ways, Flake8 is tied to the version of Python on which it runs.