Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Решено] Проблема с установкой модуля openpyxl
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Russian
View previous topic :: View next topic  
Author Message
OlegM
n00b
n00b


Joined: 28 Jun 2024
Posts: 2

PostPosted: Fri Jun 28, 2024 8:46 am    Post subject: [Решено] Проблема с установкой модуля openpyxl Reply with quote

Мне для работы в python понадобился дополнительный модуль openpyxl.

Стандартными средствами питона модули в gentoo не устанавливаются, насколько я понял:
Code:

$ pip install openpyxl
error: externally-managed-environment

× This environment is externally managed
╰─>
    The system-wide Python installation in Gentoo should be maintained
    using the system package manager (e.g. emerge).
   
    If the package in question is not packaged for Gentoo, please
    consider installing it inside a virtual environment, e.g.:
   
    python -m venv /path/to/venv
    . /path/to/venv/bin/activate
    pip install mypackage
   
    To exit the virtual environment, run:
   
    deactivate
   
    The virtual environment is not deleted, and can be re-entered by
    re-sourcing the activate file.

note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
hint: See PEP 668 for the detailed specification.


Нужный мне модуль существует в виде пакета dev-python/openpyxl и нормально устанавливается через emerge, pip list показывает, что модуль в системе установлен, но приложения питона его почему то не видят (import openpyxl выдает ошибку "ModuleNotFoundError: No module named 'openpyxl'").

Подскажите, что делаю не так?
Back to top
View user's profile Send private message
OlegM
n00b
n00b


Joined: 28 Jun 2024
Posts: 2

PostPosted: Fri Jun 28, 2024 1:03 pm    Post subject: Reply with quote

В общем разобрался. Виртуальное окружение надо было настроить.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Russian All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum