Skip to content

Instantly share code, notes, and snippets.

@frpaulas
Created October 20, 2018 15:09
Show Gist options
  • Save frpaulas/8d9c55f902704c65ccbae4ec0ab2c15b to your computer and use it in GitHub Desktop.
Save frpaulas/8d9c55f902704c65ccbae4ec0ab2c15b to your computer and use it in GitHub Desktop.
pry(4)> conn |> put_layout("app.html") |> render("mp.html", model: model, page_controller: "prayer")
** (FunctionClauseError) no function clause matching in Phoenix.HTML.raw/1
The following arguments were given to Phoenix.HTML.raw/1:
# 1
{:ok,
"<div><div id='Psalm_102' class='req'> <h3>Psalm 102. <span class=\"ps_title\">Domine, exaudi.</span> </h3> </br> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>1</sup></li> <li class=\"ps_first\">HEAR my prayer, O LORD, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">and let my crying come unto thee.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>2</sup></li> <li class=\"ps_first\">Hide not thy face from me in the time of my trouble; &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">incline thine ear unto me when I call; O hear me, and that right soon.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>3</sup></li> <li class=\"ps_first\">For my days are consumed away like smoke, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">and my bones are burnt up as it were a firebrand.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>4</sup></li> <li class=\"ps_first\">My heart is smitten down, and withered like grass; &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">so that I forget to eat my bread.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>5</sup></li> <li class=\"ps_first\">For the voice of my groaning, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">my bones will scarce cleave to my flesh.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>6</sup></li> <li class=\"ps_first\">I am become like a pelican in the wilderness, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">and like an owl that is in the desert.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>7</sup></li> <li class=\"ps_first\">I have watched, and am even as it were a sparrow, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">that sitteth alone upon the housetop.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>8</sup></li> <li class=\"ps_first\">Mine enemies revile me all the day long; &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">and they that are mad upon me are sworn together against me.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>9</sup></li> <li class=\"ps_first\">For I have eaten ashes as it were bread, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">and mingled my drink with weeping;</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>10</sup></li> <li class=\"ps_first\">And that, because of thine indignation and wrath; &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">for thou hast taken me up, and cast me down.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>11</sup></li> <li class=\"ps_first\">My days are gone like a shadow, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">and I am withered like grass.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>12</sup></li> <li class=\"ps_first\">But thou, O LORD, shalt endure for ever, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">and thy remembrance throughout all generations.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>13</sup></li> <li class=\"ps_first\">Thou shalt arise, and have mercy upon Sion; &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_second\">for it is time that thou have mercy upon her, yea, the time is come.</li> </ul> <ul class=\"psalm\"> <li class=\"ps_num\"><sup>14</sup></li> <li class=\"ps_first\">And why? thy servants think upon her stones, &#42; </li> </ul> <ul class=\"psalm\"> <li class=\"ps_secon" <> ...,
[]}
Attempted function clauses (showing 3 out of 3):
def raw({:safe, value})
def raw(nil)
def raw(value) when is_binary(value) or is_list(value)
(phoenix_html) lib/phoenix_html.ex:123: Phoenix.HTML.raw/1
(iphod) lib/iphod_web/templates/prayer/mp.html.eex:50: IphodWeb.PrayerView."mp.html"/1
(iphod) lib/iphod_web/templates/layout/app.html.eex:62: IphodWeb.LayoutView."app.html"/1
(phoenix) lib/phoenix/view.ex:399: Phoenix.View.render_to_iodata/3
(phoenix) lib/phoenix/controller.ex:729: Phoenix.Controller.__put_render__/5
(phoenix) lib/phoenix/controller.ex:746: Phoenix.Controller.instrument_render_and_send/4
(stdlib) erl_eval.erl:677: :erl_eval.do_apply/6
(iex) lib/iex/evaluator.ex:249: IEx.Evaluator.handle_eval/5
(iex) lib/iex/evaluator.ex:229: IEx.Evaluator.do_eval/3
(iex) lib/iex/evaluator.ex:207: IEx.Evaluator.eval/3
(iex) lib/iex/evaluator.ex:94: IEx.Evaluator.loop/1
(iex) lib/iex/evaluator.ex:24: IEx.Evaluator.init/4
(iex) lib/iex/pry.ex:64: IEx.Pry.pry/2
(iphod) lib/iphod_web/IphodWeb.controllers/IphodWeb.prayer_controller.ex:11: IphodWeb.PrayerController.mp/2
(iphod) lib/iphod_web/IphodWeb.controllers/IphodWeb.prayer_controller.ex:3: IphodWeb.PrayerController.action/2
(iphod) lib/iphod_web/IphodWeb.controllers/IphodWeb.prayer_controller.ex:3: IphodWeb.PrayerController.phoenix_controller_pipeline/2
(iphod) lib/iphod_web/IphodWeb.endpoint.ex:1: IphodWeb.Endpoint.instrument/4
(phoenix) lib/phoenix/router.ex:275: Phoenix.Router.__call__/1
(iphod) lib/iphod_web/IphodWeb.endpoint.ex:1: IphodWeb.Endpoint.plug_builder_call/2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment