[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Python3 - How do I import a class from another file

Am 11.12.2019 11:22 schrieb R.Wieser:

> I think I will just go out on a limb and just assume that the __del__ 
> method
> /will/ be called as part of a "del instance" request causing the 
> reference
> count to reach zero (directly or indirectly), before the next command 
> is
> executed [...].

That's what I take the word "when" to mean in the documentation:

"Note: del x doesn?t directly call x.__del__() ? the former decrements 
the reference count for x by one, and the latter is only called when x?s 
reference count reaches zero."