Categories
Programming What I’m Up To

I’m building 20 projects in 2020!

Photo: 20 Projects in 2020, featuring a white Apple Watch and White iPhone outdoors on a wooden picnic table.

Here’s my personal challenge for this year: I will try to complete at least 20 small software projects in 2020 and document them here on Global Nerdy. The number of projects I’ve chosen to attempt this year comes straight from the way the year is commonly pronounced: twenty-twenty.

Why am I doing this? Because now that I’m back to writing code for a living — after a good long period of time as a product manager or owner, a developer evangelist, or a marketer — and I want to up my game. Yes, I’ll get lots of practice at work, but as those of you who code for a living know, the projects you do at work tend to focus on a narrow segment of what’s possible with code, and largely about solving a business problem instead of learning a new technology, language, or skill.

There’s also another reason: quantity leads to quality.

Photo: Cover of “Art & Fear: Observations On the Perils (and Rewards) of Artmaking” by David Bayles and Ted Orland.

There’s a pretty good chance that you’ve heard the “ceramics class quantity vs. quality” story. It’s from the book Art & Fear: Oberservations on the Perils (and Rewards) of Artmaking, and it’s appeared many times over the past couple of decades on sites that techies are likely to read. In Cool Tools, Kevin Kelly included it in a list of excerpts from the book way back in 2003, Jeff Atwood wrote about it in Coding Horror in 2008, then Jason Kottke wrote about it in 2009, Ben Thompson cited it in Stratechery in 2015 when writing about Buzzfeed’s success, and in 2016, it’s referred to in a Hackernoon post.

Here’s the story, with emphasis added by me:

The ceramics teacher announced on opening day that he was dividing the class into two groups. All those on the left side of the studio, he said, would be graded solely on the quantity of work they produced, all those on the right solely on its quality.

His procedure was simple: on the final day of class he would bring in his bathroom scales and weigh the work of the “quantity” group: fifty pound of pots rated an “A”, forty pounds a “B”, and so on. Those being graded on “quality”, however, needed to produce only one pot – albeit a perfect one – to get an “A”.

Well, came grading time and a curious fact emerged: the works of highest quality were all produced by the group being graded for quantity. It seems that while the “quantity” group was busily churning out piles of work – and learning from their mistakes – the “quality” group had sat theorizing about perfection, and in the end had little more to show for their efforts than grandiose theories and a pile of dead clay.

Here’s Jeff “Coding Horror” Atwood’s take-away from this story:

Quantity always trumps quality. That’s why the one bit of advice I always give aspiring bloggers is to pick a schedule and stick with it. It’s the only advice that matters, because until you’ve mentally committed to doing it over and over, you will not improve. You can’t.

When it comes to software, the same rule applies. If you aren’t building, you aren’t learning. Rather than agonizing over whether you’re building the right thing, just build it. And if that one doesn’t work, keep building until you get one that does.

In short, it boils down to the old adage “Practice makes perfect,” or more accurately, “Practice makes progress.”

Most of these projects will be built for “toy” systems: mobile devices, wearables, the Raspberry Pi and set-top boxes. I’ve made this choice for a number of reasons:

  1. I got an Apple Watch for Christmas! Sure, it does neat things like track my exercise and tell the time, but the real reason I got it was to write apps for it.
  2. “Toy” projects allow me to constrain them so that they don’t take an excessive amount of time to build, which is key when you aim to put together 20 projects in a year.
  3. My day-to-day work is mobile development. Anything that makes me better at it is a good thing.
  4. I need topics for my meetup, Tampa iOS Meetup. Yup, that’s making a grand comeback shortly.
  5. I’ve already got an interesting side project that involves the Apple Watch.
  6. I also got a mini-screen for my Raspberry Pi, which has been neglected as of late.

6. Finally, and most importantly, I’m doubling down on the philosophy that I talked about on The 6-Figure Developer podcast: “Always bet on the toy.”

Creative Commons photo by Chris Cox. Tap to see the source.

Chris Dixon wrote about this ten years ago in an article titled The next big thing will start out looking like a toy. Here are the opening paragraphs:

One of the amazing things about the internet economy is how different the list of top internet properties today looks from the list ten years ago.  It wasn’t as if those former top companies were complacent – most of them acquired and built products like crazy to avoid being displaced.

The reason big new things sneak by incumbents is that the next big thing always starts out being dismissed as a “toy.”  This is one of the main insights of Clay Christensen’s “disruptive technology” theory. This theory starts with the observation that technologies tend to get better at a faster rate than users’ needs increase. From this simple insight follows all kinds of interesting conclusions about how markets and products change over time.

Disruptive technologies are dismissed as toys because when they are first launched they “undershoot” user needs. The first telephone could only carry voices a mile or two. The leading telco of the time, Western Union, passed on acquiring the phone because they didn’t see how it could possibly be useful to businesses and railroads – their primary customers. What they failed to anticipate was how rapidly telephone technology and infrastructure would improve (technology adoption is usually non-linear due to so-called complementary network effects). The same was true of how mainframe companies viewed the PC (microcomputer), and how modern telecom companies viewed Skype. (Christensen has many more examples in his books).

He also points out that something being toy-like doesn’t necessarily mean that it will become the next big thing. He’s saying that initially they seem like toys, but due to external forces, they become useful in ways that seem obvious in hindsight but invisible at the time. It’s yet another example of William Gibson’s cyberpunk maxim: “The street finds its own uses for things.”

Dixon closes his article about the next big thing being a toy with this paragraph, which mentions the new decade:

But startups with sustaining technologies are very unlikely to be the new ones we see on top lists in 2020. Those will be disruptive technologies – the ones that sneak by because people dismiss them as toys.

Watch this space as I post about these projects throughout 2020! The first — a simple Apple Watch app that’s also a “How to write an Apple Watch app” article in disguise — will be here on Global Nerdy soon.

Categories
Conferences Florida Tampa Bay

Synapse Summit 2020 volunteer informational meeting: Tuesday, January 7th at Brick House

Banner: Synapse Volunteer Informational Meeting - January 7, 2020 @ Brick House Tavern + Tap, 6 - 8 p.m.

Are you looking for a chance to attend a big tech event, get some serious networking done, and help make Tampa Bay’s tech scene even better? You might want to volunteer at Synapse Summit 2020! They’re holding a volunteer informational meeting this Tuesday, January 7th from 6:00 p.m. to 8:00 p.m. at the Brick House Tavern + Tap.

Photo: The Synapse Summit 2019 exhibitor floor on center ice at Amalie Arena.

The Synapse Summit is Tampa Bay’s largest annual technology and entrepreneurship gathering, bringing together “makers, hackers, thinkers, and doers” from not just the Tampa Bay area and Florida, but the world. Held in Amalie Arena, it brings in thousands of attendees to see keynotes from industry leaders, sessions and panels covering important tech and business topics, and network with the bright lights of Tampa’s growing tech ecosystem. The 2020 Synapse Summit takes place on Tuesday, February 11 and Wednesday, February 12, and general admission tickets are $300 (students, active military, first responders, and government officials can attend for a special deeply-discounted price: $50).

2020 will mark the third time that the Synapse Summit has taken place. It’s organized by Synapse Florida, a non-profit organization whose focus is on boosting Florida’s entrepreneurial ecosystem.

Photo: The front exterior of Brick House Tavern + Tap in Tampa.

Volunteers are a key part of Synapse Summit’s success. As they say on the upcoming meeting’s Eventbrite page:

[Volunteering at Synapse] is a wonderful opportunity to fine tune your skills, network and meet great people and give back and feel good.

We need volunteers for all areas. Regardless of your skills, we can use your help. Come out on 1/7/20 for our volunteer informational meeting being held at Brick House. We want to answer any and all questions you may have.

The bottom line

Categories
Podcasts Programming What I’m Up To

I’m on episode 123 of “The 6 Figure Developer” — “iOS Apprentice & Accordions w/ Joey deVilla”!

Last month, the folks at The 6 Figure Developer podcast interviewed me, and that interview was published this morning! It’s titled iOS Apprentice & Accordions w/ Joey deVilla, and you can find it right on the 6 Figure Developer site, or through your favorite way to find podcasts.

You can also use the player below:

The topics covered in the interview:

  • How I got started in the industry and where I am now. I started as a developer, then a developer evangelist, then marketing, then product owner, and now I’m a developer again!
  • My new job at Lilypad, which I like to describe as “a CRM for the alcohol industry”, and how much fun I’m having being a developer again.
  • My tech strategy: “Always bet on the toy.” The technology that people dismiss as a toy today often becomes tomorrow’s indispensable tool.
  • Working on the 8th edition of iOS Apprentice for raywenderlich.com. It was an adventure, what with having to cover the new SwiftUI framework in a beginner-friendly way. I also talk about being honored to work on this edition of the book, as I learned iOS programming from an earlier edition written by the original author, Matthijs Hollemans.
  • Cross-platform vs. native mobile development and the challenges with each approach. When do you use each approach?
  • The people whose primary way of getting online is their mobile device. I talk about a key demographic — about 8% — whose smartphone is pretty much their only gateway into the online world.
  • Taking an active role in the Tampa Bay tech scene. I explain that it’s a habit I picked up from the Toronto tech scene in the early 2000s, during the era of DemoCamp Toronto. This work helped turn Toronto into one of the top 5 tech powerhouses in North America, and I think Tampa Bay can borrow a few of those tricks.
  • Don’t forget that two Tampa Bay authors have iOS books! It’s not just me, but Craig Clayton as well.
  • Recommended meetups and resources for Tampa Bay mobile developers. There’s Tampa iOS Meetup, the Suncoast Google Developers Group, and of course, the Coders, Creatives, and Craft Beer meetup.
  • My one piece of career advice: It’s actually Eleanor Roosevelt’s advice — “Do the thing you think you cannot do.”

Who interviewed me?

The hosts of The 6 Figure Developer who interviewed me are:

John Callaway: An International Speaker, Author, and Microsoft MVP, John has been a professional developer since 1999. He has focused primarily on web technologies and currently focuses on C# and .NET Core in Azure. Clean code and professionalism are particularly important to him, as well as mentoring and teaching others what he has learned along the way.

Clayton Hunt: Clayton has been programming professionally since 2005 doing mostly web development with an emphasis on JavaScript and C#. He has a focus Software Craftsmanship and is a signatory of both the Agile Manifesto and the Software Craftsmanship manifesto. He believes that through short iterations and the careful gathering of requirements that we can deliver the highest quality and the most value in the shortest time. He enjoys learning and encouraging other to continuously improve themselves.

Jon Ash: Jon has been a web developer since 2011 and a professional consultant since 2006. Coming from the aerospace industry he brings a passion for professionalism and excellence. He has a broad experience in current web technologies, with a strong foundation in C# and JavaScript. Though working knowledge of technologies are important, he takes pride in practicing and promoting clean code, adherence to the SOLID principles, and disciplines such as Test Driven Development.

Categories
Current Events Humor

Fake ad, but true statement

Tap the photo to see it at full size.

This is why I’ve been posting most things — even if it’s just a single photo or link — on my blogs rather than social media. As far as I’m concerned, the primary purpose of Facebook, Twitter, and LinkedIn are to direct readers to my blogs.

Categories
Security The Street Finds Its Own Uses For Things

Weaponizing social media with strobing images, Neuromancer, and what we can do

In another occurrence of terrible people weaponizing the internet, a number of assholes posted strobing images to Twitter with the intent of inducing seizures in people with the photosensitive variety of epilepsy. In order to ensure that their intended victims viewed the images, they @-mentioned the Epilepsy Foundation’s Twitter username and included epilepsy-related hashtags in their tweets. Worse still, they did this in November — National Epilepsy Awareness Month — when a larger than usual number of people would be following the Epilepsy Foundation’s Twitter account.

The Epilepsy foundation has since filed criminal complaints against the owners of 30 Twitter accounts with law enforcement, with the intention of ensuring that the perpetrators “are held fully accountable”.

This isn’t the first time that someone has tried this sort of attack against a person with epilepsy. In December of 2016, John Rayne Rivello, who didn’t agree with journalist Kurt Eichenwald’s negative takes on Donald Trump, tweeted a seizure-inducing animated GIF to Eichenwald from an account named @jew-goldstein. The GIF included the text “YOU DESERVE A SEIZURE FOR YOUR POSTS”.

Eichenwald viewed the tweet, as suffered a seizure, as was Rivello’s intent. As written up in The Outline:

According to a federal civil suit filed by Eichenwald against Rivello in Maryland, that seizure left him vulnerable to additional ones; he had another a week later. The second one forced him to increase the dosage of his anti-convulsive medication, despite profoundly debilitating side effects, and he spent Christmas of 2016 in a sedated haze.

Unsurprisingly, Rivello’s defense in the suit is based on the First Amendment, but as the Outline article says in a pull quote:

PUNCHING SOMEONE IN THE FACE COMMUNICATES A MESSAGE, BUT IT ISN’T ONE PROTECTED BY THE FIRST AMENDMENT.

The proceeding has been delayed until January 31, and Rivello is expected to plead guilty.

William Gibson wrote about this in Neuromancer

The idea of deliberately using strobing images on screens to induce epileptic seizures isn’t new. It most prominent use in science fiction that I’m aware of dates from 1984, in a heist executed on the Sense/Net broadcasting corporation by the protagonists and a gang called the Panther Moderns in William Gibson’s cyberpunk novel, Neuromancer:

The Panther Moderns allowed four minutes for their first move to take effect, then injected a second carefully prepared dose of misinformation. This time, they shot it directly into the Sense/Net building’s internal video system.

At 12:04:03, every screen in the building strobed for eighteen seconds in a frequency that produced seizures in a susceptible segment of Sense/Net employees. Then something only vaguely like a human face filled the screens, its features stretched across asymmetrical expanses of bone like some obscene Mercator projection. Blue lips parted wetly as the twisted, elongated jaw moved. Something, perhaps a hand, a thing like a reddish clump of gnarled roots, fumbled toward the camera, blurred, and vanished. Subliminally rapid images of contamination: graphics of the building’s water supply system, gloved hands manipulating laboratory glassware, something tumbling down into darkness, a pale splash… The audio track, its pitch adjusted to run at just less than twice the standard playback speed, was part of a month-old newscast detailing potential military uses of a substance known as HsG, a biochemical governing the human skeletal growth factor. Overdoses of HsG threw certain bone cells into overdrive, accelerating growth by factors as high as one thousand percent.

What can we do?

  • Read the Mozilla doc Web accessibility for seizures and physical reactions and follow its recommendations.
  • On your web pages and applications, consider removing auto-play from animated GIFs and videos.
  • Use tools to screen your video content for seizure-inducing flashing or strobing:
  • If you have the ability, write applications like Epilepsy Blocker, which detects potentially seizure-inducing images and videos. Otherwise, help susceptible people install it on their devices, and help spread the word about it!
  • And finally, if you see people using these kinds of attacks on social media, report and block them. If Gamergate taught us only one thing, it’s that the “ignore the bullies” tactic doesn’t work against online harassment campaigns.

Recommended reading

Categories
Programming

Table-driven programming and the weather forecasting stone

Creative Commons photo by Tim Rogers. Click to see the source.

Whenever a picturesque small town located by a body of water gets popular with tourists, someone eventually sets up a “weather forecasting stone” like the one pictured above. It’s not all that different from a lot of what a lot of programs do: For a given input, provide corresponding output.

Prior to becoming a senior developer at Lilypad/Fintech, I took a consulting gig where my mission was to bring an application to a more workable condition. During that time. I saw a lot of “weather forecasting stone” code, and in this article, I’ll show you what I did with it.

The most common approach: if / else if

Most of the “weather forecasting stone” code took the form of good ol’ if / else if. Here’s the JavaScript implementation:

let forecast;
if (stoneCondition == 'wet') {
  forecast = 'Rain';
} else if (stoneCondition == 'dry') {
  forecast = 'Not raining';
} else if (stoneCondition == 'shadow') {
  forecast = 'Sunny';
} else if (stoneCondition == 'white') {
  forecast = 'Snowing';
} else if (stoneCondition == 'unseen') {
  forecast = 'Foggy';
} else if (stoneCondition == 'swinging') {
  forecast = 'Windy';
} else if (stoneCondition == 'jumping') {
  forecast = 'Earthquake';
} else if (stoneCondition == 'gone') {
  forecast = 'Tornado';
}

Aside from not handling the case where stoneCondition doesn’t match any of the expected values, this code works just fine. It’s reasonably readable, but it doesn’t have the conciseness of the the sign in the photo. It reads more like this:

  • Is the stone wet?
    • The forecast is “Rain”.
  • Otherwise, is the stone dry?
    • The forecast is “Not raining”.
  • Otherwise, is the stone casting a shadow?
    • The forecast is “Sunny”.
  • Otherwise, is the stone casting a shadow?
    • The forecast is “Sunny”.
  • Otherwise, is the stone white on top?
    • The forecast is “Snowing”.
  • Otherwise, is the stone unseen?
    • The forecast is “Foggy”.
  • Otherwise, is the stone swinging?
    • The forecast is “Windy”.
  • Otherwise, is the stone jumping?
    • The forecast is “Earthquake”.
  • Otherwise, is the stone gone?
    • The forecast is “Tornado”.

Another approach: switch

In the same application, I saw more “weather forecasting stone” code, and from all appearances, it appeared that it was written by another programmer. This one preferred to keep variable names as short as possible, often condensing them to remove as many vowels as possible. They also were deeply in love with the switch statement. Their code, as implemented in JavaScript, looked like this:

let frcst;
switch (stnCndtn) {
  case 'wet':
    frcst = 'Rain';
    break;
  case 'dry':
    frcst = 'Not raining';
    break;
  case 'shadow':
    frcst = 'Sunny';
    break;
  case 'white':
    frcst = 'Snowing';
    break;
  case 'unseen':
    frcst = 'Foggy';
    break;
  case 'swinging':
    frcst = 'Windy';
    break;
  case 'jumping':
    frcst = 'Earthquake';
    break;
  case 'gone':
    frcst = 'Tornado';
    break;
  default:
    frcst = 'Unknown';
}

The switch statement in JavaScript is modeled after the one in C. This means that a break statement has to be added to the end of each case to prevent fall-through. You should think of it as more of a goto statement in disguise rather than a structured branching statement.

Note that switch requires a default clause to handle the case when none of the other cases apply. In the code above, I’ve set it so that any case we haven’t accounted for causes the forecast to be “Unknown”. In the circumstance where the code should never have to deal with an unexpected case, I’d have the default throw an exception or similar red flag that we should catch during development.

It works, but it’s even wordier than the if / else if example, thanks to the required break statement on every clause except the default one. Once again, it’s not as concise as the sign, because it reads like this:

  • Is the stone wet?
    • The forecast is “Rain”.
    • Stop here.
  • Is the stone dry?
    • The forecast is “Not raining”.
    • Stop here.
  • Is the stone casting a shadow?
    • The forecast is “Sunny”.
    • Stop here.
  • Is the stone casting a shadow?
    • The forecast is “Sunny”.
    • Stop here.
  • Is the stone white on top?
    • The forecast is “Snowing”.
    • Stop here.
  • Is the stone unseen?
    • The forecast is “Foggy”.
    • Stop here.
  • Is the stone swinging?
    • The forecast is “Windy”.
    • Stop here.
  • Is the stone jumping?
    • The forecast is “Earthquake”.
    • Stop here.
  • Is the stone gone?
    • The forecast is “Tornado”.
    • Stop here.
  • And if you’ve made it this far:
    • The forecast is “Unknown”.

My preferred approach: Lookup tables

While both approaches work, I was still looking to make the code as simple to read as the sign (and in the process, also make it simple to maintain and modify). I wanted code that looked like this table:

If the stone’s condition is… …then the forecast is:
Wet Rain
Dry Not raining
Casting a shadow Sunny
White on top Snowing
Unseen Foggy
Swinging Windy
Jumping Earthquake
Gone Tornado
None of the above Unknown

Here’s my lookup-table based implementation of the “weather forecasting stone” sign, in JavaScript

const FORECAST_LOOKUP_TABLE = {
  'wet'      : 'Rain',
  'dry'      : 'Not raining',
  'shadow'   : 'Sunny',
  'white'    : 'Snowing',
  'unseen'   : 'Foggy',
  'swinging' : 'Windy',
  'jumping'  : 'Earthquake',
  'gone'     : 'Tornado',
  'default'  : 'Unknown'
}
const forecastLookup = (stoneCondition) =>
  FORECAST_LOOKUP_TABLE[stoneCondition] || FORECAST_LOOKUP_TABLE['default']

This code gives you a couple of things:

  1. FORECAST_LOOKUP_TABLE, an object that acts as a lookup table. Its property keys are the set of strings for all the possible stone conditions, and its values are the forecasts that correspond to each condition.
  2. forecastLookup, a function that makes it easier to use the lookup table.

With this code, you can get the forecast using the lookup table…

let forecast = FORECAST_LOOKUP_TABLE['wet'];

…or to handle unexpected stone conditions, get it using the forecastLookup() function:

let forecast1 = forecastLookup('wet'); // results in "Rain"
let forecast2 = forecastLookup('covered in gravy'); // results in "Unknown"

The table-based solution is easier to read and maintain than the if / else and switch methods. It also requires fewer lines, which is important if you follow Corbató’s Law:

Simply put, what Corbató is saying is that every day, you only have so many lines of code in you on any given day. The corollary to Corbató’s Law is that for maximum productivity, you should code in such a way that uses as few lines as possible while maintaining readability and maintainability. I think my solution does just that!

Categories
Current Events Security The Street Finds Its Own Uses For Things

The 2020 presidential campaigns aren’t ready to fight disinformation. It might be up to us.

In today’s New York Times, there’s a frightening article titled 2020 Campaigns Throw Their Hands Up on Disinformation, which Techmeme succinctly summarizes like so: Campaign staff and researchers say almost no political campaigns, including presidential ones, have teams for spotting and pushing back on disinformation.

Welcome to the downside of the old internet promise that anyone can be a publisher or a journalist: It’s that everyone also has to be an editor, a fact-checker, a media critic, and yes, an investor too.

Start with these basics:

Also worth reading: The Internet Broke the News Industry—and Can Fix It, Too, by Jimmy Wales and Orit Kopel:

The people-powered solution

In the end, what may end up making a big difference is the rise of contributors who care enough to give up some of their time to act as independent fact-checkers and watchdogs. That’s how the Urban Legends Reference Pages got its start, and it eventually became Snopes. Just as social media accounts can be used to spread disinformation, they can also be used to spread the truth. Algorithms have been weaponized against people, but they can also be harnessed to protect them.

Someone’s going to have to take on the challenges that the campaigns and social media networks can’t or won’t do, and as the drivers of the information age, that responsibility will fall to us. Are we up to it?