2012-01-28 53 views
1

每次我上傳我的應用程序,以谷歌的App Engine,日誌總是顯示此警告:谷歌App Engine的本地開發服務器SSL警告(Python 2.7版)

WARNING appengine_rpc.py:435 ssl module not found. Without the ssl 
module, the identity of the remote host cannot be verified, and 
connections may NOT be secure. To fix this, please install the ssl 
module from http://pypi.python.org/pypi/ssl . 

我運行一個virtualenv與Python 2.7。當我在它的時候,我嘗試運行

$ pip install ssl 

但是這會產生一個錯誤:

ValueError: This extension should not be used with Python 2.6 or later 
(already built in), and has not been tested with Python 2.3.4 or earlier. 

如果ssl被置在Python 2.7,我怎麼告訴當地的發展服務器使用內置ssl模塊?

回答

1

聽起來像appcfg.py沒有正確使用你的virtualenv。您可以嘗試編輯appcfg.py腳本,以便打印sys.version和sys.path,以確認它正確使用virtualenv。 (shebang行是「#!/ usr/bin/env python」,所以應該使用你的活動環境,但是值得檢查。)

如果你使用Launcher,你需要明確地告訴它尋找你的virtualenv的Python。轉到首選項,並將Python路徑設置爲您的virtualenv的Python 2.7。啓動程序打印它在日誌中使用的Python路徑(至少在啓動開發服務器時)。

相關問題