I'm certainly no expert when it comes to snakes,but it seems pretty obvious that the best way to feed is in the enclosure and only remove it when you want to handle.It's all about learned behaviour,if you remove it then it is not expecting food so it wont bite.
Always feed in the enclosure and only feed at night. When hands go into the enclosure in the daylight hours, to clean, or what have you, there should "hopefully" be no association with food. This is what works for me anyway.