<commit_before>/* global __ROLLBAR_POST_TOKEN__, __VERSION__, __API_HOST__, __PROD__ */
import Rollbar from 'rollbar/dist/rollbar.umd';

let rollbar;

console.log('__ROLLBAR_POST_TOKEN__', __ROLLBAR_POST_TOKEN__);
console.log('__VERSION__', __VERSION__);
console.log('__PROD__', __PROD__);
console.log(__API_HOST__ || `${window.location.protocol}//${window.location.host}`);


if (__PROD__) {
  rollbar = new Rollbar({
      accessToken: __ROLLBAR_POST_TOKEN__,
      captureUncaught: true,
      payload: {
          environment: __API_HOST__ || `${window.location.protocol}//${window.location.host}`,
          client: {
            javascript: {
              /* eslint-disable camelcase */
              code_version: __VERSION__,
              guess_uncaught_frames: true
              /* eslint-enable camelcase */
            }
          },
          server: {
            root: 'webpack:///./'
          }
      },
      // to deal with URI's as local filesystem paths, we use the "many domain" transform:
      // https://rollbar.com/docs/source-maps/#using-source-maps-on-many-domains<commit_msg>[WEB-75] Clean up debugging logs in rollbar.js<commit_after>/* global __ROLLBAR_POST_TOKEN__, __VERSION__, __API_HOST__, __PROD__ */
import Rollbar from 'rollbar';

let rollbar;

if (__PROD__) {
  rollbar = new Rollbar({
      accessToken: __ROLLBAR_POST_TOKEN__,
      captureUncaught: true,
      captureUnhandledRejections: true,
      payload: {
          environment: __API_HOST__ || `${window.location.protocol}//${window.location.host}`,
          client: {
            javascript: {
              /* eslint-disable camelcase */
              code_version: __VERSION__,
              guess_uncaught_frames: true
              /* eslint-enable camelcase */
            }
          },
          server: {
            root: 'webpack:///./'
          }
      },
      // to deal with URI's as local filesystem paths, we use the "many domain" transform:
      // https://rollbar.com/docs/source-maps/#using-source-maps-on-many-domains
{'fraction_non_alphanumeric': 0.12340842311459353, 'fraction_numerical': 0.0009794319294809011, 'mean_word_length': 2.321951219512195, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3773889', 'n_tokens_mistral': 620, 'n_tokens_neox': 610, 'n_words': 121}