fix attribute processing bug, but introduce questionable namespace processing