Could it be an infection? My girl just got the same some months ago, she had a retained eye cap from 3 sheds ago which went really bad. From what I've experienced, you gotta take her to the vet ASAP if that's the case.

Here's some photos from the day we took her to the vet, we had to wait like 2-3 days because the closest reptile-vet only works on Tuesdays...

You can clearly see the eye is bulging out.




Is this somewhat what it looks like on your snake?