What is Nostr?
Glyph /
npub1h5u…y2g4
2023-07-10 22:53:24

Glyph on Nostr: Here's a puzzle: Let's say we have a bunch of different kinds of object that exist in ...

Here's a puzzle:

Let's say we have a bunch of different kinds of object that exist in some long-lived context, like a server-side physics sim or a GUI. They have attributes. We *want* to model them as such, not stringly-typed config, because they're data structures with types & behavior.

How to implement generic change notifications without inheriting an implementation of __setattr__ or something morally equivalent?

This is the final frontier of composition-over-inheritance for me.

#python
Author Public Key
npub1h5u94g9409m9c6yrckcwk9lg4c6sexyvvk23p0s7s3f42lhrs7zq75y2g4