<commit_before>import requests
import json
from requests.auth import HTTPBasicAuth


class GithubRequester(object):
    """
    Object used for issuing authenticated API calls to GitHub.
    """
    def __init__(self, username, password):
        self.username = username
        self.password = password

    def get_auth(self):
        return HTTPBasicAuth(self.username, self.password)

    def get(self, url):
        return requests.get(url, auth=self.get_auth())

    def post(self, url, payload):
        return requests.post(
            url, data=json.dumps(payload),
            auth=self.get_auth())<commit_msg>Add debug logging to http utils<commit_after>import requests
import json
from requests.auth import HTTPBasicAuth
import logging

log = logging.getLogger(__name__)


class GithubRequester(object):
    """
    Object used for issuing authenticated API calls to GitHub.
    """
    def __init__(self, username, password):
        self.username = username
        self.password = password

    def get_auth(self):
        return HTTPBasicAuth(self.username, self.password)

    def get(self, url):
        log.debug("Fetching %s", url)
        return requests.get(url, auth=self.get_auth())

    def post(self, url, payload):
        log.debug("Posting %s to %s", payload, url)
        return requests.post(
            url, data=json.dumps(payload),
            auth=self.get_auth())
{'fraction_non_alphanumeric': 0.10128388017118402, 'fraction_numerical': 0.0, 'mean_word_length': 2.941011235955056, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5582371', 'n_tokens_mistral': 401, 'n_tokens_neox': 390, 'n_words': 111}