Based on those two different snakes with the odd behavior I would suggest you look for mites and see if you can treat for it.

Provent-A-Mite is the one of the top used items for that. I have used it with great success.