[Twisted-Python] [ANN] thimble 0.1.0
Glyph
glyph at twistedmatrix.com
Tue May 20 02:37:37 MDT 2014
On May 19, 2014, at 2:29 AM, Laurens Van Houtven <_ at lvh.io> wrote:
> On Mon, May 19, 2014 at 12:19 AM, Glyph <glyph at twistedmatrix.com> wrote:
> I think this is the sort of thing that should move into Twisted itself, eventually. Thoughts?
>
> I agree! There's a few things I'd like to work out with the freedom to break things of a v0.x.x semver version before that happens though.
Oh, definitely. Hence: eventually.
> Notably, this thing assumes that all attribute accesses are thread-safe and synchronous. That's often true, but hey, this is Python, so you get to do whatever you want when you access an attribute (and @property even makes it easy to do so). Also because right now I'm suggesting a pool with a singled thread for synchronized access to an object that isn't thread safe; especially if you *know* the object isn't thread safe you probably want something to take care of attribute access too :-)
Just write a decorator that programmatically verifies that everything about the attribute it's decorating is thread-safe. Simple! ;-)
-g
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/twisted-python/attachments/20140520/4ec1a3b0/attachment-0002.html>
More information about the Twisted-Python
mailing list