[issue44140] WeakKeyDictionary should support lookup by id instead of hash

2021-08-26 Thread Alessio Bogon
Change by Alessio Bogon : -- nosy: +youtux ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44140] WeakKeyDictionary should support lookup by id instead of hash

2021-06-23 Thread Andrei Kulakov
Andrei Kulakov added the comment: Josh: thanks for the explanation, this makes sense. -- ___ Python tracker ___ ___

[issue44140] WeakKeyDictionary should support lookup by id instead of hash

2021-06-23 Thread Josh Rosenberg
Josh Rosenberg added the comment: Andrei: If designed appropriately, a weakref callback attached to the actual object would delete the associated ID from the dictionary when the object was being deleted to avoid that problem. That's basically how WeakKeyDictionary works already; it doesn't

[issue44140] WeakKeyDictionary should support lookup by id instead of hash

2021-06-22 Thread Andrei Kulakov
Andrei Kulakov added the comment: Maybe I am misunderstanding, but if an object is deleted, and another object created with the same ID, wouldn't WeakRefDict now be pointing to the wrong object? -- nosy: +andrei.avk ___ Python tracker

[issue44140] WeakKeyDictionary should support lookup by id instead of hash

2021-05-21 Thread Brandt Bucher
Change by Brandt Bucher : -- nosy: +brandtbucher ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44140] WeakKeyDictionary should support lookup by id instead of hash

2021-05-15 Thread conchylicultor
New submission from conchylicultor : WeakKeyDictionary are great to "associate additional data with an object owned by other parts of an application", as quoted from the doc: https://docs.python.org/3/library/weakref.html#weakref.WeakKeyDictionary However, this currently only works for