I found the code below on the python website.
However the code does not compile on Windows 10 with Python 3.6.5 installed.
I've tried the same code on Ubuntu 16.04 (Python 2.7) and the code works fine.
from multiprocessing import Process
def f(name):
print ('hello', name)
if __name__ == '__main__':
p = Process(target=f, args=('bob',))
p.start()
p.join()
The error I get is shown below. I've only shown the last line of the stack trace since this seems to be where the error is generated. I've done a lot searching but have not found a solution.
File "J:\Programs\Python\Python36\lib\multiprocessing\context.py", line 321, in _Popen from .popen_spawn_win32 import Popen
ImportError: cannot import name 'Popen'
Thanks in advance for any help.