擅长:python、mysql、java
<p>我将忽略这个设计中令人质疑的地方,而将重点放在所提供代码中的错误上</p>
<p><code>AttributeError</code>是由<code>{self}</code>引起的:</p>
<pre><code>super().__init__({self}, owner)
</code></pre>
<p>这将尝试在完全初始化之前获取<code>self</code>的哈希值</p>
<p>将<code>{self}</code>替换为<code>[self]</code>,代码就可以正常运行了</p>