fixed span issue, general clean up
fixed span issue, general clean up
began adding debug mode