George V. Reilly

Python f-strings

At this month’s PuPPy (Puget Sound Pro­gram­ming Python) Meetup, I heard a brief mention of Python f-strings as a new feature coming in Python 3.6.

In essence, they offer a simpler, more versatile method of string formatting and in­ter­po­la­tion over existing methods. F-strings can include not only symbol names but Python ex­pres­sions within strings. With str.format, you can write 'Hello, {name}'.format(name=some_name). You can control various aspects of how name is formatted, such as being centered within a field—see PyFormat and Python String Format Cookbook for ex­am­ples—but no more complex expression is allowed between the braces.

Herewith some examples of f-string ex­pres­sions drawn from PEP 0498:

>>> date = datetime.date(1991, 10, 12)
>>> f'{date} was on a {date:%A}'
'1991-10-12 was 
continue.

Dark Chocolate Gelato-Buttermilk Milkshakes

For the CookBrite holiday party this evening, we selected recipes from the CookBrite app and cooked them for each other.

We had a lot of good food. I par­tic­u­lar­ly enjoyed making and drinking these milkshakes.

In­gre­di­ents

In­struc­tions

Cooking time: 12 minutes

Adapted from Twenty-Dollar, Twenty-Minute Meals, Caroline Wright

Christmas Cards

It seems old-fashioned to do so, but I still like to send and to receive Christmas cards. We wrote 30 cards last weekend. Almost all were Wondermark Multi-Purpose Greeting Cards, from a Kick­starter that Emma con­tributed to a few months ago.

Speaking of Kick­starters, No Holds Bard showed up in my Facebook feed today. I was so tickled by the concept that I anted up $10. I’ve read several novels where Will Shake­speare was a character, such as Ink and Steel and Revenger, but never a comic book where he was a superhero.

Yesterday, we started receiving cards from other people. A couple of dozen more will follow.

Painting the Bar Room

Two weeks ago, we painted the kitchen blue. A deeper blue than I had intended. It had more than a little bit of the Greek taverna about it.

Today, we started work on the "bar room", the room between the kitchen and the back yard, where we keep the booze. No painting yet. We’ve taken everything out of that room and cleaned. Fifteen years of cobwebs have been removed from behind the book cases.

Soon, a lighter blue.

Review: Legend

Tom Hardy has had a very good year, starring in Mad Max: Fury Road and playing both Reggie and Ronnie Kray in Legend.

Legend loving recreates London in the Swinging Sixties when the Kray twins were not only notorious gangsters but also celebri­ties, mingling with the rich and famous in their nightclubs. Reggie is portrayed as the smarter, charming, and stable brother; Ronnie as erratic and psy­cho­pathic; both are capable of great violence. The film is narrated from beyond the grave by Reggie’s wife, Frances, and con­cen­trates mostly on Reggie. Hardy is excellent as Reggie, but hard to understand as Ronnie, while Emily Browning does a fine job as the young wife who’s continue.

Christmas Movies: Die Hard

We have three non-tra­di­tion­al Christmas movies that we watch almost every December, Die Hard, Die Hard 2: Die Harder, and The Ref.

Die Hards 1 and 2 are the best in the series. Although they seemed wildly over the top when they were made (1988 and 1990), they seem un­der­stat­ed compared to the thrillers that Hollywood pumps out now.

We saw Die Hard again tonight. Bruce Willis and Alan Rickman shine in their breakout roles. Willis exhibits the trademark cockiness that was already familiar from Moon­light­ing, but he’s not as obnoxious as he often was in later roles. Rickman gently nibbles the scenery as a terrorist turned master criminal.

USB 3 Drivers on a Lenovo E545

Emma’s been com­plain­ing for some time that USB devices only worked in one port on her Lenovo E545 laptop. The USB 2 port worked; the USB 3 ports didn’t.

I took a look at Device Manager, and I noticed that most of the USB nodes looked wrong. She went to the Lenovo website and downloaded two USB-related drivers, the AMD USB Filter Driver and the AMD USB 3.0 Driver. Between them, they fixed the problem and she now has all ports working.

This machine is running Windows 7. At some point, she wiped the machine to get rid of Lenovo crapware, and installed a clean copy of Windows 7. She downloaded a pile of continue.

Review: The Ax

Title: The Ax
Author: Donald E. Westlake
Rating: ★ ★ ★ ★ ½
Publisher: Grand Central Publishing
Copyright: 1997
Pages: 352
Keywords: crime, dark humor
Reading period: Nov 7, 2015

Burke Devore is a middle-aged middle manager at a paper mill, who’s been laid off for some time. There are too many others like him and they’re beating him out for the few positions in his field. In des­per­a­tion, he decides to eliminate the com­pe­ti­tion by placing a fake job ad­ver­tise­ment for others with similar skills and by killing them off.

Westlake is known for a variety of crime novels, including the light-hearted, humorous Dortmunder books. There’s humor here, but in a very dark vein, and social continue.

History of Toilet Paper

Let me tell you, people go on and on about what a great idea electricity was, but I'm going to put toilet paper right next to the wheel and say those are the best ideas anyone's ever had. Scoff at it if you will, but try living for two millennia without it and then we'll talk. - Kevin Hearne

At Freely Speaking Toast­mas­ters tonight, Kim gave a talk on the History of Toilet Paper. It was inspired by the quote above from the Iron Druid Chronicles, by a 2000-year-old druid.

She got much of her in­for­ma­tion from wikipedia. I found the toilet paper FAQ while writing this post.

At FSTM, after the speech evaluator gives the speaker a formal evaluation, we have five minutes of open evaluation from the audience.

My father has a hundred or so sayings that he trots out again and again and again—much to the annoyance of those who know him well. When he moved from the Dublin to the London office of his bank in the

continue.

Christmas Puddings

I spent a couple of hours this evening making Christmas Puddings. I soaked several pounds of dried fruit overnight in hot water with a little whiskey. The fruit plumped up con­sid­er­ably. I let it drain throughout the day.

The photo shows the puddings in their bowls just before I sealed them and put them into the oven for four hours of steaming. They’ll get another four or five hours tomorrow. When we’re ready to eat one, it’ll get another hour of steaming to heat it up. We decant it from the bowl, stick a sprig of holly in the top, heat a tablespoon of whiskey until it catches fire, and pour the flaming continue.

Previous » « Next