<commit_before>language: python

sudo: false
dist: trusty

env:
  global:
    - BOTO_CONFIG="/tmp/nowhere"
    - MINICONDA_VERSION="latest"
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>

matrix:
  include:
    # unit tests (python 2.7, 3.4, and 3.5)
    - python: 2.7
      env: GROUP=unit
    - python: 3.4
      env: GROUP=unit
    - python: 3.5
      env: GROUP=unit
    - python: 3.6
      env: GROUP=unit

    # examples tests (python 2.7 and 3.4)
    - python: 2.7
      env: GROUP=examples
    - python: 3.4
      env: GROUP=examples EXTRA_CMD=--no-js

    # linting, package and docs building (python 3.4)
    - python: 3.4
      env: GROUP=flake_docs

    # integration tests (python 3.4)
    - python: 3.4
      env: GROUP=integration
      addons:
        sauce_connect: true

branches:
  only:
  - master
  - "/^\\d+.\\d+.\\d+dev\\d+$/"
  - "/^\\d+.\\d+.\\d+rc\\d+$/"
  - "/^\\d+.\\d+.\\d+$/"

before_install:
  - export PATH="$HOME/miniconda/bin:$PATH"
  - export PATH="$HOME/build/bokeh/bokeh/bokehjs/node_modules/phantomjs-prebuilt/bin:$PATH"
  - export TRAVIS_COMMIT_MSG="$(git log --format=%B --no-merges -n 1)"
  - if [[ -z "${SAUCE_USERNAME}" ]] || [[ -z "${SAUCE_ACCESS_KEY}" ]]; then echo "External committer, not using saucelabs"; else export SAUCELABS=true; fi

install:
- scripts/travis_install

script:
  # preamble
  - python -m bokeh info

  # unit tests
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == unit ]]; then
      py.test -s -m js;
    fi
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == unit ]]; then
      py.test --rerun=5 -m 'unit or selenium' --cov=bokeh --cov-config=bokeh/.coveragerc;
    fi

  # examples tests
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == examples ]]; then
      if [[ $TRAVIS_COMMIT_MSG == *"[ci disable examples]"* ]]; then
        echo "Examples run disabled by commit";
      else
        export IPYTHON_ALLOW_DRAFT_WEBSOCKETS_FOR_PHANTOMJS=1;
        time py.test -s -v --tb line -m examples --diff-ref FETCH_HEAD --upload --report-path=examples.html $EXTRA_CMD;
      fi;
    fi

  # linting, package and docs building
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == flake_docs ]]; then
      py.test -m quality;
    fi
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == flake_docs ]]; then
      CONDA_PY="${TRAVIS_PYTHON_VERSION/./}" conda build --quiet --no-test conda.recipe;
      NOARCH_DIR="$HOME/miniconda/conda-bld/noarch";
      echo "noarch build output contents:";
      ls -l $NOARCH_DIR;
      BUILD_FILE_COUNT="$(ls $NOARCH_DIR | wc -l)";
      if [ $BUILD_FILE_COUNT != 3 ]; then
         echo "noarch build has wrong number of files";
         exit 1;
      fi
    fi
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == flake_docs ]]; then
      cd sphinx;
      GOOGLE_API_KEY=${GOOGLE_API_KEY:-"junk"} make SPHINXOPTS=-v all;
    fi

  # integration tests
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == integration ]]; then
      if [ "$SAUCELABS" == "true" ]; then
        py.test -m integration --driver SauceLabs --html=tests/pytest-report.html -n4 -r3 --upload;
      fi;
    fi

  # Simple build log
  - echo "********** SIMPLE BUILD LOG **********";
    echo $TRAVIS_COMMIT_MSG;
    echo $TRAVIS_PULL_REQUEST;
    if [[ "$GROUP" == integration ]]; then
      echo "https://s3.amazonaws.com/bokeh-travis/$TRAVIS_JOB_ID/tests/pytest-report.html";
    fi;
    if [[ "$GROUP" == examples ]]; then
      echo "https://s3.amazonaws.com/bokeh-travis/$TRAVIS_JOB_ID/examples.html";
    fi;
    killall python;
    ps -efw;
    echo "********** END SIMPLE BUILD LOG **********";

after_success: |
  if [[ ! -z "$TRAVIS_TAG" && "$TRAVIS_PYTHON_VERSION" == '3.4' && "$GROUP" == flake_docs ]]; then
      # Install some additional dependencies
      conda install anaconda-client --yes
      conda install -c defaults -c conda-forge fabric3 --yes
      # Decrypt some files and place them in the correct location
      openssl aes-256-cbc -K $encrypted_c19429b59af5_key -iv $encrypted_c19429b59af5_iv -in secrets.tar.enc -out secrets.tar -d
      tar xvf secrets.tar
      cp known_hosts ~/.ssh/known_hosts
      cp .npmrc ~/.npmrc
      cp .pypirc ~/.pypirc
      chmod 600 bokeh_key
      eval `ssh-agent -s`
      ssh-add bokeh_key
      # Signal the correct build
      if [[ "$TRAVIS_TAG" == *"dev"* ]] || [[ "$TRAVIS_TAG" == *"rc"* ]]; then
        echo "Building a DEV or RC package: $TRAVIS_TAG"
      else
        echo "Building a FULL RELEASE package: $TRAVIS_TAG"
      fi
      python scripts/build_upload.py $TRAVIS_TAG
      exit $?
  else
      echo "No tag present, not building a release package."
  fi

notifications:
  flowdock:
    secure: <KEY>
<commit_msg>only run js tests on py3 builds for now (#6529)<commit_after>language: python

sudo: false
dist: trusty

env:
  global:
    - BOTO_CONFIG="/tmp/nowhere"
    - MINICONDA_VERSION="latest"
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>
    - secure: <KEY>

matrix:
  include:
    # unit tests (python 2.7, 3.4, and 3.5)
    - python: 2.7
      env: GROUP=unit
    - python: 3.4
      env: GROUP=unit
    - python: 3.5
      env: GROUP=unit
    - python: 3.6
      env: GROUP=unit

    # examples tests (python 2.7 and 3.4)
    - python: 2.7
      env: GROUP=examples
    - python: 3.4
      env: GROUP=examples EXTRA_CMD=--no-js

    # linting, package and docs building (python 3.4)
    - python: 3.4
      env: GROUP=flake_docs

    # integration tests (python 3.4)
    - python: 3.4
      env: GROUP=integration
      addons:
        sauce_connect: true

branches:
  only:
  - master
  - "/^\\d+.\\d+.\\d+dev\\d+$/"
  - "/^\\d+.\\d+.\\d+rc\\d+$/"
  - "/^\\d+.\\d+.\\d+$/"

before_install:
  - export PATH="$HOME/miniconda/bin:$PATH"
  - export PATH="$HOME/build/bokeh/bokeh/bokehjs/node_modules/phantomjs-prebuilt/bin:$PATH"
  - export TRAVIS_COMMIT_MSG="$(git log --format=%B --no-merges -n 1)"
  - if [[ -z "${SAUCE_USERNAME}" ]] || [[ -z "${SAUCE_ACCESS_KEY}" ]]; then echo "External committer, not using saucelabs"; else export SAUCELABS=true; fi

install:
- scripts/travis_install

script:
  # preamble
  - python -m bokeh info

  # unit tests
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == unit ]]; then
      py.test --rerun=5 -m 'unit or selenium' --cov=bokeh --cov-config=bokeh/.coveragerc;
    fi

  # examples tests
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == examples ]]; then
      if [[ $TRAVIS_COMMIT_MSG == *"[ci disable examples]"* ]]; then
        echo "Examples run disabled by commit";
      else
        export IPYTHON_ALLOW_DRAFT_WEBSOCKETS_FOR_PHANTOMJS=1;
        time py.test -s -v --tb line -m examples --diff-ref FETCH_HEAD --upload --report-path=examples.html $EXTRA_CMD;
      fi;
    fi

  # linting, package and docs building

  # TEMP MOVE OF JS TESTS TO NON-PYTHON 2 BUILD
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == flake_docs ]]; then
      py.test -s -m js;
    fi

  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == flake_docs ]]; then
      py.test -m quality;
    fi
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == flake_docs ]]; then
      CONDA_PY="${TRAVIS_PYTHON_VERSION/./}" conda build --quiet --no-test conda.recipe;
      NOARCH_DIR="$HOME/miniconda/conda-bld/noarch";
      echo "noarch build output contents:";
      ls -l $NOARCH_DIR;
      BUILD_FILE_COUNT="$(ls $NOARCH_DIR | wc -l)";
      if [ $BUILD_FILE_COUNT != 3 ]; then
         echo "noarch build has wrong number of files";
         exit 1;
      fi
    fi
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == flake_docs ]]; then
      cd sphinx;
      GOOGLE_API_KEY=${GOOGLE_API_KEY:-"junk"} make SPHINXOPTS=-v all;
    fi

  # integration tests
  - if [[ -z "$TRAVIS_TAG" && "$GROUP" == integration ]]; then
      if [ "$SAUCELABS" == "true" ]; then
        py.test -m integration --driver SauceLabs --html=tests/pytest-report.html -n4 -r3 --upload;
      fi;
    fi

  # Simple build log
  - echo "********** SIMPLE BUILD LOG **********";
    echo $TRAVIS_COMMIT_MSG;
    echo $TRAVIS_PULL_REQUEST;
    if [[ "$GROUP" == integration ]]; then
      echo "https://s3.amazonaws.com/bokeh-travis/$TRAVIS_JOB_ID/tests/pytest-report.html";
    fi;
    if [[ "$GROUP" == examples ]]; then
      echo "https://s3.amazonaws.com/bokeh-travis/$TRAVIS_JOB_ID/examples.html";
    fi;
    killall python;
    ps -efw;
    echo "********** END SIMPLE BUILD LOG **********";

after_success: |
  if [[ ! -z "$TRAVIS_TAG" && "$TRAVIS_PYTHON_VERSION" == '3.4' && "$GROUP" == flake_docs ]]; then
      # Install some additional dependencies
      conda install anaconda-client --yes
      conda install -c defaults -c conda-forge fabric3 --yes
      # Decrypt some files and place them in the correct location
      openssl aes-256-cbc -K $encrypted_c19429b59af5_key -iv $encrypted_c19429b59af5_iv -in secrets.tar.enc -out secrets.tar -d
      tar xvf secrets.tar
      cp known_hosts ~/.ssh/known_hosts
      cp .npmrc ~/.npmrc
      cp .pypirc ~/.pypirc
      chmod 600 bokeh_key
      eval `ssh-agent -s`
      ssh-add bokeh_key
      # Signal the correct build
      if [[ "$TRAVIS_TAG" == *"dev"* ]] || [[ "$TRAVIS_TAG" == *"rc"* ]]; then
        echo "Building a DEV or RC package: $TRAVIS_TAG"
      else
        echo "Building a FULL RELEASE package: $TRAVIS_TAG"
      fi
      python scripts/build_upload.py $TRAVIS_TAG
      exit $?
  else
      echo "No tag present, not building a release package."
  fi

notifications:
  flowdock:
    secure: <KEY>

{'fraction_non_alphanumeric': 0.16032551257662228, 'fraction_numerical': 0.014161910801099133, 'mean_word_length': 2.44735883424408, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 4, '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': '4277587', 'n_tokens_mistral': 3704, 'n_tokens_neox': 3491, 'n_words': 878}