Python metaclasses
ivansmirnov.io
Python metaclasses
1–10 of 30 posts
Re: Python metaclasses
#2Another loosely related suggestion: if we could stay away from singleton as examples, I think we would save ourselves a lot of future troubles. ^^
Re: Python metaclasses
#3Can anyone maybe suggest a few examples of where this could be used (or is used already?)
Re: Python metaclasses
#4Great tool, but not to be put in the wrong hands. The folks at Django got it right. We used it for unifying, simplifying and ensuring consistency of deeply nested configuration data entered using different means. However, in environment with less experience, I have seen "Akira-final-scene-tetsuo" monsters come to life with this. Another loosely related suggestion: if we could stay away from singleton as examples, I t…
Re: Python metaclasses
#5This is an interesting and fairly well explained post, but a little light on real world examples. Can anyone maybe suggest a few examples of where this could be used (or is used already?)
Re: Python metaclasses
#6This is an interesting and fairly well explained post, but a little light on real world examples. Can anyone maybe suggest a few examples of where this could be used (or is used already?)
http://ivansmirnov.io/python-metaclasses/#metaclass-as-a-reg...
This enables things like plugin systems, where you want the act of importing a plugin which defines some objects to load those objects into the available plugin list.
Re: Python metaclasses
#7This is an interesting and fairly well explained post, but a little light on real world examples. Can anyone maybe suggest a few examples of where this could be used (or is used already?)
https://github.com/bkeroack/elita/blob/27129ea64382275effa99...
https://github.com/bkeroack/elita/blob/27129ea64382275effa99...
Re: Python metaclasses
#8This is an interesting and fairly well explained post, but a little light on real world examples. Can anyone maybe suggest a few examples of where this could be used (or is used already?)
It's a very powerful language feature. Also very dangerous. It's a magnet for technical debt and obscure bugs.
Re: Python metaclasses
#9This is an interesting and fairly well explained post, but a little light on real world examples. Can anyone maybe suggest a few examples of where this could be used (or is used already?)
Re: Python metaclasses
#10This is an interesting and fairly well explained post, but a little light on real world examples. Can anyone maybe suggest a few examples of where this could be used (or is used already?)