Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dropbox connection error / Errno::ECONNRESET (Connection reset by peer) #4

Open
rhulka opened this issue Sep 9, 2011 · 6 comments
Open

Comments

@rhulka
Copy link

rhulka commented Sep 9, 2011

Hi!

Thanks for your work and nice plugin!

I faced with one problem, when i click save file or synchronize with dropbox i getting 500 Internal error, i checked webrick debug output and plugin sources and i guess that reason of the problem is that in file app/models/dropbox_document.rb:180 ```
@auth = Authenticator.new(@conf) unless defined?(AUTH)

(https://github.com/zuinqstudio/redmine_drop_box/blob/master/app/models/dropbox_document.rb#L180)

```@auth.request_token``` is nill... but i have no idea how to fix it...

More about error and  configuration of my environment below.

I will be very grateful for any advice!

Errno::ECONNRESET (Connection reset by peer):
Errno::ECONNRESET (Connection reset by peer):
/usr/lib/ruby/gems/1.8/gems/net-http-persistent-1.8/lib/net/http/faster.rb:15:in read_nonblock' /usr/lib/ruby/gems/1.8/gems/net-http-persistent-1.8/lib/net/http/faster.rb:15:inrbuf_fill'
/usr/lib/ruby/1.8/net/protocol.rb:116:in readuntil' /usr/lib/ruby/1.8/net/protocol.rb:126:inreadline'
/usr/lib/ruby/1.8/net/http.rb:2020:in read_status_line' /usr/lib/ruby/1.8/net/http.rb:2009:inread_new'
/usr/lib/ruby/1.8/net/http.rb:1050:in request' /usr/lib/ruby/1.8/net/http.rb:1037:inrequest'
/usr/lib/ruby/1.8/net/http.rb:543:in start' /usr/lib/ruby/1.8/net/http.rb:1035:inrequest'
oauth (0.4.5) lib/oauth/consumer.rb:164:in request' oauth (0.4.5) lib/oauth/consumer.rb:197:intoken_request'
oauth (0.4.5) lib/oauth/consumer.rb:139:in get_request_token' vendor/plugins/redmine_drop_box/app/models/dropbox_document.rb:181:indropbox_connect'


```raise @auth.inspect``` gives:

<Authenticator:0xb5f155f8 @access_token=nil, @consumer_key="imhmwa7p9sbkvye", @consumer=#<OAuth::Consumer:0xb5f154b8
@key="imhmwa7p9sbkvye", @secret="u8j8t8kg3hwjz7t",
@options={:access_token_url=>"http://api.dropbox.com/0/oauth/access_token", :http_method=>:post,
:request_token_url=>"http://api.dropbox.com/0/oauth/request_token", :signature_method=>"HMAC-SHA1",
:request_token_path=>"/oauth/request_token", :proxy=>nil, :authorize_path=>"/oauth/authorize", :scheme=>:header,
:oauth_version=>"1.0", :site=>"http://api.dropbox.com", :access_token_path=>"/oauth/access_token",
:authorize_url=>"http://www.dropbox.com/0/oauth/authorize"}>, @request_token=nil,
@oauth_conf={:access_token_url=>"http://api.dropbox.com/0/oauth/access_token", :http_method=>:post,
:request_token_url=>"http://api.dropbox.com/0/oauth/request_token", :scheme=>:header,
:site=>"http://api.dropbox.com", :authorize_url=>"http://www.dropbox.com/0/oauth/authorize"},
@config={"verifier"=>"", "authorization_url"=>"http://www.dropbox.com/0/oauth/authorize",
"content_server"=>"api-content.dropbox.com", "port"=>80, "consumer_key"=>"imhmwa7p9sbkvye",
"consumer_secret"=>"u8j8t8kg3hwjz7t", "request_token_url"=>"http://api.dropbox.com/0/oauth/request_token",
"server"=>"api.dropbox.com", "root"=>"dropbox", "testing_user"=>"[email protected]",
"access_token_url"=>"http://api.dropbox.com/0/oauth/access_token", "testing_password"=>"[HERE WAS MY PASSWORD]"},
@consumer_secret="u8j8t8kg3hwjz7t">


Environment:
* Ruby 1.8
* Gem 1.4.2
* Redmine 1.1.2
* Gems: mechanize (2.0.1),  oauth (0.4.5), net-http-persistent (2.0, 1.8) 
@zuinqstudio
Copy link
Owner

Thanks for the feedback. We've being working on this issue from last week. Please, be patient, I'll keep you informed as soon as we fix it.

Regards!

@zuinqstudio
Copy link
Owner

Can you try to test if the plugin works now? I think it´s Dropbox plugin bug that is now solved...

Regards!

@rhulka
Copy link
Author

rhulka commented Sep 15, 2011

I reinstalled plugin, but still the same bug

Errno::ECONNRESET (Connection reset by peer):
/usr/lib/ruby/gems/1.8/gems/net-http-persistent-1.8/lib/net/http/faster.rb:15:in read_nonblock' /usr/lib/ruby/gems/1.8/gems/net-http-persistent-1.8/lib/net/http/faster.rb:15:inrbuf_fill'
/usr/lib/ruby/1.8/net/protocol.rb:116:in readuntil' /usr/lib/ruby/1.8/net/protocol.rb:126:inreadline'
/usr/lib/ruby/1.8/net/http.rb:2020:in read_status_line' /usr/lib/ruby/1.8/net/http.rb:2009:inread_new'
/usr/lib/ruby/1.8/net/http.rb:1050:in request' /usr/lib/ruby/1.8/net/http.rb:1037:inrequest'
/usr/lib/ruby/1.8/net/http.rb:543:in start' /usr/lib/ruby/1.8/net/http.rb:1035:inrequest'
oauth (0.4.5) lib/oauth/consumer.rb:164:in request' oauth (0.4.5) lib/oauth/consumer.rb:197:intoken_request'
oauth (0.4.5) lib/oauth/consumer.rb:139:in get_request_token' vendor/plugins/redmine_drop_box/app/models/dropbox_document.rb:181:indropbox_connect'
vendor/plugins/redmine_drop_box/app/models/dropbox_document.rb:113:in dropbox_metadatos' vendor/plugins/redmine_drop_box/app/controllers/drop_box_controller.rb:159:insynchronize'
vendor/plugins/redmine_drop_box/app/controllers/drop_box_controller.rb:154:in each' vendor/plugins/redmine_drop_box/app/controllers/drop_box_controller.rb:154:insynchronize'

@rhulka
Copy link
Author

rhulka commented Sep 15, 2011

I checked it on my local machine (not on the server) and it works... almost
When i trying synchronize uploaded file with dropbox i getting:

ActionView::MissingTemplate (Missing template drop_box/synchronize_document.erb in view path vendor/plugins/redmine_backlogs/app/views:vendor/plugins/redmine_drop_box/app/views:app/views):
  app/controllers/application_controller.rb:509:in `default_template'
  /usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
  /usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
  /usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
  /usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
  /usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
  /usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
  /usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
  /usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
  /usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
  /usr/lib/ruby/1.8/webrick/server.rb:82:in `start'

Also i getting "Dropbox connection error. Check user / password Dropbox account on plugin page configuration." when i had create new document, but i checked it many times and i completly sure that user/password is correct..

So, i think maybe Errno::ECONNRESET (Connection reset by peer) is a problem with my environment, i will check and write here about results. Maybe it will be useful for someone.

BR,
Rostyk

@themick79i
Copy link

I have the same @rhulka problem

the problem it could be the authorization in dropbox...maybe

tnx

@dafyk
Copy link

dafyk commented Mar 30, 2012

Had the same issue today with Redmine 1.3.2 and Dropbox plugin (0.0.1, build 5b4c1bf). Problem solved by deauthorizing APP from my twitter account, and re-authorizing in plugin settings by clicking "Click here to authorize Redmine by your DropBox account"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants