webmaster-kazu.com

テクノロジー・データ分析・実践ログ・その他

【Python】通知を簡単に送信するライブラリ「Notifiers」のインストール

カテゴリ: Python【初歩から現場実務的なもの】

通知を簡単に送信するライブラリ「Notifiers」のインストールについて解説しています。

Notifiers(https://github.com/liiight/notifiers)は、特定のプロバイダーに簡単に通知を送信することができるライブラリです。

■Python

今回のPythonのバージョンは、「3.8.5」を使用しています。(Windows10)(pythonランチャーでの確認)

■Notifiersをインストールする

Notifiersをインストールを行いますが、今回はpipを経由してインストールを行うので、まずWindowsのコマンドプロンプトを起動します。

pip install notifiers

起動後、上記のコマンドを入力し、Enterキーを押します。

なお、今回は、pythonランチャーを使用しており、Python Version 3.8.5にインストールを行うために、pipを使う場合にはコマンドでの切り替えを行います。

py -3.8 -m pip install notifiers

切り替えるために、上記のコマンドを入力し、Enterキーを押します。

Defaulting to user installation because normal site-packages is not writeable

Collecting notifiers

Downloading notifiers-1.3.3-py3-none-any.whl (43 kB)

|████████████████████████████████| 43 kB 337 kB/s

Collecting click<9.0.0,>=8.0.3

Downloading click-8.0.4-py3-none-any.whl (97 kB)

|████████████████████████████████| 97 kB 842 kB/s

Collecting jsonschema<5.0.0,>=4.4.0

Using cached jsonschema-4.4.0-py3-none-any.whl (72 kB)

Collecting requests<3.0.0,>=2.27.1

Using cached requests-2.27.1-py2.py3-none-any.whl (63 kB)

Requirement already satisfied: colorama in c:\users\user_\appdata\roaming\python\python38\site-packages (from click<9.0.0,>=8.0.3->notifiers) (0.4.4)

Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in c:\users\user_\appdata\roaming\python\python38\site-packages (from jsonschema<5.0.0,>=4.4.0->notifiers) (0.17.3)

Requirement already satisfied: attrs>=17.4.0 in c:\users\user_\appdata\roaming\python\python38\site-packages (from jsonschema<5.0.0,>=4.4.0->notifiers) (21.2.0)

Requirement already satisfied: importlib-resources>=1.4.0 in c:\users\user_\appdata\roaming\python\python38\site-packages (from jsonschema<5.0.0,>=4.4.0->notifiers) (5.4.0)

Requirement already satisfied: urllib3<1.27,>=1.21.1 in c:\users\user_\appdata\roaming\python\python38\site-packages (from requests<3.0.0,>=2.27.1->notifiers) (1.26.5)

Requirement already satisfied: idna<4,>=2.5 in c:\users\user_\appdata\roaming\python\python38\site-packages (from requests<3.0.0,>=2.27.1->notifiers) (2.10)

Collecting charset-normalizer~=2.0.0

Downloading charset_normalizer-2.0.12-py3-none-any.whl (39 kB)

Requirement already satisfied: certifi>=2017.4.17 in c:\users\user_\appdata\roaming\python\python38\site-packages (from requests<3.0.0,>=2.27.1->notifiers) (2021.5.30)

Requirement already satisfied: zipp>=3.1.0 in c:\users\user_\appdata\roaming\python\python38\site-packages (from importlib-resources>=1.4.0->jsonschema<5.0.0,>=4.4.0->notifiers) (3.6.0)

Installing collected packages: charset-normalizer, requests, jsonschema, click, notifiers

Attempting uninstall: requests

Found existing installation: requests 2.25.1

Uninstalling requests-2.25.1:

Successfully uninstalled requests-2.25.1

Attempting uninstall: jsonschema

Found existing installation: jsonschema 3.2.0

Uninstalling jsonschema-3.2.0:

Successfully uninstalled jsonschema-3.2.0

Attempting uninstall: click

Found existing installation: click 7.1.2

Uninstalling click-7.1.2:

Successfully uninstalled click-7.1.2

Successfully installed charset-normalizer-2.0.12 click-8.0.4 jsonschema-4.4.0 notifiers-1.3.3 requests-2.27.1

Enterキーを押すと、インストールが開始され、上記のように「Successfully installed」と表示されます。これが表示されれば、notifiersが正常にインストールされたことになります。

なお、今回はnotifiersのバージョン1.3.3をインストールしました。