Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

5
  • What's the entire error? Usually it gives a line number Commented Jul 14, 2020 at 9:39
  • Let me post the screenshot of the error then Commented Jul 14, 2020 at 9:42
  • 1
    Things you need to keep in mind while using selenium, add some delays for 2-3 secs (just waiting for gmail to load completely) also be assured that there is such element with xpath present (i hope you have not copy pasted the code from some resource because xpath is relative(changes)). Commented Jul 14, 2020 at 9:54
  • the xpath is correct. I didn't copy & paste the code I took the path directly from the chrome developer tab. Commented Jul 14, 2020 at 10:05
  • I solved it. I am putting the solution into the answer Commented Jul 15, 2020 at 4:17