UTC Log Format borked by …_universal_time_dst/1 #1

beerriot opened this Issue Nov 8, 2010 · 1 comment

2 participants


The riak_err application fails to start if the sasl application environment variable 'utc_log=true' is set.

To reproduce, start erl with:

$ erl -pa ../riak_err/ebin -sasl utc_log true

Then start sasl and riak_err, you should see output similar to:

1> application:start(sasl).
2> application:start(riak_err).
<0.48.0>: riak_err_monitor: handler riak_err_handler exited for reason {EXIT,{function_clause,[{riak_err_stdlib,write_time,[{utc,[{{2010,11,8},{17,35,1}}]},"PROGRESS REPORT"]},{riak_err_handler,format_event,2},{riak_err_handler,handle_event,2},{gen_event,server_update,4},{gen_event,server_notify,4},{gen_event,handle_msg,5},{proc_lib,init_p_do_apply,3}]}}

The trace is caused by https://github.com/basho/riak_err/blob/master/src/riak_err_handler.erl#L216

The call to riak_err_stdlib:maybe_utc/1 uses calendar:local_time_to_universal_time_dst/1, which returns a list of datetime tuples, instead of a single datetime tuple. This output causes a function clause error on the subsequent call to riak_err_stdlib:write_time/1.


I'd swear that I'd already commented on this issue and closed it ... but it looks like I'd commented in Basho's Bugzilla system but not here at github.

Fixed by 3c52872
See also https://issues.basho.com/show_bug.cgi?id=873

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