There is the following command:
print(os.popen("sudo tshark").read())
I enter it and get an error like this:
sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
I'm trying to solve the problem like this:
proc.stdin.write('3621\n')
proc.stdin.flush()
But it does not work, how to fix it help!!!