Friday, June 19, 2015

On Focused Reading...

Reading without focus can often be like mindlessly watching whatever is being shown on TV. In other words, it is highly important to focus your reading to topic(s) that genuinely interest you, and not just which are 'out there'. Another analogy for unfocussed incessant reading, is snacking incessantly on potato chips. Reading without focus, can thus also be termed as 'info-snacking', i.e. continuous intake of info-snacks, without thinking whether they are causing an improvement in intellectual health or not. Since, this realization I have tried to be more focused in what I read, and where I read it from.

Tuesday, June 9, 2015

When [NSFileManager defaultManager] became nil

A few days back we faced an interesting problem. To use / manipulate a locally stored file, we were using the [NSFileManager defaultManager] to obtain an instance of the default File Manager, and then were trying to access the file. However, whenever this code fragment was executed the app would crash. We setup up breakpoint(s) to try to isolate the issue, and during debugging it showed up that on the very first line, where we tried to obtain a reference to the defaultManager, the instance was a valid one, but the moment we actually tried to use the reference to do something useful, the instance showed up as nil. We checked online as well, and couldn't find any references to other having a similar problem and spent some time being perplexed by why would the defaultManager be returned as nil. 

After sometime when we didn't make progress on resolving the defaultManager issue, we decided to check on the path to the file that we were trying to access and found that the path was invalid due to a bundling issue, which was in turn invalid because of build script issue. We immediately resolved the build script issue, and subsequently the defaultManager returned a valid reference ( as expected ! ). While we were happy at resolving the issue, we were also hoping that the defaultManager didn't show up as nil in the debugger, which led us to spending quite a bit of time in trying to figure that one out ( which ultimately turned out to be a "ghost" issue distracting us from the real problem ).

Wednesday, June 3, 2015

Unchartered Territory....


What's the good about unchartered territory ? By definition, no one ( or atleast you yourself :-) ) has explored it, it is wide open for exploration, you set the pace, you set the rules and you show the way, and this can lead to personal growth. Ultimately, life is about exploration, and people usually remember the explorers, and not the followers. The objective of life should be to try to stay in explorer mode, and resist the urge to be in follower mode. There are other ways of saying the same, namely try to leave your comfort zone and go and do something new and unchartered...