Single Table Inheritance with Sequel

I struggled with STI with Sequel as there is very little documentation on using plugins, let alone this specific one. It turns out it is incredibly trivial, but did require trawling through the code base to figure it out.

In your super class you need to activate the plugin (Sequel::Plugins::SingleTableInheritance), and specify the column name to be used to hold the name of the specific class for each object. In this case the super class is called Fruit, and the field I am using is object_type

class Fruit < Sequel::Model
   plugin :single_table_inheritance, :object_type
end

It’s really important that the field name is a symbol. If it is a string it will go bang.

Obviously you need to create the field object_type in your database table fruits as some kind of text field long enough to hold the name of the superclass and any subclass.

Your subclasses are trivial, simply extend your superclass.


class Apple < Fruit

end

Hope this helps someone!

Don’t Loose Focus on Women in Tech

Yahoo!’s recent atrocity of hiring lap dancers for geeks at their Taiwan hack day was the cause of a flurry of activity on the web and caused some people who don’t often talk out on women in tech issues to speak up. That’s a great thing, but did it really take this unbelievable event to get the world to sit up and listen?
What worries me more is that this may be the new bar by which the attitude towards women in tech is judged. Whilst the norm (outside of this event) seems to be fairly innocuous and less explicit (few female speakers / attendees, general hyper-masculine attitude, pink laptops, etc) this is clearly way out there. The danger is that by focusing on not doing such incredibly insensitive activities we loose track of where the real battlefield should be. That by focusing on not objectifying women we stop focusing on ensuring we feel more involved.

Yahoo!’s recent atrocity of hiring lap dancers for geeks at their Taiwan hack day was the cause of a flurry of activity on the web and caused some people who don’t often talk out on women in tech issues to speak up. That’s a great thing, but did it really take this unbelievable event to get the world to sit up and listen?

What worries me more is that this may be the new bar by which the attitude towards women in tech is judged. Whilst the norm (outside of this event) seems to be fairly innocuous and less explicit (few female speakers / attendees, general hyper-masculine attitude, pink laptops, etc) this is clearly way out there. The danger is that by focusing on not doing such incredibly insensitive activities we loose track of where the real battlefield should be. That by focusing on not objectifying women we stop focusing on ensuring we feel more involved.

The BarCampLondonPlanningAssociation (BCLPA)

The BarCampLondonPlanningAssociation
We set up this association whilst planning BarCampLondon6 as a body to hold a bank account and assets to simplify organising future BarCamps in and around London. By no means is there any implied overlap between the membership of BCLPA and the planning team of any BarCamp. The BCLPA has no authority over anything, but is there to be used as a resource by anyone who wants it’s help. It is able to provide the following:
- assistance in terms of experience and support of people who have been involved with the planning of BarCamps.
- banking support for BarCamp sponsorship so you don’t have to set up your own bank account
- reusable items such as power strips, ethernet cables and spare items such as post it notes and index cards.
The BCLPA is not a group of people who are specifically planning any future BarCamp, nor are it’s members the only people who can use the name BarCampLondon – that is something anyone can decide to use. There are, however, a number of members who are interested in running future BarCamps, but they do this individually not as members of the BCLPA. Membership of the BCLPA is only indicative of your interest in how BarCamps are planned and run.
To clarify, the role of the BCLPA is purely advisory and assistance to planners of Camps in and around London. We actively encourage people to go ahead and plan BarCamps (including future BarCampLondons) without being a member of the association. We are sorry if there has been any confusion over this.
If you are organising a Camp in or around London and you do want some of the assistance that the BCLPA can provide, or you are interested in becoming a member to help out others please feel free to contact Emma Persky (emma.persky@gmail.com / @emmapersky).

We set up this association whilst planning BarCampLondon6 as a body to hold a bank account and assets to simplify organising future BarCamps in and around London. By no means is there any implied overlap between the membership of BCLPA and the planning team of any BarCamp. The BCLPA has no authority over anything, but is there to be used as a resource by anyone who wants it’s help. It is able to provide the following:

  • assistance in terms of experience and support of people who have been involved with the planning of BarCamps.
  • banking support for BarCamp sponsorship so you don’t have to set up your own bank account
  • reusable items such as power strips, ethernet cables and spare items such as post it notes and index cards.

The BCLPA is not a group of people who are specifically planning any future BarCamp, nor are it’s members the only people who can use the name BarCampLondon – that is something anyone can decide to use. There are, however, a number of members who are interested in running future BarCamps, but they do this individually not as members of the BCLPA. Membership of the BCLPA is only indicative of your interest in how BarCamps are planned and run.

To clarify, the role of the BCLPA is purely advisory and assistance to planners of Camps in and around London. We actively encourage people to go ahead and plan BarCamps (including future BarCampLondons) without being a member of the association. We are sorry if there has been any confusion over this.

If you are organising a Camp in or around London and you do want some of the assistance that the BCLPA can provide, or you are interested in becoming a member to help out others please feel free to contact Emma Persky (emma.persky@gmail.com / @emmapersky).

Social Media Douchebags are Just Douchebags in Social Media

 

 
There is a certain amount of constructed jealousy from the alpha geeks who coined this phrase. After all, who wouldn’t want a job where apparently all you have to do is what we all do for fun (tweet, blog, tag, text, post, ping, write, etc). Just to be clear, I know this isn’t actually all that Social Media types do… at least not the good ones, much more goes into working in an industry where communication is key. I have a lot of respect for many of these people, and am proud to call some of them my friends.
One of the phrases I often hear when Social Media becomes the topic of conversation is “Why don’t they just get real jobs?”, normally uttered by software developers or engineers. I myself may have uttered such a phrase from time to time. I think this stems from the small group of people who want to be social media types, because they don’t want to work – in other words, from the same misguided constructed jealousy that caused techies to claim the phrase “Social Media Douchebag.” Ironically those who hate most on Social Media types are not only the most jealeous, but also the people who would be the worst at it. They simply don’t get what it’s about. I’m no Social Media expert (well, not yet!), but I think I have a pretty good idea of the industry and many of the concepts it revolves around. 
In any industry (especially technology) there are douchebags, twats and pretenders who really don’t get their subject field, and so bring their entire subject into disrepute. By no means is Social Media isolated from this. There are certainly Social Media Douchbags out there, but they are Douchebags by nature, not because of Social Media. We’ve all got friends who tell us all they want to do is tweet all day and go to parties, and that they want to quit their job to become a Social Media Consultant. What these people really don’t get is that there is so much more work to it than just going to parties. You actually have to be good at what you do, not just at drinking Cosmopolitans and Dom Perignon.
Social Media Douchbags aren’t Douchebags because they are in Social Media. They are just plain old Douchebags. The same applies to the arrogant alpha geeks. Douchebags, like the rest of them.

Why do we in the tech community make so much fun of so called “Social Media Douchebags”?

There is a certain amount of constructed jealousy from the alpha geeks who coined this phrase. After all, who wouldn’t want a job where apparently all you have to do is what we all do for fun (tweet, blog, tag, text, post, ping, write, etc). Just to be clear, I know this isn’t actually all that Social Media types do… at least not the good ones, much more goes into working in an industry where communication is key. I have a lot of respect for many of these people, and am proud to call some of them my friends.

One of the phrases I often hear when Social Media becomes the topic of conversation is “Why don’t they just get real jobs?“, normally uttered by software developers or engineers. I myself may have uttered such a phrase from time to time. I think this stems from the small group of people who want to be social media types, because they don’t want to work – in other words, from the same misguided constructed jealousy that caused techies to claim the phrase “Social Media Douchebag.” Ironically those who hate most on Social Media types are not only the most jealous, but also the people who would be the worst at it. They simply don’t get what it’s about*. 

In any industry (especially technology) there are douchebags, twats and pretenders who really don’t get their subject field, and so bring their entire subject into disrepute. By no means is Social Media isolated from this. There are certainly Social Media Douchbags out there, but they are Douchebags by nature, not because of Social Media. We’ve all got friends who tell us all they want to do is tweet all day and go to parties, and that they want to quit their job to become a Social Media Consultant. What these people really don’t get is that there is so much more work to it than just going to parties. You actually have to be good at what you do, not just at drinking Cosmopolitans and Dom Perignon.

Social Media Douchbags aren’t Douchebags because they are in Social Media. They are just plain old Douchebags. The same applies to the arrogant alpha geeks. Douchebags, like the rest of them.

*I’m no Social Media expert (well, not yet!), but I think I have a pretty good idea of the industry and many of the concepts it revolves around. 

BarCamps are not just for techies

I’ve been following two events recently, Unsheffield and TweetCamp. They’re both BarCamp style events with high levels of self organisation, and I’m really pleased that people are taking the time to run events like this. Unfortunately, they have both taken the line that they are moving away from or different to Barcamp because Barcamps are aimed solely at the tech community. And this frustrates me.

I’m fed up of people perpetuating the myth that BarCamps are just for techies. Seriously fed up. Yes, there are a bunch of technical folk who attend these events, and yes they may be the majority, but that majority is not large. Out of all of the many BarCamps I have ever been to I have rarely been to a “technical” talk, and only myself given one that was in any way technical (that was demonstrating my dissertation project and was seriously cool). 

By segregating “geeks, hackers and core techies” from regular people you are only diving apart the community of people who desire to “share and learn in an open environment.” And yes, we are one community, with members from all sorts of backgrounds. Our community is defined by our desire to share and learn, and not by the types of activities we do (hack, paint, fish, etc.). Anyone, from any walk of life, any background, and profession and or any experience level should be comfortable being a member of this community. 

Did anyone honestly find BarCampLondon6 too technical? In fact, there were some people who complained that it was not geeky enough, lacking a dedicated hackspace or way for hackers to get together, but I do not see BarCamp as a hackspace. BarCamp has been and should always be about sharing knowledge, whatever that knowledge is. BarCampLondon6 had sessions on Reflexology, Sourdough Bread Making, Tai Chi, Making your own drop spindle(spinning wool with a potato), and other BarCamps have had similarly diverse sessions.

I’m not suggesting that there shouldn’t be other events, there should and needs to be. Nor am I suggesting that TweetCamp shouldn’t happen, though I am of the opinion it would be better off with less structure. To fully engender the experience of Twitter in the real world I think it is necessary to duplicate the experience as closely as possible. Since Twitter is a fully unstructured environment, perhaps it would be beneficial to have a TweetCamp in a bar or a park or a coffee shop without the (self) organisation of BarCamp style sessions.

I applaud the efforts of the organisers of Unsheffield to see the potential to engage more people. Reaching out to different communities by re branding and widening your event is a great thing. But peddling false rhetoric about the technical basis of barcamp is unjust. If you want to separate yourself from BarCamp then you should, but denigrating it to increase the potential of your own event is just petty. Similarly, justifying TweetCamp by saying that BarCamp is not for “regular” people undermines all of the work many of us put into uniting this community of open minded knowledge seekers. 

BarCamps are not exclusivley for “geeks“, and similarly *Camps and Unconferences are not just for “regular” people. They all exist for anyone and everyone who has a desire to learn and and a passion for sharing.

Social Networks for Search

 

I’m not thinking about searching twitter (that’s a whole other area of concern I have for another day), but using twitter as an alternative to way to find information. This was prompted by a question posed by Tara Hunt while at Search Engine Strategies conference in Toronto

Does Google become less relevant as we create stronger trusted networks of sharing (tweet)

My initial reply

how often have we all asked questions to our twitter followers. Different questions require different technologies (tweet)

sums up my thoughts, but I thought I would expand on why and how this is so. And more specifically what classes of questions are appropriate for different technologies.

I’ll start with with a simple one. The question as originally posed was hastaged #sesto. My first port of call was, of course, google. Failing to find anything of relevance there, I resorted to looking at the hastag stream on twitter to find a clue, and found a few people talking about SES Toronto. Bingo, a disambiguation that I could understand instantly. But this doesnt really capture the essence of using your network of followers in twitter AS the search tool. Twitter Search is simply a slightly differently calculated index on a much reduced dataset, fundementally it doesn’t employ your implicit or explicit social network in order to help your search. I think it would be fair to say that for current situation twitter’s hashtag searching can be helpful in narrowing down your search.

What about a different class, something very specific and defined, for example the price of a flight from Montreal to New York’s 34th Street Helipad (YUL to TSS). Google certainly helps these days with offering direct links to searches on various travel websites. Actually, this specific search doesn’t really work, I’m guessing Google haven’t yet worked out that TSS is the IATA Airport Code for the helipad. The principle applies for most airports, for example “YUL to EWR” works as expected. But this class of search isn’t really Google’s domain either, you are just pointed at a specialised provider. If the route (or query)is something quite standard for your followers, say LON – SFO (for me, often travelling, and knowing many that travel that route), your followers might help in providing an indication of how much you can expect to spend. Useful for validating you are not being ripped off.

Ok, so Google is not good a specifics, at least not directly. What about something defined, for example a list of IATA Codes, or even better, Airport Codes, assuming you didn’t know they were known as IATA Codes. For this, Google is perfect. You are searching for “something similar” to the phrase you have in your mind, or information relating to it. It’s quick and simple. This is definately not a class of questions you want to be asking your followers, you would drive them mad!

Then what sort of search is Twitter (or any other “real time” social network for that matter) good for. It’s great for comparative and emotive questions.

#QUESTION: Are you more productive with music playing or other background noises? OR are you more productive when it’s silent? (tweet)

Guys, #question What’s ur favorite scent on a woman? I don’t have a favorite perfume anymore. (tweet)

Questions that have a philosophical nature

#Question of the day: Why do you twitter? (tweet)

And most importantly questions that stimulate wider discussion

wants to know why do British elections suck? No I voted sticker, no sense of pride. More from *watching* US elections. How do we change this (tweet)

The beauty of the modern internet is that every piece of information can now spark off tangential discussion that ultimately enrich our lives. Harness the power of your social networks to ask the questions that need some perspective of who you are to get the right answer, questions whose answers need a discussion, and questions that you don’t even know how to ask.

Twitter Spam

I have been engaging with my Twitter followers over the last few days about Twitter Spam, Blocking and so on. Most of them ferverously block any ‘spammy’ people that follow them. There were two things that interested me about this

  1. What constitutes spam on Twitter
  2. Why bother blocking people

I’ll consider the latter first. There was an overwhelming consensus that blocking people was the Right Thing and that not blocking spammers gave them validity.

From my perspective actually blocking them is giving them validity, it’s proof that they are getting to you. It takes time to consider an account and the decide to block or not. Whilst I’m certainly not in the upper eschelons of the twitterati with tens of thousands (millions these days, I guess) of followers, I am followed by about 10 people a day, and to be honest, I don’t always have time to look at who they are. As far as I am concerned if someone interacts with me on Twitter then I will check out their account, and that’s the crucial point. Simply being followed on Twitter can not constitute spam when at most you receive a new follower notification, which can be turned off…

So what is Twitted Spam. Something becomes ‘spammy’ when it starts to interfere with your standard routines, when it forces you to take part unwillingly in some activity. Real Twitter spam is when tweets are injected into your @reply stream or you are flodded with direct messages.

And for the first time in the history of my twitter use this has happened. And it wasn’t from anyone random that followed me, but from a viral game injecting messages into the Twitter stream of those I follow. At one point polluting it so that the latest 20 tweets where all about it. #spymaster was the most effective twitter spam (viral marketing?) campaign to date.