<commit_before>import oauth_secrets #NOTE this file is not included in the repository because it contains the OAuth consumer secrets
from os import environ
from gheatae import color_scheme
import logging

min_zoom = 10
max_zoom = 18 # note that these must also be in the static wdyg-private.js file

level_const = 140. #TODO fix this from being hard coded in models.py for UserInfo - I was getting a <type 'exceptions.AttributeError'>: 'module' object has no attribute 'level_const'

default_photo = 'static/foursquare_girl.png'
# def get_default_photo(gender='male'):
#   if gender is 'male':
#     return 'static/foursquare_boy.png'
#   else:
#     return 'static/foursquare_girl.png'   
default_color = color_scheme.color_schemes.keys()[0]
default_lat = -23.526218 #SaoPaulo
default_lng = -46.632843
default_zoom = 13
default_dimension = 640

def get_google_maps_apikey():
  domain = environ['HTTP_HOST']
  if domain == 'www.wheredoyougo.net':
    return '<KEY>'
  elif domain == 'where-do-you-go.appspot.com':
    return '<KEY>'
  elif domain == 'www.heredoyougo.com':
    return '<KEY>'
  elif domain == 'localhost:8080':
    return '<KEY>'
  else:
    logging.error('No Google maps key found for domain ' + domain)

def get_oauth_strings(force_primary_domain=False):
  if force_primary_domain: # I was getting SIGNATURE_INVALID oauth errors on many of my backend calls because 
                           # I was not using the same domain for the requests as I was when the users signed up
                           # Always forcing this will break support for other domains, but will fix some OAuth
                           # issues, so that's what I'm doing for now.
      domain = 'www.wheredoyougo.net'
  else:
      domain = environ['HTTP_HOST']
  logging.info('-------------------------------')
  logging.info(domain)
  if domain == 'www.wheredoyougo.net':
    consumer_key = '<KEY>'
    callback_url = 'http://www.wheredoyougo.net/authenticated'
  elif domain == 'where-do-you-go.appspot.com':
    consumer_key = '<KEY>'
    callback_url = 'http://where-do-you-go.appspot.com/authenticated'
  elif domain == 'www.heredoyougo.com':
    consumer_key = '<KEY>'
    callback_url = 'http://www.heredoyougo.com/authenticated'
  elif domain == 'localhost:8080':
    consumer_key = '<KEY>'
    callback_url = 'http://localhost:8080/authenticated'
  elif domain == 'checkalor.appspot.com':
    consumer_key = '<KEY>'
    callback_url = 'http://localhost:8080/authenticated'
  else:
    consumer_key = ''
    callback_url = ''
    logging.error('No Foursquare OAuth consumer key found for domain ' + domain)
  return consumer_key, oauth_secrets.get_oauth_consumer_secret_for_domain(domain), callback_url

provider = None<commit_msg>fixes fro prod<commit_after>import oauth_secrets #NOTE this file is not included in the repository because it contains the OAuth consumer secrets
from os import environ
from gheatae import color_scheme
import logging

min_zoom = 10
max_zoom = 18 # note that these must also be in the static wdyg-private.js file

level_const = 140. #TODO fix this from being hard coded in models.py for UserInfo - I was getting a <type 'exceptions.AttributeError'>: 'module' object has no attribute 'level_const'

default_photo = 'static/foursquare_girl.png'
# def get_default_photo(gender='male'):
#   if gender is 'male':
#     return 'static/foursquare_boy.png'
#   else:
#     return 'static/foursquare_girl.png'   
default_color = color_scheme.color_schemes.keys()[0]
default_lat = -23.526218 #SaoPaulo
default_lng = -46.632843
default_zoom = 13
default_dimension = 640

def get_google_maps_apikey():
  domain = environ['HTTP_HOST']
  if domain == 'www.wheredoyougo.net':
    return 'ABQIAAAAwA6oEsCLgzz6I150wm3ELBSujOi3smKLcjzph36ZE8UXngM_5BTs-xHblsuwK8V9g8bZ_PTfOWR1Fg'
  elif domain == 'where-do-you-go.appspot.com':
    return '<KEY>'
  elif domain == 'www.heredoyougo.com':
    return '<KEY>'
  elif domain == 'localhost:8080':
    return '<KEY>'
  elif 'checkalor.appspot.com':
    return '<KEY>'
  else:
    logging.error('No Google maps key found for domain ' + domain)

def get_oauth_strings(force_primary_domain=False):
  if force_primary_domain: # I was getting SIGNATURE_INVALID oauth errors on many of my backend calls because 
                           # I was not using the same domain for the requests as I was when the users signed up
                           # Always forcing this will break support for other domains, but will fix some OAuth
                           # issues, so that's what I'm doing for now.
      domain = 'www.wheredoyougo.net'
  else:
      domain = environ['HTTP_HOST']
  logging.info('-------------------------------')
  logging.info(domain)
  if domain == 'www.wheredoyougo.net':
    consumer_key = 'KTNXGQJ4JXDZGAG35MGZ3WN0EQIO5XHNALYQZATHVEPDR3TI'
    callback_url = 'http://www.wheredoyougo.net/authenticated'
  elif domain == 'where-do-you-go.appspot.com':
    consumer_key = 'S1PL51GWSZORANT244XXZC2UXIZGUUPGGNWNA3YHDGWM4M4U'
    callback_url = 'http://where-do-you-go.appspot.com/authenticated'
  elif domain == 'www.heredoyougo.com':
    consumer_key = '<KEY>'
    callback_url = 'http://www.heredoyougo.com/authenticated'
  elif domain == 'localhost:8080':
    consumer_key = '<KEY>'
    callback_url = 'http://localhost:8080/authenticated'
  elif domain == 'checkalor.appspot.com':
    consumer_key = '<KEY>'
    callback_url = 'http://checkalor.appspot.com/authenticated'
  else:
    consumer_key = ''
    callback_url = ''
    logging.error('No Foursquare OAuth consumer key found for domain ' + domain)
  return consumer_key, oauth_secrets.get_oauth_consumer_secret_for_domain(domain), callback_url

provider = None
{'fraction_non_alphanumeric': 0.11311820413889863, 'fraction_numerical': 0.020694493160294633, 'mean_word_length': 3.577046548956661, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 14, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7503645', 'n_tokens_mistral': 1941, 'n_tokens_neox': 1819, 'n_words': 489}