Whisky Oriented Development


Whisky Oriented Development – Victoria’s Programmers’ Whisky Society.

Read the rest of this entry »

Google Chrome about links: One link to rule them all

This post is going to be short, but if like me, you frequently are trying to tweek the settings on your Google Chrome, you are constantly looking up what the different Chrome about: links are.

Well, I have good news. There is one master link, which will help you remember the rest of them.

chrome://about. It will actually provide you with a list of all of the other chrome links.

In reality, I’m writing this mostly for myself, because I frequently end up spending time looking for the right chrome link, and this will save me time.

Victoria JavaScript Community

Over the past few years, I’ve become increasingly interested in meeting new people, getting exposed to new ideas and networking. I’ve attended the Victoria Google Developers Group to learn about all kinds of new and interesting Google based technologies, including Android. I’ve went to the Vancouver Island Java Users Group and learned about all kinds of interesting technologies around the JVM. I’ve even gone to OpenDataBC meetups, learned about interesting uses of Open Data, and even showed off a few of my own.

There is one group I haven’t found though.

I spend a large amount of my time writing JavaScript both at work, and in my free time. This is something that I know a fair amount about, but I’d love to network with other people, and maybe exchange a few tricks. There is one problem though. There doesn’t seem to be a Victoria JavaScript community. I’d like to change that.

If you would be interested in networking with other JavaScript developers, drop a comment below, and tell me what kind of meetups you’d be interested in: Show and Tell about your projects, Open Question Answer sessions, Social meetups over some beers, a combination, or something else entirely. Let me know, tell your colleagues, and I’ll try to take it from there.



Find the time of your next bus, fast! – BusTimes

BusTimes.ca is a Web-based application for mobile devices, designed to help answer the question of “When is the next bus?”

Read the rest of this entry »

Canadian Population Pyramids



Canadian Population Pyramids is a Web-based visualization that allows users to explore the 2011 Canadian Census, Age-Sex data set. Read the rest of this entry »

Victoria Rental Map / Breeze


Victoria Rental Map is a Web-based visualization that shows apartments for rent in Victoria, in relation to bus routes to the University of Victoria. Read the rest of this entry »

Why I won’t be getting a Lumia 900

The Nokia Lumia 900 is a great looking phone, running what I believe to be a great operating system. It was named “Best of CES” by CNET. It is powered by the latest LTE technology. But I won’t be getting it. If you’re in Canada, I recommend you don’t either.

Not that it’s not a great phone. On paper, the phone is actually pretty amazing, and I’d be happy to have one. But instead of being an example of what is right in the Windows Phone, it has become a symbol for what is wrong with telecommunications in Canada.

Before I get into all of that, let me step back a bit, and catch you up to this point. I’ve been an iPhone user for years. I ordered my first iPhone, the iPhone 3G, the first week that it became available in Canada. If I recall correctly, it was actually on the day after it was released (I didn’t get it the first day because I was negotiating with Rogers for a better plan). I was really happy with my iPhone 3G, up until iOS 4.

Like many 3G owners, as soon as I installed iOS 4, the whole experience went sideways. Things that were really responsive before, and could be completed quickly, were suddenly taking 20 seconds to respond, to keyboard press. This included things like Google Maps, Email, and many others.

I quickly moved up to the iPhone 4, and these problems quickly went away. But something didn’t feel right. But I went ahead using my phone as if nothing was wrong.

This year, while talking with one of the post-docs in my research group, I had the sudden epiphany. I was no longer in love with my phone. Somewhere along the way, we had drifted apart. The shiny button like icons that had once thrilled me, no longer brought me joy. Suddenly I realized, I had regressed to my childhood. I had once loved my phone so much, now every time I looked at it, all I could think about was Windows 3.1, with its folders and icons.

iOS had stagnated. The once innovative young company that was happy to break the rules, no longer tried, because the rules were made by it. Instead of releasing revolutionary new systems that would change their users lives, they were happy to release evolutionary new features, that would improve them, slightly, at a price.

I tried everything. I used all of the iOS 5 betas, hoping that I could rekindle the flame, but with big features like Notification center, and iMessage, it was hopeless. I new what had to be done.

After talking with my colleagues, and sleeping on it, many nights, I knew in my heart I needed something new. Android wouldn’t do it. Android at this point was essentially an open copy of iOS. The only one out there that seemed to be innovating was Microsoft.

Windows Phone 7 from Microsoft was a big rethink of what mobile should be. Instead of small icons with little number notifications, it used tiles, that could actually show more meaningful information. I knew that this was something I would have to try. It was very different of course, so with such a big change, a big risk would be involved. The best way to know for sure would be to try it. But nobody I knew had it. Well, not nobody, but no one near by. I had a few friends that had them, but none where I could really get my hands on it.

This would be something that people would have to get their hands on I thought to myself. If I had one, and liked it, I knew I would convert many people, but I’d have to get one first.

As a side note here, I like to create things. This is important to note at this point because as a friend of mine pointed out, there was a way I could get a Windows Phone for free. Well, not exactly free, but while doing something I loved doing anyway, creating things.

Microsoft knew that one of the biggest weaknesses in its platform was the lack of apps. Apple had millions, and the Windows Phone Marketplace, well, not so much (don’t worry though, all the big ones are there).

To entice developers to develop for the Windows Phone, they started a program to give them incentives. They called it the Developer Movement (Canada only). For each of your first two apps you made, you’d get a reward. As pointed out by a friend of mine, there, next to app number two, was my new phone.

So I started learning how to develop for Windows Phone. I hadn’t worked with C# in a while, but I was eager to learn again. From signing up for the program, learning the frameworks, to finishing two apps, all done in under 2 months. (If you’re interested, you can check out my apps at www.laudable.net).

So now you’re pretty much caught up. My second app was accepted April 6th (Good Friday. I was surprised to see my app get approved on a holiday). So now I can choose my reward. A brand new Windows phone. Or a $500 American Express gift card.

I knew, I threw that second possibility in there kind of late. The Windows Phone that the program had up for grabs was a Lumia 800, but one of my friends pointed out another possibility. The Lumia 800 was great, but I could take the gift card of $500, and buy the brand new Lumia 900. The 900 had a few features the 800 didn’t. Front facing camera. Access to the brand new, high speed LTE network. The review were pretty awesome. These all sounded very cool, but could I get it for $500? Apparently, yes I could. The word was, it would be available for $450, no contract.

Well, at least in the States it would be $450. But this is the no contract price. With a Canadian dollar essentially floating on parity with the American and no tariffs on cellphones, there would be little reason it shouldn’t be the same, right?

There is only one company in Canada that will be selling the Nokia Lumia 900, Rogers Communications. Rogers is one of, if not the largest, Wireless communications company in Canada. It has one of the largest numbers of subscribers in the market, and it knows how to use that to it’s advantage, and it does.

But the prices got leaked. No big surprise, the largest wireless company in Canada was not trying to compete with it’s American counterpart. Where AT&T was offering the Lumia 900 for $99 on a Two year contract and $450 with no commitment, Rogers would be offering the same device for $99 on a Three year contract, or $529.99. Why the higher price? Because they can, who else are you going to buy from.

So where does that leave me? Well, I had a decision to make.

I could pony up the extra cash ($29.99 extra for the phone + $63.60 in taxes, and that’s still not unlocked)…

Or I could just take the Lumia 800 from the Developer Movement, not have to deal with the extra hassle, and make a small stand against the greed in the Canadian wireless system.

I think I know which way I’ll be going.

Fixed: ExecJS RuntimeError and FATAL ERROR: v8::Context::New() when deploying Rails to Shared Hosting

I’ve recently been working on setting up a rails app for a site I’m building for one of my side projects.  While I’ve mostly been working on this in my spare time, I decided that it would be important, to one day be able to deploy it to a larger audience (like friends and family). After trying to get rails set up on my old hosting, and being told that Rails 3 wasn’t supported. I recently moved to Vexxhost. Two things enticed me: 1) they’re Canadian; 2) Their hosting is bloody cheap.

So after moving my PHP sites over, I got to work on deploying my currently simple rails app.  And that’s when I hit a problem.

The Problem

ExecJS::RuntimeError in Home#index

Showing /home/jrstarke/apps/___/releases/20120128224905/app/views/layouts/application.html.erb where line #6 raised:

FATAL ERROR: v8::Context::New() V8 is no longer usable (in /home/jrstarke/apps/___/releases/20120128224905/app/assets/javascripts/charities.js.coffee)

Now if you’re finding yourself  in a similar situation, Stop. Take a breath. You’re not very far.

The reason you are finding this is because Rails is clever. The .erb and .js.coffee files in application are compiled, compressed, and this all happens dynamically. They call this the ‘Asset Pipeline’.

The problem is that if you’re shared hosting is anything like Vexxhost (and I imagine most that use cpanel are), their servers in their shared hosting are based on efficiency.  This compiling of assets dynamically takes time and resources, and really, once you’d deployed it to the server, they don’t usually change much (with the exception of a new version, but then that won’t change much either until the next version).

The Solution

It turns out that the solution isn’t all that hard, in fact, most of it I found through a great article on the Ruby on Rails site about The Asset Pipeline – In Production Environments.

The trick is that you essentially need to turn off the asset pipeline. During the dynamic compilation on the fly of assets into a more static compilation. This will still compile your multiple stylesheets and javascript into single files though.

Without further ado, to the solution.

First you need to go into your config/application.rb and disable the application pipeline. You will look for the following line:

config.assets.enabled = true

and turn it to false

config.assets.enabled = false

Update (thanks Hien)If that doesn’t solve it:  go to your Gemfile and comment out the following 3 lines:

gem 'sass-rails', " ~> 3.1.1"
gem 'coffee-rails', "~> 3.1.1"
gem 'uglifier'

These are all the changes we need to make, but before we can deploy the application, we need to compile the assets, ourselves. This is where you will use the following line.

bundle exec rake assets:precompile

At this point use whatever tool you normally use to deploy your app (in my case, Capistrano). If you’re using Capistrano, don’t forget to commit the new assets that would have just been created in your public/assets folder.

Next you’ll need to log into your cpanel, or whatever actually controls your app, stop and restart it. Even if your deploy tool (like Capistrano) just said it restarted your app, don’t believe it, just restart it. This part caught me for a few hours trying to fix this bug. Even though Capistrano said it restarted the app, it still seemed to hold onto the old gems (sass and coffee) until I actually restarted.

With any luck, try your app now, and if your system is anything like mine, it will have worked.

MacBook Pro unable to connect to internet after waking from sleep

The Problem

I recently I’ve been having some problems with my MacBook Pro.  At first, I would seem to get disconnected from the internet randomly.  After a few weeks, I finally figured out what the pattern was to the problem.

One morning sat down on the couch, opened my MacBook, and as was becoming normal, I was unable to connect to the internet. The AirPort icon on the menu bar was fully black (meaning that the signal was good).

So I went into the browser and tried to to the router address.  To my surprise, I could fully connect to router. I mean fully. I could log in. I could change the settings. I could ping different websites. It all worked flawlessly. But as soon as I went back to my browser and attempted to connect to a website, any browser, it would complain that I wasn’t connected to the internet.

I would turn off the Wi-Fi a few times, and eventually it would connect fully. So then an idea came to me: Maybe it was related to the fact that I just woke it from sleep. I thought back. Every time I could remember, I had just opened the computer, and it would have difficulty connecting.

So I tried it. I made sure I could access different websites. All signs were a go. Then I closed the lid, and waited for the status light to start flashing. After it did, I would wait a few seconds, and then open the lid. I logged in, opened Chrome, and tried gmail. Gmail is currently unavailable it would tell me. So I opened Safari, and tried again. Same story. After going to the AirPort icon turning it off and on a few times, it came back. I decided to try it again. Sure enough same story. So I tried it a few more times.

After having successfully reproduced this exact approach 6 times, I decided it was time to call Apple. I talked to a rep one day, who walked me through a few steps, that failed to get any results, and before we could go through everything, I had to leave for a meeting. I called back a few days later, and got a Wonderful rep. named Ryan. After 17 minutes on the phone, my problem was solved. I was ecstatic.

The Solution

So the solution to the problem was actually pretty simple. I post it here, so that it might help others (or me if the problem recurs sometime). Remember to back up before hand, as it is possible that you might lose something.

I would also recommend storing your Wi-Fi password on your computer (especially if your password is as complex as mine is).

Here’s what worked for me:

  1. Open Finder.
  2. From the Menu at the top, choose ‘Go’ -> ‘Computer’.
  3. Open your hard drive (probably called ‘Macintosh HD’).
  4. Open the ‘Library’ folder.
  5. Open the ‘Preferences’ folder.
  6. Locate the ‘SystemConfiguration’ folder (likely at the bottom).
  7. Drag this folder to your desktop (as far as I can tell, this is to back it up incase something goes wrong)
  8. Once the copy is complete, drag the original to the trash.
  9. In Finder, open Applications (If you don’t have it on the sideback, use ‘Go’ -> ‘Applications’).
  10. Open the ‘Utilities’ folder.
  11. Open ‘Keychain Access’.
  12. Select ‘login’ from the list of Keychains.
  13. In the list to the right, locate an object with the name of your wireless network.
  14. Select it and press ‘delete’ on your keyboard.
  15. Select ‘System’ from the list of Keychains.
  16. Repeat steps 13 and 14 above.
  17. Restart your MacBook.
  18. Once your computer has restarted, connect to your wireless network.

With any luck your computer will now no longer have issues with your wireless network. This worked perfectly with my D-Link DIR-655 router, on which I could reproduce the wireless network issues flawlessly. Since I performed the steps above, my wireless connection has worked flawlessly.

Update: If this has worked successfully for you, you can go ahead and delete the SystemConfiguration folder that you copied to your desktop. It was designed as a backup, and is no longer needed.

Best software for On-line Communities?

I’m Looking for advice as to what the best software is for creating online communities.

I’m currently trying to set up a Graduate Students’ Association in my Computer Science department at the University of Victoria.

After talking to a number of Graduate students in my department about what they think would be useful to them, I received a number of great suggestions. Based on the suggestions, I came up with 3 features that I think would be useful:

  • A Blog: Which will allow the Grad. Association to keep grad students informed about important upcoming events.
  • A Forum or discussion board: Will allow grad. students to discuss whatever they feel is important to them or their work.
  • A Wiki: This will allow grad. students to easily create useful resources for other grad students.

There are many possible choices, but it all seems to come down to trade-offs.

As A Service or Host your own

There are two major options for hosting the community. You can either choose to use an As a Service model, where someone else manages the infrastructure, or the Host your own, where you take the software and run it on an infrastructure you control.

The obvious trade off here is Control for maintenance and cost. By going with an as a service, you will decrease costs, and maintenance, but you also decrease your control. By hosting your own, you increase the three.

In the maintenance category, I would like to reduce as much maintenance as possible, as this will likely be run by busy grad students. At the same time though, if we lose all control, we are completely at the liberty of the service to decide what we can do, and how long we can keep it up.

Separate Services or an All-in-one

Again, it is possible that we can use a number of different systems (such as a blog system, a forum and a wiki), or we can find a system that does all three.

In this case we have a trade off between consistency and maintenance versus precision. Of course, if you use 3 systems, you have to deal with maintaining 3 systems, and if you have 3 systems, it is unlikely that the three systems can be consistent.

In the precision category though, any one system will likely be good at a small number of features, and will be less good a others. So by going three systems, they’ll likely be better at the particular thing they do.

For this, I’d like to make the ease of use as easy as possible. If it is really hard for the users to go from one aspect to the other, like the discusion forum to the wiki or the blog, they are less likely to do it, unless it is absolutely necessary. If it’s not possible to link to the other systems consistently, this will be particularly hard.

Community Advice

I’ve use WordPress for blogs before, and they work pretty well. I’ve also considered CMS systems like TikiWiki, but it appears to be particularly buggy. I’ve also used Drupal, and it’s particularly bad for maintenance (which makes me die a little inside).

So this is where I look for advice from the community. What software can you recommend?

Older posts «