2017-10-07 109 views
0

我試圖出版我的Python項目天青,但我得到了 導入錯誤:沒有名爲「azure.storage.sharedaccesssignature」模塊。該項目工作正常,沒有虛擬環境,它不會工作,並給我這個錯誤。是的,所有的依賴關係都在駕駛室內,並且在requirements.txt中是--find-links控制檯。無論是否有ve,依賴關係都是相同的。
`Azure的web應用azure.storage.sharedaccesssignature導入錯誤

--find-links wheelhouse 
Flask==0.12.1 
azure-storage-blob==0.37.0 
azure-storage-file==0.37.0 
azure-storage-queue==0.37.0 
azure==2.0.0 
azure-storage==0.34.3 
azure-batch==4.0.0 
azure-mgmt-scheduler==1.1.3 
azure-mgmt-storage==1.0.0 

` 請告訴我什麼樣的信息,你也需要。 謝謝!

編輯1: 我輸出的日誌中天青:

D:\home\site\wwwroot>cat logs.txt 
2017-10-07 16:08:25.674062: wfastcgi.py 2.1.1 started 

2017-10-07 16:08:25.689690: Python version: 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32 bit (Intel)] 

2017-10-07 16:08:25.689690: wfastcgi.py 2.1.1 initializing 

2017-10-07 16:08:25.737007: Activating venv with executable at D:\home\site\wwwroot\env\Scripts\python.exe 

2017-10-07 16:08:26.886554: Getting handler main.app 

2017-10-07 16:08:31.038583: Error occurred while reading WSGI handler: 



Traceback (most recent call last): 

    File "D:\Python34\Scripts\wfastcgi.py", line 711, in main 

    env, handler = read_wsgi_handler(response.physical_path) 

    File "D:\Python34\Scripts\wfastcgi.py", line 568, in read_wsgi_handler 

    return env, get_wsgi_handler(handler_name) 

    File "D:\Python34\Scripts\wfastcgi.py", line 541, in get_wsgi_handler 

    handler = handler() 

    File ".\virtualenv_proxy.py", line 93, in get_venv_handler 

    handler = get_wsgi_handler(os.getenv('WSGI_ALT_VIRTUALENV_HANDLER')) 

    File ".\virtualenv_proxy.py", line 62, in get_wsgi_handler 

    raise ValueError('"%s" could not be imported%s' % (handler_name, last_tb)) 

ValueError: "main.app" could not be imported: Traceback (most recent call last): 

    File ".\virtualenv_proxy.py", line 46, in get_wsgi_handler 

    handler = __import__(module_name, fromlist=[name_list[0][0]]) 

    File "D:\home\site\wwwroot\main.py", line 3, in <module> 

    from azure.storage.table import TableService, Entity 

    File "D:\home\site\wwwroot\env\lib\site-packages\azure\storage\table\__init__.py", line 26, in <module> 

    from .tableservice import TableService 

    File "D:\home\site\wwwroot\env\lib\site-packages\azure\storage\table\tableservice.py", line 82, in <module> 

    from ..sharedaccesssignature import (

ImportError: No module named 'azure.storage.sharedaccesssignature' 







StdOut: 



StdErr: 

2017-10-07 16:08:31.055892: Unhandled exception in wfastcgi.py: Traceback (most recent call last): 

    File "D:\Python34\Scripts\wfastcgi.py", line 711, in main 

    env, handler = read_wsgi_handler(response.physical_path) 

    File "D:\Python34\Scripts\wfastcgi.py", line 568, in read_wsgi_handler 

    return env, get_wsgi_handler(handler_name) 

    File "D:\Python34\Scripts\wfastcgi.py", line 541, in get_wsgi_handler 

    handler = handler() 

    File ".\virtualenv_proxy.py", line 93, in get_venv_handler 

    handler = get_wsgi_handler(os.getenv('WSGI_ALT_VIRTUALENV_HANDLER')) 

    File ".\virtualenv_proxy.py", line 62, in get_wsgi_handler 

    raise ValueError('"%s" could not be imported%s' % (handler_name, last_tb)) 

ValueError: "main.app" could not be imported: Traceback (most recent call last): 

    File ".\virtualenv_proxy.py", line 46, in get_wsgi_handler 

    handler = __import__(module_name, fromlist=[name_list[0][0]]) 

    File "D:\home\site\wwwroot\main.py", line 3, in <module> 

    from azure.storage.table import TableService, Entity 

    File "D:\home\site\wwwroot\env\lib\site-packages\azure\storage\table\__init__.py", line 26, in <module> 

    from .tableservice import TableService 

    File "D:\home\site\wwwroot\env\lib\site-packages\azure\storage\table\tableservice.py", line 82, in <module> 

    from ..sharedaccesssignature import (

ImportError: No module named 'azure.storage.sharedaccesssignature' 



2017-10-07 16:08:31.069837: wfastcgi.py 2.1.1 closed 
+0

請您在Kudu上發佈完整的日誌信息? –

回答