The snake is preparing to moult, note the milky eyes. It will likely get hungry again, really soon!
The hampster has been in there 3 months so far. The snake has shed prior, I'm sure.
I had a ball python for 4 years & only once did he refuse food, but that refusal went on for almost 3 months. Finally, I figured out that her eyecaps had remained on after one or two sheds & the she couldn't see. I would put the 2 mice in the tub with her & she allowed them to run up on her as she couldn't see them. They would run right up to her mouth and she would recoil. If I had let those mice stay in her cage, it would "look" like they were friends.....until the next shed.