<commit_before>#!/usr/bin/env python
# vim: tabstop=2 expandtab shiftwidth=2 softtabstop=2

import requests, re, time, options
from prometheus_client import start_http_server, Gauge
from geopy.geocoders import Nominatim
try:
  from functools import lru_cache
except ImportError:
  from backports.functools_lru_cache import lru_cache

@lru_cache()
def get_location(city):
  location = Nominatim(timeout=options['geocode_timeout']).geocode(city)
  return location

class WeatherExporter:
  def __init__(self,options):
    self.guages={}
    self.weather={}
<commit_msg>Convert geocode_timeout to int<commit_after>#!/usr/bin/env python
# vim: tabstop=2 expandtab shiftwidth=2 softtabstop=2

import requests, re, time, options
from prometheus_client import start_http_server, Gauge
from geopy.geocoders import Nominatim
try:
  from functools import lru_cache
except ImportError:
  from backports.functools_lru_cache import lru_cache

@lru_cache()
def get_location(city):
  location = Nominatim(timeout=int(options['geocode_timeout'])).geocode(city)
  return location

class WeatherExporter:
  def __init__(self,options):
    self.guages={}
    self.weather={}

{'fraction_non_alphanumeric': 0.08996539792387544, 'fraction_numerical': 0.005190311418685121, 'mean_word_length': 6.416666666666667, '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': '2342076', 'n_tokens_mistral': 402, 'n_tokens_neox': 393, 'n_words': 93}