Skip to content

Commit

Permalink
Fixed issue related to installation hangs on Windows with cython nthr…
Browse files Browse the repository at this point in the history
…eads>=1.
  • Loading branch information
akornatskyy committed Dec 30, 2020
1 parent 51f4ea7 commit dcdca23
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/usr/bin/env python

import multiprocessing
import os
import re

Expand All @@ -21,7 +22,8 @@
os.path.join(p, "handlers", "__init__.py"),
os.path.join(p, "middleware", "__init__.py"),
],
nthreads=2,
# https://github.com/cython/cython/issues/3262
nthreads=0 if multiprocessing.get_start_method() == "spawn" else 2,
compiler_directives={"language_level": 3},
quiet=True,
)
Expand Down

0 comments on commit dcdca23

Please sign in to comment.