Archive for January 2016

Saturday, January 30, 2016 [Tweets] [Favorites]

In Praise of Control Center

John Gruber:

Control Center is probably my single favorite system-level UI change to iOS ever. I kind of wish you could change the apps hard-coded at the bottom (I’d replace Calculator with PCalc, for example), but I use it all the time.

I think Notification Center and Today view could still use some improvement. But cramming Control Center into the same pull-down sheet would make things worse, not better.

Yep.

Update (2016-02-02): Dr. Drang:

I like the limitation of having just a few available slots, but being able to replace the “dead” spots with buttons I’d actually use would be a big improvement.

[…]

And the design inconsistency I mentioned earlier? The buttons on the top do a single thing and they do it immediately—they do not launch apps. The buttons on the bottom do launch apps, which is why the have the rounded rectangle shape of app icons. The exception, the inconsistency, is the Flashlight button. It belongs on the top. I can only assume that Apple put it where it is because they wanted six “do it now” buttons but had room to fit only five comfortably. It’s a minor inconsistency, but it wouldn’t be necessary if we could customize our button layouts.

Sunsetting Parse

Ilya Sukhar in 2013:

Some of the world’s best brands trust us with their entire mobile presence, and a growing number of the world’s brightest independent developers trust us with their next big thing. We couldn’t be happier.

As stewards of a good thing, we’re always thinking about the next step in growing Parse to become a leading platform in this age of mobile apps.

[…]

Parse has agreed to be acquired by Facebook. We expect the transaction to close shortly. Rest assured, Parse is not going away. It’s going to get better.

Via Nick Heer:

According to their brag page, Parse’s customers included some of the biggest and most popular apps on both iOS and Android. Uniqlo, Eventbrite, Plenty of Fish, Lululemon, and more all used Parse. Stubhub? Parse. Vevo? Yep. Zoosk? HopStop? The fucking White House? Their apps used Parse. Heck, even that shelved new app Panic was working on used it.

Dan Rowinski in 2014 (via Tim Burks):

Parse also sold but in a very different fashion. What Parse did well (create developer community connections to brands) worked really well for Facebook’s aim of bringing developers to its platform. Parse’s product is still alive and well—and supported by Facebook—and that isn’t going to end any time soon.

Kevin Lacker (via Natasha Murashev, comments):

Beginning today we’re winding down the Parse service, and Parse will be fully retired after a year-long period ending on January 28, 2017.

[…]

First, we’re releasing a database migration tool that lets you migrate data from your Parse app to any MongoDB database. During this migration, the Parse API will continue to operate as usual based on your new database, so this can happen without downtime. Second, we’re releasing the open source Parse Server, which lets you run most of the Parse API from your own Node.js server. Once you have your data in your own database, Parse Server lets you keep your application running without major changes in the client-side code. For more details, check out our migration guide here.

Manton Reece:

For years I had always heard great things about Parse. I eventually used it for the first time a few months ago on a client project. It’s got a well-designed API, friendly monthly pricing (free for many apps), and it seemed well supported, with new features like tvOS support and a web dashboard redesign rolling out just a month ago.

Michael Yacavone:

Entirely predictable. Even the title is blasé: “Moving On.”

Guy English:

If it had been me shutting down Parse I would have changed the home page to not point out how many “Trust Us”.

Drew McCormack:

Let’s face it: if you want it done properly, you have to do it yourself. Is this the death of SAAS?

I think the biggest problem now is just trust. If FB can’t provide guarantees for your app’s backend, who can?

Jeff Lawson:

“But seriously developers, trust us next time your needs temporarily overlap our strategic interests. And here’s a t-shirt.”

Joel Bernstein:

The subtext to the Parse shutdown is “never trust a Facebook platform ever again, for any reason”

Tim Burks:

Yes, but solutions will emerge. I haven’t looked at the SDK code but expect this can be fixed w/ a URL update.

Parse was a model for selling products to developers. But it also succeeded by burning enough VC money to suffocate its competitors.

Update (2016-01-30): Marco Arment (tweet, 2014):

For whatever it’s worth, running your own Linux servers today with boring old databases and stable languages is neither difficult nor expensive. This isn’t to say “I told you so” — rather, if you haven’t tried before, “You can do this.”

Update (2016-02-01): Allen Pike:

Hundreds of thousands of unsuccessful Parse apps will perish. Like links to long-dead Geocities pages, dead mobile apps that relied on Parse will linger in the App Stores for years, slowly accumulating one-star reviews.

As much as Parse will try to get the word out that they’re shutting down, many apps’ owners don’t even know that they’re reliant on Parse. Parse’s overly generous free plan made them popular with freelancers and consultants building quick app backends for their clients. Many of those clients don’t know what Parse is, let alone that the little app they commissioned a couple years ago is a ticking time bomb.

Marco Arment:

In particular, it’ll be problematic when possibly hundreds of thousands of iOS apps just stop working in a year because their developers have long since moved on, or their contracts expired, or they can’t afford to spend time on a significant update.

One of the most damaging side effects of unhealthy App Store economics is that developers have little motivation or resources to keep apps updated.

Update (2016-02-02): Microsoft:

If you have been using Parse hosting as the backend that supports your mobile apps, this may be the perfect time to try out Azure App Service. Due to recent occurrences, the folks at Parse have provided a way to migrate an existing backend hosted by Parse to another host. When searching for a new host, we hope that you try Azure.

Todd Hoff:

Where should you go? What should you do? By now you’ve transitioned through all five stages of grief and ready for stage six: doing something about it. Fortunately there are a lot of options and I’ve gathered as many resources as I can here in one place.

Update (2016-02-03): Sascha Konietzke (via Hacker News):

When Facebook acquired Parse back in April 2013, many people thought this meant Facebook goes all in on becoming a developer platform. If you recall, Facebook was at a crossroads back then, with a share price below IPO level, desktop traffic plateauing, and mobile revenues a big question mark. Enter Parse, which brought immediate mobile app developer reach, helping Facebook to distribute its SDKs and ensure developers are using Facebook’s login system. That in turn helped secure mobile adoption and a foothold in user profiles and mobile advertising. Fast forward to 2016, and Facebook essentially owns the mobile ads space, and its SDK is #1 in terms of mobile reach. Meaning Parse has run its cause as an SDK distribution vehicle. In other words, they never wanted to host your app, they just wanted you to use Facebook login.

Glider Pro on GitHub

John Calhoun has open sourced the excellent Glider Pro and other games (via Brendan Shanks, comments). It’s a CodeWarrior C project.

Meet iCloud’s Great-grandfather: iTools

Stephen Hackett:

iReview housed reviews and rankings of other websites. Initial reviews were written by Apple employees, and the site launched with 250 published reviews. That number grew slowly, as personal Mac users could append to existing reviews, but not create new ones.

[…]

Apple also introduced iCards, a section of the company’s website where users could go to create and send virtual greeting cards.

[…]

iDisk offered users 20MB (yes, MB!) of Internet storage, hosted on Apple’s servers. Instead of fiddling with FTP settings, iDisk was baked into Mac OS 9 — there was an icon for it right on the Desktop.

VMware Fusion

Christian Hammond (via Craig Hockenberry and Paul Haddad, comments):

Yesterday morning, the Hosted UI team, responsible for VMware’s Workstation and Fusion products, woke up to find themselves out of a job. These products, despite being award-winning and profitable, are probably not long for this world.

Rob Griffiths:

Sad about Fusion, it was always my fave. Much more “Mac like” than Parallels with great performance. Will keep using it until I can’t.

It hasn’t been canceled, but the entire local team is gone. I read something that said future dev is offshored to China.

Sean Gallagher:

When contacted to comment, a VMware spokesman said that the company was committed to continuing development and support for Fusion and Workstation and that the company was “transitioning the Fusion and Workstation teams to co-locate” with the rest of the company as part of its reorganization. “Our commitment to Fusion and Workstation products is unchanged,” he said.

[…]

VMware was acquired by EMC in 2004, which offered 15 percent of VMware’s stock in a 2007 initial public offering. EMC is in the process of being acquired by Dell, which would give Dell a majority stake in VMware (though the company will remain independent).

Fusion is a great app. I hope it lives on.

Previously: Turning Off Ads in Parallels, Parallels Desktop 9 and Parallels Access.

Update (2016-02-08): Christian Hammond (via Hacker News):

I’d like to share some thoughts and pictures from a few people in our team about what made our team great, and share some comments from some of our users. Keeping it positive here.

Friday, January 29, 2016 [Tweets] [Favorites]

The 2015 Panic Report

Cabel Sasser:

iOS Revenue. I brought this up last year and we still haven’t licked it. We had a change of heart — well, an experimental change of heart — and reduced the price of our iOS apps in 2015 to normalize them at $9.99 or less, thinking that was the upper limit and/or sweet spot for iOS app pricing. But it didn’t have a meaningful impact on sales.

More and more I’m beginning to think we simply made the wrong type of apps for iOS — we made professional tools that aren’t really “in demand” on that platform — and that price isn’t our problem, but interest is.

[…]

One of our interesting app experiments — an app to share and discover music — was 95% done, had a beautiful interface and some interesting ideas, plus a complete server-side component… then got shelved. It wasn’t an easy decision. It was mostly worries about revenue — it doesn’t seem possible that you can charge money for a social app in 2016, since mass adoption is critical. And is advertising really a thing we want to do? This is maybe one of the only times I wished we were a startup — with a “release now, figure out how to make money later” culture — but we’re not.

[…]

Later in the year should see a brand-new, major update to Transmit, that will increase speed, add Panic Sync, seriously expand protocol support, and more. A Transmit overhaul is long overdue and we are extremely excited to get this out to the world in 2016. (One open question: will we distribute it in the Mac App Store? Hmm…)

Numbers 3.6.1 for Mac Review

Rob Griffiths:

Beyond this one change, however, Numbers 3.6.1 looks much like Numbers 3.0. There’s still no formatting bar below the customizable toolbar, so everything is still controlled by the context-sensitive right-hand panel. And while this cleans up the look a lot, it leads to lots of clicking between tabs in the panel for many common tasks.

Another annoyance that remains from version 3.0 is the lack of an editable formula bar. To edit a formula, you have to double-click the formula, which pops up a tiny editing box. This box can be both resized and moved, but for no reason I can discern, these changes aren’t permanent, so you have to resize and move the formula box every time you use it (assuming you don’t like its size/location).

AppleScript, which vanished in 3.0, has also returned from the dead, to the relief of scripters everywhere. (It’s even gained a couple new options for PDF and Excel export.) Macros, which didn’t exist before, still don’t exist. I expect them to continue to not exist in all future versions, so macro users should look elsewhere.

This version of Numbers also returns Help to the app, sort of: Numbers no longer opens a webpage when you open help, but the in-app help viewer still requires an Internet connection.

He reports some big performance improvements. My 2013 test of opening a CSV file now takes 44s in Numbers 3.6.1 (down from 3m25s) vs. 3s (up from 2s) for Excel 2016.

Update (2016-02-02): I’ve found that, although some AppleScript features were restored, at least one property was removed/renamed, which broke my scripts.

Update (2016-02-05): The AppleScript support doesn’t seem to actually work. There is a dictionary, but nothing shows up in Script Debugger’s explorer. And basic scripts such as:

tell application "Numbers"
    get document 1
end tell

fail with error -1,728.

A Modern Network Operation

Marcus Zarra:

Fortunately, I have recently worked on a design that I have been quite pleased with. In this design I am happily using NSOperation subclasses again and I am using the NSURLSession API.

[…]

Note that I am triggering a KVO notification on isFinished as opposed to finished which is what the property name is. This seems to be a Swift-ism as the NSOperation get accessor is called isFinished instead of getFinished and I suspect that is part of why I need to tickle the accessor name instead of the property name.

[…]

By using NSOperation subclasses I can now prioritize my network calls (posting to twitter is a higher priority than receiving avatars from twitter for example), cancel operations that are no longer needed (avatars or images that are no longer on screen) and in general be a much better citizen by only keeping the radios on for as long as I need them and not any longer.

Further, I can now watch for application life-cycle events in my NetworkController and terminate operations when my application goes into the background, further improving my citizenship status. I can also look for operations that need to finish when the application goes into the background and request additional background time.

Lightroom 6.4

Tom Hogarty (tweet):

The goal of this release is to provide additional camera raw support, lens profile support and address bugs that were introduced in previous releases of Lightroom. This release also includes a new Boundary Warp feature for Creative Cloud members.

The direct download link is here (via ProDesignTools).

Linnie Rourke:

This is a very simple step-by-step guide [to migrate from Aperture to Lightroom] as I could not find anything with a really detailed description of the process for someone reasonably competent but not expert and who has a highly organised Aperture library of Projects, Folders and Albums!

BBEdit 11.5

Lots of good stuff in this BBEdit update:

There is a new setting in the Text Colors preferences: “Differences”. This color setting determines how differences are highlighted in editing views when you select them in a Differences window. (The color for differences within a line is derived from this, by darkening or lightening as needed.) If a custom color scheme does not include a Differences color, BBEdit will use a dark gray or light gray (depending on the scheme's background color) instead.

[…]

Things that are highlighted in the text at various times (matches for selected text, Live Search results, spelling errors, and diffs) are now marked in the view’s vertical scroll bar. The tick marks indicating matches for selected text may be turned off in the Editing preferences, if desired.

[…]

The “Apply to Left” and “Apply to Right” commands (and buttons) no longer pay attention to the selected range(s) of text in the respective documents. Instead, they will apply the difference based on what is reported in the differences list (and highlighted using the Differences color).

[…]

Open File by Name will now search Xcode for system framework headers, rather than relying on previous installation of the Xcode command-line tools package (which places framework headers in /System/Library/Frameworks/).

[…]

Updated the Objective-C/Objective-C++ keyword lists to add __kindof, nullable, _Nullable, _Nonnull, _Null_unspecified, and a few others.

Tuesday, January 26, 2016 [Tweets] [Favorites]

Twitter Has Stopped Showing Ads to Some VIP Users

Peter Kafka (tweet):

For the past few months, the social media company has stopped displaying ads, or has dramatically reduced the number of ads it displays, to a small group of some of its most prominent and active users.

For those people, Twitter is an ad-free, or nearly ad-free, experience.

Sources say Twitter made the move in an attempt to get some of its VIP users to stay engaged with the service.

Daniel Jalkut:

Selective treatment on Twitter gives me the creeps. First @verified, now no ads for the elite

It seems like the ads have become a lot more intrusive lately.

Monday, January 25, 2016 [Tweets] [Favorites]

Marvin Minsky, RIP

Glenn Rifkin (via Dan Bricklin, Hacker News, Slashdot):

Well before the advent of the microprocessor and the supercomputer, Professor Minsky, a revered computer science educator at M.I.T., laid the foundation for the field of artificial intelligence by demonstrating the possibilities of imparting common-sense reasoning to computers.

“Marvin was one of the very few people in computing whose visions and perspectives liberated the computer from being a glorified adding machine to start to realize its destiny as one of the most powerful amplifiers for human endeavors in history,” said Alan Kay, a computer scientist and a friend and colleague of Professor Minsky’s.

[…]

Professor Minsky’s scientific accomplishments spanned a variety of disciplines. He designed and built some of the first visual scanners and mechanical hands with tactile sensors, advances that influenced modern robotics. In 1951 he built the first randomly wired neural network learning machine, which he called Snarc. And in 1956, while at Harvard, he invented and built the first confocal scanning microscope, an optical instrument with superior resolution and image quality still in wide use in the biological sciences.

Philip Greenspun:

Marvin questioned many of the assumptions around Academia. He would show up to deliver a formal talk with a stack of notes and pick from them more or less at random. I wish that I could say that the results were amazing due to his dazzling intellect, but unfortunately the lack of an organized outline made these talks less than satisfying. Marvin was at his best in small groups or working one-on-one with others at MIT. What I remember most about him was his genial skepticism. If two people were arguing, rather than take one side, Marvin could show that both were operating from an assumption about the world that perhaps wasn’t necessary or true. He was a bit of a modern-day Socrates.

Update (2016-01-28): Paul Whitmore Sas:

Another defining characteristic of his mind was its utterly stochastic trajectory. No one, and certainly not Marvin, could discipline his curiosity cum hubris. SoM class lectures rode roughshod over a thousand topics, and left many stacks unpopped. The book, which exemplifies a horde of daemons tackling random splinters of cognition, was rumored to have been assembled from shards collected together with Hillis’ help.

Update (2016-01-29): Adam C. Engst:

I’ll remember him as a TidBITS reader and for his openness and kindness. Although plans to meet up at Macworld Boston never came to fruition, I exchanged email with him back in 1992 about Apple’s Casper voice recognition technology (see “Casper Speaks,” 9 March 1992), which evolved into a system called PlainTalk (see “Bossing Your Mac with PlainTalk,” 28 August 2000).

Stephen Wolfram (via Hacker News):

Being no expert on such things (and without the web to look anything up!), I called Marvin to ask what to do. What ensued was a long discussion about the possibility of developing microrobots that could chase mealybugs away. Fascinating though it was, at the end of it I still had to ask, “But what should I actually do about Margaret’s plants?” Marvin replied, “Oh, I guess you’d better talk to my wife.”

[…]

Marvin immediately launched into talking about how programming languages are the only ones that people are expected to learn to write before they can read. He said he’d been trying to convince Seymour Papert that the best way to teach programming was to start by showing people good code.

Update (2016-01-30): Scott Aaronson:

For example, in his and Papert’s 1968 book Perceptrons—notorious for “killing neural net research for a decade,” because of its mis- or over-interpreted theorems about the representational limitations of single-layer neural nets—the way Minsky and Papert proved those theorems was by translating questions about computation into questions about the existence or nonexistence of low-degree polynomials with various properties, and then answering the latter questions using MATH. Their “polynomial method” is now a mainstay of quantum algorithms research (having been brought to the subject by Beals et al.), and in particular, has been a mainstay of my own career.

Update (2016-03-17): Steven Levy:

Minsky quotes in fortune cookies.

7 Scandalous Weird Old Things About the C Preprocessor

Robert Elder (via Peter Steinberger):

Bjarne Stroustrup even points out that the standard isn’t clear about what should happen in function macro recursion[1]. With reference to a specific example he says “The question is whether the use of NIL in the last line of this sequence qualifies for non-replacement under the cited text. If it does, the result will be NIL(42). If it does not, the result will be simply 42.”. In 2004, a decision was made to leave the standard in its ambiguous state: “The committee’s decision was that no realistic programs “in the wild” would venture into this area, and trying to reduce the uncertainties is not worth the risk of changing conformance status of implementations or programs.”

[…]

Many languages are first tokenized, and then the list of tokens doesn’t change throughout further processing of the program. In the C preprocessor, new tokens can be created at run time! This makes it impossible to build a parse tree ahead of time because you don’t know what tokens would be included in the final tree.

[…]

In general, when evaluating a function macro body, you need to consider both the pre-expanded version of the arguments, and the untouched tokens that were passed for that argument. This behaviour is unlike how C arguments and functions are evaluated, because in C you can always replace an argument that’s described by an expression with the result of that expression and have the same meaning (ignoring any side effects).

He also mentions handling of whitespace, which is confusing and also buggy in Clang.

Amazon’s Customer Service Backdoor

Eric Springer (Hacker News, Slashdot):

The attacker gave Amazon my fake details from a whois query, and got my real address and phone number in exchange. Now they had enough to bounce around a few services, even convincing my bank to issue them a new copy of my Credit Card.

[…]

I again contact Amazon to reiterate how important it is that they keep my account secure, and not give out my details to anyone with a name and address. They promise they’re putting a note on my account, and it’ll never happen again. And I will be contacted by a specialist (never happened, again)

Anywhere But Medium

Dave Winer:

Medium is on its way to becoming the consensus platform for writing on the web. if you’re not sure you’re going to be blogging regularly, the default place to put your writing is Medium, rather than starting a blog on Tumblr or WordPress.com, for example. I guess the thought is that it’s wasteful to start a blog if you’re not sure you’re going to post that often.

[…]

People also post to Medium to get more flow. But at what cost? Which pieces get flow? Ones that are critical of Medium? I doubt it. Or offend the politics of the founder? I don't know.

[…]

I also want to preserve the ability of developers to innovate in this area. If Medium sews up this media type, if they own it for all practical purposes, as Google owned RSS (until they dropped it), then you can’t move until they do. And companies with monopolies have no incentive to move forward, and therefore rarely do.

John Gruber:

The comparison to Google Reader is perfect. Google Reader was both (a) the most popular thing that ever happened to RSS, and (b) the worst thing that ever happened to RSS.

The Story Behind F.lux

Matthew Braga (via Hacker News):

“We really thought six months after that, that we were done. We had done this app that was pretty baked. And we didn’t really think it was that hard,” Michael recalled. “Now we have this joke that, everyone thinks this problem is easy until they spend a year or two on it, and then they think it’s the hardest problem they’ve ever worked on.”

Developing f.lux, it turned out, was more complex than either Lorna or Michael initially thought. And in the seven years since they started working on the app full time, Michael and Lorna have realized what they’re really on is a mission to change the way that we sleep.

[…]

Michael and Lorna are quick to point out that that brightness also plays a role, as does distance from the source of light. The pair even operate a companion site called f.luxometer that measures the light intensity of various popular devices, and how this factors into your phase shift—the amount of time, say, a MacBook Air might shift your circadian timing if used before bed.

I think I’ve determined that all my Lightroom hangs occur when Flux re-enables itself after being suspended for an hour.

Saturday, January 23, 2016 [Tweets] [Favorites]

Exploring Swift Dictionary’s Implementation

Ankit Aggarwal:

There are multiple ways to store these (key, value) records one of which is open addressing with linear probing which is used by swift’s dictionary implementation.

[…]

Bitmap value of a bucket tells if the key and value in that bucket is valid and initialized or not. If not, then that bucket is called a hole.

[…]

Also note that the end of bucket array is connected to start of the bucket array forming a logical ring. This just means that if you’re at end of the bucket array and you call next method, you’ll end up at begining of the array.

[…]

squeezeHashValue does try to create a good hash by applying some transformation operations.

Also it looks like to keep hashValues different across executions, execution speed was supposed to mixed with hashValue provided by the Key type but its a constant placeholder value for now

[…]

[_NativeDictionaryStorageOwner] was created to keep track of correct reference count for Copy on Write feature, since the storage will be referenced by Dictionary and DictionaryIndex both, reference count will be 2 for the storage but if Dictionary refers this class and reference count of this class is tracked, everything should be fine.

[…]

If a Value has to be removed from the bucket array, we might end up creating a hole which might cause side effect of probing to stop earlier than expected. To take care of that the elements are rearranged at their ideal position.

Previously: Exploring Swift Array’s Implementation, Exposing NSDictionary.

Unsteady Platform

Daniel Jalkut:

I’m scratching my head. Did it somehow get removed as a dependency? But then I notice something subtle. It’s looking for the framework in the “Release” build folder, but for my iOS build it should be looking in “Release-iphoneos”. What the heck is going on?

[…]

If any target in a Scheme’s dependency tree targets OS X, then the scheme itself will also be considered to target OS X.

[…]

This must be at least a relatively common scenario for iOS builds of certain complexity. Because the platform on which all iOS builds run is OS X, any helper tools that are compiled and used in the process of generating sources or otherwise processing build materials, must be built for OS X.

iPhone 5se Rumors

Mark Gurman:

Sources have provided the following list of “iPhone 5se” upgrades over the 5s:

The chamfered, shiny edges have been replaced with curved glass like on the iPhone 6 and 6s lines

Hopefully not, because the curved glass is much less comfortable to hold.

Update (2016-01-29): Manton Reece:

I can understand wanting consistency between models, but the iPhone 6 sleep button is a major usability issue because it gets in the way when trying to use the volume buttons. I’ll be disappointed if the design trade-offs from the 6 make the 5se worse.

Friday, January 22, 2016 [Tweets] [Favorites]

Localized Hardware

Apple (via Joe Groff):

Monitors based on cathode-ray tube (CRT) technology, including those found in iMac computers, use precisely controlled magnetic fields to direct the flow of electrons to the red, green, and blue light emitting phosphors on the monitor. The earth’s magnetic field varies in intensity throughout the world, which can affect the path of this electron beam. During manufacturing, CRT-based monitors are aligned in special areas called helmholtz cages that simulate the magnetic field the monitor is being aligned for. Monitors are typically aligned for the Northern Hemisphere or the Southern Hemisphere, and sometimes for the equatorial region.

A CRT-based monitor purchased in the Northern Hemisphere may not perform correctly if it is moved to the Southern Hemisphere.

Brave Browsers

Brendan Eich (comments):

Once you grant this premise, that the Web needs ads in the large, it follows that your browsing habits will be surveilled, to the best of the ad ecosystem players’ abilities. Also, depending on how poorly ads are designed and integrated, you may become blind or averse to them. Since the ’90s, I’ve seen several races to the bottom along these lines.

[…]

Everyone’s talking about ad blocking. Blockers can make the user experience of the Web much better. But as Marco Arment noted, they don’t feel good to many folks. They feel like free-riding, or even starting a war. You may never click on an ad, but even forming an impression from a viewable ad has some small value. With enough people blocking ads, the Web’s main funding model is in jeopardy.

At Brave, we’re building a solution designed to avert war and give users the fair deal they deserve for coming to the Web to browse and contribute. We are building a new browser and a connected private cloud service with anonymous ads. Today we’re releasing the 0.7 developer version for early adopters and testers, along with open source and our roadmap.

Brendan Eich:

We have a micro payments channel to publishers, frictionless and anonymous, under construction, for folks who want no ads and who will pay.

Other users than you will be able to mix and match, too: better and more private ads on sites they don’t support, with a revenue share to these users that they can spend on sites they do.

We aren’t saying “only ads”. We do see ads as a necessary funding model for much of the web today. I would love to see micropayments replace ads. Let’s see what can be done.

e15ctr0n:

Though the team working on Brave seems to have a few ex-Mozilla engineers, they have chosen to fork browsers other Firefox.

[…]

The desktop browser is a cross-platform desktop application created with a fork of Github’s Electron framework that is itself based on Node.js and Chromium.

The iOS browser is a fork of Firefox for iOS, which is a Swift app developed from scratch by Mozilla.

[…]

The ad blocking technology is courtesy a Node.js module of Adblock Plus filter that uses a bloom filter and Rabin-Karp algorithm for speed.

Stephen Shankland:

Beyond privacy protection, Eich promises Brave’s browser will come with a big speed boost: It loads pages two to four times faster than other smartphone browsers and 1.4 times faster than other browsers for personal computers.

[…]

How does Brave walk that fine line? The browser infers from your browsing history what you’re interested in, such as gourmet coffee or European cars, and shares industry-standard categories with publishers who can then place appropriate ads without knowing anything else about you. Brave, the company, says it doesn’t know or want to know any of this information.

For now, there are no ads. There are only empty patches that show where ads used to be. Once Brave has enough people using the browser, Eich hopes publishers will supply ads based on the limited information the browser shares. That will also be Brave’s revenue source.

Previously: Peace iOS 9 Content Blocker, Modern Web Ad Blocking, Safari Content Blocker and Web Advertising.

Not Out to Get You

Jon Gotow (via Kirk McElhearn):

Yes, I’m asking you to pay for software that saves you time and frustration on a daily basis. I’m not trying to sneak that by you. I’m not trying to dupe you. I’m not playing you for a fool. I’m running a business. And yes, if you don’t think Default Folder X is worth as much as a meal at Denny’s, you certainly don’t have to buy the upgrade. It’s your choice – you can vote with your wallet.

It takes a lot of work just to keep products like this compatible with new versions of the OS.

Mobile Safari Tips

Rene Ritchie:

To show you more of the page content, Safari hides the toolbar as you scroll down. Instead of trying to make it reveal itself by scrolling back up […] Tap the very bottom of the screen.

[…]

Touch and hold down on the back arrow button at the bottom left to pull up the history list of pages you visited previously.

[…]

Touch and hold down on the tab you want to reorder. Drag it to the position you want it.

[…]

When the time comes to close a tab, you can hit the small X button at the top left, but if you want to be a little more physical, and have a little more fun […] Toss it away to the left.

[…]

Once you find the web page you want, you might still need to find specific text on that page like a word or phrase. You can still do that in the most recent version of iOS, but the option has moved to the Share sheet.

Wednesday, January 20, 2016 [Tweets] [Favorites]

Little Things That Can Make Your Life Easier

Krzysztof Zabłocki:

There is much more you can do with [breakpoints], e.g. you can elevate your custom breakpoint to User Breakpoint and have them work in all your projects, why would you do that?

Because you can create symbolic breakpoint’s that execute code whenever a specific point is reached, e.g. UIApplicationMain[…]

See also this snippet to log x86_64 Objective-C methods calls and Xtrace.

KZLinkedConsole - adds ability to jump straight to the source code that logged an error

Unit test failures are another place Xcode could use some linking.

Once Bitten

William Gallagher interviews Ken Case:

Apple now provides iCloud, a service that amongst other things keeps apps in sync across many devices, yet the Omni Group ignore that in favor of its own alternative. That product has a better name -- it’s called OmniPresence -- but it is really duplicating what Apple is already doing. “Well, iCloud is really great when it works. I’ll put it that way,” says Case.

“When it doesn’t work, then customers blame us, but we have nothing we can do to try to fix their problems. When we shipped the first versions of all of our software on iOS, all of them supported WebDAV.” This was part of Apple’s predecessor to iCloud, and performed much the same job of syncing. “Well, of course we all know what happened: after they introduced iCloud, they turned off the WebDAV access, and suddenly everybody who was syncing through Apple’s once-supported service were upset because their Omni apps stopped syncing.

“So I guess there’s an element of once bitten, twice shy. If we then switched to Apple’s iCloud, then we would bitten again when the next thing comes along. I think it’s great that Apple does keep moving forward, but we need to make sure we can support our customers, and we couldn’t do it very well when we were building on top of services that could go away at any moment; that we didn’t have control over.”

Shush Is Now Swish

Daniel Jalkut (tweet):

A little over a year ago, I received a message from Apple that another developer had challenged my use of their trademark. Although I had been using the trademark myself for 7 years, they filed a trademark registration, and set to work demanding that I, and probably others, cease using the mark. I pushed back as long and as hard as I felt that I could without risking huge legal costs. I am confident that if I could justify the expense of defending the trademark, I would have prevailed because of my clear prior use of the mark. I could not, however, justify that cost. Hence the name change to Swish.

[…]

Before the trademark issue came to a head, I had built and submitted a version for Apple TV. […] Apple deemed the app too simplistic and suggested that I add more functionality.

It seems useful enough to me.

Swift Named Parameters

Keith Harrison:

The rules for naming parameters in Swift functions and methods have changed for the better over the last few releases but still seem to cause confusion. Here is my quick summary updated for Swift 2.1.

Coming from Objective-C, I still think it feels a bit weird that the declaration and call site don’t match. In Swift declarations, we have external-space-internal-colon-type, whereas at the call site we have external-colon-value. In Objective-C, we have external-colon-(optional type)internal and external-colon-value, which makes sense because the value goes into the internal name. In Objective-C, the external name is always followed by a colon. In Swift, the external name is sometimes followed by a space and sometimes by a colon, and the colon is also used to specify the type. It’s a thorny problem because there is precedent in other languages for both uses of the colon.

Sunday, January 17, 2016 [Tweets] [Favorites]

Why We Automate

Dr. Drang:

What these have saved me, more than time—although they’ve saved a lot of that, too—is my concentration, exactly as Cook says.

[…]

Another advantage of automation, one that Cook doesn’t talk about, is accuracy. No matter how simple a series of steps is, if it’s a dull, repetitive task, I will eventually screw up one of the steps and have to go back and fix it. I doubt that I’m unique in that way. Automation ensures consistency.

Swift Golf

Cocoanetics:

We learned several new ways to pick out a specific element from a collection. I found the discussion exhilarating and uniquely instructive. In particular combining for + where and for + case let were new to me. I am sure that I will soon find more uses for these.

Playing Code Golf in Swift is not about brevity, but mostly about beauty, elegance and code readability. Because of this I ended up with an approach that reads like plain english to me: “from the cell’s content view’s subviews, get the first element of type UISwitch”. Anybody can understand that.

I would lean towards a combination of Variant 6 and Variant 3. It probably doesn’t matter much for this particular case, but a reusable generic extension should not flatMap the entire collection just to find one element.

Update (2016-01-20): Arkadiusz Holko:

V. 6 can be even smarter by inferring generic from return type.

This is cool but seems risky and potentially confusing to me.

The Unbugged Sessions Part 1

Eloy Durán (tweet):

In this post I’ll take you through a debugging session where I reproduce a crash, for which we were receiving a bunch of crash reports, but I was unable to reproduce by just using the application.

It will cover the following topics:

  • Narrow down the breakpoint to the method invocation where the crash occurs.
  • Locate the exact instruction that causes the crash.
  • Look at the implementation of the method where the crash occurs.
  • Simulate the crash.

Saturday, January 16, 2016 [Tweets] [Favorites]

Apple Eliminating Its App and Radio Ads

Apple:

The iAd App Network will be discontinued as of June 30, 2016. Although we are no longer accepting new apps into the network, advertising campaigns may continue to run and you can still earn advertising revenue until June 30.

John Gruber:

When iAd launched, its biggest advocate among Apple’s leadership was Scott Forstall. In some ways I’m surprised it took this long for them to pull the plug. After Forstall, I don’t think anyone’s heart was in this.

Rosyna Keller:

iAd was always doomed to fail. Apple was unwilling to give advertisers the personal information they “needed”.

Manton Reece:

I was confused at first by Apple’s iAd announcement to developers. I read it as iAd completely shutting down, but apparently it’s just the “app network”.

[…]

It seemed at odds with Apple’s focus as a product company, not to mention hypocritical for a company with ad-blocking APIs. Apple and third-party developers should be united in encouraging users to pay for apps; iAd is a distraction from that.

Kirk McElhearn:

Apple has contacted users to inform them that the free, ad-supported version of iTunes Radio will be eliminated at the end of the month.

Juli Clover:

Apple has quietly continued to offer ad-supported iTunes Radio stations in the United States and Australia even after the launch of Apple Music, but with the end of its current iAd platform on the horizon, the feature will be limited to those who pay for Apple Music going forward.

japanime:

Also, one of the main reasons I subscribed to iTunes Match was so I could listen to iTunes Radio ad-free. I don’t consider that a “perk,” but rather an integral part of the Match service.

Rigby:

So just like that, they are removing a feature that iTunes Match subscribers paid for? Nice going, Apple. The chances of me joining Apple Music just went from slim to zero, and perhaps I’ll cancel iTunes Match too.

Apple’s advertising page currently mentions ads in News, “offers” in Wallet, ads in apps, and ads in Apple Music. So, as far as regular ads, it sounds like this leaves only News.

Update (2016-01-20): At first I thought that “iAd App Network” meant Apple’s ads that are displayed in apps. Now I think it only refers to adds for apps. In other words, app developers will still be able to earn revenue from displaying iAds for various other products in their apps. They just won’t earn revenue from advertising other apps, and Apple won’t run ads promoting their app.

Benjamin Mayo:

The announcement is confusingly worded, but it does not mean that all of iAd is being discontinued. Developers will still be able to show iAd banners in their application; it’s just that the inventory for App Store apps to advertise will no longer exist. This is a blessing and a curse — it won’t help iAd improve its fill-rates but the CPM on these type of ads was significantly lower as the buy-in from the publisher side was also lower.

Roy Marmelstein:

Apple is only talking about the iAd App Network. These are the iAds you see advertising apps on the app store.

Nick Lockwood:

If so, that post is a masterclass in sowing fear and doubt about your own product, and frightening your business partners unnecessarily.

Update (2016-01-22): David Smith makes almost half of his living from iAd but doesn’t understand which parts of it Apple is shutting down.

Update (2016-03-07): Benjamin Mayo (via Becky Hansmeyer):

We have followed up with Apple numerous times since this original post for more clarification and have finally received a firm answer to explain the situation. The whole of the iAd network is going away — developers will not be able to include any ad banners in their apps after June 30. Developers will have to find a new ad company to continue monetizing their apps using ads, as iAd will no longer function.

The Past, Present, and Future of Sketch

Pieter Omvlee (via Hacker News):

We set out to build it for websites and icons, then it became popular for design applications when those became more popular.

[…]

It started out with just my friend and me, and right now it’s 13 people. A few people fill multiple roles, but I would say 6 developers, a few designers, support, QA and someone who deals with the plugin and scripting community.

[…]

The fact that I’m not in the Valley also means that I don’t have to pay your very high rents and other premium costs of living. Another advantage I see is the fact that we’re completely remote. It means we don’t necessarily have to compete with those who need to live physically there. We can hire people who are perfectly happy living on an island off the coast of Scotland and just hire them because they are good and wouldn’t require—or even want to—move to San Francisco, or Amsterdam, or wherever.

[…]

There is always risk from competitors. Adobe announced Comet a few months ago. This definitely poses a serious threat. The risk with a company like Adobe is that it doesn’t have to be an instant success for them. They can lose money on it for years while they improve it — and they clearly have enough talented people in their company to do so, so I do feel some pressure from that announcement.

[…]

I absolutely agree that a one-time fee for an application is not sustainable. I also know that we don’t want to switch to a subscription model.

Updated Gatekeeper Exploit

Dan Goodin (Slashdot):

Patrick Wardle said the security fix consisted of blacklisting a small number of known files he privately reported to Apple that could be repackaged to install malicious software on Macs, even when Gatekeeper is set to its most restrictive setting. Wardle was able to revive his attack with little effort by finding a new Apple trusted file that hadn’t been blocked by the Apple update. In other words, it was precisely the same attack as before, except it used a new, previously unblocked Apple-trusted file.

[…]

“It literally took me five minutes to fully bypass it,” Wardle, who is director of research of security firm Synack, told Ars, referring to the updated Gatekeeper. “So yes, it means that the immediate issue is mitigated and cannot be abused anymore. However the core issue is not fixed so if anybody finds another app that can be abused we are back to square one (full gatekeeper bypass).”

Previously: Gatekeeper Exploit.

Friday, January 15, 2016 [Tweets] [Favorites]

Interact: Better iOS Contact Management

David Sparks:

As I explained earlier, I’d pretty much given up on managing Contact groups on iOS. Interact fixes that. I am now able to add, edit, and delete groups on my iPad and and iPhone and (even better) then see them appear nicely organized when I returned to my Mac. Note that this only works in the default system account and it must be using the vCard protocol. (iCloud and Google both work but if you have more than one account, it will only work in your primary account.) Since I manage all contacts in one iCloud account, I had no problem but this could be a limitation if you use more than one service.

In addition to adding, removing, and editing groups, you can also add and remove group members. Just select a group and then tap on the Add Contacts to Group button and you are off to the races. It was all very intuitive and, as a Beta testor, I was witness to the hard work the developer went through to make it as easy as possible for users. For instance, to remove a member from the group, just tap on the “X” button next to their name.

A nice touch is the ability to see all of the groups a specific contact belongs to.

This last bit is not even possible in the Mac Contacts app.

Update (2016-01-16): Dr. Drang:

Let’s say you got an email from a new client whose contact info is in a signature block but who, unfortunately, doesn’t include a link to a vCard. Instead of laboriously typing the bits of information one at a time into their respective fields, with Interact you can swipe through the entire signature block, copy it, and paste it into Interact’s Contact Scratchpad. Interact will parse the text and create a new contact entry for you with little or no extra effort on your part.

NSStringFromClass and NSClassFromString in Swift

Natasha Murashev (tweet):

Not sure when it happened, but I was extremely to see a more native solution in @aligatr’s blog post!

// This now works!!!
String(MyTableViewCell)

Joe Groff:

NSClassFromString is in progress too.

The Resolution of the Bitcoin Experiment

Mike Hearn:

But despite knowing that Bitcoin could fail all along, the now inescapable conclusion that it has failed still saddens me greatly. The fundamentals are broken and whatever happens to the price in the short term, the long term trend should probably be downwards. I will no longer be taking part in Bitcoin development and have sold all my coins.

Why has Bitcoin failed? It has failed because the community has failed. What was meant to be a new, decentralised form of money that lacked “systemically important institutions” and “too big to fail” has become something even worse: a system completely controlled by just a handful of people. Worse still, the network is on the brink of technical collapse. The mechanisms that should have prevented this outcome have broken down, and as a result there’s no longer much reason to think Bitcoin can actually be better than the existing financial system.

Architecture of the Web Inspector

Diego Pino García:

The Web Inspector is an important component of the WebKit project. It’s an application structured in 3 layers: a frontend, a backend and a target. This abstraction allows detaching the inspector from the target (inspected WebKit browser).

The frontend is a web application composed of HTML + CSS + JavaScript. It implements a Model-View-Controller pattern and makes heavy use of ECMA2015 features. The backend exposes information of WebKit’s WebCore and JavaScriptCore elements.

Communication between frontend and backend is provided by several dispatchers that communicate both parts through the WebKit Remote Debugging Protocol (a JSON-RPC 2.0 based protocol). The protocol defines several domains. Each domain defines commands and events which are the messages the frontend and the backend exchange with each other. Actual implementation of backend commands is provided by agent classes that live in WebCore and JavaScriptCore side. On the frontend side, several observer classes can listen and respond backend notifications.

Update (2016-01-16): Timothy Hatcher:

As the years progressed, we rapidly added to the tool — exposing more features and evolving the UI to adapt to new developer workflows. To commemorate the past 10 years of Web Inspector, we put together this timeline of major events and past blog posts for posterity.

Wednesday, January 13, 2016 [Tweets] [Favorites]

The Most Upgradable Portable Mac Ever

Thomas Brand:

The PowerBook G3 Series was Apple’s most upgradable portable computer ever! It weighed 7.8 pounds, and cost anywhere between $2,299 to $7,000 fully loaded. Codenamed “Wallstreet” the PowerBook G3 Series was the second line of Macintosh portable computers to include a PowerPC G3 processor, and the oldest portable Macintosh capable of running Mac OS X.

[…]

The PowerBook G3 Series included two hot swappable docking bays on either side. The left hand bay could accommodate a battery, a 3.5" floppy disk, a Iomega Zip drive, a third-party magnetic optical drive, or even a secondary hard drive. The right hand bay was larger and could accommodate all of the above plus a full size 5.25" optical drive. A small internal nickel-cadmium battery allowed swapping of the main batteries while the computer was asleep, and with two batteries installed at the same time the PowerBook G3 Series could last up to seven hours on a single charge.

It’s hard to remember now just how useful the bays were. When working at my desk, I would often run it with no battery. There was no built-in Wi-Fi, and it was super thick. This particular model was much less reliable than today’s Mac notebooks. Often, mine wouldn’t turn on unless I reset the PMU.

Better Translation of Objective-C APIs Into Swift

Proposal SE-0005 has been accepted:

This proposal describes how we can improve Swift’s “Clang Importer”, which is responsible for mapping C and Objective-C APIs into Swift, to translate the names of Objective-C functions, types, methods, properties, etc. into names that more closely align with the Swift API Design Guidelines being developed as part of Swift 3. Our approach focuses on the differences between the Objective-C Coding Guidelines for Cocoa and the Swift API Design Guidelines, using some simple linguistic analysis to aid the automatic translation from Objective-C names to more “Swifty” names.

The new names will not be as Googleable, and this may make switching back and forth between Swift and Objective-C more difficult. But I think it’s a good move to leverage the type system to make the APIs more concise, but not overly so.

Update (2016-02-03): Nate Cook:

This is a concurring opinion with Drew’s review, agreeing that we should reconsider removing the “NS” prefix but providing my own reasons. The proposal as a whole is exciting and far-reaching, but this particular change is misguided.

1) The change will elide the different semantic expectations for Foundation and Swift standard library types.

[…]

2) The change may stifle the development of more Swift-oriented APIs.

[…]

3) The change will make it harder to find information about the revised APIs.

Drew Crawford:

No, the elimination of 2 characters is not significant enough of a problem to break all Swift programs, let alone to introduce literally thousands of new opportunities for shadowing.

Backblaze Mails Unencrypted Hard Drives

Tamara Burns (via Hacker News):

Plaintiff Scott Hellervik takes issue with Backblaze’s procedures for returning a large amount of information back to the user via an external recovery drive. When customers order an external storage drive, Backblaze then unencrypts the data that is loaded onto the drive, and ships it to the customer without added protection, according to Hellervik.

Additionally, when shipping hard drives, the physical packaging contained very concerning private information, the class action lawsuit alleges. According to a label displayed in the court documents, Backblaze has its full name and address, drawing attention to its status as a well-known data backup and recovery company, and includes the recipient’s name and address, of course, but also includes the customer’s phone number and personal email address. “USB Restore” is listed under the department number on the label, exposing the contents within.

According to the Backblaze class action lawsuit, “Sending highly sensitive unencrypted personal information through the mail is reckless. By failing to encrypt customers’ personal information before mailing it (and, in fact, actively unencrypting it), Backblaze allows nefarious parties to target these packages (given the sensitive information disclosed on the shipping labels), intercept them before reaching the intended customers, and access their sensitive personal information.”

CrashPlan used to mail restoration hard drives using its own encrypted format. However, on January 4 it discontinued the Restore-to-Door service. Its seeding service to speed initial backups was discontinued in late 2015. So I don’t know of any Mac backup services that get this right.

Update (2016-01-13): Gleb Budman:

we actually offer encrypted restore drives at no extra cost.

Don’t Leave an iTunes Store Page Open in iTunes

Kirk McElhearn:

If you use a laptop, and your battery dies quickly, check and see if you accidentally left iTunes open on an iTunes Store page, even in the background. Look how much CPU it uses to simply display a front page, and rotate graphics in the carrousel at the top of the page[…]

If I have a store page open, I see constant 20-60% CPU use from iTunes, even when it’s hidden and not playing music.

Tuesday, January 12, 2016 [Tweets] [Favorites]

CloudKit JS

AgileBits:

CloudKit is still the way that developers access the iCloud database, but Apple has provided a brand new way of accessing their CloudKit servers: CloudKit web services. CloudKit web services allows apps to access CloudKit via a really nice web framework called CloudKit JS. When these changes were announced at WWDC, we were excited to start working with this new framework to see what possibilities it would present. Ultimately, CloudKit JS enabled us to support iCloud sync in our AgileBits Store version of 1Password.

[…]

To make sync as seamless and stable as possible we wanted to make very few changes to the existing sync code in 1Password. We felt the best way to do that was to make a framework that looks and acts like Apple’s native CloudKit framework, but uses the CloudKit web services. This means 1Password can use Apple’s native CloudKit framework in the Mac App Store version, and our new AgileCloudKit framework in the AgileBits Store version.

[…]

CloudKit JS does not use the iCloud settings from OS X, so to authenticate with Apple, 1Password will prompt you to log in to your iCloud account by displaying the iCloud login page in your default web browser.

They plan to make the framework open source, which is great news. But think of all the engineering hours spent making a harder to use version of the API Apple is withholding.

Michael Fey:

We need to have a product in the store, but the customer does not need to own it to use AgileCloudKit.

Dave DeLong:

Yes. The policy is that you can use the [Web service] as long as you have a comparable app in the stores

Update (2016-05-06): Rick Fillion:

Today we’re pleased to announce that AgileCloudKit is officially open source and available on GitHub. AgileCloudKit is a framework that we’ve built for the purpose of bringing iCloud Sync to the AgileBits Store version of 1Password. AgileCloudKit allows us to take our existing iCloud Sync solution and make it work outside the Mac App Store.

Master List of CarPlay Vehicles

Apple (via Christopher Turner, archived list):

Every major automobile manufacturer currently offers models that support CarPlay or is planning to introduce them.

Unfortunately, many of them fall into the second category of only having plans, including Nissan, Kia, and Toyota (until recently the largest car company in the world).

johncarync:

For reference: Major brands sold in the US that are not on the list: Acura*, Alpha Romeo*, Aston Martin, Bently, BMW*, Chrysler*, Dodge*, Fiat*, Infiniti, Jaguar*, Jeep*, Kia*, Lamborghini, Land Rover*, Lexus, Lotus, Lincoln, Masarati, Mazda*, Mini, Nissan*, Ram*, Rolls Royce, Scion, Smart, Subaru*, Tesla, Toyota*

*Listed as a partner on Apple’s CarPlay website so they have something in the works just not released yet.

Previously: CarPlay.

Update (2016-01-30): Julio Ojeda-Zapata:

In my CarPlay testing over two weeks — one with the Silverado, another with the Regal — I found it to be equal parts enjoyable and frustrating. On the plus side, I vastly preferred using an Apple-designed interface over the one provided by the car maker. What iPhone user wouldn’t? At the same time, CarPlay’s simplified nature irked me after having used a full-featured iPhone in my car for years.

Update (2017-01-13): Jared Dipane:

Here’s a current list of the cars that Apple says support CarPlay, and we’ll keep the list updated as more announcements are made. Keep in mind, CarPlay is often packaged as an option for these vehicles, so you may need to jump to a higher price point in order to take advantage of it.

Still no Nissan or Toyota.

How to Fix Stuck Mac OS X Clipboard

Dan Warne (via John Gordon):

Something has been bugging me with OS X for a while — sometimes the OS X clipboard (officially known as “pasteboard”) gets stuck and won’t accept any new ‘copied’ content. Instead, when you ‘paste’ in any app, the clipboard always pastes back the last thing you successfully copied.

I’ve been seeing this for years, but it usually works again after a few minutes. He says that killing the pboard process helps.

Intel CPU Bugs of 2015

Dan Luu (via Hacker News and Peter Steinberger):

We’ve seen at least two serious bugs in Intel CPUs in the last quarter, and it’s almost certain there are more bugs lurking. Back when I worked at a company that produced Intel compatible CPUs, we did a fair amount of testing and characterization of Intel CPUs; as someone fresh out of school who’d previously assumed that CPUs basically worked, I was surprised by how many bugs we were able to find. Even though I never worked on the characterization and competitive analysis side of things, I still personally found multiple Intel CPU bugs just in the normal course of doing my job, poking around to verify things that seemed non-obvious to me. Turns out things that seem non-obvious to me are sometimes also non-obvious to Intel engineers. As more services move to the cloud and the impact of system hang and reset vulnerabilities increases, we’ll see more black hats investing time in finding CPU bugs. We should expect to see a lot more of these when people realize that it’s much easier than it seems to find these bugs. There was a time when a CPU family might only have one bug per year, with serious bugs happening once every few years, or even once a decade, but we seem to have moved past that. In part, that’s because “unpredictable system behavior” have moved from being an annoying class of bugs that forces you to restart your computation to an attack vector that lets anyone with an AWS account attack your cloud-hosted services, but it’s mostly because CPUs are now complex enough that they’ve become too complicated to test effectively. Ironically, we have hardware virtualization is supposed to help us with security, but the virtualization is so complicated4 that the hardware virtualization implementation is likely to expose “unpredictable system behavior” bugs that wouldn’t otherwise have existed.

Night Shift in iOS 9.3

Apple:

Many studies have shown that exposure to bright blue light in the evening can affect your circadian rhythms and make it harder to fall asleep. Night Shift uses your iOS device’s clock and geolocation to determine when it’s sunset in your location. Then it automatically shifts the colors in your display to the warmer end of the spectrum, making it easier on your eyes. In the morning, it returns the display to its regular settings. Pleasant dreams.

Surprisingly, it is configurable.

Juli Clover:

The Night Shift feature appears to be limited to iOS devices that have a 64-bit processor.

Previously: Sideloading f.lux on iOS.

Update (2016-01-15): f.lux (via Hacker News):

Rather than suggest simple answers, our mission is to enable f.lux to advance the science, while providing customized solutions for each person. We intend to make f.lux better in every way than the app we designed back in 2009.

Today we call on Apple to allow us to release f.lux on iOS, to open up access to the features announced this week, and to support our goal of furthering research in sleep and chronobiology.

Update (2016-02-18): Steven Aquino:

Night Shift strikes me as one of those technologies that isn’t intentionally built for accessibility’s sake, but works well enough that it also has relevance to people with disabilities.

[…]

Secondly, all the consideration I’ve put into the brightness and contrast of an iOS device’s screen leaves me longing for a system-wide dark mode.

Unencrypted iTunes Backups Don’t Include Health Data

Trevor McKendrick:

Unbelievable. If you restore an unencrypted iPhone backup from iTunes, all your health data disappears.

Apple:

The Encrypt Backup feature in iTunes locks and encodes your data. An encrypted iTunes backup includes certain information that other backups don’t:

  • Your saved passwords
  • Wi-Fi settings
  • Website history
  • Health data

iTunes doesn’t encrypt your backups by default. To encrypt a backup in iTunes for the first time, you’ll need to turn on the password-protected Encrypt Backup option. After you turn on Encrypt Backup, iTunes automatically makes encrypted backups for that device from then on.

This makes a fair amount of sense as a privacy feature. You might not want your health data stored in the clear. But I doubt many people know how this works, and encrypted backups are not the default, so it’s easy to accidentally lose your data when restoring. As far as I know, there is no good warning about what might happen.

After you’ve overwritten your phone with the unencrypted backup, and used the phone for a while, it’s not clear what to do. iOS backups and restores are all-or-nothing. There is no granularity to say: keep the new data I’ve created in other apps, but restore my old HealthKit data from iCloud.

Update (2016-01-12): Hwee-Boon Yar:

I had a corrupted health.db in an iCloud backup. After a few days, couldn’t get a working version anymore.

…had to setup iPhone as new, lost all health data (years of steps and sleep data from Jawbone UP) and watch activity.

Plugs in Boxes:

My Workflow for exporting and importing Health data to and from CSV

Sunday, January 10, 2016 [Tweets] [Favorites]

Proposal: XCTest Support for Swift Error Handling

Chris Hanson:

Swift 2 introduced a new error handling mechanism that, for completeness, needs to be accommodated by our testing frameworks. Right now, to write tests that involve methods that may throw an error, a developer needs to incorporate significant boilerplate into their test. We should move this into the framework in several ways, so tests of code that interacts with Swift error handling is concise and intention-revealing.

[…]

One other downside of the above is that a failure caught this way will be reported as an expected failure, which would normally be a failure for which XCTest is explicitly testing via an assertion. This failure should ideally be treated as an unexpected failure, as it’s not one that’s anticipated in the execution of the test.

[…]

I propose several related solutions to this issue:

  1. Allow test methods to throw errors.
  2. Allow test assertion expressions to throw errors.
  3. Add an assertion for checking errors.

Drew Crawford:

This proposal IMO addresses an important problem, but I am not convinced it actually solves it. #2 & #3 are basically sound API designs. It is a mystery to me why #3 “generated some debate” as this is a feature I already implement manually, but I can’t address unknown concerns. I can tell you I implement this, and nothing terrible has happened to me so far.

[…]

When the test function throws we no longer even find out a line number in the test case anymore, because the error is passed into XCTest and the information is lost. We have just the name of the test case (I assume; the proposal is silent on this issue, but that’s the only way I can think of to implement it), and some of my tests are pretty long. So, that makes it even harder to track down.

This sounds like a small thing but my test coverage is so thorough on mature projects that mostly what I turn up are heisenbugs that reproduce with 2% probability. So getting the report from the CI that has the most possible detail is critical, because if the report is not thorough enough for you to guess the bug, too bad, because that’s all the information you get and the bug is not reproducible.

For that reason, I won’t use #1.

Indeed, Swift and XCTest don’t currently work together very smoothly. I suspect that many developers have implemented their own versions of #2 and #3 already.

The lack of support for tracing the flow of errors is a more general problem that goes beyond testing. With exceptions, you would get a stack trace. In Objective-C, it’s easy to use macros to add tracing information to errors when propagating them. In Swift, I’ve seen this tip for tracking the source of errors that you create, but that isn’t most errors.

PayPal’s Poor Security

Brian Krebs (via @SwiftOnSecurity):

My PayPal account was hacked on Christmas Eve. The perpetrator tried to further stir up trouble by sending my PayPal funds to a hacker gang tied to the jihadist militant group ISIS. Although the intruder failed to siphon any funds, the successful takeover of the account speaks volumes about why most organizations — including many financial institutions — remain woefully behind the times in authenticating their customers and staying ahead of identity thieves.

[…]

But by the time I got back home to a computer, my email address had been removed and my password had been changed. So much for PayPal’s supposed “monitoring;” the company couldn’t even spot the same fraudulent email address when it was added a second time.

[…]

In my second call to PayPal, I insisted on speaking with a supervisor. That person was able to tell me that, as I suspected, my (very long and complex) password was never really compromised. The attacker had merely called in to PayPal’s customer support, pretended to be me and was able to reset my password by providing nothing more than the last four digits of my Social Security number and the last four numbers of an old credit card account.

[…]

PayPal does offer additional security protections — including a PayPal Security Key fob that periodically generates a new one-time password which needs to be entered at login in addition to a username and password. I’ve used this solution since shortly after the company began offering it almost a decade ago, but a fat lot of good it does if PayPal is going to continue letting users reset their passwords by regurgitating static data that is trivial to purchase from the cybercrime underground.

Dave Mark:

Last night we got an email from a PayPal spokesperson with this official response:

The safety and security of our customers’ accounts, data and money is PayPal’s highest priority. Due to our privacy policies that protect our customers, PayPal does not publicly disclose details about our customers’ accounts or their specific cases. However, it appears that our standard procedures were not followed in this case. While the funds remained secure, we are sorry that this unacceptable situation arose and we are reviewing the matter in order to prevent it from happening again.

The 15-Year History of iTunes

Kirk McElhearn:

Jobs then introduced iTunes, arguably the most important software Apple ever released, other than its operating systems. iTunes set the tune for the company’s next decade and its rise from a “beleaguered” hardware and software company to the industry leader we know today. Admitting that Apple was playing catch-up, Jobs said, “We’re late to this party and we’re about to do a leapfrog.”

And they sure did.

[…]

In my writings about iTunes—notably my Ask the iTunes Guy column—I field questions from users perplexed by the quirks of this app. I used to get questions asking how to do something more efficiently, and I was able to help people organize and manage their music creatively. Now, most of the questions I get are about trying to work around things that are broken, or how to find features that were once easily accessible. More and more users long for a simple music player that sheds much of the cruft that has built up over the years.

When he started the column, I totally underestimated how much material there would be for it.

Update (2016-01-12): Nick Heer:

For my use, iTunes has become steadily worse over the years, as I’m regularly pushed to purchase more from the iTunes Store and place all my music in iCloud. Neither of those things appeals to me. Yet, I’m compelled to continue using iTunes partly because I sync my iPhone in the old-fashioned way, and partly because I’ve never found a compelling replacement for it.

Office 2016, Sandboxing, and VBA Code

Ron de Bruin:

In Windows Excel 97-2016 and in Mac Excel 2011 you can open files or save files where you want in almost every folder on your system without warnings or requests for permission. But in Mac Office 2016 Microsoft have to deal with Apple’s sandbox requirements. When you use VBA in Mac Excel 2016 that Save or Open files you will notice that it is possible that it will ask you permission to access the file or folder (Grant File Access Prompt), this is because of Apple’s sandbox requirements. This means that when you want to save/open files or check if it exists with VBA code the first time you will be prompted to allow access on the first attempt to access such a folder or file.

He recommends putting your documents in the Library folder:

There are a few places on your Mac that you can use to avoid the prompts and let your code do what it needs to do without user interaction. But these folders are not in a place that a user can easily find so below are some steps that I hope to make it easier for you to access the folder manual if you want.

Saturday, January 9, 2016 [Tweets] [Favorites]

Improving the iOS 9 Videos App

I find the iOS Videos app frustrating to use. It’s almost unbelievable that in the 9th major version of the OS it’s missing what seem to be some pretty basic features. However, this also means that it should’t be hard to make it a lot better:

Of course, ideally we wouldn’t have to wait for Apple to improve the Videos app. After all, we have the App Store. Lots of people don’t like the new Music app, but fortunately there are excellent third-party alternatives such as Ecoute (App Store). However, as far as I can tell, none of the many video apps in the store are a viable alternative to Apple’s Videos app. It looks like there are APIs for apps to get a list of locally stored videos, but there’s no way for apps to see which videos were purchased and to selectively download them from the cloud. The same limitations are in place for music, but that doesn’t matter so much because the iPhone has plenty of space to store my entire music library. It’s not feasible to store one’s entire video library on an iOS device. My iPad only has enough free space for one movie at a time. An app for managing videos must be able to manage videos that are stored in the cloud.

Update (2016-01-10): Actually, it appears that there is an API for accessing music in the cloud, and Ecoute lets you control whether non-local songs are shown. You can stream them but not manage the local copies.

Jared Sinclair:

Re: Videos․app, this unforgivable caching bug introduced with iOS 7 is still around on iOS 9

TL;DR “Streamed” playback is downloaded in full resolution, not cleared, nor manually clearable w/out signing out/back in.

Friday, January 8, 2016 [Tweets] [Favorites]

Exploring Swift Array’s Implementation

Ankit Aggarwal:

Swift declares a C struct in its SwiftShim’s module inside GlobalObject.h called _SwiftArrayBodyStorage

[…]

  • count is the number of elements currently stored in the buffer
  • _capacityAndFlags is used to store two things:

    • first is the capacity of the buffer
    • second “Is the Element type bitwise-compatible with some Objective-C class?”

Via David Smith:

Apparently C-like performance, memory safety, resizing, copy-on-write, and ObjC bridging all together is hard

The subscript implementation in _ContiguousArrayBuffer has an interesting note:

Manually swap because it makes the ARC optimizer happy.

The method is also marked with a mysterious nonmutating keyword, which the Swift language guide mentions but does not explain. This could be an optimization to avoid unnecessary writebacks or a way to make the compiler enforce that the setter does not actually change any properties of the structure (just the contents of the memory they point to).

Update (2016-05-03): Jasdev Singh:

Stepping through Sidney’s example, we can see how nonmutating signals that a setter doesn’t modify the containing instance, but instead has global side effects.

Slow Swift Array Type Inference

Benjamin Encz:

Slow compile time in Swift? Try to rearrange some of your expressions.

Update (2016-01-20): Bryan Irace (tweet):

I had a problem. The new iOS application that I’m working on – written 100% in Swift – was noticeably taking much longer to compile than should, given its size (~200 files). More concerning, it was suddenly a lot slower than only a couple of weeks prior. I needed to get to the root of the problem as soon as possible, before it got any worse.

The first step was to add -Xfrontend -debug-time-function-bodies to my Swift compiler flags […] This causes the compiler to print out how long it takes to compile each function […]

Six Colors’ Apple Report Card

Jason Snell:

Generally, our panel praised the quality of Apple’s hardware design and reliability. As John Moltz wrote, “Apple hardware continues to be one of its great strengths.” “Better than ever,” wrote Stephen Hackett. “No one else seems close,” wrote Rich Mogull.

[…]

If the broad perception is that hardware remains an Apple strength, here’s the flip side: the perception that Apple’s software efforts lag behind.

[…]

Serenity Caldwell framed the issue as one of focus. “iOS still feels buggy and unfinished. iPad Pro launched without any key Apple iOS apps. Too many software projects for one year.” As James Thomson wrote, “iOS and OS X are improved, but it feels that many other things are barely held together with digital string.”

Other panelists were far less generous. “Software quality has really gone downhill,” wrote Khoi Vinh. “Apple’s software quality continues to drop,” wrote Adam Engst. Rob Griffiths praised iOS but had harsh words for OS X: “Longstanding seemingly ‘simple’ bugs don’t get fixed.”

I agree that Apple’s hardware quality continues to be great. Aside from reverting to mDNSResponder, I have not seen an overall improvement in software quality this year. With Mac OS X 10.11, I’m still regularly seeing problems with Finder, Mail, Safari, Disk Utility, Preview, Calendar, Spotlight, and Time Machine that were not present in previous versions. I hear a lot about Mail from my customers, and Mail in 10.11 overall seems to be even less reliable than in 10.10. And old bugs from 10.10 and even 10.9 remain. iOS has always been relatively less buggy for me, but it still has some annoying bugs as of 9.2. I hear people saying that Apple kind of did a Snow Leopard in 2015, but I’m just not seeing it.

Our panel’s message is clear: Apple has a lot of work to do to repair its relationship with third-party software developers. “Apple’s heading towards a crisis point,” wrote Andy Ihnatko. “In 2014, I said that I’d never seen Apple developers less happy. Things are even worse a year later[…]

[…]

The developers on our panel specifically cited long delays to process approvals and builds, with iTunes Connect being “the least reliable this year than at any time in the last seven years,” according to James Thomson.

I agree with all of this. Swift, and the way Apple has handled its open sourcing, is mostly a bright spot, though.

Generic Collections, SubSequences and Overloading

Airspeed Velocity:

And before long you smack your head against one of the more confusing things about generic collections: a sequence’s SubSequence doesn’t necessarily contain the same element type as that sequence. This usually manifests itself in one of those compiler errors that has you yelling “what are you talking about you infernal machine” at the compiler before eventually realizing what you’ve done wrong and sheepishly fixing it.

[…]

There’s nothing about this definition that forces the elements of SubSequence to be anything specific. Really, this needs a where clause on the typealias – something that Swift doesn’t currently support[…] So, in the mean-time, the way around this is to specify any requirements like this as part of the declaration.

Apple Mail Ignores Named Anchors

Adam C. Engst:

I now have direct confirmation that Apple is aware that the versions of Mail in both OS X 10.11 El Capitan and iOS 9 do not properly honor navigating to standard HTML named anchor tags.

[…]

Frankly, I find this bug extremely distressing, not because it’s all that significant — you can always just scroll down in the TidBITS issue — but because named anchors were described in the 1992 CERN document (presumably by Tim Berners-Lee) that was the very first public documentation of HTML. It boggles the mind that Apple’s engineers could bungle such a simple behavior that sits at the very core of HTML, and fail to fix it in the two minor updates to El Capitan and iOS 9 released so far.

Microsoft Solitaire Was Developed by a Summer Intern

Wes Cherry (via Hacker News):

I wrote it for Windows 2.1 in my own time while an intern at Microsoft during the summer of 1988. I had played a similar solitaire game on the Mac instead of studying for finals at college and wanted a version for myself on Windows.

The code is nothing great…the only slightly interesting thing is the optimizations I did to get card dragging to work smoothly. Back in those days getting a pixel onto the EGA buffer took getting out a hammer and chisel and chipping away at the silicon for an eternity.

Object oriented programming was a newish thing back then and there wasn’t a C++ compiler available for windows, so it has a goofy message passing architecture to get polymorphism and inheritance.

At the time there was an internal “company within a company” called Bogus software. It was really just a server where bunch of guys having fun hacking Windows to learn about the API tossed their games. A program manager on the Windows team saw it and decided to include it in Windows 3.0. It was made clear that they wouldn’t pay me other than supplying me with an IBM XT to fix some bugs during the school year - I was perfectly fine with it and I am to this day.

Thursday, January 7, 2016 [Tweets] [Favorites]

SecTransformExecuteAsync Considered Confusing

Jeff Johnson:

We have a group transform that first generates a digest from the message and then signs the message digest. Intuitively, you would think that the intermediate result would be the digest, and the final result would be the signature, right? Right?

I don’t know how it’s intended to work, but my interpretation of the vague documentation is that you don’t get results from the intermediate transforms. You get intermediate results for the final transform. This is the same result as with SecTransformExecute, only it’s possibly split into chunks. isFinal means that you’ve received the last chunk.

The documentation in Dash says that the SecTransform functions aren’t available in Swift, but that seems to be incorrect.

Swift 2.2 Release Process

Apple:

Swift 2.2 is the first offical release of Swift after Swift was released as open source. It will be a mostly source-compatible release with Swift 2.1, containing a large number of core improvements (e.g., bug fixes, enhancements to diagnostics, faster generated code) without many significant visible changes to the language itself. It is intended to be an intermediate point between Swift 2 and Swift 3, with Swift 3 containing more disruptive changes to both the language and Standard Library.

Commonly Rejected Changes:

This is a list of changes to the Swift language that are frequently proposed, but that are unlikely to be accepted. If you’re interested in pursuing something in this space, please familiarize yourself with the discussions that we have already had. In order to bring one of these topics up, you’ll be expected to add new information to the discussion, not just say “I really want this” or “This exists in some other language and I liked it there”.

Facebook Tests Users’ Reaction to Crashes

Anil Dash quotes an article by Amir Efrati:

Facebook has tested the loyalty and patience of Android users by secretly introducing artificial errors that would automatically crash the app for hours at a time […] Even if the native app continued to not work, the users would open Facebook on their phone’s mobile browesr.

Neven Mrgan:

A depressing fact: even learning of this very deception still won’t make users quit. There is no “choice”.

Basically no amount of abuse is going to make me attempt to convince my uncles to stop using Facebook, so eff it.

Five Years of Mac App Store

Graham Spencer:

The Mac App Store, announced at Apple’s ‘Back to the Mac’ event in late 2010, offered the alluring promise of revitalising the Mac app market with easier access to customers, and, it was hoped, greater financial success for developers.

[…]

Apple has let the Mac App Store stagnate and become a second class citizen to the iOS App Store and too many developers are leaving or avoiding the Mac App Store. When important apps leave the Mac App Store, it makes the store as a whole less enticing and customers have one less reason to open the Mac App Store.

Just how often do you open the Mac App Store?

Michael Rockwell:

But Graham’s right, the only time I ever open the Mac App Store is when there are updates available for software I already own.

Stephen Hackett:

There’s still promise in the Mac App Store, but Apple has a long way to go to prove that it can be worthwhile for developers again. I’d like to see them address this, since an all-in-one place to download and update apps can really simplify things for everyday users.

Nick Heer:

The Mac App Store simply doesn’t compete. […] when few high-profile apps are available from the Mac App Store and the Store is cluttered with lots of really crappy apps, it’s hard to recommend it.

Swift Bracing

Erica Sadun:

It’s a shame then that the language has adopted 1TBS over Allman when the latter exposes scope so beautifully and the former can be quite hard to follow, especially with respect to complex declarations that include external and internal labels, default values, and other complicating features

Around the time Swift was introduced, I switched to 1TBS after about 20 years of Allman. I like the compactness.

The indentation of switch statements is pretty bad, though. At first I thought it was a bug in Xcode’s auto-indentation, but the Swift documentation uses the same style.

Clearing the App Store Cache

Zachary Drayer:

tap on any of the tab bar items 10 times.

(that forces the App Store to clear its cache and reload everything)

Mike Rundle:

Craziest iOS dark magic I’ve ever heard. How to clear the App Store cache by @zadr. It works!

Tuesday, January 5, 2016 [Tweets] [Favorites]

Unexpected iCloud Music Library Downloads

Kirk McElhearn:

This weekend, I wanted to add some music to the cloud, so I grabbed a bunch of files from my main library and added them to the MacBook’s library. I was very surprised to notice later that most of them had automatically downloaded to my iPad. The device had no music on it at all; now it shows 3.9 GB of music.

[…]

I later noticed that the same music was downloaded to my iPod touch, for a total of about 8 GB. I don’t have a bandwidth cap, but if I did, I’d be mighty unhappy. Also, if I were using an iPhone, and it was set to allow cellular downloads, I’d be irate.

Government Encryption Registration and SNAP-R

Carousel Apps (via Hacker News):

Last week we published a blog post describing how if your app does anything with encryption, even a single https request, then you need an Encryption Registration (ERN) from the US Bureau of Industry (BIS).

You need to submit an updated encryption export compliance report each year.

Why the 2012 non-Retina MacBook Pro Still Sells

Marco Arment:

As we’ve progressed toward thinner, lighter, more integrated Macs, we’ve paid dearly in upgradeability, versatility, and value. There are many Macs to choose from today, but in some ways, we have less choice than ever. The 101 represents the world we’re leaving behind, and our progress hasn’t all been positive.

The better question isn’t why anyone still buys the 101, but why the rest of the MacBook lineup is still less compelling for the 101’s buyers after almost four years, and whether Apple will sell and support the 101 for long enough for newer MacBook models to become compelling, economical replacements.

I hope they don’t get rid of the 11-inch MacBook Air.

Update (2016-01-07): John Gruber:

It occurs to me that for all our collective worrying about the iOS-ification of Mac OS X, it’s the MacBook hardware that’s gotten iOS-ified, not the software. Thinness as a top priority, and an almost complete lack of upgradeability.

Nick Heer:

I think most kids would have their eyes opened at just how straightforward it is to snoop around inside many of today’s tech products. I replaced the SSD in my MacBook Air this past weekend and was pleasantly surprised at how much easier it was than replacing the hard drive in my mid-2007 MacBook Pro. It took just ten screws to remove the back panel and a single screw to remove the drive, as opposed to the far more screws and clips required to remove the top case of the Pro.

Google Docs Data Loss

John Gordon:

Today I discovered the 2010 document has lost its images. The text is there, but the images are gone. I tried downloading as PDF, but they don’t show there.

It’s a significant non-recoverable Google Cloud data loss, probably related to old versions of Google Docs.

Microsoft takes data longevity more seriously than Apple and Google.

Nintendo, Two Years Later

Lukas Mathis:

There’s still a console market. Mobile devices didn’t kill it. Nintendo can be profitable on its own platforms, but that hasn’t kept them from also starting to work on mobile titles. Unfortunately, we probably still won’t see a «real» Nintendo title — a full Mario Kart or New Super Mario Bros title, for example — on iOS anytime soon.

Previously: Nintendo.

Sunday, January 3, 2016 [Tweets] [Favorites]

Shuffle in iOS 9.2’s Music App

John Gordon:

With Music.app in OS 9.x Apple effectively made “shuffle” the default way to play an album or playlist. That’s not necessarily bad, but where they went off the rails was they gave one icon two very different behaviors.

[…]

So on this screen, to recap, there are 3 functions, play non-shuffle, play-shuffle, and pause. The functions are distributed between two controls, one a toggle and the other an action button, and the action button uses the same icon as a toggle control that appears on another screen.

More generally, the new Music app is a regression for anyone not using Apple Music. There’s too much going on, too many indicators and controls that I don’t need to see. The font is too small, yet text is also too often truncated. All the music that I listen to is stored on the iPhone, and it wastes a line at the top of the screen to constantly tell me this. Then it shows barely recognizable iPhone-checkmark icons on each song, not lined up. The Albums and Artists tabs at the bottom are gone, replaced by Radio and Connect, which I never use.