[feature] remove raw level socket API from python extension