<commit_before>from selenium import webdriver
from applitools import logger
from applitools.logger import StdoutLogger
from applitools.eyes import Eyes
from applitools.common import StitchMode

import os
#os.environ['HTTPS_PROXY'] = "http://localhost:8888"

driver = webdriver.Chrome()

eyes = Eyes()
eyes.api_key = os.environ['APPLITOOLS_API_KEY']

logger.set_logger(StdoutLogger())

# Force Eyes to grab a full page screenshot.
eyes.force_full_page_screenshot = True
eyes.stitch_mode = StitchMode.CSS

try:
    driver = eyes.open(driver, "Python app", "applitools", {'width': 800, 'height': 600})
    driver.get('http://www.applitools.com')
    eyes.check_window("Home")

    automated_paragraph = driver.find_element_by_class_name("automated")
    eyes.check_region_by_element(automated_paragraph, "Automated Testing Paragraph")

    eyes.close()
finally:
    driver.quit()
    eyes.abort_if_not_closed()
<commit_msg>Updated example.<commit_after>from selenium import webdriver
from applitools import logger
from applitools.logger import StdoutLogger
from applitools.eyes import Eyes
from applitools.common import StitchMode

import os
#os.environ['HTTPS_PROXY'] = "http://localhost:8888"

driver = webdriver.Chrome()

eyes = Eyes()
eyes.api_key = os.environ['APPLITOOLS_API_KEY']

logger.set_logger(StdoutLogger())

# Force Eyes to grab a full page screenshot.
eyes.force_full_page_screenshot = True
eyes.stitch_mode = StitchMode.CSS

try:
    driver = eyes.open(driver, "Python app", "applitools", {'width': 800, 'height': 600})
    driver.get('http://www.applitools.com')
    eyes.check_window("Home")

    hero = driver.find_element_by_class_name("hero-container")
    eyes.check_region_by_element(hero, "Page Hero")

    eyes.close()
finally:
    driver.quit()
    eyes.abort_if_not_closed()

{'fraction_non_alphanumeric': 0.11555555555555555, 'fraction_numerical': 0.011111111111111112, 'mean_word_length': 5.363957597173145, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '2094434', 'n_tokens_mistral': 640, 'n_tokens_neox': 619, 'n_words': 130}