<commit_before>from django.shortcuts import render

# Create your views here.<commit_msg>Best scrapper<commit_after>from django.shortcuts import render

# Create your views here.


"""
    Scraping with JS support:

>>> import dryscrape
>>> from bs4 import BeautifulSoup
>>> session = dryscrape.Session()
>>> session.visit(<MY_GRAB_URL>)
>>> response = session.body()
>>> soup = BeautifulSoup(response)
>>> soup.find(id="intro-text")
<p id="intro-text">Yay! Supports javascript</p>

    Find by all attribute name element:

    myfilter = soup.find_all("<DOM_ELEMENT_NAME>", { "<ATTRIBUTE_NAME>" : "<ATTRIBUTE_VALUE>" })



"""
{'fraction_non_alphanumeric': 0.14992025518341306, 'fraction_numerical': 0.001594896331738437, 'mean_word_length': 5.28, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 30, 'https://': 0, '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': '2437257', 'n_tokens_mistral': 207, 'n_tokens_neox': 193, 'n_words': 48}