PodSearch

Developing Perspective

#209: Not so Fast.

 

00:00:00   Hello and welcome to Developing Perspective. Developing Perspective is a podcast discussing

00:00:04   news of note in iOS development, Apple, and life. I'm your host, David Smith. I'm an independent

00:00:09   iOS developer based in Herndon, Virginia. This is show number 209, and today is Friday,

00:00:13   January 23rd. Developing Perspective is never longer than 15 minutes, so let's get started.

00:00:19   All right, before I dive into the main topic I'm going to be discussing today, I just want

00:00:23   to have a brief aside about a little update on the As I Learn Watch Kit series that I've

00:00:27   I've been doing both my blog, on the podcast, as well as on a YouTube channel.

00:00:31   I just wondered if you aren't aware of that, it's something that I've been

00:00:34   continuing to do and have been making, I think, some fairly interesting progress

00:00:37   and putting out some hopefully useful resources. So there'll be a link to that in the show notes

00:00:41   if you aren't aware of that already. The main topic I'm going to be talking about

00:00:46   today is a little bit of my storytelling about Swift and kind of where, how my

00:00:54   thinking about it has evolved over the last, I guess, almost a year now, eight months,

00:01:01   something like that, since WWDC, and why I'm in the position I am now with my use of Swift.

00:01:09   And I won't ruin the ending with exactly what that looks like. But let's get started with

00:01:13   the story. So I remember quite clearly sitting in the WWDC keynote last year, you know, just

00:01:20   sitting there, they had gone through kind of a few things about iOS 8, what we're going

00:01:24   to expect there.

00:01:25   And then right at the end, they jump out and they say, OK,

00:01:29   we have this one other thing, and it's called Swift.

00:01:32   And it's this brand new language,

00:01:33   and everyone got excited.

00:01:34   And we're all kind of like, whoa, that's crazy.

00:01:36   This is awesome.

00:01:37   They finally did it.

00:01:38   They finally came out with something.

00:01:41   We can finally put to bed some of the speculation

00:01:44   and the talking about where they're going to go next.

00:01:46   Is there going to be this next version of Objective-C?

00:01:49   Are they going to keep doing what they have been doing,

00:01:51   where they keep bolting on other features

00:01:53   to the existing language and frameworks.

00:01:56   They added Arc, and they added all the cool new modern syntax

00:01:59   stuff with the way that they've handled

00:02:03   automatic synthesized properties and automatic boxing

00:02:06   and unboxing of things.

00:02:07   And some of these things that are really cool,

00:02:09   they've just been able to bolt onto the language inside

00:02:13   of the existing thing just by the way

00:02:15   that they've been able to enhance the compiler

00:02:17   and taking control of that out of GCC and onto LLVM.

00:02:22   So we're all excited.

00:02:23   We all see this thing, and it's called Swift.

00:02:25   And you kind of have that excitement.

00:02:27   And then I remember kind of sitting down and looking

00:02:31   at the WWDC schedule and thinking to myself what it was

00:02:35   that I was going to do, what I was going to pursue.

00:02:37   I have a limited amount of time and energy.

00:02:39   During that one week at WWDC, what did I want to do?

00:02:43   And there's a whole bunch of new APIs and cool stuff from iOS 8.

00:02:46   And there's these whole other track of Swift stuff.

00:02:49   And then there's the labs.

00:02:51   And I had to decide how I was going to split up my time.

00:02:54   And I made the conscious decision at that point

00:02:56   to say, you know what?

00:02:57   Swift looks cool, but the reality

00:03:00   is I need to focus in on shipping updates for iOS 8

00:03:04   this fall.

00:03:05   That is an absolute requirement for my business

00:03:07   to continue to be successful.

00:03:08   And so I need to go ahead and prioritize that.

00:03:10   Swift is cool.

00:03:10   I'll look at it later.

00:03:12   And I essentially ended up splitting my time

00:03:14   between iOS 8 and between going to labs,

00:03:17   talking to people, which is a fairly productive exercise.

00:03:21   And so this was pretty cool.

00:03:22   I went and did that.

00:03:24   I remember on the flight back from WWDC,

00:03:27   I sort of read the first chapter of the programming guide

00:03:29   that they had put in iBooks.

00:03:31   But I hadn't been to any sessions.

00:03:32   And Swift kind of looked interesting.

00:03:34   But it's also probably worth mentioning

00:03:36   that while I have a background in computer science,

00:03:38   and I've done the academic stuff in terms of understanding

00:03:43   a bit of the language, differences

00:03:46   between different languages, ways of approaching things, benefits and disadvantages of different

00:03:50   type systems. I'm not a language nut. I'm brutally pragmatic, to a fault. In some ways

00:03:58   that allows me to do what I do, but that also can sometimes be tricky when I look at something

00:04:02   like this. If it doesn't have a direct and obvious impact and benefit to my work, I'll

00:04:07   often disregard it. I'm not going to be clever for clever's sake. I just want to be pragmatic.

00:04:12   I want to just build the thing, and whatever tool is going to help me get there faster,

00:04:16   even if there were a more elegant solution for whatever version of elegant you might

00:04:20   think, I'm probably just going to do whatever is the simple, obvious, easy, basic thing.

00:04:25   You know, I'm going to be walking around with a hammer and building stuff that way, and

00:04:29   that tends to work.

00:04:31   That's kind of how I've been able to keep doing what I'm doing because it tends to be

00:04:34   very efficient.

00:04:35   You don't tend to go down too many rabbit holes.

00:04:37   And by that I mostly just mean that there are elements of Swift that I certainly have

00:04:42   no understanding of.

00:04:43   I don't really understand all of what's going on there.

00:04:47   Not necessarily because I couldn't, but because I haven't tried.

00:04:52   The academic part of learning a language like Swift doesn't really appeal to me.

00:04:57   I just want to know how this will make my apps better.

00:05:01   So let's go back to the story.

00:05:04   So I go through the summer working on my iOS 8 updates.

00:05:08   I have a lot of apps, and I have a lot of updates to put together and build.

00:05:11   And there was some cool stuff in iOS 8

00:05:12   we were thinking about, some stuff with extensions,

00:05:14   and some of the ways that--

00:05:16   other things that we had to do to take advantage,

00:05:17   adaptive layouts, things that we kind of had hints

00:05:19   that there were going to be bigger screen iPhones,

00:05:21   so making sure everything works with that.

00:05:23   And so I do that, and I get my updates out.

00:05:25   You know, for the most part, I had most of my updates

00:05:28   out within the first week or so of iOS 8 dropping,

00:05:30   which is always a bit of a task when you have as many apps

00:05:33   as I do, but I got it done.

00:05:35   Then there's the next round of iOS 8 updates

00:05:38   in terms of all the bug fixes to fix the things that I broke

00:05:40   I did the first updates and get those done, OK, great.

00:05:44   Now what do I do?

00:05:45   Should I start working on new features from applications?

00:05:48   Things are settling down.

00:05:50   And it was around that time that Apple

00:05:53   did one of their other keynote events.

00:05:56   And I remember in it them having a slide.

00:06:00   Probably it was Craig Federighi.

00:06:01   I can't remember exactly which executive was talking about it.

00:06:04   But one of the executives was up on a stage saying,

00:06:06   and here are all the apps that have

00:06:09   been shipped with Swift in it already.

00:06:10   And they're kind of up on stage in their big marketing event

00:06:13   talking about Swift.

00:06:14   And then I remember seeing them add a new sort of root site

00:06:19   to apple.com that if you go to apple.com/swift,

00:06:23   there's this whole big page marketing the language

00:06:25   and promoting it and talking about it.

00:06:28   And by and large, in general, I tend to--

00:06:31   I'm kind of all in on Apple in many ways.

00:06:33   And maybe that's a good thing, maybe that's a bad thing.

00:06:35   But I'm fairly committed to their platform.

00:06:39   It is where the vast majority of my income comes from.

00:06:42   I have one Android app that does something.

00:06:45   And obviously, I have FeederAngler,

00:06:46   which is a service outside of the App Store.

00:06:49   But by and large, my income in my business

00:06:50   is based around the App Store and around Apple.

00:06:53   And so when they are putting a lot of energy and effort

00:06:56   and marketing capital behind something, I tend to take notice.

00:06:58   I tend to try and get myself on board.

00:07:01   And in general, that tends to be sort

00:07:03   of the path of least resistance.

00:07:04   If I head in the direction that Apple wants me to be heading,

00:07:08   I'm unlikely to bump into them and to have problems down the road.

00:07:12   And so that's what I was sort of starting to prepare to do.

00:07:14   I see all these things.

00:07:16   Talking about it in another keynote, making a big page on apple.com,

00:07:20   and just generally promoting the language makes me start to think,

00:07:23   OK, I don't want to swim against the grain on this.

00:07:25   I need to start thinking about Swift.

00:07:28   And at the time, I'd shipped most of my updates,

00:07:30   so I had some bandwidth and availability to do it.

00:07:33   And I was actually, just as a random kind of aside and bit of trivia,

00:07:37   I was actually starting to lay the groundwork and working on a series that I was then going

00:07:41   to be called, as I learned Swift, which you may have noticed was overtaken by something

00:07:47   else, the Apple Watch, because a few weeks after this, Apple announces the Apple Watch.

00:07:55   And while at that point we didn't have WatchKit, that didn't ship until later in the year,

00:07:59   it became clear that this was going to be also another major thing that Apple was going

00:08:04   to pursue another major thing that Apple was going to put marketing behind. And another

00:08:08   place that as developers was something that I wasn't sure would make sense for me to focus

00:08:12   attention on. And so I kind of abandoned Swift, or at least abandoned learning Swift. And

00:08:19   to this day, I still yet to write a line of actual app Swift code. I think I wrote, I

00:08:26   opened up a playground when the, you know, in the first version of Xcode after WWDC.

00:08:31   And I typed a few lines, and the playground didn't really work.

00:08:34   Or at least I didn't understand how to make it work.

00:08:36   And that's it.

00:08:38   And maybe that's a slight confession.

00:08:40   It seems like as an iOS developer, at this point,

00:08:43   I probably should have done something in Swift, but I haven't.

00:08:47   And the reality is I think I'm OK with that.

00:08:50   And that's part of why I decided to do this episode,

00:08:52   is for a while I didn't really want to be one of these people

00:08:55   kind of being boo-hooing Swift.

00:08:57   Because Swift is best to understand.

00:08:59   functionally and conceptually is pretty awesome. But from a

00:09:03   pragmatic perspective, in terms of in the context of my

00:09:06   business, and context of what it is I'm trying to do and build,

00:09:10   I'm not sure it has a place for me yet. I'm not sure if it if

00:09:15   its benefits, whatever those may be, exceed the time, energy and

00:09:21   effort that it would take for me to invest into it. That as I'm

00:09:26   building watch kit apps, you know, like I took that as I

00:09:28   I learned Swift series and turned it into As I Learn Watch

00:09:30   Kit with kind of the preparation and thinking

00:09:32   that I'd had around that.

00:09:34   That transition was easy and obvious because all Watch

00:09:37   Kit is for me is a new device.

00:09:40   All the tools, all of the tools both in terms

00:09:43   of Xcode and Interface Builder and all those type things

00:09:46   are fairly stable.

00:09:47   And I understand them, and I work really well with them.

00:09:50   And Swift, everything I hear is not quite that same way.

00:09:55   It's a different thing.

00:09:57   it'll take a lot of time to wrap my head around the right idiomatic way of using Swift. And

00:10:04   I just don't think I have the time to do that, that I it's not going to make my apps any

00:10:09   better. And that's the tricky thing with a lot of these things. Swift falls into that

00:10:14   category as you know, it's kind of like classic refactor, that the balance you have to strike

00:10:20   when you're refactoring something of, can I justify the time and the energy that I would

00:10:27   take to do this thing that is only relevant technically, that my customer will likely

00:10:33   never see? And while I'm sure you could make the argument that Swift will make your app

00:10:38   more stable, that it will improve the quality of your software over time, maybe it's more

00:10:41   performant, maybe it isn't, but there are things that customers might notice down the road.

00:10:46   Everything I see makes me think that most customers aren't

00:10:50   going to care that my app was written in Swift,

00:10:53   that I'm competent enough as an Objective C developer

00:10:56   at this point that I'll be fine just doing what I've

00:10:59   been doing in Objective C.

00:11:01   And it's also slightly compounded by the hearsay

00:11:04   around Swift right now.

00:11:06   I kind of hear that the tools and the process of building

00:11:11   an app in Swift is a bit more clunky,

00:11:13   that Xcode gives you weird error messages,

00:11:16   There's things that take-- like compilation

00:11:18   seems sounds like it's a bit slower.

00:11:20   There's all these things that really don't

00:11:22   make the process sound good.

00:11:23   I keep hearing the word "optionals" constantly.

00:11:27   Honestly, I have no idea what that means.

00:11:29   I haven't looked into it.

00:11:30   I just-- all I hear is every now and then, I keep hearing these--

00:11:33   like, seeing blog posts after blog post in my RSS reader

00:11:36   saying, you know, how to work around something with optionals.

00:11:39   Optionals this, optionals that.

00:11:41   Apparently, optionals are a problem.

00:11:42   And like I said, I haven't looked into it.

00:11:45   it hasn't made sense for me to have some vague intellectual curiosity about that. But the reality

00:11:50   is, if there's some weird issue and problem that developing apps for Swift has now, unless I'm using

00:11:56   Swift, it's just sort of wasted cycles in my head to focus attention on that. So I haven't. But

00:12:01   apparently, there's these weird little issues, weird gotchas, things that I'd have to spend a

00:12:04   lot of time working myself around. And so those things certainly don't make me more and more

00:12:10   excited about diving into it.

00:12:12   One random note that has also been kind of a frustrating

00:12:15   thing since Swift came out is the impact it's

00:12:18   had on tutorials, documentation, examples, things like that.

00:12:25   Whereas before, anytime I would find a tutorial or an article

00:12:28   someone was writing about developing for the iPhone,

00:12:30   I could pretty much expect to completely follow the code

00:12:34   that they were doing, because it was going to be Objective C.

00:12:37   Or if they have an example project, or a library,

00:12:40   or something like that, it was going to be in Objective C.

00:12:42   And there's this unfortunate bifurcation now

00:12:45   in our developer community where a lot of the resources

00:12:48   for development are split between Swift and Objective C.

00:12:53   And if anything, it seems like a lot of the kind of people

00:12:55   who tend to make resources like this, the educators,

00:12:58   the people who put that together, seem excited about Swift.

00:13:01   And so are building-- it is probably, in some ways,

00:13:03   a disproportionate shift in terms

00:13:05   of tutorials written in Swift versus actual production code

00:13:08   written in Swift.

00:13:09   And that's just been kind of frustrating.

00:13:11   I just mention that because it's something I've noticed,

00:13:13   and it's a really kind of awkward time

00:13:16   to find ourselves in as a community.

00:13:19   And so that's where I am.

00:13:21   And that's sort of where I am right now

00:13:22   and where I expect to stay.

00:13:24   I will likely continue shipping Objective-C exclusively

00:13:28   until there is some compelling reason to switch.

00:13:34   There's some new API.

00:13:35   There's some new platform.

00:13:36   There is something that says--

00:13:38   Apple comes up on a stage and says,

00:13:39   you now have to learn Swift.

00:13:42   You now have to use Swift in order to use something.

00:13:44   And at that point, obviously, I would start to use it.

00:13:48   But until then, as much as I tend to jump on the bandwagon

00:13:51   and just go with whatever Apple wants me to do,

00:13:55   I think this is an example of a place

00:13:57   that I'm just going to hang out in Objective-C land

00:13:59   for as long as I can.

00:14:00   Not to be a curmudgeon, not to be just kind of stuck

00:14:05   in my ways.

00:14:05   but because it seems like that's the thing that is going to benefit my customers the most that that is the most pragmatic solution that it will help me to ship the highest volume and highest quality of applications and write the best code for my people, you know, for my applications right now. And that's kind of a weird place to find myself and if you're new to the platform, if you're new to, you know, iOS development, switch might be a great thing to start with and start learning. But for somebody who shipped a lot of apps who has a lot of existing code, and for whom the process of building an app and objective C,

00:14:35   is kind of second nature now, it doesn't make a lot of sense for me.

00:14:39   Alright, that's it for today's show. As always, if you have questions, comments, concerns, or complaints,

00:14:43   you can email me, david@developingperspective.com, or I'm on Twitter @_davidsmith.

00:14:47   We have a great week. Happy coding. Bye.