2013-11-14 94 views
6

流星(版本0.6.6.3)出現以下錯誤,並點擊Twitter登錄按鈕。Twitter和流星問題

I2038-06:13:28.670(-8)? Exception while invoking method 'login' Error: Failed to send OAuth1 request to https://api.twitter.com/oauth/request_token. failed [401] Failed to validate oauth signature and token 
I2038-06:13:28.673(-8)?  at OAuth1Binding._call (packages/oauth1/oauth1_binding.js:143) 
I2038-06:13:28.674(-8)?  at OAuth1Binding.prepareRequestToken (packages/oauth1/oauth1_binding.js:27) 
I2038-06:13:28.675(-8)?  at Oauth._requestHandlers.(anonymous function) (packages/oauth1/oauth1_server.js:21) 
I2038-06:13:28.676(-8)?  at middleware (packages/oauth/oauth_server.js:105) 
I2038-06:13:28.677(-8)?  at packages/oauth/oauth_server.js:78 

有人有關於如何解決這個問題的想法?

謝謝

回答

3

好吧,等我扯了一會兒後,我終於做到了。以下是我發現的解決方法,希望可以幫助其他人獲得類似的錯誤。

設置

  • 本地Debian的服務器上運行的流星,IP地址爲192.168.2.100。可以是像我這樣的虛擬機。
  • 您正在訪問的 192.168.2.100:3000從Windows計算機
  • 通過Twitter的包連接與導航儀流星應用程序無法正常工作

解決方案

  • 在你windows主機文件設置你的本地主機爲192.168.2.100而不是127.0.0.1
  • 在Twitter應用程序配置中輸入回調http://192.168.2.100:3000/_oauth/twitter?close
  • 您可能需要等待或者從頭
+0

相關且有幫助(使用流星+推特使用圖片進行認證)http://meteor.hromnik.com/blog/login-with-facebook-twitter-and-google-in-meteor – DeBraid

7

我有相同的問題,造成手動刪除和插入loginServiceConfiguration不正確。如果您不使用配置工具,請確保您插入consumerKey而不是clientId

Accounts.loginServiceConfiguration.remove({ 
    service: "twitter" 
}); 

Accounts.loginServiceConfiguration.insert({ 
    service: "twitter", 
    consumerKey: "...", 
    secret: "..." 
}); 
+0

重啓謝謝您的答覆,但我的配置似乎是正確的。我有正確的領域。我已經刪除了collectin,並經過了幾次配置,但沒有任何幫助。 – Ben

+0

非常感謝您提供這方面的信息。這正是我所錯過的。 –

+0

Plz給這個人一個餅乾!謝謝 ! – Arthur