LightAutoML
LightAutoML copied to clipboard
Handle import errors of extras modules
🚀 Feature Request
LightAutoML should inform a user about additional extras that he needs to install to avoid the import problem. Similar to: https://github.com/sb-ai-lab/LightAutoML/blob/f2fa4107b5256e65ace778561ac62037f48d3190/lightautoml/report/report_deco.py#L1134
https://github.com/sb-ai-lab/LightAutoML/blob/f2fa4107b5256e65ace778561ac62037f48d3190/lightautoml/text/tokenizer.py#L21
Or automatically install missing extras as in following proposal.
Proposal
try:
from weasyprint import HTML
except ImportError:
import pip
pip.main(['install', '--user', 'lightautoml[pdf]'])
from weasyprint import HTML
Stale issue message