update logging and option handling -- exciting! also updated assert to use echo_log
institute some assertions -- not tested yet, rollback if necessary