<commit_before>import json
import logging

from django.views.decorators.csrf import csrf_exempt
from django.http import HttpResponse

from utilities.utils import get_request_info

from find2run.models import User

logger = logging.getLogger(__name__)


@csrf_exempt
def signup(request):
    if request.method == 'POST':
        request_info = get_request_info(request)
        logger.debug("The data received is %s", json.dumps(request_info))
        User(**request_info).save()
        return HttpResponse("User added")


def welcome(request):
    return HttpResponse('Welcome to find2run')


@csrf_exempt
def update_location(request):
    if request.method == 'POST':
        request_info = get_request_info(request)
        try:
            a_user = User.objects.get(email=request_info['email'])
            a_user.lattitude = request_info['lattitude']
            a_user.longitude = request_info['longitude']
            a_user.save()
            return HttpResponse('Location updated')
        except Exception as e:
            logger.error(e, exc_info=True)
            return HttpResponse(e)
<commit_msg>making all gets<commit_after>import json
import logging

from django.views.decorators.csrf import csrf_exempt
from django.http import HttpResponse

from utilities.utils import get_request_info

from find2run.models import User

logger = logging.getLogger(__name__)


@csrf_exempt
def signup(request):
    request_info = get_request_info(request)
    logger.debug("The data received is %s", json.dumps(request_info))
    User(**request_info).save()
    return HttpResponse("User added")


def welcome(request):
    return HttpResponse('Welcome to find2run')


@csrf_exempt
def update_location(request):
    request_info = get_request_info(request)
    try:
        a_user = User.objects.get(email=request_info['email'])
        a_user.lattitude = request_info['lattitude']
        a_user.longitude = request_info['longitude']
        a_user.save()
        return HttpResponse('Location updated')
    except Exception as e:
        logger.error(e, exc_info=True)
        return HttpResponse(e)

{'fraction_non_alphanumeric': 0.094106463878327, 'fraction_numerical': 0.0019011406844106464, 'mean_word_length': 3.6674057649667406, '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': '2822335', 'n_tokens_mistral': 627, 'n_tokens_neox': 616, 'n_words': 142}