How to deal with timeout issue when debugging Phoenix app

There is a common scenario: You'd like to debug your Phoenix app with break!/4 or IEx.pry/0. Everything works fine, until... Phoenix server throws a timeout error statement.

Table of contents
    ** (EXIT from #PID<0.5227.0>) shell process exited with reason: shutdown

    It happens after about 60 seconds. Why?

    The process has a certain amount of time to send a response. If it takes more - then the server says: "It takes too long. The process is probably suspended and in the meanwhile, the Client/user is raging on the other side. Let's kill him... (the process, not the user)".

    Usually, it's a very nice, and helpful logic. But in the case of debugging it might be a real pain in the neck.

    As soon, as we know the reason, we're able to find the solution. And here we are. Just set the idle_timeout option at your endpoint config. Generally at config/dev.exs, or so.

    config :appname, Appname.Endpoint,
      http: [
        protocol_options: [idle_timeout: 5_000_000_000],
    Download our ebook
    Oskar Legner
    Oskar Legner Elixir & React Developer

    Read more
    on #curiosum blog

    The little story of Elixir programming language

    The Elixir language, operating on an Erlang machine, is constantly gaining more and more followers. Where can these languages be used? How was Elixir created and what does it have in common with Erlang?

    Top Elixir Learning Media & Resources in 2022

    Regardless of whether you've only just heard of the Elixir programming language and would like to learn it, or if you're a seasoned developer with years of experience, you need adequate learning resources to ensure steady progress in your career - and just equally as important is the need to be up to date with what's new & trending in the functional