selenium.common.exceptions.StaleElementReferenceException: Message: stale element reference: element is not attached to the page document
The above is the error message that I am getting.
There is a button that is clickable in the browser in the beginning.
But then it becomes unclickable, hence the error message.
How do I check whether a button is clickable or not before clicking on it?