Closed wubli closed 6 years ago
I've changed the line:
from pebble import process, TimeoutError # to handle timeout
to:
import pebble
from concurrent.futures import TimeoutError
And:
with process.Pool(1) as p:
job = p.schedule(main,args=(args,),timeout=args.timeout)
try:
job.get()
to:
with pebble.ProcessPool(1) as p:
job = p.schedule(main,args=(args,),timeout=args.timeout)
try:
job.result()
This is causing some error messages on Windows: RuntimeError: I/O operations still in flight while destroying Overlapped object, the process may crash
but at least I can run the script
pip2 install 'pebble==3.1.15'
might also work
I comment out the line from pebble import process, TimeoutError # to handle timeout
Pebble
has changed its interface in version 4.
I see the requirements.txt
having a loose >=
restriction on the package version. If the code was developed on top of Pebble3
and pip will fetch Pebble4
then you will get API mismatch.
Either restrict the requirements.txt
to ==
3.1.17 (the last release of Pebble3
), or upgrade your code to use Pebble4
. I'd recommend the second approach.
Fixed requirements.txt file https://github.com/tvwenger/maxfield/commit/bbe8f1c4c32703352e8bc8c90373ba0d5115fc4e
Any way to solve this?