In all cases of adverse claims or disputes arising out of conflicting claims to land or concerning boundary lines, the adverse claimants may submit the decision thereof to said judge by an agreement in writing specifying particularly the subject matter in dispute and may agree that his or her decision shall be final. The said judge must hear the proofs, and shall execute a deed or deny the execution of a deed in accordance with the facts; but in all other cases of adverse claims the party out of possession shall commence his or her action in a court of competent jurisdiction within six months after the filing of the patent (or a certified copy thereof) from the United States, in the office of the county auditor. In case such action be commenced within the time herein limited, the plaintiff must serve notice of lis pendens upon such judge, who must thereupon stay all proceedings in the matter of granting or executing any deed to the land in dispute until the final decision in such suit; upon presentation of a certified copy of the final judgment in such action, such judge must execute and deliver a deed of the premises, in accordance with the judgment, adjudging the claimant to have been an occupant of any particular lot or lots at the time of the entry of such townsite in the United States land office, or to be the successor in interest of such occupant.