2011-03-15 67 views
10

我有Mercurial 1.8.1,Python 2.6.6安裝在運行於虛擬機上的Win 2k8 R2上。我曾嘗試安裝從msi,源代碼和使用tortisehg。命令行汞柱工作正常,但我得到的運行hgweb.cgi時同樣的錯誤:Mercurial CGI(hgweb.cgi)失敗

 
Traceback (most recent call last): 
    File ".\hgweb.cgi", line 17, in 
    application = hgweb(config) 
    File "mercurial\hgweb\__init__.pyc", line 26, in hgweb 

    File "mercurial\hgweb\hgwebdir_mod.pyc", line 61, in __init__ 

    File "mercurial\hgweb\hgwebdir_mod.pyc", line 70, in refresh 

    File "mercurial\ui.pyc", line 35, in __init__ 

    File "mercurial\demandimport.pyc", line 75, in __getattribute__ 

    File "mercurial\demandimport.pyc", line 47, in _load 

    File "mercurial\util.pyc", line 576, in 

    File "mercurial\demandimport.pyc", line 85, in _demandimport 

    File "mercurial\windows.pyc", line 21, in 

    File "mercurial\demandimport.pyc", line 75, in __getattribute__ 

    File "mercurial\demandimport.pyc", line 47, in _load 

    File "mercurial\osutil.pyc", line 12, in 

    File "mercurial\osutil.pyc", line 10, in __load 

ImportError: DLL load failed: The specified module could not be found. 

我已經在SO發現和其他地方指着我嘗試從源代碼安裝,刪除純osutil到其他的答案安裝或安裝舊版本。我已經全部嘗試過了。

這特別令人沮喪,因爲我有其他類似的非虛擬機器運行正常,但一直無法找到斷開連接。

想法?

+0

我有同樣的問題,你有沒有找到解決辦法?我花了很多時間,試圖讓它工作... – 2011-03-23 18:52:59

回答

1

每當我有少於描述性的錯誤信息,告訴我在系統級別發生了什麼,但不是,我使用Sysinternals' Procmon告訴我註冊表和文件系統發生了什麼。它很冗長,並且讓過濾器僅顯示感興趣的過程需要一些學習,但是您可以將結果導出到Excel並瀏覽它們以獲得可疑的結果。當然,要特別注意失敗。

試試看看DLL正在搜索什麼。

18

我不得不使用以下的系統配置相同的錯誤

  • Python的2.6.6安裝爲MSI
  • 水銀-1.8.2 86安裝爲MSI
  • IIS7

我簡單地解決了這個問題:

  1. Pyt漢已安裝早期
  2. 卸載水銀MSI軟件包
  3. 下載和安裝「水銀-1.8.2(32位py2.6)」從mercurial website安裝程序,其被標記爲「這被推薦用於hgweb設置」 。
  4. 將C:\ Python26 \ Lib \ site-packages \ mercurial \的內容複製到IIS7網站設置中使用的目錄中。

直到現在一切正常。希望這會有所幫助。

+1

確認! msi包使用相同的堆棧跟蹤給了我相當一致的repro。 通過切換到Mercurial Python安裝程序,它現在就像一個魅力:) – Antony 2011-05-09 05:46:43

+0

它的工作原理!謝謝! – ThiagoAlves 2011-08-27 18:11:02

+0

對我來說也是! – 2012-02-23 14:31:27

相關問題