J. Burton Browning and Marty Alchin
Pro Python 3Features and Tools for Professional Development3rd ed.
J. Burton Browning
Oak Island, NC, USA
Marty Alchin
Agoura Hills, CA, USA
ISBN 978-1-4842-4384-8e-ISBN 978-1-4842-4385-5
Library of Congress Control Number: 2019936454
© J. Burton Browning and Marty Alchin 2019
This work is subject to copyright. All rights are reserved by the Publisher, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting, reproduction on microfilms or in any other physical way, and transmission or information storage and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodology now known or hereafter developed.
Trademarked names, logos, and images may appear in this book. Rather than use a trademark symbol with every occurrence of a trademarked name, logo, or image we use the names, logos, and images only in an editorial fashion and to the benefit of the trademark owner, with no intention of infringement of the trademark. The use in this publication of trade names, trademarks, service marks, and similar terms, even if they are not identified as such, is not to be taken as an expression of opinion as to whether or not they are subject to proprietary rights.
While the advice and information in this book are believed to be true and accurate at the date of publication, neither the authors nor the editors nor the publisher can accept any legal responsibility for any errors or omissions that may be made. The publisher makes no warranty, express or implied, with respect to the material contained herein.
Distributed to the book trade worldwide by Springer Science+Business Media New York, 233 Spring Street, 6th Floor, New York, NY 10013. Phone 1-800-SPRINGER, fax (201) 348-4505, e-mail [email protected], or visit www.springeronline.com. Apress Media, LLC is a California LLC and the sole member (owner) is Springer Science + Business Media Finance Inc (SSBM Finance Inc). SSBM Finance Inc is a Delaware corporation.

This edition is dedicated to Champion Suyaki Mamma Mia of Misibo and her sister Champion Sienna of Olympia of Misibo, two of the best Siamese cats who ever owned me.

Introduction
This third edition expands on Marty’s original work. Found in each chapter of this third edition are useful libraries that any Python programmer will find of value. Use what you learn for your own projects and enjoyment!

J. Burton Browning

When I wrote my first book, Pro Django , I didn’t have much of an idea what my readers would find interesting. I had gained a lot of information I thought would be useful for others to learn, but I didn’t really know what would be the most valuable thing they’d take away. As it turned out, in nearly 300 pages, the most popular chapter in the book barely mentioned Django at all. It was about Python.

The response was overwhelming. There was clearly a desire to learn more about how to go from a simple Python application to a detailed framework like Django. It’s all Python code, but it can be hard to understand based on even a reasonably thorough understanding of the language. The tools and techniques involved require some extra knowledge that you might not run into in general use.

This gave me a new goal with Pro Python : to take you from proficient to professional. Being a true professional requires more experience than you can get from a book, but I want to at least give you the tools you’ll need. Combined with the rich philosophy of the Python community, you’ll find plenty of information to take your code to the next level.

Marty Alchin

Who This Book Is For

The goal is to bring intermediate programmers to a more advanced level; we wrote this book with the expectation that you’ll already be familiar with Python on some basic level. You should be comfortable using the interactive interpreter, writing control structures, and [using] a basic object-oriented approach.

That’s not a very difficult prerequisite. If you’ve tried your hand at writing a Python application—even if you haven’t released it into the wild, or even finished it—you likely have all the necessary knowledge to get started. The rest of the information you’ll need is contained in these pages.

Acknowledgments
This third edition covers some exciting library features available in the Python 3 language. Try the samples and expand on your own projects with what you learn. Do not be afraid to experiment and have fun!

J. Burton Browning

I wouldn’t have even started this project if not for the endless encouragement from my lovely wife, Angel. She’s been my sounding board, my task manager, my copyeditor, and my own personal cheerleader. There’s no way I could do anything like this without her help and support.

I’d also like to thank my technical reviewer, George, for everything he’s done to help me out. He’s gone above and beyond the limits of his role, helping with everything from code to grammar and even a good bit of style. After enjoying his help on Pro Django , I wouldn’t have even signed on for another book without him by my side.

Lastly, I never would’ve considered a book like this if not for the wonderful community around Python. The willingness of Python programmers to open their minds and their code is, I believe, unrivaled among our peers. It’s this spirit of openness that encourages me every day, leading me to discover new things and push myself beyond the limits of what I knew yesterday.

We learn by doing and by seeing what others have done. I hope that you’ll take the contents of this book and do more with it than what I’ve done. There’s no better reward for all this hard work than to see better programmers writing better code.

Marty Alchin

Table of Contents

Index 449

About the Authors and About the Technical Reviewer

About the Authors

J. Burton Browning

earned his doctorate from North Carolina State University. He has conducted research in areas including distance learning, programming, and instructional technology. As a lifelong learner and someone who has interests in topics such as programming, photography, robotics, car restoration, woodworking, hunting, reading, fishing, and archery, he is never at a loss for something to do. The art and joy of serving as a professor suits his inquisitive nature. Dr. Browning’s previous publications include works on Cross-Functional Learning Teams (CFLT), the Utopian School (teacher-led school model), computer programming (several languages), open-source software, healthcare statistics and data mining, CNC plasma cutter operation, educational technology, biography, mobile learning, online teaching, and more.

 
Marty Alchin

By day, Marty Alchin works as a senior software engineer at Heroku, and after that, he writes and codes for fun and community. His blog can be found at http://martyalchin.com and he has profiles on many other services under the name Gulopine. In particular, his code can be found on GitHub and his random thoughts are on Twitter. He also accepts tips for his open source work at https://gittip.com/gulopine .

 

About the Technical Reviewer

Michael Thomas
../images/330715_3_En_BookFrontmatter_Figb_HTML.jpg

has worked in software development for over 20 years as an individual contributor, team lead, program manager, and vice president of engineering. Michael has over 10 years of experience working with mobile devices. His current focus is in the medical sector, using mobile devices to accelerate information transfer between patients and healthcare providers.

 
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset