4719c2f1d3bad4bd7bad5ef3856b363b27e267a5
Linux/Install/Home.md
... | ... | @@ -65,4 +65,21 @@ $ uname -a |
65 | 65 | # poweroff |
66 | 66 | # shutdown -h now |
67 | 67 | ``` |
68 | -- shutdown コマンドの -h オプションを付けないと、シングルユーザモードになるだけで電源は切れない。 |
|
... | ... | \ No newline at end of file |
0 | +- shutdown コマンドの -h オプションを付けないと、シングルユーザモードになるだけで電源は切れない。 |
|
1 | + |
|
2 | +# pip3 エラー対応 (AttributeError: '_NamespacePath' object has no attribute 'sort') |
|
3 | +- python3-pip, python3-setuptools を再インストールする。 |
|
4 | +``` |
|
5 | +# dnf erase python3-pip python3-setuptools |
|
6 | +# dnf install -y python3-pip python3-setuptools |
|
7 | +``` |
|
8 | +- 再インストールで直らない場合は、該当ファイルを修正する。<br> |
|
9 | +/usr/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py |
|
10 | +```python |
|
11 | +#orig_path.sort(key=position_in_sys_path) |
|
12 | +#module.__path__[:] = [_normalize_cached(p) for p in orig_path] |
|
13 | +orig_path_t = list(orig_path) |
|
14 | +orig_path_t.sort(key=position_in_sys_path) |
|
15 | +module.__path__[:] = [_normalize_cached(p) for p in orig_path_t] |
|
16 | +``` |
|
17 | +- [python - pip3 error - '_NamespacePath' object has no attribute 'sort' - Stack Overflow](https://stackoverflow.com/questions/47955397/) |