Fix replica reference
Merge branch 'master' into python