<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>andrewmccall.com &#187; bugs</title>
	<atom:link href="http://andrewmccall.com/tag/bugs/feed/" rel="self" type="application/rss+xml" />
	<link>http://andrewmccall.com</link>
	<description>If you want to know what I think...</description>
	<lastBuildDate>Tue, 17 Aug 2010 20:56:42 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Can&#8217;t login after Leopard Upgrade. Oh Apple, why would you do this to me?</title>
		<link>http://andrewmccall.com/2008/08/cant-login-after-leopard-upgrade-oh-apple-why-would-you-do-this-to-me/</link>
		<comments>http://andrewmccall.com/2008/08/cant-login-after-leopard-upgrade-oh-apple-why-would-you-do-this-to-me/#comments</comments>
		<pubDate>Fri, 01 Aug 2008 13:47:24 +0000</pubDate>
		<dc:creator>Andrew</dc:creator>
				<category><![CDATA[random]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[leopard]]></category>
		<category><![CDATA[upgrade]]></category>

		<guid isPermaLink="false">http://andrewmccall.com/?p=62</guid>
		<description><![CDATA[I wanted to write something else today, but instead I&#8217;m recovering my laptop because I decided to &#8220;quickly&#8221; upgrade from ...]]></description>
			<content:encoded><![CDATA[<p>I wanted to write something else today, but instead I&#8217;m recovering my laptop because I decided to &#8220;quickly&#8221; upgrade from Tiger to Lepoard this morning. Everything looked to be going perfectly and I figured I&#8217;d got away without any major problems &#8211; that is until I tried to login. </p>
<p>Unfortunately there is an all too common bug with upgrading a system that has a filevault user &#8211; in short it doesn&#8217;t fucking work! I&#8217;m the only user on my laptop and when I tried to log in after the upgrade all I got was an error message: </p>
<blockquote><p>&#8220;Your FileVault-protected home folder did not open and needs to be repaired. Click OK to repair the folder and continue logging in. Click Cancel Login to log in as a different user&#8221; </p></blockquote>
<p><strong>oh fuck</strong>. </p>
<p>I&#8217;d like this part of the story to be the part where I say, it&#8217;s all ok because I had backups, but it&#8217;s not. I had my daughter in my arms and was flying one handed, she&#8217;d just dozed off for a short nap and I didn&#8217;t want to wake her up so I didn&#8217;t reach down, unplug the external drive from my desktop machine, I didn&#8217;t plug it into my laptop and I didn&#8217;t back up my files. </p>
<p><strong>oh fuck</strong>. </p>
<p>I clicked OK, waited a few seconds and hoped for the best&#8230;</p>
<blockquote><p>&#8220;Logging into the account failed because an error occurred&#8221;</p></blockquote>
<p><strong>oh fuck</strong>. </p>
<p>Now it sinks in, what was meant to be a nice little morning project, upgrade my OS has turned into a total nightmare. Here are the steps to sort it out, they worked for me and hopefully will help someone else. </p>
<h1>Reset the root password, so you can login</h1>
<p>Restart you machine with the install disk in the drive and hold the <strong>c</strong> key to boot from the disk. </p>
<p>Select your instalation language, accept the agreements and click continue. When it&#8217;s loaded choose reset password from the utilities list. Choose your system drive and select <em>System Administrator (root)</em> from the list of users. Set a password and click save. </p>
<h1>Login as root</h1>
<p>Close all the windows and quit the Mac OS X Installer, when your prompted to select a startup disk choose your hard disk. </p>
<p>Now you login screen should have an option to log in as another user, pick this and use the username root and the password you set above. You should now get a new desktop from here you&#8217;ll be able to recover your files. </p>
<h1>Get your files</h1>
<p>Open finder and browse to the Users folder. Find your user and in there you should find a file called <em>username</em>.sparseimage. </p>
<p>I tried to back the whole file up to my external drive, but couldn&#8217;t get it to copy in either Finder or terminal.</p>
<p>So just double click it to mount it as a disk. You&#8217;ll be asked to type a password, it&#8217;s your user password for the account. Type it and click ok. </p>
<p>Finder will start to mount the disk then stop with the following message:</p>
<p><img src="/images/blog/damaged-home-osx-filevault-leopard-upgrade.jpg" alt="file vault dis image is damaged" /></p>
<p>You&#8217;ve got nothing to lose here, it&#8217;s mount it or lose everything so just go ahead and click Open. </p>
<p><img src="/images/blog/not-repairable-osx-filevault-leopard-upgrade.jpg" alt="errors message file vault not repairable" /></p>
<p>So it can&#8217;t read it properly, just click ok. You should now have a drive mounted and it has all your files in there. Time to back them all up, except they probably won&#8217;t all back up. I tried that and got some permission issues, rather then worry too much about them I ignored them and just made sure I got all my documents, pictures, music, movies and the application settings I wanted, I ignored everything else. </p>
<p>I have a lot of files and this took a very long time, the lesson I&#8217;ve learned &#8211; back up more often. Ironically that&#8217;s part of the reason I wanted to upgrade, so timemachine would do this for me&#8230; but I digress. </p>
<h1>Recover</h1>
<p>At this point you have a choice. You can create a new users, move files into it and move on with your upgraded system. Since I was tempted to wipe the system and start again when I considered installing the OS I chose to go that route. I rebooted, used disk utility to clean the drive and started again from fresh. </p>
<p>Either way from you backups and your new user you should be able to either do a recovery and get more or less back to where you wanted to be.  </p>
<h1>Rant</h1>
<p>Filevault is promoted as a great security feature of the OS. I like it, I deal with the fact that my machine is somewhat slower for using it, but I feel the benefits if for any reason my laptop is lost or stolen far outweigh the inconviniences. </p>
<p>I haven&#8217;t really had any problems with my mac before now and I don&#8217;t see any reason that my system should be anything but standard. Since I&#8217;m <a href="http://discussions.apple.com/thread.jspa?messageID=5881960">not the only one that has been experiencing these issues</a>, one can only assume it&#8217;s fairly widespread. </p>
<p>If only I&#8217;d know, I could have saved myself hours by simply turning file vault off. I mean I took the trouble to reboot once and clean up my home directory so the OS could fully recover it&#8217;s space.</p>
<p>To anyone reading this contemplating an upgrade, <strong>TURN FILEVAULT OFF FIRST!</strong></p>
<h1>The good news</h1>
<p>The only good to come from the whole experience is that I ended up with the clean install I kinda wanted anyway. Though not really through choice. </p>
<p>Also next time I&#8217;ll be running a simple google search for &#8220;snow lepoard upgrade problems&#8221; first and hopefully timemachine means I&#8217;ll have consistent backups, before I start. </p>
]]></content:encoded>
			<wfw:commentRss>http://andrewmccall.com/2008/08/cant-login-after-leopard-upgrade-oh-apple-why-would-you-do-this-to-me/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>It&#8217;s not working! Again!</title>
		<link>http://andrewmccall.com/2008/06/its-not-working-again/</link>
		<comments>http://andrewmccall.com/2008/06/its-not-working-again/#comments</comments>
		<pubDate>Fri, 27 Jun 2008 09:11:00 +0000</pubDate>
		<dc:creator>Andrew</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[process]]></category>
		<category><![CDATA[software development]]></category>

		<guid isPermaLink="false">http://andrewmccall.com/?p=5</guid>
		<description><![CDATA[Bugs, in an awful lot of organisations they&#8217;re a four letter word, they just shouldn&#8217;t happen. But unfortunately despite the ...]]></description>
			<content:encoded><![CDATA[<p>Bugs, in an awful lot of organisations they&#8217;re a four letter word, they just shouldn&#8217;t happen. But unfortunately despite the shouting and stomping, they still will. </p>
<h1>your software has bugs</h1>
<p>Your software has bugs, go ahead, say it, try it on. Does it scare you? It doesn&#8217;t scare me. I know mine does, this isn&#8217;t a shock, revelation or epiphany for me. I had that years ago:</p>
<p><i>One dark stormy night with a start I sat bolt upright and realised I wasn&#8217;t perfect, that I couldn&#8217;t write perfect code. I sat through the rain and the thunder awake and frightened, but as the sun broke the next morning it a clear new day dawned on a world washed free of it&#8217;s sins. I felt renewed, rejuvenated; I bounded to the office, spearheaded an overhaul of our development process, got a more agile workflow implemented with fast iterations and complete management support.</i></p>
<p>Ok, it wasn&#8217;t quite like that. I was actually up all night because someone somewhere had been freaking out about yet another bug the day before. It was affecting one user, and it would only be a matter of time before it would be affecting others &#8211; then like dominoes all of them; soon they&#8217;d be the rats leaving our sinking ship upstream and they&#8217;d take the paddles with them &#8211; in short: DOOM! </p>
<p>It&#8217;s very easy to find a bug, say it&#8217;s obvious and should have been tested, it&#8217;s quite another to test all the functionality and find all of the bugs before launch.  My software has bugs, so does yours and everyone else too. </p>
<h1>get over it and stop blaming others for your problems</h1>
<p>Bugs are a result of code, written by programmers- but it&#8217;s not always just the programmers who are to blame. Organisational pressures leading to scope and feature creep, poor design and processes or a lack of any sort of roadmap will all contribute to the problem. </p>
<p>So many times I&#8217;ve been working to a deadline (beginning, middle or end &#8211; it doesn&#8217;t really matter once a timeline is fixed any changes will incur a cost), then someone comes along and starts a sentence with &#8220;What about&#8230;&#8221; and totally blows the schedule. The problem is people rarely take into account the very simple fact that the schedule wasn&#8217;t set to include this new task, or the next next one.</p>
<p>This schedule pressure then leads to rushing either the design, the testing, the coding or all of them &#8211; this more or less ensures there will be more bugs. </p>
<p>Common excuses I hear for this are:
<ul>
<li>
<p><em>It&#8217;s obvious, and should have been thought of.</em> Sometimes this is a valid comment, but I have never been part of a team where the obvious was actually missed. In my experience this has almost always been used as some rhetorical comment to excuse someone for not mentioning a feature until launch or later.</p>
</li>
<li>
<p><em>If we don&#8217;t have that for Friday&#8217;s launch, we won&#8217;t get customer X</em>< The short simple answer should always be, if this goes into the current iteration- no customers will get a launch Friday. </p>
</li>
<li>
<p><em>Adding <i>
<the next big thing></i> would mean getting so many more customers</em> This is such a great trap for a business- so good I&#8217;ll be writing much more about it in the future. Oftentimes it&#8217;s political or the result of an organisation without any clear goal setting or planning.</p>
</ul>
<p>Schedule pressure is often further exacerbated by not making any allowances for bugs. If you don&#8217;t make allowances for fixing them post launch, you&#8217;ve already missed your next deadline. </p>
<h1>what can we actually do about them?</h1>
<p>There are a few things we can do organisationally and individually to lessen their impact. Start by not being afraid of them, accept they&#8217;re a fact of life and get over it. Shit happens, and it piles up &#8211; get a shovel or get out of the way. Look to the processes and people and streamline the development workflow. Everyone involved needs to think things through. Finally once you&#8217;ve accepted bugs, worked to minimised them in development deal with them calmly and rationally, if at all. </p>
<h2>deal with the workflow issues</h2>
<p>If your development processes seem to be creating a lot of bugs, they&#8217;re the fist place to look. These are going to be the hardest to change, but they&#8217;ll also give you the biggest returns. A few of simple steps to take: </p>
<ul>
<li>
<p><em>Design the interfaces first</em> Changes to desgin mid-stream cost at any stage of the cycle, but the earlier they&#8217;re discovered the less of an impact it will have. At least wireframing your interfaces means everyone gets a good look at them before development starts, and can say &#8220;what about&#8230;&#8221; early.</li>
<li>
<p><em>Remember changes cost</em> When someone asks for a change, make sure you point out that changes will affect delivery. Ask them why it wasn&#8217;t thought of earlier. Don&#8217;t take anything as read and make sure nobody else does either.</p>
</li>
<li>
<p><em>Iterate often</em> Small quick iterations mean features go into use quickly and mean less changed code and less places for bugs to hide. This also allows bugs to form part of the next iterations work.</li>
</ul>
<h2>all bugs are not created equal</h2>
<p>Not all bugs will affect people equally. Minor display issues are not as important as an issue where user data is randomly disappearing. An issue where the front page of your website is full of gibberish is far more important that a newsletter not being sent on time. </p>
<p>All bugs should enter a triage system, where the scope of the problem is analysed and a prioritisation decision is taken. There is no room for rhetoric, blame or politics in this process and clear descriptions of the problems are key. The title of this post is verbatim the subject line from quite a few emails I&#8217;ve seen in my life, the body is usually not much more helpful and generally descends into politics and conflict. A minor display issue affecting some users is hardly &#8220;irreparably damaging&#8221;, &#8220;actionable&#8221;, cause for anyone to &#8220;seek any and all legal recourses for reimbursement or compensation&#8221; or cause to run off and offer the person our most heart felt and abject apologies for the inconvenience. </p>
<p>We need to step back, look at the extent of the problem and respond appropriately. Going off on one while a wild wacky tale to tell alter, isn&#8217;t really professional or productive. </p>
<p>Which leads us to&#8230;</p>
<h2>not all bugs need to be fixed immediately, or even at all</h2>
<p>In a perfect world, we&#8217;d fix every bug as soon as it was reported. Then again, the world wouldn&#8217;t be so perfect because we&#8217;ve got a bug in our code&#8230; in a slightly more perfect, yet undeniably imperfect world we&#8217;d like to fix bugs as soon as they happen. This isn&#8217;t always going to be possible and for various reasons it may not make sense to fix a bug immediately. </p>
<p>Take for example the following completely hypothetical situation. You&#8217;ve got a bug in some obscure import routine written for one customer a year and a half ago. The sales team promised it was going to be the next big thing, would open the door on a whole raft of customers that used that package &#8211; it turned out to be just the one and they may or may not renew their contract in six months time. Politics aside, given certain situations the import fails and you might choose to just not fix the bug</p>
<ul>
<li>
<p><em>They&#8217;re unlikely to renew and fixing it isn&#8217;t going to sway them or get you any new customers</em> Don&#8217;t fix it and just remove the whole broken import from a future iteration. Chalk it up to learning and plan new features better so you&#8217;re addressing the needs of your users</p>
<li>
<p><em>A work around exists</em> Your time might be better spent elsewhere, especially if the problem only affects a single or small number of customers</li>
<li>
<p><em>Planned developments will obsolete the feature</em> A reworking of the feature, section or other areas of your website, the integration of a new API or a new workflow or way of doing things may mean the bug just dissapears in a future revision. One caution with this, as with any bug fix the promise should be delivered to the cusqtomer on time</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://andrewmccall.com/2008/06/its-not-working-again/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
