Every so often a book comes along that makes you ask yourself, "Gee, when was the last time I had my eyes checked?" David M. Beazley's Essential Reference is just such a book. Condensing thousands of pages of Python online documentation into a compact 319-page softcover, Beazley and his editors used the old-college trick (often performed in reverse) of dickering with the font size to meet a putative page-limit requirement. The result is a truly condensed product fit for the occularly well-adjusted (nota bene). Beazley's subject is Python, a full-featured, freely-redistributable, POSIX-compliant (platforms include Linux, Unix, Macintosh, and Windows) scripting language that is based on object-oriented design principles. As advertised, Beazley's source release (1.5.2) is available from an unfortunately slow server at www.python.org. The installation under Linux (Redhat 5.2) proceeded without incident. Beazley holds true to his catalogic fully 230 pages are formatted as technical appendices and indices covering the standard built-in function syntax, database features, OS-level interfaces, Internet interfaces, and compiling/profiling/debugging. All references are fully annotated and illustrated with example source code that runs from a couple of lines to a couple of pages. In lock step with competing scripting languages, Python is extensible and embeddable in C and C++, and with blitzkrieg efficiency, Beazley summarizes these crucial practical issues in the final 30 pages. Python users who are tired of chasing questions through hyperlinked online documents will benefit from the expansive random-access index. Python the book captures the orderliness of Python the language. Beazley begins with an 86-page précis of Python in the fashion of Kernighan and too brief for a newbie tutorial but enough to propel old hands into a scripting language that aspires to the elegance of a compiled language. Indeed, it is a byte-compiling language. The line bytecode=compile("some_python_script",'','exec')) creates 'bytecode' as a token executed by exec bytecode. But a five-minute investigation through Beazley's book does not describe how 'bytecode' can be written into a separate executable file. If writing the byte-compiled code to a file is not possible, Python suffers from the limitations of other scripting the executable is the source and cannot be hidden from the user, at least not without some difficulty. Despite its extensibility, embeddability, and pleasing architecture, Python is like other scripting appropriate for solving small nonproprietary problems. Those familiar with more established scriptors like Perl may ask, "Why Python?" Unlike Perl, Python is a product of the fully object-oriented (OO) era, and its constructs reflect design principles that aspire beyond keystroke shortcuts of the succinct-but-often-arcane Perl. Python creator Guido van Rossum cleansed Perl's idiosyncracies and objectified basic data structure, data manipulations, and I/O. With Python, OO is so intrinsic that learning Python is equivalent to learning OO. The same cannot be said of Perl. Unfortunately, comparisons with other languages are missing from Beazley's book. Van Rossum, in an embarrassingly self-serving foreword, preemptively asserts that we readers need "neither evangelizing nor proselytizing"--after all, we already own the book--but we do need galvanizing and we don't find it. Specifically, we need a response to the oft-repeated wisdom that new computer languages are only worth learning if they teach us to organize our thinking along new lines. Scripting languages, however, are for quick and dirty quick to write, easy to hack, and ultimately disposable. The essential tension created by van Rossum and friends is between the elegance of object-oriented principles and the utility of a quick-hacked script. Sadly, the tension remains unresolved in Beazley's reference. There is little to convince us that Python has earned its place in the firmament by changing our thinking. But Beazley has given us much to get us going if we have already taken the leap of faith. --Peter Leopold
This book was pitched to me as something that answers typical Python questions faster than google and StackOverflow. Well, it's hard to beat google, but for a lot of the topics I found it to be best description out there (huge props for description of Unicode in Python).
It's first time I read language reference back to back - Python is big and I decided it's time to read about _all_ the features. I'm using Python for about two years now and every month or so I found an unexpected feature. This books provides a very decent coverage and makes it pretty fun to read about every single thing language offers.
And this is reference done right - doesn't try to cover every little detail, but all the important ones. When describing print, it'd be sure to mention how to make it not insert end of line. When describing metaclasses, it'd be sure to provide an example where they're useful.
I felt this was a painful, long read the first time through when I was trying to learn Python. I wanted to get things done asap. But reading this a 2nd time, it seems so much clearer. It has much excellent information and the organization is good. The prose is concise but not uselessly terse; and the examples are illustrative not long, tedious and noisy like in some other series. Probably wouldn't recommend to someone completely unfamiliar with Python as this is closer to a quick reference than a textbook.
I got a lot of sideways glances when I said I was going to schedule out time to read a "reference" manual from cover to cover. Being fairly new to the python language, this was well worth my time. The book will now be used as a reference! When the next version comes out I fully intend to take the time to go over it for things that have changed.
I feel like I really wasted my money on this book. I'm not even sure why it's need with the internet (and Stackoverflow) readily available. I would classify myself as an intermediate-level Python user, and this book is written over my head. I tried going to it at first, to get my money's worth, but I inevitably ended up searching online for better, more understandable answers.
I came to this book with a lot of programming experience in C, Delphi (object oriented), bash and perl, and I found it very frustrating. This is probably because I wanted a simple mapping of what I know to the python method for the same thing, and that is not what this book provides. After grinding through the entire thing, I felt that I was no wiser. However, to my surprise, some of what I read in the book did actually help me - things like knowing that everything in python is an object, the fact that functions get overloaded and similar have helped me to produce, lately, reams of unmaintainable python code, including choice phrases like lines=open('x','r').readlines(). If you are already using python, this might be a useful book for you, but I gave it away in disgust, and gave up on python until I discovered that you could do everything in a bash subshell with for line is os.popen("ps uaxwf",'r').readlines(): x=line.split(); if line.find("nobody")>=0: os.kill(int(x[1])); (or whatever).
Книга описывает возможности языка Python. Книга не является учебным пособием и предназначена для тех, кто уже знаком с программированием в целом и языком Python в частности. В первой части книги описываются общие возможности языка, синтаксис, структура программ и т.д. В воторой части подробно описываются наиболее используемые модули стандартной библиотеки. В заключительной части описываются возможности расширения с использованием языка C (в основном) и встраивения (вызова) кода Python в программах на языке C.
Описание возможностей сопровождается комментариями, рекомендациями (зачем сделано именно так и как лучше применять) и примерами. Прочтение книгу позволило получить обзорное представление возможностей библиотеки, увидеть/понять многие аспекты программирования на языке. Кроме того знакомство с библиотечными функциями и комментариями по использованию позволяют лучше понять, например, технику программирования с использованием асинхронных вызовов (select, сопрограммы и.д.) или даже работу операционных систем.
Perfect reference and great book for experienced programmers who want to learn Python. Lots of great concepts described like concurrent programming and quote deeply described standard Python library from working with strings to network APIs.
As its reference, its hard to read. But its worth it, Beazley spreads lots of spark ideas and insights along the way.
If you're a programmer fluent in another language this is a concise way to pick up Python. I find myself referring back to it occasionally to this day. Which means it either continues to be useful or I'm just darn forgetful.
Python docs can be a little daunting on the online site. This reference I keep right next to my laptop and anytime I don't fell like plowing through the library reference the python.org site, this has been coming in quite handy as a quick reference. Detailed, with sample code.
This is the best Python book I've seen so far. I'm an intermediate level Python hacker and I found this reference to be very helpful in explaining some of the more advanced python concepts such as decorators, object oriented programming, coroutines, etc.
My all-around favorite book on Python 2.7 programming, with most of it applying well to Python 3.x. See also “Fluent Python” to round out a Python education.
This book would not be appropriate for someone new to programming, but it does have a short introduction to python in the first chapter. Most of the book is devoted to the various library packages.