getPackageVersion(moduleName) {
    try {
      const trackedItems = shimmer.registeredInstrumentations.getAllByName(moduleName)
      if (trackedItems === undefined) {
        throw Error(`no tracked items for module '${moduleName}'`)
      }
      const item = trackedItems.find((item) => item.instrumentation.resolvedName !== undefined)
      if (item === undefined) {
        return process.version
      }
      const pkg = require(path.resolve(item.instrumentation.resolvedName, 'package.json'))
      return pkg.version
    } catch (err) {
      logger.debug('Failed to get version for `%s`, reason: %s', moduleName, err.message)
      return process.version
    }
  }
Gets the version of a given package by parsing it from package.json

@param {string} moduleName name of module
@returns {string} version, defaults to Node.js version when it cannot parse