アプリケーションレベルで定期的な処理実行をサポートするPytonライブラリ。
「Python」タグアーカイブ
anaconda バージョンアップ方法
[python] pipのインストール失敗
Ubuntuにおいて pip / pip3 のインストールに失敗する(インストールパッケージがみつからない)
※ Ubuntu 18.04LTS
1. 失敗例
1 2 3 4 5 |
$ sudo apt install python3-pip Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package python3-pip |
python 2 と python 3 を共存
pyenvを利用する
pyenvのインストール
1 |
$ brew install pyenv |
PATHの追加 (.bash_profileなど)
1 |
export PATH=$HOME/.pyenv/shims:$PATH |
pyenvの使い方
インストール可能なバージョン一覧
1 |
$ pyenv install --list |
Pythonsのインストール
1 |
$ pyenv install <version name> |
グローバルで使用するバージョンの切り替え
1 |
$ pyenv global <version name> |
リハッシュ
1 |
$ pyenv rehash |
High SierraにPython3.6.3のインストールで失敗
High Sierra (macOS 10.13) に pyenv で Python 3.6.3 をインストールすると失敗する。(BUILD FAILED)
解決方法
1. opensslをインストール
1 |
$ brew install openssl |
2. opensslのインストールパスを指定してpyenvを実行
1 2 3 |
CFLAGS="-I$(brew --prefix openssl)/include" \ LDFLAGS="-L$(brew --prefix openssl)/lib" \ pyenv install -v 3.4.3 |
ERROR: The Python ssl extension was not compiled. Missing the OpenSSL lib?