API Design: Lessons Learned
log in to bookmark this presentaton
Hear the story and principles behind the design of Python's "in" operator, the development of deques, and the evolution of the set API.
Examine the principles and story behind the development of the named tuple API. Learn about unforeseen use cases and a bug that made it to production.
Discuss the decimal module's API challenge -- adhering to a published standard. Talk about the Queue module's framework style and how the API was refactored.
Discuss what we've learned about naming functions and methods. Look at the i-naming convention in itertools, camelcase oddities, the proposed Italian name for enumerate, and vaguely named methods like assertItemsEqual.
Learn about Guido's ideas on when to add flags to method signatures. Recap his thoughts on the problems with the percent formatting operator. Then hear Raymond's advice on packaging, hierarchies, and nested name spaces.
See how to use documentation to mitigate API problems using examples from regular expressions, decimal, tokenize, sorting.