Fix NoneType error for kwargs to macro and upgrade-macros.