I had this before when ten major opponents were accidently in the game. The game doesn't allow for more than 9 opponents in the ranking on the foreign relations screen so it reports back the string not found in place of a ranking higher numerically than tenth. Here's where I had posted about it with a screenie, see maybe if this matches your problem.
String not found issueEdit: yea after looking at your debug a little closer that is your issue, but it was supposed to be fixed back in October where you couldn't have 10 opponents.