File tree Expand file tree Collapse file tree 1 file changed +0
-16
lines changed Expand file tree Collapse file tree 1 file changed +0
-16
lines changed Original file line number Diff line number Diff line change 1
- import sys
2
- import os .path
3
1
4
- # mypyc depends on a copy of mypy installed as package-data that won't
5
- # live in the normal python path (to avoid potential conflicts with an
6
- # installed mypy). In order to make sure we find it, we perform
7
- # sys.path shenanigans here when mypyc is first imported.
8
- base_path = os .path .dirname (__file__ )
9
- mypy_path = os .path .abspath (os .path .join (base_path , 'external' , 'mypy' ))
10
- sys .path .insert (0 , mypy_path )
11
-
12
- # Make sure that we can find mypy and that it is the *right* mypy. If
13
- # mypy was imported before mypyc was, our path manipulations might
14
- # have been too late, and this assert will catch the problem.
15
- import mypy
16
- assert mypy .__file__ == os .path .join (mypy_path , 'mypy' , '__init__.py' ), (
17
- "Found a mypy other than the one packaged with mypyc!" )
You can’t perform that action at this time.
0 commit comments