Skip to content

Instantly share code, notes, and snippets.

@jschoch
Last active August 29, 2015 13:56
Show Gist options
  • Save jschoch/9313808 to your computer and use it in GitHub Desktop.
Save jschoch/9313808 to your computer and use it in GitHub Desktop.
1) test can send proxy email message: stubbed (InfuTest)
** (EXIT) {:badarg, [{:unicode, :characters_to_binary, [[AAA957E6927471FF9EADE64D79FE07D52: {2, 1}]], []}, {String,
:from_char_list!, 1, [file: 'lib/string.ex', line: 1188]}, {Infu.Router, :send_email, 2, [file: 'lib/infu.ex', line: 15
3]}, {Infu.Router, :handle_call, 3, [file: 'lib/infu.ex', line: 77]}, {:gen_server, :handle_msg, 5, [file: 'gen_server.e
rl', line: 588]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 239]}]}
def new_session_key do
rand = :random.uniform(round(:math.pow(2, 48))) |> integer_to_binary
b = :crypto.hash(:md5,rand)
l = lc << x >> inbits b, do: integer_to_binary(x,16)
l = ["AAA"|l]
Enum.join(l) |> binary_to_atom
end
@jschoch
Copy link
Author

jschoch commented Mar 2, 2014

:2014-03-02 16:08:38.968 [error] <0.152.0> CRASH REPORT Process router with 1 neighbours exited with reason: bad argument in call to unicode:characters_to_binary([{124857969864740,{2,1}}]) in 'Elixir.String':'from_char_list!'/1 line 1188 in gen_server:terminate/6 line 747

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment