I received a review copy of Mark Pilgrim’s updated Dive Into Python 3_ back in early November, but with the various holidays and end-of-year activities I didn’t have a chance to read it until the past week or so. I’m glad I waited until I had the time to sit down and look over it carefully, because there is a lot of good material here!
Disclaimer: The review copy was free.
Disclosure: I received a copy of this book for free from the publisher as part of the PyATL Book Club.
The goal of Citizen Engineer, from Prentice Hall/Pearson Education, is to awaken the socially responsible engineer in each of us. The topics covered range from the environmental impact of product design to the sociopolitical ramifications of intellectual property law. Authors David Douglas (Senior VP of Cloud Computing, Sun), Greg Papadopoulos (CTO and Executive VP of R&D, Sun), and John Boutelle (freelance writer) share their experience in all of these areas to create a thought-provoking introductory guide to the issues of modern engineering practice.
Optimizing repetitive operations is one of my obsessions. I can’t stand following long sequences of steps to make the computer do what I want. The whole point of computers is to have them do more work for us, right?
As a developer with several ongoing projects, I frequently find myself switching contexts as one project becomes blocked (read: I lose interest) and I want to move on another. Typically that means unloading a bunch of files from my editor and loading others.
A friend of mine recently found an old floppy disk created under OS 8 or 9 in the early 1990’s. There was a letter on the disk that she wanted copied off, but she doesn’t have a Mac any more.
No problem, I figured. I did a little research and found hfsutils, and thought all I would need to do is stick the disk in my Linux box and grab the files.
Earlier today I mentioned on twitter that I was making chili and several people asked for the recipe. I make a variation of “Gilroy Chili” from The Garlic Lovers’ Cookbook, put together by the organizers of the Gilroy Garlic Festival in Gilroy, CA. My wife and I picked up copies of volumes I and II not long after we were married and have several favorite recipes from each.
The original recipe is from David B.
plistlib provides an interface for working with property list files used under OS X. plist files are typically XML, sometimes compressed. They are used by the operating system and applications to store preferences or other configuration settings. The contents are usually structured as a dictionary containing key value pairs of basic built-in types (unicode strings, integers, dates, etc.). Values can also be nested data structures such as other dictionaries or lists.
Most Python programs end up as a combination of several modules with a main application importing them. Whether you are using the features of the standard library, or organizing your own code in separate files to make it easier to maintain, understanding and managing the dependencies for your program is an important aspect of development. sys includes information about the modules available to your application, either as built-ins or after being imported.
I have a couple of different thumb drives that I use as portable working devices. The data on them is important, so I wanted to back them up. Today I worked out how to copy the contents of the USB drive to a folder on my hard drive every time the USB drive is inserted into the computer.
The two technologies I used to accomplish this are Folder Actions and AppleScript.
There are two ways to inject code to watch your program run: tracing and profiling. They are similar, but intended for different purposes and so have different constraints. The easiest, but least efficient, way to monitor your program is through a trace hook, which can be used for writing a debugger, code coverage monitoring, or many other purposes.
Read more at pymotw.com: sys