selenium get element by parent code example
Example 1: selenium select parent element
parent_element = element.find_element_by_xpath('./..')
Example 2: selenium get element parent
//label[contains(., 'labelName')]/parent::*//input[@value='elementToSelect']