Sunday, May 19, 2019

Locked-in by a 2-year old

3rd Feb 2019

To look back, it may become a funny memory or a embarrassing one...but today, for the momemt when i realized what had just happpened...i was actually frightened. Not for myself but for the little one standing outside the door..unaware of the various probabillities.

So, i live close by to my sister and it was my play day with my nephew. I had heard such stories and have been warned that dont teach kids how to lock doors etc. until they are little older. But we humans learn by our own mistakes right, so I have also, in critical situations, used doors and locks at times as items of distraction or innovative playing options. And finally paid the price of such impromptu decisions today.

In the middle of a role play game, i felt the need to use the loo and told my nephew to please wait and that mausi will be back in 2 mins. But he followed me and pushed the door open in fun. So, i locked it from the inside and quickly went on with my business.  I am not sure what went through his mind, if  he thought it was part of the game and that i need to be locked up or quite possibly, he just wanted to explore the latch n locked it in his innocent curiosity.

He kept talking n I kept replying. Then when i quickly wanted to open the door n get back to my game...it took me few looks at the inner latch to realize that i did open it, still door is not opening. Then within next few seconds, after getting flashes of my infinite future in that small room, imagining trying to shout from the bathroom window trying to get attention of some neighbors, then realizing that my side of neighbouring building has no living beings. Scolding myself for not carrying my phone to the bathroom. Then realizing that even if call someone, they would neef to break open the gates as all entries to my house are bolted from inside and have metal cage in balcony. I finally came back to my senses and realized my nephew was still talking non stop that means he is still waiting for me to say something back. I felt relieved and tried to pursuade him to open the latch. But how do you explain a two, almost going to be three year old, what a latch (chitkani, as we call in hindi) is? With the small hole that was present just near the latch, for a reason unknown to me, as it was there when i rented the house, I tried pointing to him that open this thing. Pull it back or in opp direction of whatever he did. But again, the kiddo wont know what "opposite" is right. Finally, i tried blackmailing him that i will stay inside only and he wont be able  to continue the game. Alas...as if that could ever work. He also gave up and said you only open the door. Then i could hear him playing with other things far away from door. 

At last after few minutes being locked, the responsible person awakened (better way of saying, i had no other option left), i started pulling the door towards me with jerks, and given the weak plastic nature of door, after 4-5 good pulls, the latch screws came out and i was relieved to come out of that room and come face to face to a mischievously (or maybe not), but a  smiling   nephew. 

First thing i did was to hug him tightly and then trying to be the adult, asked him does he know what he did. He had locked mausi inside and that he would be all alone if i could not come out. Had to tell him that he could get scolding for this, but thinking in my head that it would be me who would get scolding really for locking the door in the first place. After few such lecturing statements...he finally made his  serious face and probably got scared, thinking of his father's scolding may be. So to change the temperature of the room, I distracted him with his favorite game of imitating aminal howls n barks. Within 15-20 minutes, he was tired and wanted to sleep.

All in all, it was a scary experience and in  probably few minutes, I got a learning lesson and added this to my list of "what not to do" when you are around young curious minds. Never under estimate the possibility of the unknown.   

Wednesday, October 23, 2013

Why I miss Airtel and hate BSNL...

When will BSNL overcome its shortcomings and come at par with its competitors like Airtel, Tata, or Reliance in providing broadband connection? Well let’s just leave reliance too, since they are equally bad.
Pros – BSNL has most widespread area coverage and feasibility
Cons – Poor service quality, Costly plans, Corrupt Linemen who only work if they get paid some amount, and sometimes even then they will not work.

The only reason I switched to BSNL was because Airtel was not available in my new locality.
Since I have mainly used Airtel (used for 3 years, then changed house in an area where feasibility was not there), I would like to compare all the Cons of BSNL which are actually strengths of Airtel.


Comparison point
Airtel
BSNL
New Connection process
Getting a new connection was so easy with Airtel; everything was done from home. All I had to do was raise a request on their website and next day I got a call and same day my documents were collected. And I got net within 3 days.
Even after 20 days, net has not been provided and getting landline connection was no easy process either.
Even though they have built a website and provided features like online lead request for new connection etc., these requests are not attended quickly. The webpages have JavaScript issues which cause failure in form submission multiple times. Finally, I had to visit a CSC and fill the form all over again. Then also, no one called for 1 week and only after going to CSC again some person was sent after 3-4 days to give the connection. That fellow only did the wiring and took money stating wire cost and work done by two people. Even then I had to call him multiple times to start the landline and net have not yet been activated.
Lineman / Service Quality
Trained Professionals.
The service people would always stick to their SLAs, spoke politely and NEVER ask for bribes. They were even ready to visit to rectify problems on times which suit the customers but were after their office hours. Biggest advantage is that all this service is free of cost from Airtel. No hidden cost.
Totally un-professional behavior. First they will work only from 10-5 from Mon-Sat, so most of us have to either take off or wait for Sat to let them in. Then also they need money just because they visited your place, irrespective of if the problem is rectified or not.
(I am thinking about filing a written complaint against them)
Lodging a Complaint for dead phone
You can raise request from Airtel mobile or any other mobile by calling customer care.
There are no customer care numbers which can be dialed from mobile. All numbers are given which can only be dialed from another BSNL landline phone.
Costly Plans
Since plans keep changing, so I will not quote any plan here. But Airtel provides same speed in almost half or three-fourth of the cost, compared to BSNL.
 
 
All in all…I just want to say that I miss you …my Airtel broadband. Next time when I switch house, I need to check the Airtel feasibility first.

Friday, February 8, 2013

Unit Testing tips for developers

Whose responsibility is it to test the code you write?
I get this question in my mind so frequently these days. Having been part of various projects, I got a chance to interact with many senior developers. Without commenting on their knowledge level, all of them had one thing in common – they did not know how to or did not want to test the code they write.

Is it too difficult to perform basic unit testing? No, it is not. People simply verify the happy path testing and release their code for testing team. They forget to include some small but crucial negative scenario, which if encountered can generate high priority defects. Then follows the meetings and several mails from managers and clients as to why code failed in Production.
So, I just thought of putting down some scenarios that should also be verified before releasing the code, especially if your code might be accessed in different browsers.

1.  Testing input fields on the form
a.  What happens when only spaces or value with leading & trailing spaces are entered – to check if you need to code the trim() logic.

b.  What happens when special symbols having special meanings for browsers are entered? Example: hash (#), apostrophe ('), ampersend (&) etc. – These become even more crucial, when these input values are used as querystring and sent through the URL. Some Browsers like Firefox will consider their special meanings and break the URL flow.

c.  When user enters the value with caps lock ON? – Sometimes, the values entered are correct, but only because their case is different than what you have coded, your logic fails.

d.  Input fields having regular expression validation like Email, must also be tested for above combinations, although these are relatively safer and less prone to bad input values.

2. Testing navigation related scenarios
If your form allows user to select some values and then navigate away and return, it becomes important that your code retains the user-selected values on return. For example: You have an online shopping website and user has selected to view items in descending order of price, from a particular city and in a given price range. When user moves from one page to other, you need to retain those preferences.

3.  Database and Screen field length Testing
Most fields on an input form are mapped to a database column. In many projects with large teams, these are coded by different individuals. Chances of a mismatch in coded values are more. Thus each field should be validated for its maxlength (maximum allowed character limit).
Now, do you think these should not be part of Unit level testing and it should be a developer’s responsibility to validate at least such scenarios instead of waiting for a Testing resource, who may have more than one project to handle, to identify such flaws in your coding.