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

remove dependency on Http::Parser#request_path #99

Merged
merged 1 commit into from
Jan 16, 2014

Conversation

dalyons
Copy link
Contributor

@dalyons dalyons commented Jan 16, 2014

The upstream releases of the c http_parser no longer expose the request_path method, causing Websocket#dispatch to crash out.

lib/guard/livereload/websocket.rb:15:in 'dispatch': undefined method 'request_path' for #<HTTP::Parser:0x007ff21378e670> (NoMethodError)

Also see: tmm1/http_parser.rb#8

I'm not sure exactly what combination of versions of gems pulls in a recent enough version to cause this to be a problem, as I have a lot of complicated dependencies around em-http-request etc.

Anyway, we don't need to depend on request_path, its trivial to use URI.parse().path to remove this dependency, and make guard-livereload a bit more future proof.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.49%) when pulling edc6db1 on dalyons:master into 9f8a6a7 on guard:master.

@thibaudgg
Copy link
Member

Looks good, thanks!

thibaudgg added a commit that referenced this pull request Jan 16, 2014
remove dependency on Http::Parser#request_path
@thibaudgg thibaudgg merged commit 5adca8f into guard:master Jan 16, 2014
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

Successfully merging this pull request may close these issues.

3 participants