0

I'm trying to run a python script as an Azure webjob on App service. I have packaged the script along with required libraries using virtualenv. Still I'm getting import error.

File "D:\local\Temp\jobs\continuous\get-stock-details\03j5dtql.crz\lxml\html\__init__.py", line 53, in <module>
from .. import etree
ImportError: cannot import name 'etree'

I though of installing pip and the libraries directly using Kudu console, but there I'm getting Access denied error.

I'm using Python 3.6 and Windows as my OS.

Shiv Rajawat
  • 898
  • 9
  • 21

1 Answers1

0

I though of installing pip and the libraries directly using Kudu console, but there I'm getting Access denied error.

I can reproduce the issue, you can use the --user parameter, then the error will not appear.

python -m pip install <package-name> --user
Joy Wang
  • 39,905
  • 3
  • 30
  • 54