Ok sorry to have made you lose your time, it's working now... I don't know if it's whether I started pulseaudio directly instead of using start-pulseaudio-x11... However, I had checked that pulseaudio ran (with ps ax | grep pulse) and even in that case the python code that is on the page I refered to didn't work... Having started with pulseaudio -vvv the same code worked, I don't know why... Thanks again for your help and sorry for the trouble!