There are several size options under 'SELECT SIZE' on this site: https://www.myntra.com/sports-shoes/puma/puma-men-black-eternity-nitro-running-shoes/14521968/buy
I have been trying to somehow click one button to choose size of the shoes using python selenium but every time it says "no such element: unable to locate element:.....".Here's what I have tried till now.
size_button = self.find_element(
By.CSS_SELECTOR,
'button[class="btn default outline size-btn big selected"]'
)
size_button = self.find_element(
By.CSS_SELECTOR,
'ul[class="sizes-list list-unstyled list-inline padding-md-left padding-md-bottom"]'
)
size_button = self.find_element(
By.XPATH, '/html/body/div[2]/div/div[2]/div[2]/div[2]/div/div[2]/div[1]/div/div/div[4]/div[6]/div[2]/div[1]/div[2]/ul/li[1]/button'
)
size_button = self.find_element(
By.XPATH, '//[@id="reactPageContent"]/div/div/div[4]/div[6]/div[2]/div[1]/div[2]/ul/li[1]/button'
)
Here's the error for one of the above code:
selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element: {"method":"css selector","selector":"button[class="btn default outline size-btn big selected"]"}