Added thread request functionality in python+c