[Python-Dev] Aaron Hall, Introduction and pull-request bump

Aaron Hall aaronchall at yahoo.com
Mon Sep 11 22:17:45 EDT 2017


Hi there,
I have had the privilege of getting to know some core developers at PyCon in Portland, and I've met some others through my volunteering at PyGotham and the NYC Python meetup group (resisting urge to name-drop). 
In spite of not joining the mailing list until about a week ago at Brett Cannon's suggestion, I have managed to submit 3 bug-report fixes, with 1 closed by pull-request, 1 nearly closed with the pull-request accepted, and 1 with the pull request not yet accepted (looks like there's a conflict in misc/NEWS now, not sure how to use Github to resolve it either). That last pull request is here: bpo-26103 resolve Data descriptor contradiction by aaronchall · Pull Request #1959 · python/cpython - probably good if


|  |  | 
bpo-26103 resolve Data descriptor contr...
 |


I also had a "MutableNamedTuple" implementation I put on codereview.stackexchange.com (https://codereview.stackexchange.com/q/173045/23451) and Ashwini Chaudhury gave me some excellent pointers, and inspired by the recent discussion on "Data Classes" I now have a half-baked implementation that leverages __slots__ with a Mapping, for example (from a unittest, hence the indentation):
        class MNTDemo(MutableNamedTuple):
            "Demo"
            __slots__ = {
                'arg0': arg(),
                'arg1': arg(typing.List),
                'kwarg': arg(default=0), # must be positional if passed *args
                'args': arg(stars=Stars.ARGS),
                # everything after *args must be keyword argument
                'kwarg1': arg(list, []), 
                'kwarg2': None,
                'kwargs': arg(typing.Any, stars=Stars.KWARGS) 
                }
        mnt = MNTDemo(1, 2, 3, 'stararg1',
                      kwarg1=1, kwarg2=2, kwarg3=3)
Maybe there's a nicer way to do it, but arg is a function returning a namedtuple (attrs: type, default, stars) with some defaults. It allows the __init__ to have required positional arguments and required named arguments, pretty much as flexible as a regular function signature, but communicated via __slots__. And thanks to the slots, they're every bit as performant as a namedtuple, I presume (I gave the __slots__ talk at PyCon).
Anyways, to wrap up my introduction, I'm a moderator on StackOverflow (https://stackoverflow.com/users/541136/aaron-hall?tab=profile) and nearly about to catch Raymond in reputation points, mostly due to Python, I'm currently teaching Python at NYU (Introduction to Programming), and I'm an all-around Python evangelist (as much as I know how to be.) I owe a lot to the Python community, especially the meetup community in NYC, but also virtual community (Ned Batchelder in IRC comes to mind). 
Thank you for everything, I'm looking for my chance to give back!
Cheers, 
Aaron Hall
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20170912/3e33a585/attachment.html>


More information about the Python-Dev mailing list