<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-5543385228943672308</id><updated>2011-12-16T08:28:57.108-05:00</updated><category term='blob'/><category term='Unicode'/><category term='android'/><category term='list'/><category term='git'/><category term='python'/><category term='ipod'/><category term='black diamonds'/><category term='apple'/><category term='virtualenvwrapper'/><category term='play'/><category term='mac'/><category term='pip'/><category term='objects'/><category term='assistant'/><category term='migration'/><category term='os x'/><category term='corruption'/><category term='count'/><category term='virtualenv'/><category term='itunes'/><category term='database'/><category term='google'/><category term='Excel'/><title type='text'>Mac Hacking Fun</title><subtitle type='html'>My adventures hacking at computers and life.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>14</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-2070604784823825425</id><published>2011-12-16T08:09:00.002-05:00</published><updated>2011-12-16T08:24:24.241-05:00</updated><title type='text'>iTunes Drama Finale</title><content type='html'>So I heard back from iTunes support... they are refunding the cost of tracks that I purchased. I'm very pleased with the outcome, and can't complain. I should see the refund in the next week or so and then I'm not sure what I will do. I definitely want the complete Goat Rodeo Sessions albumand out of curiosity clicked the 'Buy Album' button again, which now reflects the purchase of one of the videos with a reduced price of $9.00, and I still get the same error message, 'The item is being modified, please try again later.' So there is something still amiss, and in general I've noticed some wonky behavior with streaming content in general, I have an Apple TV and for the past couple weeks I've frequently received an ambiguous error message when trying to watch video from Apple, NetFlix, Vimeo and YouTube. I don't think the scaling of iCloud and other on demand streaming services is going a peachy as would be desired.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-2070604784823825425?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/2070604784823825425/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-finale.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/2070604784823825425'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/2070604784823825425'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-finale.html' title='iTunes Drama Finale'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-7302705281193642317</id><published>2011-12-15T14:25:00.001-05:00</published><updated>2011-12-15T14:26:36.088-05:00</updated><title type='text'>iTunes Drama Part IV</title><content type='html'>So I've heard back from iTunes support and... yeah no resolution. I will freely admit that maybe I didn't explain this issue as clearly as I could have, but remember I was racing the 'Session Timeout Gremlin' so now that I have real email contact I will try again to explain my current problem. Here is the response I received from Apple support.&lt;br /&gt;&lt;br /&gt;&lt;blockquote class="tr_bq"&gt;&lt;span class="Apple-style-span" style="font-family: monospace;"&gt;Dear Jason,&lt;br /&gt;&lt;br /&gt;Welcome to iTunes Store Customer Support. My name is Nisha and I am glad to assist you.&lt;br /&gt;&lt;br /&gt;I understand from your email that you are missing the "The Goat Rodeo Sessions" from your Complete My Album. I know how valuable your purchases are and I will be happy to help you, so that you can enjoy the iTunes Store as soon as possible.&lt;br /&gt;&lt;br /&gt;Jason, the iTunes Store gives you the ability to download your&amp;nbsp;past&amp;nbsp;purchases without incurring additional charges as long as what you want to download is shown on your Purchased page. You may be able to download this particular purchase using this feature.&lt;br /&gt;&lt;br /&gt;To enable this feature, you must have the latest version of iTunes. It is available on the Apple website:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.itunes.com/download"&gt;http://www.itunes.com/download&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The latest version of iTunes will not affect your library or any items in your account.&lt;br /&gt;&lt;br /&gt;To learn how to download past purchases, check out this article:&lt;br /&gt;&lt;br /&gt;Downloading past purchases from the App Store, iBookstore, and iTunes Store&lt;br /&gt;&lt;a href="http://support.apple.com/kb/HT2519"&gt;http://support.apple.com/kb/HT2519&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;If you don't see what you want to download in the list, it may have been removed or modified since you purchased it, and no longer available for download.&lt;br /&gt;&lt;br /&gt;If you have trouble downloading any of your past purchases, please reply to let me know.&lt;br /&gt;&lt;br /&gt;You will now be able to re-download your purchases.&lt;br /&gt;&lt;br /&gt;If you have any further questions, feel free to contact us and we will be happy to assist you.&lt;br /&gt;&lt;br /&gt;Have a nice day!&lt;br /&gt;&lt;br /&gt;Sincerely,&lt;br /&gt;&lt;br /&gt;Nisha&lt;br /&gt;iTunes Store/Mac App Store Customer Support&lt;br /&gt;&lt;br /&gt;Please Note: I work on Sunday - Thursday, 7:00 AM- 4:00 PM CST&lt;br /&gt;&lt;br /&gt;Thank you for allowing me the opportunity to assist you. You may receive an AppleCare survey email; any feedback you provide would be greatly appreciated.&lt;/span&gt;&lt;/blockquote&gt;&lt;br /&gt;So we are close but no cigar, I had already thought of that and checked my previous purchases to see if the whole album was there. But remember I haven't purchased the entire album, just a subset of songs that very closely match the total cost of the album. So we will try this again, here is my response.&lt;br /&gt;&lt;br /&gt;&lt;blockquote class="tr_bq"&gt;&lt;span class="Apple-style-span" style="font-family: monospace;"&gt;Hi Nisha,&lt;br /&gt;&lt;br /&gt;Thank you for your prompt response but this does not resolve my issue. I am using the most current version of iTunes, update yesterday here is a screen shot&lt;br /&gt;&lt;/span&gt;&lt;/blockquote&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;screen shot&lt;br /&gt;&lt;blockquote class="tr_bq"&gt;&lt;span class="Apple-style-span" style="font-family: monospace;"&gt; and I did check my previous downloads to make sure that I had not purchased the entire album and didn't realize and that the files also did not download to my computer for some reason. Here is a screen shot&lt;/span&gt;&lt;/blockquote&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;screen shot&lt;br /&gt;&lt;blockquote class="tr_bq"&gt;&lt;span class="Apple-style-span" style="font-family: monospace;"&gt; &lt;br /&gt;I will try to explain again in more detail, I was rushed in my previous message because I was racing the session timeout in my account on iTunes and the comment box for contact support does now allow cut-and-paste.&lt;br /&gt;&lt;br /&gt;Yesterday I initially purchased the song and video&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;Here and Heaven&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;Hear and Heaven (Live)&lt;br /&gt;&lt;br /&gt;from the album 'The Goat Rodeo Sessions' iTunes LP. A few hours later I decided to purchase the entire album. When I returned to the iTunes store and click on the 'Buy Album' button for 'The Goat Rodeo Sessions' I received an error message. I wish I had taken a screen shot of the error message but unfortunately I did not, but other have had this same problem and here is a thread&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;&lt;a href="https://discussions.apple.com/thread/1219341?start=0&amp;amp;tstart=0"&gt;https://discussions.apple.com/thread/1219341?start=0&amp;amp;tstart=0&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;in the mean time I purchased one more video and four more songs from 'The Goat Rodeo Sessions' while waiting for the ability to purchase the complete album, here is a list of the items purchased in order&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;Attaboy&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;No One But You&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;Inside the Goat Rodeo Sessions&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;Helping Hand&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;Hill Justice&lt;br /&gt;&lt;br /&gt;After purchasing the song 'Hill Justice' I noticed that 'The Goat Rodeo Sessions' iTunes LP was no longer in my 'Complete My Album' cue in the iTunes store and that when I viewed the album directly in the iTunes store my previous purchases are not indicated (via grey'd out effect over the track) and that the purchase price of the album also did not reflect my previous purchases and was the total price of $10.99.&lt;br /&gt;&lt;br /&gt;One additional detail I did notice is that the total sum of the tracks purchased from the album&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-tab-span" style="white-space: pre;"&gt; &lt;/span&gt;5 * $1.29 + 2 * $1.99&lt;br /&gt;&lt;br /&gt;five songs plus two videos is $10.43. So by my reasoning I should be able to purchase the complete album at a cost of $0.56.&lt;br /&gt;&lt;br /&gt;Thank you again for your quick response and assistance.&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Jason Goodell&lt;/span&gt;&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-7302705281193642317?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/7302705281193642317/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-part-iv.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/7302705281193642317'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/7302705281193642317'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-part-iv.html' title='iTunes Drama Part IV'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-7781986803766728521</id><published>2011-12-15T09:28:00.000-05:00</published><updated>2011-12-15T09:28:35.552-05:00</updated><title type='text'>iTunes Drama Part III</title><content type='html'>So I gave it one last try, I retype the whole letter that I previously posted here and was able to submit without a time-out of my session. I'm sure it is not exactly like the copy I pasted here, but it should reproduce the spirit. Let's see what comes of this.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-7781986803766728521?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/7781986803766728521/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-part-iii.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/7781986803766728521'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/7781986803766728521'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-part-iii.html' title='iTunes Drama Part III'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-998957619033461053</id><published>2011-12-15T08:52:00.001-05:00</published><updated>2011-12-16T08:28:57.121-05:00</updated><title type='text'>iTunes Drama Part II</title><content type='html'>Well this update came fast, trying to contact iTunes' support is not so easy. After clicking the 'support' link at the bottom of the iTunes store page you are presented with a FAQ site, with a contact support option. Selecting the contact support option presents you with an express lane option that cost money, unless you have a Apple Care support package or are still under the complimentary first year service after a hardware purchase. In the fine print you can find that iTunes store support is available via email... okay. So some more searching through the apple online documentation and I find a page showing you how to send one of those emails to customer support that doesn't cost money... but it's out of date. I click around for a while and figure it out and go to paste my pre written letter... you can't cut and past into the support page comment box. So I start typing and retype the whole letter into the comment box, no errors appear I guess I'm not over some text limit and I click submit... and appears the popup 'Your session has times out. Try again.' &amp;nbsp;Nope I'm not kidding folks I will be redrafting the letter to make it shorter and reposting it here. To be continued...&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-998957619033461053?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/998957619033461053/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-part-ii.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/998957619033461053'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/998957619033461053'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-drama-part-ii.html' title='iTunes Drama Part II'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-1579645348755977857</id><published>2011-12-15T08:27:00.002-05:00</published><updated>2011-12-15T09:29:29.657-05:00</updated><title type='text'>iTunes not allowing purchase of remaining album content, album disappears from 'Complete My Album' option.</title><content type='html'>So yesterday I stumbled across 'The Goat Rodeo Sessions' album by Yo-yo Ma, Chris Thile and Co. I soon realized that most of the musicians involved had works that I was familiar with and was very impressed with the track 'Here and Heaven' I bought the song and the video then decided to purchase the remainder of the album, but was unable to. A pop up message kept appearing claiming that the item (being the album) was being edited or altered and was not available for sale, and to try again later. I purchased several more songs a video from the album when I then noticed that the album has disappeared from my 'Complete My Album' cue on iTunes that when I view the album in the iTunes store I presented with the album at full price and none of my previous purchases are indicated. This morning the receipt came in from iTunes, and lo and behold my purchases from the album nearly equal the total cost of the album. I'm contacting iTunes with the issue and have drafted a letter which I will attach below, we will see where this gets me, I'm not getting my hopes up but I maybe surprised.&lt;br /&gt;&lt;br /&gt;&lt;blockquote class="tr_bq"&gt;&lt;span class="Apple-style-span" style="font-family: Arial;"&gt;Yesterday I purchased a song and video from 'The Goat Rodeo Sessions' by Yo-yo Ma, later that day I tried to 'complete the album' and complete the iTunes LP but received the an error message, to para phrase 'Sorry this item is being edited and cannot be purchased at this time, please try again later.' I received this message several times over the course of the afternoon, in the mean time I purchased several more songs and another video from the album while waiting for the ability to purchase the complete album. After the purchase of the track 'HIll Justice' , 'The Goat Rodeo Sessions' iTunes LP album disappeared from my 'complete the album' option in my iTunes account and when I view the album in the iTunes store 'The Goat Rodeo Sessions' iTunes LP I no longer see a discounted price with my previous purchases indicated but the complete album at the full price. I would like to purchase the remainder of 'The Goat Rodeo Sessions' iTunes LP for whatever balance remains on the full price, I'm assuming this is a technical issue. Thanks in advance for your assistance.&lt;/span&gt;&lt;br /&gt;&lt;div style="font-family: Arial;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="font-family: Arial;"&gt;Regards,&lt;/div&gt;&lt;div style="font-family: Arial;"&gt;Jason Goodell&lt;/div&gt;&lt;/blockquote&gt;&lt;br /&gt;I'll post any and all resulting correspondence here.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-1579645348755977857?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/1579645348755977857/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-not-allowing-purchase-of-remain.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/1579645348755977857'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/1579645348755977857'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/12/itunes-not-allowing-purchase-of-remain.html' title='iTunes not allowing purchase of remaining album content, album disappears from &apos;Complete My Album&apos; option.'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-5681187458065067679</id><published>2011-04-05T14:13:00.000-04:00</published><updated>2011-04-05T14:13:48.839-04:00</updated><title type='text'>Django's template engine and the AddThis plugin with a Twitter template.</title><content type='html'>I ran into a problem recently that had me stymied for a full day, I was working on a feature ticket for my current project, the ticket requested adding a social media sharing button to each favorite list on the site. Another project had used the AddThis plugin with a lot of success and we decided to use the plugin again. I am not a JS/UI wizard but was able to implement the feature using the AddThis plugin before lunch with little fuss. Pushed the code up, my lead and I hammered at the feature for a while, and then did some polishing. One thing I wanted to do was use a template for formatting the Twitter post, using the AddThis default the link was not being shortened with bit.ly or formatted well in Twitter, and decided to give the template option a try. Like the configuration for AddThis all that was required for using a template with Twitter was the creation of a new JS object assigned to the 'addthis_share' variable.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;var addthis_share = {&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;templates: {&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;twitter: 'Check this out! {{url}}'&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;};&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;After adding this I refreshed the browser, clicked the share button and selected Twitter. Checking the outgoing message I notice that the post was 'Check this out! ' without the url. I went over the syntax several times looking for the most minute error and tried a few other options but nothing seemed to have an effect. I then posted my issue to the AddThis forum, put the word out among developers and slept on the problem.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The next day after some discussion I decided to have a look at possible name-space collisions and started pulling out other pieces of the JS for the project to see if that would have any effect. I also started scrutinizing the JS using Firebug and noticed while comparing my project to a mockup page using the AddThis plugin that the JS wasn't getting the '{{url}}' in the template, and that is when I realized what the problem was. This is a python/django site and the django template engine also uses the '{{ VARIABLE }}' token syntax. To test this theory I tried setting the '{{url}}' token in the Twitter template to something I knew django had a value for and sure enough out popped&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&amp;nbsp;'Check this out! /m/'&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The final elegant solution was to construct the AddThis template string&lt;/div&gt;&lt;div&gt;&amp;nbsp;&lt;/div&gt;&lt;div&gt;&amp;nbsp;'Check this out! {' + '{url}' + '}'&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;so that django would leave it alone while rendering the page, allowing AddThis to render the Twitter template with the '{{url}}' token intact.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Many thanks to my friend Brendan McNerney and his co-worker Paul Denya for their help on this, it would have taken me a while to come up with a solution as simple as '{' + '{url}' + '}' if Paul had not suggested it.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The lesson learned here is that two seemingly orthogonal technologies like a JS plugin and a template engine written in python can interact and have unintended side-effects when working within the same context. In this case the common context was the HTML template.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-5681187458065067679?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/5681187458065067679/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/04/djangos-template-engine-and-addthis.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/5681187458065067679'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/5681187458065067679'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/04/djangos-template-engine-and-addthis.html' title='Django&apos;s template engine and the AddThis plugin with a Twitter template.'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-697884195445278</id><published>2011-02-04T09:00:00.001-05:00</published><updated>2011-02-04T09:05:32.461-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='git'/><category scheme='http://www.blogger.com/atom/ns#' term='objects'/><category scheme='http://www.blogger.com/atom/ns#' term='corruption'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><category scheme='http://www.blogger.com/atom/ns#' term='blob'/><title type='text'>Corrupt Objects in Git Object Database</title><content type='html'>This past week I tried converting the Git repositories for our projects to Mercurial, why we are converting is another story, and I ran into this message&lt;br /&gt;&lt;br /&gt;&amp;nbsp;fatal: git cat-file 4429f4f6f77856bb00e66dc24121d565528f97ff: bad file&lt;br /&gt;&amp;nbsp;transaction about!&lt;br /&gt;&amp;nbsp;rollback completed&lt;br /&gt;&amp;nbsp;about: cannot read 'blob' object at&amp;nbsp;4429f4f6f77856bb00e66dc24121d565528f97ff&lt;br /&gt;&lt;br /&gt;about three hundred commits into the conversion. Some quick searching of this error message via my favorite search engine and I found postings about unpacking the Git object database and other general rooting around under-the-hood to replace bad objects by hand. There is a document&amp;nbsp;&lt;a href="http://www.kernel.org/pub/software/scm/git/docs/howto/recover-corrupted-blob-object.txt"&gt;here&lt;/a&gt;&amp;nbsp;where Linus himself discussing this process, and gives a brief comment on how corrupted objects happen.&lt;br /&gt;&lt;br /&gt;I'm not too proud to admit it took me some time to pierce the abstraction of working directly with the Git object database which is why I'm writing this post, so hopefully I will save others the same trouble as me. This is kind of a for-dummies manual, of which I'm a card carrying member, to help those of us of average ability cope in a world of super-geniuses which I seem to be surrounded by.&lt;br /&gt;&lt;br /&gt;The first step was to figure out what was going on here, the 'blob' is a 'file-blob' representing the change-set that was added to the object database when a commit was made. Some how this file blob has been corrupted, when the checksum for this 'file-blob' is looked up in some register upon retrieval the checksum in the register and the checksum generated by the corrupt blob do not match and this error is thrown. That is my understanding of the problem anyway I may still be wrong.&lt;br /&gt;&lt;br /&gt;Moving along, using the Git command 'fsck'&amp;nbsp;from inside the Git repository that I'm trying to convert, I will be able to find the commit and object database object that are associated with this 'file-blob' that is bad.&lt;br /&gt;&lt;br /&gt;&amp;nbsp;$ git fsck --tags&amp;nbsp;4429f4f6f77856bb00e66dc24121d565528f97ff&lt;br /&gt;&amp;nbsp;tagged commit&amp;nbsp;b1ef38c0aa901524362786a6405d60d1d7bd80a0 (v1.0.0) in&amp;nbsp;5adad5a9f49f396e21881ce8b85e77c729a4f050&lt;br /&gt;&lt;br /&gt;The second checksum output is the object database object that is associated with the bad 'file-blob', now to gain access to the object in the object database, and to do that you have to unpack the object database.&lt;br /&gt;The object database is in a 'pack' several directories down into the repository (the hidden .git directory), you are first going to move the pack, then open it, Git needs either the packed or unpacked object database to function. We are going to move the directory containing the packed object database out of the way so that we can work directory with the unpacked object database. The follow commands are all relative to the root of the Git repository containing the .git directory, first we are going to move the directory containing the packed object database out of the way, and there may be several object database packs in this directory depending on how old your clone of the repository is.&lt;br /&gt;&lt;br /&gt;&amp;nbsp;$ mv .git/objects/pack/ .git/objects/pack.old&lt;br /&gt;&lt;br /&gt;Once the pack directory has been renamed to pack.old we are going to unpack the object database, you may need to repeat the steps from here on out to find the object associated with your corrupt 'file-blob'.&lt;br /&gt;&lt;br /&gt;&amp;nbsp;$ git unpack-objects -r &amp;lt; .git/objects/pack.old/pack-1ca2ace5e54b94cf0312806533612ec0c5ee1249.pack&lt;br /&gt;&lt;br /&gt;This will unpack the object database inside the .git/objects database, you will see several dozen directories with two character names.&lt;br /&gt;&lt;br /&gt;NOTE: This is very import to realize and was one of the major stumbling blocks for me, the two characters in the directory names are the first two characters of the database objects contained within. This means that is when using 'git fsck --tags' you get the checksum&lt;br /&gt;&lt;br /&gt;&amp;nbsp;5adad5a9f49f396e21881ce8b85e77c729a4f050&lt;br /&gt;&lt;br /&gt;The database object will be in the unpacked directory '5a' and be in the file 'dad5a9f49f396e21881ce8b85e77c729a4f050', so using 'find' this is how I located the file containing the database object which contains the bad 'file-blob'.&lt;br /&gt;&lt;br /&gt;&amp;nbsp;$ find .git/objects/ -name&amp;nbsp;dad5a9f49f396e21881ce8b85e77c729a4f050&lt;br /&gt;&amp;nbsp;.git/objects/5a/dad5a9f49f396e21881ce8b85e77c729a4f050&lt;br /&gt;&lt;br /&gt;So there it is, the database object containing the bad 'file-blod'. Because there maybe several packed copies of the object database you might want to rerun the same command that generated the error message and see if it has gone away, you may have unpacked a packed object database that contains a good copy of that database object before the corruption took place.&lt;br /&gt;&lt;br /&gt;The trick to all this is you need to find good copy of the database object to fix the problem, either from backups or from older packs that contain a non-corrupted version of the object. Since the SHA1 checksum is so secure there is no way I know of to backwards engineer database object from scratch.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-697884195445278?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/697884195445278/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/02/corrupt-objects-in-git-object-database.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/697884195445278'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/697884195445278'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/02/corrupt-objects-in-git-object-database.html' title='Corrupt Objects in Git Object Database'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-3656718250524154110</id><published>2011-01-06T15:39:00.002-05:00</published><updated>2011-01-06T15:47:58.822-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='virtualenv'/><category scheme='http://www.blogger.com/atom/ns#' term='pip'/><category scheme='http://www.blogger.com/atom/ns#' term='git'/><category scheme='http://www.blogger.com/atom/ns#' term='virtualenvwrapper'/><category scheme='http://www.blogger.com/atom/ns#' term='python'/><title type='text'>pip, git and VirtualEnv</title><content type='html'>I've come across this problem twice now, where I work uses Gitorious to house our code repositories and we use pip to install packages and virtualenv to isolate those installations for development, test and production. The problem is with our current development work flow, we make clones of the package we are working on, on our local machine and work out of branches on that clone, pushing our changes back up to an identical branch on the remote repository. Looking through the documentation pip will allow you to install packages and modules from Gitorious with the following&lt;br /&gt;&lt;br /&gt;&amp;nbsp;-e git://remote.repo/project/project.git@branch@egg=project&lt;br /&gt;&lt;br /&gt;which works great on its own, but when you throw virutalenv in the mix this is where things get a little crazy.&lt;br /&gt;&lt;br /&gt;I have my virtualenvs, using virtualenvwrapper, stored in my home in a hidden directory.&lt;br /&gt;&lt;br /&gt;&amp;nbsp;~/.virtualenvs&lt;br /&gt;&lt;br /&gt;where the project's virtual env would be&lt;br /&gt;&lt;br /&gt;&amp;nbsp;~/.virtualenvs/project&lt;br /&gt;&lt;br /&gt;and in the virtual env there is a 'src' directory&lt;br /&gt;&lt;br /&gt;&amp;nbsp;~/.virutalenvs/project/src&lt;br /&gt;&lt;br /&gt;The problem is when I make some changes to a package that my project depends upon, using pip I remove the old version of the package&lt;br /&gt;&lt;br /&gt;&amp;nbsp;pip uninstall old_package&lt;br /&gt;&lt;br /&gt;and then using pip I install the updated package from Gitorious&lt;br /&gt;&lt;br /&gt;pip -e git://remote.repo/package/package.git@branch@egg=package&lt;br /&gt;&lt;br /&gt;I get an error stating&lt;br /&gt;&lt;br /&gt;You are not currently on a branch, so I cannot use any&lt;br /&gt;&amp;nbsp;'branch&lt;branchname&gt;.merge' in your configuration file.&lt;/branchname&gt;&lt;br /&gt;&amp;nbsp;Please specify whcih remote branch you want to use on the command&lt;br /&gt;&amp;nbsp;line and try again (e.g. 'git pull &lt;repository&gt; &lt;refspec&gt;').&lt;/refspec&gt;&lt;/repository&gt;&lt;br /&gt;&amp;nbsp;See git-pull(1) for details.&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;Complete output from command /usr/bin/git pull -q:&lt;br /&gt;&lt;br /&gt;!? This had me running in circles for a couple ours until I realized two things, one if the egg is exploded in 'site-packages' the command 'pip uninstall package' does not remove this exploded directory, two virtualenv stores a full copy of the package source in&lt;br /&gt;&lt;br /&gt;&amp;nbsp;~/.virutalenvs/project/src/package&lt;br /&gt;&lt;br /&gt;Removing the source code in both of these location allows me to use&lt;br /&gt;&lt;br /&gt;pip -e git://remote.repo/package/package.git@branch@egg=package&lt;br /&gt;&lt;br /&gt;without the error and all is good with the world. I'm just not sure where the bug is, and haven't filed a ticket yet to get the problem fixed. I'm not sure if the problem is with pip, virtualenv, virtualenvwrapper or our work flow and source control. I just hope this post helps some other folks.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-3656718250524154110?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/3656718250524154110/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2011/01/pip-gitorious-and-virtualenv.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/3656718250524154110'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/3656718250524154110'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2011/01/pip-gitorious-and-virtualenv.html' title='pip, git and VirtualEnv'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-5317519477847964076</id><published>2010-07-16T06:03:00.000-04:00</published><updated>2010-07-16T06:03:54.743-04:00</updated><title type='text'>My Project</title><content type='html'>I finally have an idea for personal project, design and implement a project management system in django and or pylons. What better subject matter than the struggle you face everyday, and I can look to some of the project management literature I have for inspiration and ideas. Some other points of interest&lt;br /&gt;&lt;br /&gt;&amp;nbsp;* Make the system Unicode aware.&lt;br /&gt;&amp;nbsp;* Start as an independent package.&lt;br /&gt;&amp;nbsp;* Once I have it hosted use for tasting at work, if I'm still there.&lt;br /&gt;&lt;br /&gt;Note: Still looking for a new job, it is awful having a supervisor that does not understand or appreciate what you do. It is even worse when they feel threatened by what you do because they don't understand software engineering, and try to micromanage you as a way to compensate for their feelings of insecurity.&lt;br /&gt;&lt;br /&gt;Hopefully I can get some experience and maybe some attention from this project that could lead to new opportunities for me. One can hope.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-5317519477847964076?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/5317519477847964076/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2010/07/my-project.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/5317519477847964076'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/5317519477847964076'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2010/07/my-project.html' title='My Project'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-8834338673688034826</id><published>2010-07-09T14:34:00.001-04:00</published><updated>2010-07-09T14:34:49.972-04:00</updated><title type='text'>Orwell</title><content type='html'>&lt;p&gt;I am almost finished reading Animal Farm and I really identify with Boxer, though I would like to think I am more like Snowball. Boxer while being the physically strongest of the animals is the most vulnerable and in need of protection. All Boxer wants is to see the farm succeed and do his fare share or more if necessary but his simple and good nature are taken advantage of by Neopoleon. In my current job I know the feeling all too well. &lt;/p&gt;&lt;div style='clear: both; text-align: center; font-size: xx-small;'&gt;Published with Blogger-droid v1.4.4&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-8834338673688034826?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/8834338673688034826/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2010/07/orwell.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/8834338673688034826'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/8834338673688034826'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2010/07/orwell.html' title='Orwell'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-2040687090158432023</id><published>2010-06-12T09:22:00.002-04:00</published><updated>2010-06-12T09:22:52.574-04:00</updated><title type='text'>It has been too long!</title><content type='html'>It has been soooooo long since I've posted here, so many things have happened. We moved from our house we had been renting in Apex NC to Raleigh on a moments notice, my boss has become an absolute nightmare, and my daughter has turned five with a road trip back to CT thrown in for good measure. It is not that I don't have things to blog about but just don't have the time.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-2040687090158432023?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/2040687090158432023/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2010/06/it-has-been-too-long.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/2040687090158432023'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/2040687090158432023'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2010/06/it-has-been-too-long.html' title='It has been too long!'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-4645392391935250085</id><published>2009-10-08T16:15:00.005-04:00</published><updated>2009-10-08T16:27:27.111-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='google'/><category scheme='http://www.blogger.com/atom/ns#' term='android'/><title type='text'>Google Android without Eclipse</title><content type='html'>&lt;div&gt;&lt;b&gt;Android &amp;amp; Eclipse&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;My only real complaint with the android project so far is how heavily the Eclipse IDE is pushed. I personally do not find IDEs helpful, they hide the project under a level of abstraction I find distracting, not convenient, and I've found working with developers who are dependent on IDEs to be frustrating. I am an Emacs jockey, but have structured this post to focus on the android tools, and how to work with an android project independent of Eclipse. As of its writing this tutorial focuses on using the latest release of the android SDK which is 1.6.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Install&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Download the new android SDK, I place mine in '/usr/local', and create a symlink to to the SDK in that directory named 'android' like this.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;i&gt;ln -s android-sdk-mac_x86-&lt;version&gt; android&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;/div&gt;&lt;div&gt;That way I can update my sdk without having to edit my profile, just change the symlink to the new sdk. Next make the necessary edits to your profile, and make sure you load the profile for the edits to take effect. Here is an example of how I have my .bash_profile set up like this.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;i&gt;HOME=/Users/jgoodell&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;i&gt;export HOME&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;i&gt;ANDROID_HOME=/usr/local/android&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;i&gt;export ANDROID_HOME&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;i&gt;ANDROID_SWT=$ANDROID_HOME/tools/lib/x86&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;i&gt;export ANDROID_SWT&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;i&gt;PATH=$ANDROID_HOME/tools:$PATH&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;i&gt; &lt;/i&gt;&lt;/span&gt;&lt;i&gt;export PATH&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I set two variables for convenience that are not necessary 'HOME' and 'ANDROID_HOME', I find that these variables come in hand all over the place, and instead of having to type these common long paths over and over, increasing the likely hood of a typo, I can use the variable in constructing paths. The two important variables are 'ANDROID_SWT' and 'PATH' which are needed for finding the android tools, and the swt jar file android needs to function.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Creating a Project&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Once you have created an 'avd' the next step is to create a project, to do this without relying on Eclipse you invoke android with the following action and options.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;android create project --package com.example.helloandroid --name HelloAndroid --activity HelloAndroid --target 2 --path &lt;path&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;/div&gt;&lt;div&gt;This follows the outline in the android 'HelloAndroid' tutorial.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Running Emulator&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;To start the android emulator without using Eclipse you will use the emulator tool and supply the 'avd' you created earlier. I start this as a backgroud operation so I can do everything from the same shell.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;i&gt;emulator -avd &lt;name&gt; &amp;amp;&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;/div&gt;&lt;div&gt;This will start the emulator, and from here you can load your application.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Loading Your Application&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I find using the built in ant script to be the most useful and for that you simply have to type&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;i&gt;ant install&lt;/i&gt;&lt;/div&gt;&lt;div&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;&lt;div&gt;while the emulator is running, this is why I start the emulator as a background process, and you are ready to test your application in the emulator.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Wrap Up&lt;/b&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;There, those are the basics of getting an android project running without having to rely on Eclipse.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-4645392391935250085?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/4645392391935250085/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2009/10/google-android-without-eclipse.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/4645392391935250085'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/4645392391935250085'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2009/10/google-android-without-eclipse.html' title='Google Android without Eclipse'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-4162682102984316200</id><published>2009-09-04T14:07:00.004-04:00</published><updated>2009-09-04T17:55:35.777-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='black diamonds'/><category scheme='http://www.blogger.com/atom/ns#' term='Excel'/><category scheme='http://www.blogger.com/atom/ns#' term='Unicode'/><title type='text'>MS Excel and Unicode</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: Helvetica; font-size: medium; "&gt;Last week I was sent a screen shot by our customer service department, the screen shot was of the application my company developed for the online management of homework for quantitative subjects such as mathematics, and physics. The screen shot showed text from a description field which as loaded into the application via an Excel spreadsheet, and between each character was a black diamond and question mark similar to this; &lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: 11px; "&gt;�&lt;span class="Apple-style-span" style="font-family: Helvetica, serif; font-size: medium; "&gt;. Thanks to Joel Spolsky's article on the subject of Unicode and character encodings, I recognized that some kind of character encoding issue was at play here. What had me confused was that the issue was not global, it only effect certain description fields, not all the description fields that where loaded from the Excel spreadsheet.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;The script that parsed the Excel file for upload into the application is written in Python, my first effort was to cast all strings coming from the Excel file as non-unicode strings, i.e. ASCII. Using the str() function in Python I did just that and expected one of two things to happen, an exception to erupt or the issue to be resolved (highly unlikely). The former is what happened, complaining that a certain character is beyond the ASCII character set, and python is nice enough to supply offending character's hexadecimal code; u2019. Popping the code into google produced an instant hit, this was the character that MS uses for the right single quote mark or apostrophe, the nearest equivalent is u0027 which will map to the ASCII character for the single quote and apostrophe. Using the replace() function I took care of that character, and worked my way through all the offending characters which also included unicode characters u201c and u201d, the left and right double quote characters that MS uses, I'll come back to these in a moment.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;I then uploaded the newly parsed Excel data, and had a look in the web browser. The black diamond with question marks where all still there but now the single quote/apostrophe's and double quotes where displaying correctly instead of the boxes with the Unicode hexadecimal codes, which I had not noticed before because I was distracted by all the diamonds. Something was still amiss, and the characters MS uses were not the whole story. There was something else which was effecting every character, because remember that diamonds with question marks were between every single character, no exaggeration. It was like the application didn't know what to do with the last bit in every character... Ah ha! I first checked to make sure that the unicode strings coming from the Excel spreadsheet were uft-8 and not something like uft-16. That wasn't the issue so I started looking at all the other different encoding, and there was one for utf-7 which was compatible with older systems that only use 7-bit ASCII strings.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Could it be that my company had turned out an application that could only handle 7-bit ASCII characters? So I converted the uft-8 string to utf-7, and then cast them as ASCII and re-parsed the spreadsheets, uploaded the data and had a look. Tada! Everything looked great, all the odd characters where gone, and my script was set up to throw an exception the next time it encountered a Unicode character it couldn't cast to ASCII.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;With my findings I went to the developer who created the application I was uploading the data for, told him about the problem I had encountered, how I had fixed it, and what it meant about our application. I got a shrug, a blank stare, and a 'Gee, I don't know anything about character sets, good thing you figured out how to fix it.' I'm still shacking my head about it, but you can only lead a horse to water.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:Helvetica, serif;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Now to go back to those characters MS uses, and why only certain description fields where effected. It is one thing for MS to use characters outside the 127 characters in the ASCII character set for punctuation, but it is quite another to switch the encodings only when those characters are used. I have not figure out whether it is the library I am using to read the Excel spreadsheets (Python's xlrd module) or if it is Excel itself, but if the string contains no characters outside the ASCII 127 character range it is ASCII 7-bit, if the string contains characters outside the ASCII 127 range the string is Unicode 8-bit. The description from the same Excel spreadsheet that do not contain any characters that MS would use special characters for came through as ASCII 7-bit, but the other descriptions that do contain these special characters come through as Unicode 8-bit. That is not cool in my opinion, and when I figure out who is behind this behavior they are going to hear from me.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-4162682102984316200?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/4162682102984316200/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2009/09/ms-excel-and-unicode.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/4162682102984316200'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/4162682102984316200'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2009/09/ms-excel-and-unicode.html' title='MS Excel and Unicode'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5543385228943672308.post-2018755507557335533</id><published>2009-07-12T10:14:00.001-04:00</published><updated>2009-07-12T15:47:43.306-04:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='play'/><category scheme='http://www.blogger.com/atom/ns#' term='migration'/><category scheme='http://www.blogger.com/atom/ns#' term='os x'/><category scheme='http://www.blogger.com/atom/ns#' term='assistant'/><category scheme='http://www.blogger.com/atom/ns#' term='count'/><category scheme='http://www.blogger.com/atom/ns#' term='list'/><category scheme='http://www.blogger.com/atom/ns#' term='mac'/><category scheme='http://www.blogger.com/atom/ns#' term='ipod'/><category scheme='http://www.blogger.com/atom/ns#' term='itunes'/><category scheme='http://www.blogger.com/atom/ns#' term='apple'/><title type='text'>Transferring iTunes Content</title><content type='html'>Finally, it has been nearly five years, and I have a new Mac. I was feeling left behind, and also fortunate to have made it that long without Apple completely dropping support for the PPC platform. I was also getting tired of looks and questions every time I would bring my little 12" G4 MacBook out. So now I have a snazzy new 15.4" Pro with 4G or RAM, a 320GB HD, and the 2.66Ghz Intel core duo processor. Woo hoo!&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;My first task was to transfer over my iTunes library, which currently is 35.28GB of movies and music that will only be getting larger as time goes on. So I though I would give Apple's Migration Assistant a try, but to my dismay this tool is more about transferring your account than the files it contains. I am one of those people who views buying a new machine as a chance to correct bad choices and errors you have made in the creation and management of your old account, so transferring that account to my new machine was not what I wanted to do. Specifically, OS X has this horrible miss-feature of creating the 'short name' (the real account name if you are a POSIX geek) for your account by simply concatenating your 'user name' together. An example would be a user name like 'Jonathan Longname' would become the short name 'jonathanlongname'. I don't know about you, but before I knew what I was doing I though that this was okay, then when I starting doing more IT and programming work I got really tired of typing all of that. In some circumstances it can make login into other remote POSIX systems more difficult, if a savvy SysAdmin gives you the user name jlongname, when the two account names don't match.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;There is a way to change your short name on OS X without having to destroy the account, but I've only done that on a work only machine that had no important or valuable personal information on it. I did it using the 'NetInfo Manager' utility OS X had before Leopard, but has since been dropped, and a quick sudo mv, and sudo chmod -r command to make the new account name and home directory line up. But on my personal machine I just never bothered and or wanted to take the risk of figuring out how to do this after I installed Leopard.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I corrected this little issue when I created the account on my new machine but low and behold when I went to use OS X's Migration Assistant to transfer the contents of my old account it complained that the short names did not match. I quickly quit and decided to use rsync instead, a simple&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;rsync -r &lt;username&gt;@&lt;address&gt;:Music/* ~/Music/.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;did the trick with about 6 hours over my home wireless network. Once this was done I just opened up iTunes, and everything worked like a charm (I did not rsync my music library over as iTunes but trans_iTunes, and then held down the alt/option key while starting iTunes to select a library). This also has the added advantage of not having to re-sync my iPod to this new machine, all I had to do was authorize this new machine to play my music, and I got to keep my play counts and playlists.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5543385228943672308-2018755507557335533?l=machackingfun.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://machackingfun.blogspot.com/feeds/2018755507557335533/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://machackingfun.blogspot.com/2009/07/transferring-itunes-content.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/2018755507557335533'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5543385228943672308/posts/default/2018755507557335533'/><link rel='alternate' type='text/html' href='http://machackingfun.blogspot.com/2009/07/transferring-itunes-content.html' title='Transferring iTunes Content'/><author><name>Jason Goodell</name><uri>http://www.blogger.com/profile/17614200760834881118</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
