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

Compatibility issue with Chrome 71 (2018-12-04) #2

Open
tmorton opened this issue Jan 20, 2019 · 0 comments
Open

Compatibility issue with Chrome 71 (2018-12-04) #2

tmorton opened this issue Jan 20, 2019 · 0 comments

Comments

@tmorton
Copy link

tmorton commented Jan 20, 2019

It seems like the Chrome DevTools protocol has changed, so this library will no longer work with Chrome 71. I haven't found a work-around. I'm just documenting this to save others the trouble.

I believe the problem is that Chrome has stopped accepting the Target.createBrowserContext message. There isn't any documentation about a change, but several similar projects have this problem: wirepair/gcd#24 and chromedp/chromedp#244

Here's the symptoms:

iex(1)> HPDF.print_pdf!("https://google.com")
** (exit) exited in: GenServer.call(#PID<0.392.0>, {:print_pdf, "https://google.com", []}, :infinity)
    ** (EXIT) exited in: GenServer.call(HPDF.Browser, :new_session, 5000)
        ** (EXIT) time out
    (elixir) lib/gen_server.ex:831: GenServer.call/3
    (hpdf) lib/hpdf/controller.ex:22: HPDF.Controller.print_pdf!/2
iex(1)> [error] GenServer #PID<0.392.0> terminating
** (stop) exited in: GenServer.call(HPDF.Browser, :new_session, 5000)
    ** (EXIT) time out
    (elixir) lib/gen_server.ex:831: GenServer.call/3
    (hpdf) lib/hpdf/controller.ex:28: HPDF.Controller.handle_call/3
    (stdlib) gen_server.erl:636: :gen_server.try_handle_call/4
    (stdlib) gen_server.erl:665: :gen_server.handle_msg/6
    (stdlib) proc_lib.erl:247: :proc_lib.init_p_do_apply/3
Last message (from #PID<0.390.0>): {:print_pdf, "https://google.com", []}
State: %{}
Client #PID<0.390.0> is alive
    (stdlib) gen.erl:169: :gen.do_call/4
    (elixir) lib/gen_server.ex:828: GenServer.call/3
    (hpdf) lib/hpdf/controller.ex:22: HPDF.Controller.print_pdf!/2
    (stdlib) erl_eval.erl:670: :erl_eval.do_apply/6
    (elixir) src/elixir.erl:233: :elixir.eval_forms/4
    (iex) lib/iex/evaluator.ex:245: IEx.Evaluator.handle_eval/5
    (iex) lib/iex/evaluator.ex:225: IEx.Evaluator.do_eval/3
    (iex) lib/iex/evaluator.ex:203: IEx.Evaluator.eval/3
    (iex) lib/iex/evaluator.ex:89: IEx.Evaluator.loop/1
    (iex) lib/iex/evaluator.ex:24: IEx.Evaluator.init/4
    (stdlib) proc_lib.erl:247: :proc_lib.init_p_do_apply/3
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