Categories
Programming Security What I’m Up To

Learn how to add Auth0 authentication to Android and iOS apps built with React Native!

Do you write apps in React Native? Do you want to add authentication — that is, login and logout — to those apps? If so, these articles are for you!

If you’re writing an Android app in React Native and you need users to log in and log out, don’t roll your own authentication! Use Auth0 instead. You’ll get full-featured authentication and have more time to concentrate on your app’s full functionality.

The article Get Started with Auth0 Authentication in React Native Android Apps gives you a tutorial where you make an Android app that lets users log in with an app-specific username/password combination or a Google account.

There’s also an iOS-specific version of this article: Get Started with Auth0 Authentication in React Native iOS Apps. Just like the Android version, this article walks you through the process of making an iOS app that lets users log in with an app-specific username/password combination or a Google account.

Both articles appear in the Auth0 Developer Blog and were written by guest author Wern Ancheta, with technical editing and additional content by Yours Truly!

Categories
Programming What I’m Up To

Ghosted after submitting a job interview programming assignment (5 years ago today)

Five years ago today, I submitted the first of two programming assignments as part of a job interview with a company that makes applications for the trucking industry.

May 2017

Ben Affleck in the "job interview" scene from "Good Will Hunting".

My interview at the company’s head office is going well. I’m giving them my Q&A A-game, the back-and-forth is flowing smoothly, and my knowledge of the trucking industry and lore — a combination of having done some research as well as repeated listenings to the Mark Dalton, Trucker/Detective audiobook series — seems to be paying off.

Ninety minutes into the one-hour interview, the CTO puts the brakes on the conversation and proposes a next step.

“We like your breadth of experience,” he says. “Now we’d like to test your depth. If we gave you a quick programming assignment, which would you prefer — writing an iOS app, or an Android app? You should go with the one you’re stronger in.”

I’m a much stronger iOS programmer than an Android one. The smart move would be to answer “iOS,” and be done with it.

But in that moment, I remember the motto: Be like Han.

Tap to view the “Be like Han” philosophy at full size.

Instead, I reply “Yes, but you’re looking for someone to lead a team of both iOS and Android developers. You really should give me both.

The CTO raises an eyebrow, makes a note on his pad, and says “Hmmm…I think I will.”

This is either a “total baller move” (to borrow a turn of phrase the kids are using these day), or the end of that job prospect. But for the job that they’re trying to fill, taking on that challenge was the right thing to do.

I leave the interview with just one thought: Good thing I don’t have a job. This is going to be a lot of work.

The app

I decided to tackle the iOS version first. The tricky part was that the assignment required that the app be written in the old iOS programming language, Objective-C. In 2017, Swift had been around for 3 years, so it was still reasonable to expect to do some Objective-C development.

Actual code from the project.

I made the leap to Swift as soon as it came out, so it had been 3 years since I’d done any Objective-C coding. It took me a couple of hours to regain my “C legs,” but after a few days’ work, I managed to come up with this app:

For the really curious, you can check out the project I submitted in this GitHub repo.

5 years later

Now I’m in the position where I am handing out programming assignments to prospective employees. I keep my 2017 experience in mind, which means:

  • I try to be respectful of their time. The assignment should be detailed enough to provide a realistic picture of the the candidate’s abilities but not so complex that they have to drop everything — including home/family responsibilities and their current job — to be able to complete it.
  • I try to be open to communication and responsive. I never want them to have that “ghosted” feeling I got five years ago.

Categories
Conferences Programming What I’m Up To

I’ll be in the Auth0 booth at PyCon US 2022 this week!

PyCon US 2022, the U.S. edition of the Python conference, happens this week in Salt Lake City, Utah at the Salt Palace Convention Center — and I’m going to be at the Auth0 booth!

Come drop by the booth — we should be pretty easy to find. Just listen for the accordion.

My history with Python

Toronto programmer D’Arcy Cain was looking for a programmer to help him develop an ecommerce site for a client. At the time, the stack that web developers needed to know was LAMP — Linux, Apache, MySQL, and Perl (later expanded to include other languages whose names start with “P”). D’Arcy’s preferred stack was BSD, Apache, Postgres, and Python, which at the time was considered to be a contrarian choice.

He asked if I was willing to learn Python, and I said “Sure! I can pick it up after I get back from Burning Man, on the first day after Labor Day…”

He said “No — I need you to hit the ground running on the first day after Labor Day.”

The edition of Learning Python I used — the first edition!

And I said, “All right. I’ll make it happen.” So I packed my laptop and a copy of O’Reilly’s Learning Python and took it with me to Black Rock Desert.

Those were wild times and even wilder hair, man.

Since Burning Man is more of party-all-night place, it can be quite peaceful in the morning. The rental RV that I shared with San Francisco-based artist David Newman and our friend Nancy was an oasis of calm with a good generator, and I was able to spend a couple of hours a day going through Python exercises, catch a nap, and then strike out onto the playa in the afternoon for the next evening’s mayhem.

By the time I got back to Toronto, I was ready to start coding in Python, and a descendant of that original site and its business still exists today. I figured that any programming language you can learn at Burning Man has to be good, so I’ve been using it to get things done since then, including putting together the Tampa Bay tech events list that appears on this blog weekly.

In spite of my long-time use of Python, even during that period when Ruby was ascendant thanks to Rails, I’ve never gone to PyCon — until now. I’m looking forward to it!

Categories
Humor Programming

Program in C: The coding song in Disney’s “The Little Mermaid”

How did I not know that this existed? Here’s a parody of Under the Sea, the bouncy song from Disney’s animated film The Little Mermaid, but instead of being about why life is better under the sea, it’s about why programming is better with C than with any of those newfangled programming languages with their classes and whatnot:

This amuses me to no end.

When I was a DJ at Clark Hall Pub, the engineering pub at Crazy Go Nuts University, among the alt-rock songs that were guaranteed to pack the dance floor was a strange outlier that started as a joke but turned into a hit that had to be played at least once a night: Under the Sea!

It’s also the time when I got proficient in C, as it was one of the acceptable programming languages for using in assignments. The other one was Turing, and yes, there’s a reason you haven’t heard of it. (One of my favorite professors, Dr. Michael Levison, used to say that Alan Turing would probably be horrified at the programming language that bears his name.)

I may have to add this one to my accordion repertoire.

Categories
Programming Reading Material

My tutorial on iOS authentication using SwiftUI and Auth0

Banner: Get Started with iOS Authentication using SwiftUI

Hey, iOS developers! My latest tutorial article on the Auth0 blog shows you how to easily add authentication (that is, login and logout) to SwiftUI apps and display information from their user profile.

The article demonstrates the most basic use of the Auth0.swift SDK, the Auth0 SDK for all Apple platforms — not just iOS, but macOS, iPadOS, watchOS, and tvOS. It’s Auth0’s third most-used SDKs, accounting for more than one in ten API requests to Auth0 systems!

It’s a two-part tutorial. Part 1 of the tutorial starts with File → New Project…, adds some basic interactivity, adds the Auth0.swift package, walks you through setup on the Auth0 side, and finally enables login and logout:

iOS Simulator screen shot: Screen with title “SwiftUI Login Demo” and “Log in” button.
The app’s “logged out” screen.
iOS Simulator screen shot: Auth0 Universal Login screen.
Auth0’s Universal Login.
iOS Simulator screen shot: Screen with title “Logged in” and “Log out” button.
The app’s “logged in” screen.

Part 2 of the tutorial takes your basic login/logout app and gives it the ability to read user information from the user profile and display it onscreen:

iOS Simulator screen shot: Screen with title “Logged in”, photo of user, user]s name and email address, and “Log out” button.
The revised “logged in” screen.
Categories
Current Events Meetups Programming Tampa Bay

This Wednesday: the Downtown Tampa Software Developers meetup!

There’s a new tech meetup here in “The Other Bay Area” — the Downtown Tampa Software Developers — and I’m planning on attending their next meetup (and getting some dinner) this Wednesday, March 30th, at 7:00 p.m.!

Organized by Michael Berlet, it’s a weekly meetup for software developers at Tampa’s big food hall/gathering place, Armature Works, which provides a wide variety of food and drink.

Here’s the group’s description from their Meetup page:

We are a group of professional, freelance, and amateur software developers living in the vicinity of downtown Tampa.

If you’re sick of impersonal online developer webinars and want to meet, make friends, and network with other developers in physical space, then this is the group for you. We’re informal, and like to chat about work, personal projects, and life in general.

Join us! It sounds like it’ll be fun. You can RSVP on the event page.

In case you need it, here’s the parking map for Armature Works:

Categories
Programming Reading Material

Two Kotlin/data science articles from Yours Truly!

Kotlin developers who want to get into data science: these articles are for you! They’re about using Jupyter Notebook, but with Kotlin instead of Python. Why should Pythonistas make all the big bucks?

Read the articles, which appear on RayWenderlich.com (the premier mobile development site, and it’s where I learned iOS and Android dev) in this order:

  1. Create Your Own Kotlin Playground (and Get a Data Science Head Start) with Jupyter Notebook: Learn about Jupyter Notebook, get it set up on your computer, and get familiar with krangl, the Kotlin library for data wrangling.
  2. Beginning Data Science with Jupyter Notebook and Kotlin: Once you’re familiar with krangl, it’s time to get familiar with data frames and working with datasets. This article will help you get started by exploring real data, crunching it, and even getting some insights from it.