Azure Python Web App Internal Server Error -


edit: problem seems importing of packages in app. packages correctly installed, , can see them in wwwroot kudu. but, when import them in scripts, 500 error. wierdest thing problem occurs when import packages way:

from package import 

but not way:

import package 

i same error, when try call package function, meaning cant access packages(?)

it seems there exception generated in web app, not in local machine. thoughts?


i'm trying publish python web app in azure web apps, keep failing. i'm using bottle web framework, , packages installed, along dependencies are:

  • numpy
  • scipy
  • scikit-image

i have configured virtual env match web app (32bit/2.7), , installed packages using wheels mentioned in post: https://azure.microsoft.com/en-us/documentation/articles/web-sites-python-create-deploy-bottle-app/

i'm deploying app via vs , publish wizard azure sdk, , works expected.

when app up, 500 error, , console says these things: enter image description here

my web.cofing this:

    <?xml version="1.0"?> <!-- generated web.config microsoft azure. remove comment prevent      modifications being overwritten when publishing project. --> <configuration>   <system.diagnostics>     <trace>       <listeners>         <add type="microsoft.windowsazure.diagnostics.diagnosticmonitortracelistener, microsoft.windowsazure.diagnostics, version=1.0.0.0, culture=neutral, publickeytoken=31b....." name="azurediagnostics">           <filter type="" />         </add>       </listeners>     </trace>   </system.diagnostics>   <appsettings>     <add key="wsgi_alt_virtualenv_handler" value="app.wsgi_app()" />     <add key="wsgi_alt_virtualenv_activate_this" value="d:\home\site\wwwroot\env\scripts\activate_this.py" />     <add key="wsgi_handler" value="ptvs_virtualenv_proxy.get_virtualenv_handler()" />     <add key="pythonpath" value="d:\home\site\wwwroot" />   </appsettings>   <system.web>     <compilation debug="true" targetframework="4.0" />   </system.web>   <system.webserver>     <modules runallmanagedmodulesforallrequests="true" />     <handlers>       <add name="python fastcgi" path="handler.fcgi" verb="*" modules="fastcgimodule" scriptprocessor="d:\python27\python.exe|d:\python27\scripts\wfastcgi.py" resourcetype="unspecified" requireaccess="script" />     </handlers>     <rewrite>       <rules>         <rule name="static files" stopprocessing="true">           <conditions>             <add input="true" pattern="false" />           </conditions>         </rule>         <rule name="configure python" stopprocessing="true">           <match url="(.*)" ignorecase="false" />           <conditions>             <add input="{request_uri}" pattern="^/static/.*" ignorecase="true" negate="true" />           </conditions>           <action type="rewrite" url="handler.fcgi/{r:1}" appendquerystring="true" />         </rule>       </rules>     </rewrite>   </system.webserver> </configuration> 

any why might happening?

finally, got working. problem version of pip using install wheels. after upgraded pip 8.11.1 worked expected.


Comments