twalpole / apparition

Capybara driver for Chrome using CDP
MIT License
363 stars 46 forks source link

Started seeing error: Capybara::Apparition::CDPError: Invalid parameters #16

Closed hemaldev closed 5 years ago

hemaldev commented 5 years ago

Hi there, firstly thanks for an incredible gem, we're a non-profit based in South India and your work with this gem is really helping us with our work.

We've run into an issue and we were wondering if you would be able to guide us. We're running a job on Heroku to do some work on a partner website which doesn't have an API. Recently when running this job we've started seeing the error Capybara::Apparition::CDPError: Invalid parameters. Below is the full stack trace...

Having played around with our codebase, we're not sure how to progress to debug further and was hoping you could provide some guidance. We're not sure if it's a Chrome issue, an issue with the response from the partner website, Capybara, or Apparition – despite the error message.

Any pointers would be much appreciated. Please let us know if we can provide any further information 🙏

2019-05-27T11:11:44.122549+00:00 app[worker.1]: 4 TID-gnledsk88 WARN: Capybara::Apparition::CDPError: Invalid parameters
2019-05-27T11:11:44.122643+00:00 app[worker.1]: 4 TID-gnledsk88 WARN: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/driver/response.rb:40:in `handle_error'
2019-05-27T11:11:44.122646+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/driver/response.rb:15:in `block in result'
2019-05-27T11:11:44.122648+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/driver/response.rb:13:in `map'
2019-05-27T11:11:44.122650+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/driver/response.rb:13:in `result'
2019-05-27T11:11:44.122651+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/page.rb:352:in `command'
2019-05-27T11:11:44.122653+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/page.rb:409:in `frame_offset'
2019-05-27T11:11:44.122654+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/page.rb:293:in `element_from_point'
2019-05-27T11:11:44.122656+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/node.rb:511:in `mouse_event_test'
2019-05-27T11:11:44.122658+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/node.rb:188:in `click'
2019-05-27T11:11:44.122659+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/node.rb:260:in `send_keys'
2019-05-27T11:11:44.122668+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/node.rb:455:in `set_text'
2019-05-27T11:11:44.122670+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/apparition-0.2.0/lib/capybara/apparition/node.rb:133:in `set'
2019-05-27T11:11:44.122671+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/capybara-3.21.0/lib/capybara/node/element.rb:119:in `block in set'
2019-05-27T11:11:44.122672+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/capybara-3.21.0/lib/capybara/node/base.rb:83:in `synchronize'
2019-05-27T11:11:44.122674+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/capybara-3.21.0/lib/capybara/node/element.rb:119:in `set'
2019-05-27T11:11:44.122676+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/capybara-3.21.0/lib/capybara/node/actions.rb:91:in `fill_in'
2019-05-27T11:11:44.122678+00:00 app[worker.1]: /app/vendor/bundle/ruby/2.6.0/gems/capybara-3.21.0/lib/capybara/session.rb:748:in `block (2 levels) in <class:Session>'

This happens when we do

@browser.find_field("join_neu_email_field").set(USER_NAME)
@browser.find_field("join_neu_password_field").set(PASSWORD)
hemaldev commented 5 years ago

Closing this as we swapped to Cuprite

twalpole commented 5 years ago

@hemaldev Ok -- If you do try it again with apparition please set an environment variable DEBUG=v and then provide the log around the error.