Fix python test after recent changes