It might be because of how you make him go into a lope/canter. Maybe how you place the reins or the way you give him the canter/lope sign just irritates him. Or it could also be that he is hurt. It could be something with bone or muscle so if it gets worse then go see a vet. It also might be that your horse just developed a bad habit.
Whatever it is I hope he gets better!