TEMP: logging stuff for rewrite