Reworked versioning code, top-level debug tracing complete