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

Some minor warnings when using kimurai #51

Open
rubyFeedback opened this issue Nov 14, 2020 · 0 comments
Open

Some minor warnings when using kimurai #51

rubyFeedback opened this issue Nov 14, 2020 · 0 comments

Comments

@rubyFeedback
Copy link

Hey there,

Sorry to bother you.

A few harmless warnings are issued when run under -w

Reason I report this is because I am quite pedantic, so I have -w on all the time.

This then pulls these warnings into my projects.

I know I can silence them, e. g. via $VERBOSE and probably the Warning module,
but I am trying the lazy approach and report them here. Feel free to disregard
this please. :-)

/.gem/gems/kimurai-1.4.0/lib/kimurai/browser_builder.rb:12: warning: assigned but unused variable - e
/.gem/gems/kimurai-1.4.0/lib/kimurai/base_helper.rb:11: warning: assigned but unused variable - uri
/.gem/gems/kimurai-1.4.0/lib/kimurai/base_helper.rb:12: warning: assigned but unused variable - e
/.gem/gems/kimurai-1.4.0/lib/kimurai/base.rb:33: warning: instance variable @run_info not initialized

(For local but unused variables, they can either be removed, or if you want to keep them, a leading
_ such as _uri would work. For uninitialized instance variables, I typically bundle them all in a method
called reset() where they are initialized to nil. That silences that warning.

I use kimurai to query javascript-heavy websites that do not easily allow us to parse the result. For
that purpose it works very well. For example I use kimurai to query the remote world-time, from a
website that uses javascript. (God I hate javascript sooo much though ...)

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

1 participant