Archive for August 14, 2013

Wednesday, August 14, 2013

Broken Flickr Links

Chuq Von Rospach:

If you link up to Flickr images, and then make a change, even if you re-upload in place. I understand the technological reason behind it, but I also know that they could create permanent redirects and route all of those links through those, just like, oh, does. But they haven’t, and if you’re someone who has a tendency to go in and rework images, well, Flickr can become a bucket of pain. The good news: a good link tester spider wandering your site will find these. The bad news: you have to actually understand the phrase I just wrote.

iPhoto ’11 Deemphasizes Content

Glenn Reid:

The mantra for iPhoto 1.0 was essentially that the user interface should disappear — photos are something you look at, so you want a very visual interface, with more photo, less UI.  This is the balance that is largely missing in iPhoto '11.  There is much more UI, and a lot less Photo.

And apparently the creator of iPhoto is another Snow Leopard fan.

Inside an Amazon Warehouse

Dave Smith (via Jens Alfke):

By storing items randomly instead of categorically, the warehouse has a much better flow of material. Even without robots or automation, Amazon can compile a “picking list” that locates where each item needs to be taken off the shelf and scanned again before it can be shipped.

The real advantage to chaotic storage is that it’s significantly more flexible than conventional storage systems. If there are big changes in a product range, the company doesn’t need to plan for more space, because the products or their sales volumes don’t need to be known or planned in advance if they’re simply being stored at random.

Furthermore, free space is much better utilized in a chaotic storage system. In a conventional system, free space may go unused for quite a while simply because stock is low or there aren’t enough products to begin with. Without any kind of fixed positions, available shelf space is always being used.

WebKit’s srcset Image Attribute

Dean Jackson:

WebKit now supports the srcset attribute on image (img) elements (official specification from the W3C). This allows you, the developer, to specify higher-quality images for your users who have high-resolution displays, without penalizing the users who don’t. Importantly, it also provides a graceful fallback for browsers that don’t yet support the feature.

I’d like to see this (or the CSS equivalent -webkit-image-set) supported in FancyZoom.

Update (2013-08-22): There’s an interesting discussion of this on Hacker News.

AMBER Alert Usability

Craig Hockenberry:

Unlike all other notifications on my iPhone, I couldn’t interact with the alert. There was no way to slide the icon for more information or tap on it in the Notification Center to get additional information. […] But I was also seeing a lot of people on Twitter whose response to the confusion was to ask how to turn the damn thing off. And since AMBER Alerts aren’t affected by the “Do Not Disturb” settings, a lot of people went to Settings > Notification Center so they wouldn’t get woken again in the future.

Update (2013-08-29): Lex Friedman:

The biggest risk is that iPhone owners (and owners of other smartphones with WEA support) will disable Amber Alerts because of the annoyance factor. And yes, you can disable the alerts if you don’t want to see (and hear) them: Go to the Settings app, choose Notifications, and scroll all the way down.

I just turned it off after being woken up at 3 AM by an Amber Alert for a flood warning that didn’t actually affect my area. It was apparently not even significant enough to show up in my weather app.

WebKit Binary Size Speed Boost

Benjamin Poulain:

The memory locality of the instructions affects the CPU caches; the more the code is spread out, the more time the CPU cores are waiting for something to do. Typically, we want to reduce the number of cache misses, being from the instruction-cache, TLB, page faults, etc. Since cache sizes and memory speeds do not increase as fast as our binaries are growing, we cannot count on new hardware to compensate. We need to address the issue in software.

The Pronunciation of European Typefaces

Ralf Herrmann:

So you’re an expert in typography? But do you pronounce Frutiger’s typeface Univers like the English word “universe”? Then you got it wrong. Here are some popular European typefaces and their proper pronunciation in German, French and Italian.

Apple’s Evolving View of “pro”

Ken Segall:

Obviously, the pro market has value for Apple, even if its numbers are relatively small. Pros are opinion leaders, influencers and evangelists. Their love of Apple shows up in the purchase decisions of friends, family and colleagues.

So Steve ultimately renewed his commitment to the pros—but he never said that this commitment wouldn’t evolve. Clearly Apple has changed its thinking about the pro market, and how it can best serve its pro users.

I’m just an amateur photographer, running Aperture on a Mac with 16 GB of RAM and an SSD, and after about half an hour it gets so slow that I have to reboot. I run into bugs nearly every session. I don’t know how the pros deal with this and other issues like dropping support for Final Cut Pro’s data format.


Even today, some Web sites don’t have RSS feeds, so Feed43 is a “free online service converts any web page to an RSS feed on the fly”:

Feed43 engine converts free-form HTML or XML documents to valid RSS feeds by extracting snippets of text or HTML by means of applying search patterns, and then joining these snippets together using output templates to form user-friendly content of feed's items. The principle of extracting specific data from source documents is also known as “HTML scraping”.

Backblaze, Arq, and External Drives


Backblaze works best if you leave the external hard drive attached to your computer all the time. However, Backblaze will backup external USB and Firewire hard drives that are detached and re-attached as long as you remember to re-attach the hard drive at least once every 30 days. If the drive is detached for more than 30 days, Backblaze interprets this as data that has been permanently deleted and securely deletes the copy from the Backblaze datacenter. The 30 day countdown is only for drives that have been unplugged. There is no countdown for local files.

If you are going on vacation for a long time, you can shut down your computer with the external drive attached. Backblaze does not detect that the external drive has been unplugged and won’t start the 30-day countdown. You can then leave your computer off and unplug your external drive for six months, and Backblaze will still keep all your files backed up including those on your external drive. When you come back from vacation, make sure to plug your external drive back in BEFORE you turn your computer on.

When an external drive is plugged back in, it may take Backblaze a minute or two hours to schedule the files on the external drive to be backed up online.


If the drive isn’t mounted, Arq just skips it.

I’m planning to use Arq to back up one of my external archive drives to Amazon Glacier. After considering the trade-offs, it seems to make sense to put this in a different backup set than my primary and auxiliary drives. I discussed this with Arq’s developer, and it sounds like it will be able to handle multiple current backup sets for the same Mac, although only one of them can be active at a time.

Update (2013-11-08): Using multiple Arq backup sets on the same Mac seems to not be as smooth as I’d hoped. For example, it does not always retain the proper S3 budget when switching between them.

Adding More Objective-C Literals to Clang

Stuart Carnie in 2012 (via Ole Begemann):

Truthfully, I’ve wanted an excuse to hack on Clang and this seemed small enough in scope to achieve in a day.  I threw out the idea of NSURL literals being represented by a @@ prefix, so the following line would compile:

NSURL *url = @@""

The Influence of Organizational Structure on Software Quality

Nachiappan Nagappan et al. (via Graham Lee):

In our case study, the organizational metrics when applied to data from Windows Vista were statistically significant predictors of failure-proneness. The precision and recall measures for identifying failure-prone binaries, using the organizational metrics, was significantly higher than using traditional metrics like churn, complexity, coverage, dependencies, and pre-release bug measures that have been used to date to predict failure-proneness. Our results provide empirical evidence that the organizational metrics are related to, and are effective predictors of failure-proneness.

The full paper is available from Microsoft Research.

Update (2019-12-20): August Lilleaas (via Hacker News):

The distance to decision makers and the number of developers working on a project is clearly and unambiguously the issue that is the best predictor of future problems with a code base.


Another shocking discovery for me personally, is that the only one that I've actually used myself - code coverage - has the lowest recall. It has a high precision, so bad code coverage does mean a high chance of bugs, i.e. low amount of false flags. But with a low recall, there are lots of bug that code coverage doesn't actually catch.


In the replicated study the predictive value of organizational structure is not as high. Out of 4 measured models, it gets the 2nd highest precision and the 3rd highest recall. The study itself does conclude that organizational complexity as a bug prediction method is worth investigating further. The study is also based on individual functions in C/C++, and not entire modules like Microsoft Research did, which can be a reason for at least a part of the discrepancy.

How I Created the Iconic iPhone Sound

Kelly Jacklin (via James Thomson):

At some point, Jeff and I were chatting about his disc burning feature, and he said he needed some way to inform the user that the burn was done. DAS being a sound-making app, he wanted a sound to alert the user, something simple. Since I’m a hobbiest musician, and had a recording setup, I told him I’d tinker around and see if I could some up with something.


So imagine my surprise when the iPhone ships, and the default text message tone is… “158-marimba”, now going by the clever (and not actually accurate, from a music theory perspective) name “Tri-Tone”. Time goes by, and this sound becomes iconic, showing up in TV shows and movies, and becoming international short-hand for “you have a text message”…

Restoring Trust in Government and the Internet

Bruce Schneier:

Ronald Reagan once said “trust but verify.” That works only if we can verify. In a world where everyone lies to us all the time, we have no choice but to trust blindly, and we have no reason to believe that anyone is worthy of blind trust. It’s no wonder that most people are ignoring the story; it’s just too much cognitive dissonance to try to cope with it.

SnappyCam 3.0.2

John Papandriopoulos:

Today, we’re excited to introduce a groundbreaking update to SnappyCam: full-sensor capture up to 8 Mpx at an incredible 20 pictures/sec. That’s faster than any other mobile platform, including Android, and 4x faster than any other camera app on iOS.

Josh Constine:

To put the speed in perspective, SnappyCam is about 4X faster than the normal iPhone 5 Camera app, and more than twice as quick as the Samsung Galaxy S4’s 7.5 shots per second. Papandriopoulos claims that other iOS camera apps built for speed like FastCamera, Camera Awesome and Camera+ often degrade photos to 0.3-megapixel postage stamps when they try to get up to 30fps, and can only do around 4fps at full resolution.

On Hacker News, Papandriopoulos describes some of the JPEG work that he did in order to achieve these speeds. It’s a great app: you can essentially shoot full-photo-resolution video and then pick out the one frame where everyone simultaneously has open eyes and a smile.

Update (2014-01-04): Josh Constine (via Jordan Golson):

Apple has acquired the one-man photo technology startup SnappyLabs, maker of SnappyCam, sources tell me. The startup was founded and run solely by John Papandriopoulos, an electrical engineering PhD from the University Of Melbourne who invented a way to make the iPhone’s camera take full-resolution photos at 20 to 30 frames per second — significantly faster than Apple’s native iPhone camera.

Sounds good to me. SnappyCam worked faster than the built-in Camera app, but there was no way to make it replace the built-in app.

Xcode 5’s New XIB Format

Nils Hayat (via Mike Rundle):

It turns out that the xib files generated by Xcode 5 are of a completely new kind. It seems that Apple started from scratch with this and the changes make xib files finally usable in teams of all sizes for the first time.

It now looks more like a “regular” XML file format, rather than the output of an object serializer.

Squarespace and Third-Party Clients

I recently came across this old post from Daniel Jalkut:

It came as a surprise when Squarespace 6 was released earlier this year, that support for 3rd party editors such as MarsEdit was dropped from the service. I had some cordial correspondence with staff at Squarespace, who explained that because of the laudable flexibility of the new version, it’s difficult to provide access to the content with one of the standard blogging APIs that MarsEdit uses to connect to Squarespace 5 and dozens of other services. Of course, as a developer with customers who depend on this support, I was disappointed to learn this.

This came as a surprise to me. I’ve heard countless Squarespace podcast sponsor reads that extol the service’s flexibility without mentioning what a very sweet solution it is.

Xerox Scanners and  Photocopiers Randomly Alter Numbers

Yves Peters (via Mark Jason Dominus):

Apparently Xerox machines use JBIG2 for compression, an algorithm that creates a dictionary of image patches it considers similar. As long as the error generated by these patches is not too high, the machine reuses them instead of using the original image data. This also would explain why the error occurs when letters or numbers are scanned in moderate resolution, yet still readable for the human eye. When the letter size is close to the patch size of JBIG2, complete letters and even blocks of letters that look similar to the machine are replaced.

Type-Safe Scalars With Single-Field Structs

Mike Ash:

An interesting feature of C structs is that structurally-identical structs are still different types. […] This fact gives us the tool we need to create new types rather than simply creating new names for existing types.

And there’s no overhead at runtime.

Remembering the Apple Newton’s Prophetic Failure and Lasting Impact

Mat Honan:

The result of all that work was a completely new category of device running an entirely new architecture housed in a form factor that represented a completely new and bold design language. There was just one problem: handwriting. “We were just way ahead of the technology,” laments Capps. “We barely got it functioning by ’93 when we started shipping it.” Handwriting recognition was supposed to be Newton’s killer feature, and yet it was the feature that probably ultimately killed the product.

Don’t Plug Your Phone Into a Charger You Don’t Own

Neil J. Rubenking (via Hacker News):

It turns out that any device you connect with an iOS via the USB port can obtain your device’s Universal Device ID (UDID), as long as the device isn’t passcode-locked. It just takes a second, so if you plug in your device while it’s unlocked, or unlock it while plugged in, or just don’t have a passcode, Mactans can attack.

Using the UDID, it effectively claims your device as a test device using the team’s Apple developer ID. “The iOS device must pair with any USB host that claims it,” said Jang. “Any USB host that initiates contact, they cannot reject it. It doesn’t ask the user’s permission and gives no visual indication. The only way to prevent a Mactans attack is to lock your device before charging it and keep it locked for the entire time.” Once accomplished, the pairing is permanent.

They can then install invisible apps that bypass the iOS app sandbox.

Growl 2.1 and AppleScript Rules

Growl 2.1 adds a cool new feature (via TidBITS). Your script handler can look at the notification and change the display style, modify the notification, control the network forwarding, or suppress the notification entirely.


OCFWebServer (via Christian Kienle):

OCFWebServer is a lightweight, modern and asynchronous HTTP (version 1.1) server. It was forked from GCDWebServer and modified to fit the needs of and hopefully other people’s needs as well.


In OCFWebServer your request handler does not have to return anything immediately. OCFWebServer will pass the request and a block to your request handler. You call the passed block as soon you have created the response object and pass the block your response object. This can be done synchronously or asynchronously.

Using Dash With BBEdit

BBEdit Hints:

BBEdit lets you customize, on a language by language basis, what tool it uses to look up documentation. You do this in the BBEdit -> Preferences -> Languages panel. Use the + button to add a custom language preference for the language you want.

In the custom language screen, set the Reference Template URL to: dash://jquery:__SYMBOLNAME__.

Apple’s Shell Scripting Primer

Apple (via Jonathan Rentzsch):

You should read this document if you are interested in learning the basics of shell scripting. This document assumes that you already have some basic understanding of at least one procedural programming language such as C. It does not assume that you have very much knowledge of commands executed from the terminal, though, and thus should be readable even if you have never run the Terminal application before.

This looks surprisingly good.

Yojimbo 4.0

Yojimbo 4.0 replaces its MobileMe Mac-to-Mac syncing, not with iCloud, but with Wasabi Sync. Syncing has always been a core feature of Yojimbo, and think it’s a good move for Bare Bones to to control its own destiny here. However, one downside of this approach is that the subscription pricing for the cloud component is incompatible with the Mac App Store. As a result, instead of only being available from Apple’s store, Yojimbo is no longer available there at all.