Spread and use Firefox
Advertise on this blog!
-->

Subscribe to my posts via Email


Delivered by FeedBurner


Recharge your mobile online!

Events I am attending
I'm attending Proto.in 2008 Delhi!

Links...

Categories

Archives

Friends



Subscribe





External Links



You might want to check out...

Online Casinos - A guide to the best online casinos, gambling sites and casino bonuses

Jul 22

ApnaBill.com team at Proto.in


(Posted at 9:34 pm)


Sameer, Sandy and myself - with the Proto.in momento.


ApnaBill.com Team - checkout the slant in the seemingly created skyline :D

Pictures courtesy Pravin from LifeBlob (one of the 15 finalist at Proto.in)

Jul 21

Proto.in July 08 Edition


(Posted at 6:04 pm)

The atmosphere was electrifying at Proto4 - and the talks were doing everything to make the conference even more interesting!

The presenting startups didn’t got much time to attend the conference talks - we were quickly rushed for the rehersals which were to prepare us for the upcoming showcase on 2nd day of the event. Helping us all along was the great team of Proto - which made sure that we had everything we needed to be ready for those 6 minutes of showcase - a big thanks to the Proto Team.

A quick presentation from ApnaBill kicked off the rehearsals - we fumbled alot, were mixed up alot - and the feedback was all worth it. Just a quick work of advice - never go to a presentation unprepared. ANY preparation is better than NO preparation ;)

After the day of reharsals, we mutually decided that Sameer would head our pack onstage. He did a nice job with the presentation and I guess our point got communicated across to the audience pretty well.


ApnaBill.com Presentation


Sameer presenting ApnaBill.com to a hall packed of audience


ApnaBill.com team (Sameer in front (second from start), Me and Sandy)

Before the day ended, each startup demo’d their products on the stalls. Checking out the stalls were potential users and investors alike.


Me posing with ApnaBill.com (ghosh! that right click…)

Here are some goodblog articles which described the event pretty well.
Rishabh from Mutiny.in - Proto.in goes North
Amit Ranjan from Webyantra - Proto IV at New Delhi: Impressive show for startups, entrepreneurship & technology
Slideshare - A list of startups showcasing at Proto4, Proto4 pictures
AlooTechie - Proto 4- A Winner’s Showcase

* More pictures and videos to follow…
**Pictures courtesy Amit from Slideshare.

Jul 18

ApnaBill.com selected amongst 15 startups to present @ Proto.in


(Posted at 12:21 pm)

All the hard work of almost 9 months culminated with an invite from Proto.in to showcase ApnaBill.com at Proto.in’s July 08 event.

Proto.in is India’s premier event for startups. Going to be held in IIT Delhi on 18th and 19th July 08 - its one of the most promising events that a startup can begin with. With more than 30 participating investors and almost 20 media houses covering this event - this is something to be very proud about. The fact that more than 100 startups applied for July’s Proto.in edition and ApnaBill.com was amongst the 15 who got selected - makes it even more awesome.

I feel jubilient to announce that ApnaBill.com would be presenting itself (for full 6 minutes) in the startup showcase on the second day of Proto.in - to a hall packed with potential investors, future channel partners and our dear current/future users.

If you are attending Proto.in, make sure not to miss this!

Hurray!

Jun 14

Happy Birthday Snoopy!


(Posted at 7:17 pm)


Someone who was and would always be - my family - Snoopy
14th June 1991 - 25th Sept 2006

I still remember very vividly that when he came to live with us on a Saturday morning (15th June, 1991) - how tiny and white and all scared he was, how he slept there on the carpet in the lobby and didn’t used to budge much from his place, how he used to run away from me always, how he used to greet us after a long day of work, how he used to love Mangoes and how Bozo used to bully him…

To us, he wasn’t a dog or a pet - but a family. Someone whom we loved and cherished.

Today, he might not be with us anymore but his memories are - and would always be.

Happy Birthday dear Snoopy - May god bless you in the doggie heaven.

For the dude he was!

Jun 7

Catching up with life!


(Posted at 12:29 am)

Past few months were crazy! An 18 hours work pattern was addictive!

But I am so happy to be back to a normal routine. I finally broke a 3 week long jinx and at 7pm, was all set to hit the gym. Its been long since I last smelled myself sweating - and its was such a welcome change. The combination of Bryan Adams (being directly delivered to my ear drums) and abdominal crunches is awesome… you just cannot believe how much it can motivate you!

Just if I can somehow shift my work schedule -3 hours, I can continue this in realtime (one is not expected to hit the gym at 12 midnight!)

June’s target - get back to 32′ 34′ waist size!

May 30

A teaser from ApnaBill.com


(Posted at 3:00 am)

The current week is just halfway through, but it has already been one of the most eventful week for ApnaBill.com - with some definite advances towards the release. We’ll be launching the live pilot mode release in just days time.

More good news - we’ve expanded our network coverage from a handful of operators/cities to a pan India coverage.


We’ll be supporting 16 different prepaid vendors across 14 different geographical locations - I must say, that is a mighty list!

And to give you a small hint with what’s in the store, I present to you, bits and pieces from ApnaBill.com UI - all this and much more is just waiting to go live!


All the hard work that has gone into cross browser support…


A self-explanatory teaser on the front page


Another teaser :)


The prepaid coupon types we’ll be selling…

  
Secure transactions - with subtle hints on the UI


And of course, the ubiquitous help!

Please do signup for our Beta Release if you have not done so. The Beta Signup is still open.

May 28

Giving wings to RAKA - graphing ability!


(Posted at 4:14 am)

Brightest ideas hit you when you least expect them. I was trying so hard all evening to put RAKA’s output into a format Graphviz could understand - but had no luck. I tried arrays, hashes, stack and what not - but nothing seemed right (or I wasn’t doing it right :) ) - and at 4am - right at the moment when I was packing up for the night - it hit me! - Just like a big bright Bulb!

Why not XML? Graphviz can very well render an XML (Some examples from ruby-graphviz gem) - and I was already able to output my tree in much similar format - whoa! 5 more minutes and I had this…


Read the graph - left to right, top to bottom. If X is displayed before Y in the graph, X is coded before Y.

And this is the code it corresponds to…

  1.  
  2. require "pp"
  3.  
  4. module Junk
  5.  
  6.   class Maku
  7.  
  8.     def say_hello(str)
  9.       puts "hello #{str}"
  10.       a = 1+1
  11.       if a == 2
  12.         if a == 1
  13.           puts "Yahoo"
  14.           if a == 10
  15.             puts "Microsoft"
  16.           else
  17.             puts "Google"
  18.           end
  19.         end
  20.         pp a
  21.       else
  22.         puts "bye"
  23.       end
  24.       puts ""
  25.       puts ""
  26.     end
  27.   end
  28.  
  29. end

Here is a side-by-side comparison of the output

The graph seems more like in vertical direction - however a more horizontal direction would look much better - what say?

Oh yes, I have a new expansion for RAKA - “A Ruby Klass Analyzer” :)

May 27

Static call graphs for Ruby code


(Posted at 5:18 am)

Ever since my bug list for ApnaBill.com started to go down, I was worried that what am I going to do in all the free time which will suddenly be created. So much so, I was even creating unnecessary tasks and them scratching them out upon realizing that they are just not needed - sure shot symptoms of working too lately!

While working on ApnaBill, I felt a huge urge to document my code - specially the libraries I wrote and some of the complex controllers. Surely enough the code is very well documented - infact, at times makes pun and even tells stories - but I was always missing a call graph generation tool, which when given my Rails project, can graph out all the calls each of the actions make. I am not talking about profile time graphs - but something pretty static, which just looks at your ruby code and draws a graph.

…And just why is it needed? Documentation - ofcourse! A colored and connected graph, which can take you directly to the source code is alot easier to digest than just the code - specially for those who have not written that piece of code. This can be real useful in many scenarios.

Ok, so I started my search two days ago, on Saturday night - and for all night, I was crawling web pages like a googlebot - trying to find the relevant pieces of information. I did came across some fantastic projects like RailRoad, RCov and ruby-prof - but there was nothing that could satisfy my need. I even tried Doxygen (which is still to support Ruby), rdoc and almost all the other doc tools mentioned at “Other tools” seciton on Doxygen’s website.

Continuing my {re}search, I came across ParseTree. Its a C extension which churns out Sexp representation of Ruby code. You can parse ruby code in classes or methods or strings format. The library (apart from other stuff) - basically gives you a callback like access to various parts of the Ruby language. So “process_defn” would be invoked when any “def my_method()” is encountered.

There isn’t much on the internet about how to use ParseTree but the code samples and RDoc included in the gem are a good start. And then there’s the code installed by the gem - which you can always read at leisure. Another document worth checking out is Ryan’s Dependency Analyzer - where he does a bit of explaining as well.

Okay, back to the problem in hand - How can I draw a call graph of my code without actually executing it. I don’t want to execute it because it cannot guarantee 100% path coverage. Further, my objective is to document the code rather than profile it.

After my initial attempts, I was finally able to create a hierarchical structure of the code (which is utterly basic as of now).

  1.  
  2. # Target code which is to be graphed
  3. # Save as "mini.rb" in your current directory
  4. module Junk
  5.  
  6.   class Maku
  7.  
  8.     def say_hello(str)
  9.       puts "hello #{str}"
  10.       a = 1+1
  11.       if a == 2
  12.         if a == 1
  13.           puts "Yahoo"
  14.           if a == 10
  15.             puts "Microsoft"
  16.           else
  17.             puts "Google"
  18.           end
  19.         end
  20.         pp a
  21.       else
  22.         puts "bye"
  23.       end
  24.     end
  25.   end
  26.  
  27. end

Introducing RAKA

  1.  
  2. #!/usr/bin/env ruby
  3. # RAKA - A Ruby Kode Analyzer
  4. # Save in same directory as mini.rb
  5.  
  6. require "pp"
  7. require ‘rubygems’
  8. require ‘parse_tree’
  9. require ’sexp_processor’
  10.  
  11. class Raka < SexpProcessor
  12.  
  13.   attr_accessor :tabber
  14.  
  15.   def initialize
  16.     super
  17.     @tabber = 0
  18.     self.strict = false
  19.     self.auto_shift_type = true
  20.   end
  21.  
  22.   # Just a wrapper for s method.
  23.   # Usefull in decrementing tabbing structure once processing is done.
  24.   def s(*args)
  25.     result = super(*args)
  26.     @tabber -= 1
  27.     return result
  28.   end
  29.  
  30.   def process_fcall(exp)
  31.     @tabber += 1
  32.     name = exp.shift
  33.     display "CALL #{name}"
  34.     return s(:fcall, exp.shift)
  35.   end
  36.  
  37.   def process_if(exp)
  38.     @tabber += 1
  39.     display "IF"
  40.     test = exp.shift
  41.     process(test)
  42.     left = exp.shift
  43.     process(left)
  44.     display "ELSE"
  45.     right = exp.shift
  46.     process(right)
  47.     display "END"
  48.     return s(:if, test, left, right)
  49.   end
  50.  
  51.   def process_defn(exp)
  52.     @tabber += 1
  53.     name = exp.shift
  54.     display "DEF #{name}"
  55.     args = process exp.shift
  56.     body = process exp.shift
  57.     display "END"
  58.     return s(:defn, name, args, body)
  59.   end
  60.  
  61.   private
  62.  
  63.   def display(str)
  64.     @tabber.times{ print "\t" }
  65.     puts "#{str}"
  66.   end
  67.  
  68. end
  69.  
  70. require "mini"
  71. puts "============Junk::Maku============"
  72. Raka.new.process(*ParseTree.new.parse_tree(Junk::Maku))

The result

call graph for mini.rb

Woha! As you can see, I am able to relate the code structure with the calls and if statements. If I can output this into a format which Graphviz can understand, we’ll have exactly what we want!

Too bad, its almost 6am - and I have to catch up on some sleep :( I’ll have to stop here - more on the project as things with RAKA proceed.

Comments and suggestions are more than welcome :)

May 24

Updates - Life and ApnaBill.com


(Posted at 4:25 am)

Its been long since I last blogged - and I was kinda missing the blogging scene.

Days and nights are as usual - super hectic. At 4:45am, with “Summer of 69” running at full volume - work on ApnaBill.com is going on in full swing. Last week, we completed integrating our Payment Gateway and Coupons Manager modules into the developer codebase. This was the last blocker bug holding us back from a release. Effort now is targetted on consolidation.

After spending endless days and nights (and full weekends - upto 20 hours each weekend), seeing everything coming and working together as one cohesive and functional unit - is like watching a kid grow and graduate! Bits and pieces of code which were written as long back as 6 months ago are suddenly coming alive all together. Assumptions which were made back then, still hold good - I guess, a bit of future planning always helps.

But as wise men say - “The end is just the beginning!” - there’s still a ton of work left before we can go Live - though we are very seriously thinking of announcing the dates now. The project is expected to go into pilot testing mode anytime now.

Just before ending - a teaser as usual :)

ApnaBill Teaser
Mobile operators we would be supporting across India.

& now …back to Summer of 69 and styling ApnaBill.com

PS: Saturday morning, The Chronilcles of Narnia is up at 10:40am at Gold Adlabs - and we have 4 tickets booked for just INR 200 :D

May 10

Making web a prettier place!


(Posted at 7:52 pm)

As we speak, CSS goodieness is oozing out of ApnaBill.com developer codebase. I just wish if I could paste some screenshots of our work here…

Anyways - that time would come! :)

May 1

ApnaBill.com completes 600 Beta Signups!


(Posted at 2:33 pm)

Nothing is more rewarding than watching beta singups grow on ApnaBill.com.

We just completed 600 signups.

We are planning some awesome schemes for our Beta users. So please signup if you havn’t already.

Apr 28

How do 300 svn commits feel like?


(Posted at 12:08 am)

ApnaBill.com SVN repository has seen some real hard work in past few days. We have had over 300 svn commits and 87 live bugs - 22 of which are still open (in new/assigned/lingering state).

These figures make me feel elated, happy - and confident that our release would be devoid of atleast these 87 bugs :D

Time and again, people have questioned me about these bugfixes in ApnaBill.com code - “Is your code that buggy?” - erhm, well no.

We track both bugs and new feature requests together (a skill that I picked up while working with Red Hat), thereby giving us a uniform outlook of the pending tasks. Besides, new features when tracked via bug reports produce a quality changelog. What was done, how and why - its important that these changes get documented while the feature is still in development phase. Makes future debugging a whole lot easier…

The road ahead, now has a crystal clear view of the destination!
All what we need to reach there is - “Focus“.

We are planning a special discount program for our Beta registrants (though cannot promise on that yet!) - So please signup for our Beta Launch - if you havn’t done so.

Back to squashing more bugs for now… ;)

Apr 24

LITBox helper for Rails


(Posted at 3:13 am)

Introducing - LITBox Helper for Rails!

Disclaimer: This is a work in progress and is available on “as is” basis.

For long, I was trying to integrate Criag Ambros’s RedBox plugin into ApnaBill.com project for implementing modal dialogs but somehow, the CSS always used to get upset, rendering the lightbox in such a way that the content which is to be shown inside it, shows below it.

Then I came across Ryan J Lowe’s LITBox(The site seems to down, try Google cache)- and boy, it rocks! Just 10 seconds setup, very light weight and looks brilliant! The code is nicely written too. But the only drawback was that it was plain JS stuff - so that means no Rails helpers available.

So, once the test implementation was done with, I decided to write a small helper myself. I’ve seen how Jorge’s Prototype Window Class’s rails helper works - so decided to base my code on the same lines. And since he’s already written the Ruby->JS part for converting between optional arguments, this didn’t seemed a daunting task even for a Wednesday night :)

  1.  
  2. # Based on Prototype Window Class Helper (http://pwc-helper.xurdeonrails.com)
  3.  
  4. module LitboxHelper
  5.  
  6.     def params_for_javascript(params) #options_for_javascript doesn’t works fine
  7.         ‘{’ + params.map {|k, v| "#{k}: #{
  8.        case v
  9.          when Hash then params_for_javascript( v )
  10.          when String then "‘#{v}’"          
  11.        else v   #Isn’t neither Hash or String
  12.        end }"}.sort.join(‘, ‘) + ‘}’
  13.     end
  14.    
  15.  
  16.     # Returns a default LITBox window.
  17.     def litbox_window(link_text, href, html_options={}, params={})
  18.       prefix = "<a "
  19.       # Add all html options as key="value" pairs
  20.       html_options.each do |k, v|
  21.         prefix += "#{k}=\"#{v}\" "
  22.       end
  23.       prefix += "href=\"javascript:void(null);\" onclick=\""
  24.      
  25.       # JS Payload
  26.       payload = "new LITBox(’#{href}’, #{params_for_javascript(params)});"
  27.      
  28.       # Rest of the stuff including link text
  29.       suffix = "\">#{link_text}</a>"
  30.      
  31.       return prefix + payload + suffix
  32.     end
  33.  
  34. end

I’m trying to make it feature complete so that I can make it available for download.

Till then… happy hacking!

Apr 23

So what is an {ab}normal day like?


(Posted at 1:59 am)

Considering that I am more of a night person, my day starts at 9pm

  • 9pm - Back from office
  • 10pm - dinner
  • 11pm - Start work on ApnaBill.com - pack a solid 3 hours of work - feature/bug fixes.
  • 3am - Plan to watch a movie - search Rama’s collection.
  • 5am - Yawwn! Lets sleep now, tomorrow’s office afterall…
  • 10:30am - Waky waky!
  • 12noon - Office… (no breakfast most of the weekdays)
  • 1:30pm - lunch
  • 4pm - Tea break
  • 6pm - Snacks
  • 9pm - Start for home - repeat the process.

So its almost 2:30am now - and guess what? Movie time ;)

Shubhu is watching Highlander off the DVD - too bad, i’ll have to plan for some other flick…

Apr 19

Meeting Entrip.com guys…


(Posted at 9:52 pm)

The day was very hectic… was up @ 10 AM, saw “Horton hears a who” @ 11 AM, had a quick breakfast @ 1PM, started for LCG meeting @ 3PM and then finally met the Entrip.com guys at 6PM - all as I planned yesternight :)

…and by now I am dead tired - just enough of me left to write this post ;)

The meeting with Entrip.com founders was special because we were kind’of resonating at the same frequency, the same enthusiasm and that energy. Of course, the thread which tied us all together was Rails ;)

EnTrip is an integrated travel utility which enables you to:

  • Plan or map out your entire trip, using our intuitive map-based interface
  • Capture the experiences and vivid memories that make up your trip, within their geographical context
  • Easily share your adventures with friends and family around the world, in a meaningful way

If you are interested in how it works, try out the founding team’s trip to India.

I wish them a ton of good luck for their project.



Some External Links
Casino - Play online casino games from home.