Changes to add debugging features and utilities