changes around testing/hacking several bugs in core