Getting elected unopposed is perfectly legal in the existing provisions of electoral laws and practice. It is also thrilling. You emerge as the unrivalled representative of the people without the people having chosen you because you are the only choice on the ballot. It is like achieving something without making the requisite effort.
Rule 11 of the Conduct of Election Rules 1961 says: “(1) The returning officer shall… cause a copy of the list of contesting candidates to be affixed in some conspicuous place in his office and where the number of contesting candidates is equal to, or less than, the number of seats to be filled, he shall, immediately after such affixation, declare under sub-section (2) or as the case may be, sub-section (3) of section 53 the result of the election in such one of the Forms 21 to 21B as may be appropriate....”