integrating tracekit @sbezboro
refactored to use tracekit @sbezboro