<commit_before>import math
import logging
from datetime import datetime
from tg import expose, validate, require, request, redirect, flash
from tg.i18n import ugettext as _, lazy_ugettext as l_
from tg.decorators import with_trailing_slash, without_trailing_slash
from repoze.what.predicates import has_permission
from webob.exc import HTTPBadRequest, HTTPNotFound, HTTPForbidden
from formencode.validators import String
from tw.forms.fields import TextField
from sprox.formbase import EditableForm
from sprox.widgets import PropertySingleSelectField
from geoalchemy2.shape import to_shape
from geoalchemy2.elements import WKTElement
from sqlalchemy.sql.expression import func
from skylines.controllers.base import BaseController
from skylines.lib import files
from sqlalchemy.sql.expression import and_, literal_column
from skylines.model import (DBSession, User, Flight, FlightPhase, Location,
                            IGCFile, Elevation)
from skylines.model.flight_comment import FlightComment
from skylines.model.notification import create_flight_comment_notifications
from skylines.lib.xcsoar import analyse_flight, flight_path
from skylines.lib.helpers import format_time, format_number
from skylines.lib.formatter import units
from skylines.lib.datetime import from_seconds_of_day
from skylines.lib.geo import METERS_PER_DEGREE
from skylines.forms import BootstrapForm, aircraft_model
from skylines.lib.sql import extract_array_item
from skylinespolyencode import SkyLinesPolyEncoder

log = logging.getLogger(__name__)


class PilotSelectField(PropertySingleSelectField):
    def _my_update_params(self, d, nullable=False):
        query = DBSession.query(User.id, User.display_name) \
            .filter(User.club_id == request.identity['user'].club_id) \<commit_msg>controllers/flight: Import cleanup<commit_after>import math
import logging
from datetime import datetime
from tg import expose, validate, require, request, redirect, flash
from tg.i18n import ugettext as _, lazy_ugettext as l_
from tg.decorators import with_trailing_slash, without_trailing_slash
from repoze.what.predicates import has_permission
from webob.exc import HTTPBadRequest, HTTPNotFound, HTTPForbidden
from formencode.validators import String
from tw.forms.fields import TextField
from sprox.formbase import EditableForm
from sprox.widgets import PropertySingleSelectField
from geoalchemy2.shape import to_shape
from geoalchemy2.elements import WKTElement
from sqlalchemy.sql.expression import func
from skylines.controllers.base import BaseController
from skylines.lib import files
from sqlalchemy.sql.expression import and_, literal_column
from skylines.model import (DBSession, User, Flight, FlightPhase, Location,
                            Elevation)
from skylines.model.flight_comment import FlightComment
from skylines.model.notification import create_flight_comment_notifications
from skylines.lib.xcsoar import analyse_flight, flight_path
from skylines.lib.helpers import format_time, format_number
from skylines.lib.formatter import units
from skylines.lib.datetime import from_seconds_of_day
from skylines.lib.geo import METERS_PER_DEGREE
from skylines.forms import BootstrapForm, aircraft_model
from skylines.lib.sql import extract_array_item
from skylinespolyencode import SkyLinesPolyEncoder

log = logging.getLogger(__name__)


class PilotSelectField(PropertySingleSelectField):
    def _my_update_params(self, d, nullable=False):
        query = DBSession.query(User.id, User.display_name) \
            .filter(User.club_id == request.identity['user'].club_id) \
{'fraction_non_alphanumeric': 0.05350140056022409, 'fraction_numerical': 0.002240896358543417, 'mean_word_length': 5.988258317025441, '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': '7635039', 'n_tokens_mistral': 1026, 'n_tokens_neox': 991, 'n_words': 295}