Archive for September 27, 2018

Thursday, September 27, 2018 [Tweets] [Favorites]

How Dropbox Migrated to Python 3

Max Bélanger and Damien DeVille (Hacker News, Reddit):

Though we’ve relied on Python 2 for many years (most recently, we used Python 2.7), we began moving to Python 3 back in 2015. This transition is now complete: If you’re using Dropbox today, the application is powered by a Dropbox-customized variant of Python 3.5. This post is the first in a series that explores how we planned, executed, and rolled out one of the largest Python 3 migrations ever.

[…]

To solve this build and deploy problem, we decided on a new architecture to embed the Python runtime in our native application. Rather than delegate this process to the freezers, we would use tooling specific to each platform (e.g. Visual Studio on Windows) to build the various entry points ourselves. Further, we would abstract Python code behind a library, aiming to more directly support the “mixing and matching” of various languages.

This would allow us to make use of each platform’s IDEs/toolchain directly (e.g. to add native targets like FinderSync on macOS) while retaining the ability to conveniently write much of our application logic in Python.

Android at 10

Dieter Bohn:

In an effort to ensure that another company wouldn’t gain dominant control over the mobile market, Google and Android have wildly, unequivocally succeeded in doing just that.

Android has taken the place in smartphones that Windows once held with desktops: dominant market share. Worldwide, IDC pegs Android’s share at about 85 percent. We can argue about regions and whether enough of those customers are willing to spend money on apps and many other things, but that number is almost too big for nuance.

Android is the dominant computing platform on the planet. Not only has Android prevented some version of Windows from taking over mobile, but it has actually eclipsed Windows as the most popular operating system, period.

CodeRunner 3

Nikolai Krill:

The all-new documentation sidebar lets you browse the online docs for your programming language without ever leaving the app.

[…]

The editor has been enhanced with lots of new features. It now supports more than 230 syntax highlighting modes, all updated to the latest language specifications.

[…]

Web development is now more powerful than ever in CodeRunner. Use the built-in Web Inspector to debug JavaScript, view and edit HTML elements, work with CSS styles, and much more. New run modes for web files let you magically inject your JavaScript or CSS files into a website or HTML file. When running your PHP files, the output can now be quickly toggled between terminal and web mode.

Todd Ditchendorf:

Wow. Dunno when this happened exactly, but CodeRunner 3.0 includes a graphical debugger UI for Python. And it’s the best I’ve seen. (By “best”, I suppose I mean “most like Xcode”… cuz that’s what I’m used to). And it seems to work with virtual environments. Nice!

Previously: CodeRunner 2, CodeRunner 1.0.

What Facebook Does For Advertisers

Kashmir Hill (Hacker News):

Facebook is not upfront about this practice. In fact, when I asked its PR team last year whether it was using shadow contact information for ads, they denied it. Luckily for those of us obsessed with the uncannily accurate nature of ads on Facebook platforms, a group of academic researchers decided to do a deep dive into how Facebook custom audiences work to find out how users’ phone numbers and email addresses get sucked into the advertising ecosystem.

[…]

They found that when a user gives Facebook a phone number for two-factor authentication or in order to receive alerts about new log-ins to a user’s account, that phone number became targetable by an advertiser within a couple of weeks. So users who want their accounts to be more secure are forced to make a privacy trade-off and allow advertisers to more easily find them on the social network.

Parmy Olson:

Facebook’s plans remain unclear. When Sandberg, Facebook’s COO, was asked by U.S. lawmakers in early September if WhatsApp still used end-to-end encryption, she avoided a straight yes or no, saying, “We are strong believers in encryption.” A WhatsApp spokesperson confirmed that WhatsApp would begin placing ads in its Status feature next year, but added that even as more businesses start chatting to people on the platform, “messages will remain end-to-end encrypted. There are no plans to change that.”

For his part, Acton had proposed monetizing WhatsApp through a metered-user model, charging, say, a tenth of a penny after a certain large number of free messages were used up. “You build it once, it runs everywhere in every country,” Acton says. “You don’t need a sophisticated sales force. It’s a very simple business.”

[…]

Within 18 months, a new WhatsApp terms of service linked the accounts and made Acton look like a liar. “I think everyone was gambling because they thought that the EU might have forgotten because enough time had passed.” No such luck: Facebook wound up paying a $122 million fine for giving “incorrect or misleading information” to the EU—a cost of doing business, as the deal got done and such linking continues today (though not yet in Europe).