more cleanups; tests still do not pass