~homeworkprod/byceps

c7f2b8cc422e1690c5fc36627d4da50a1d40ee35 — Jochen Kupperschmidt 8 months ago 7bc952e
Format more code according to Black
M byceps/blueprints/admin/board/forms.py => byceps/blueprints/admin/board/forms.py +9 -3
@@ 14,13 14,19 @@ from ....util.l10n import LocalizedForm


class BoardCreateForm(LocalizedForm):
    board_id = StringField(lazy_gettext('ID'), validators=[InputRequired(), Length(min=1, max=40)])
    board_id = StringField(
        lazy_gettext('ID'), validators=[InputRequired(), Length(min=1, max=40)]
    )


class CategoryCreateForm(LocalizedForm):
    slug = StringField(lazy_gettext('Slug'), [InputRequired(), Length(max=40)])
    title = StringField(lazy_gettext('Title'), [InputRequired(), Length(max=40)])
    description = StringField(lazy_gettext('Text'), [InputRequired(), Length(max=80)])
    title = StringField(
        lazy_gettext('Title'), [InputRequired(), Length(max=40)]
    )
    description = StringField(
        lazy_gettext('Text'), [InputRequired(), Length(max=80)]
    )


class CategoryUpdateForm(CategoryCreateForm):

M byceps/blueprints/admin/dashboard/views.py => byceps/blueprints/admin/dashboard/views.py +2 -2
@@ 129,8 129,8 @@ def view_brand(brand_id):
    newsletter_list = None
    if newsletter_list_id:
        newsletter_list = newsletter_service.find_list(newsletter_list_id)
        newsletter_subscriber_count = newsletter_service.count_subscribers_for_list(
            newsletter_list.id
        newsletter_subscriber_count = (
            newsletter_service.count_subscribers_for_list(newsletter_list.id)
        )
    else:
        newsletter_subscriber_count = None

M byceps/blueprints/admin/news/views.py => byceps/blueprints/admin/news/views.py +16 -9
@@ 239,7 239,10 @@ def image_update(image_id):
    attribution = form.attribution.data.strip()

    image = news_image_service.update_image(
        image.id, alt_text=alt_text, caption=caption, attribution=attribution,
        image.id,
        alt_text=alt_text,
        caption=caption,
        attribution=attribution,
    )

    flash_success(


@@ 299,15 302,19 @@ def _render_item_version(version, item):
            version.body, channel.id, item.images
        )

        context.update({
            'rendered_body': rendered_body,
            'error_occurred': False,
        })
        context.update(
            {
                'rendered_body': rendered_body,
                'error_occurred': False,
            }
        )
    except Exception as e:
        context.update({
            'error_occurred': True,
            'error_message': str(e),
        })
        context.update(
            {
                'error_occurred': True,
                'error_message': str(e),
            }
        )

    return context


M byceps/blueprints/admin/party/forms.py => byceps/blueprints/admin/party/forms.py +7 -5
@@ 19,8 19,12 @@ class _BaseForm(LocalizedForm):
        lazy_gettext('Title'),
        validators=[InputRequired(), Length(min=1, max=40)],
    )
    starts_on = DateField(lazy_gettext('Start date'), validators=[InputRequired()])
    starts_at = TimeField(lazy_gettext('Start time'), validators=[InputRequired()])
    starts_on = DateField(
        lazy_gettext('Start date'), validators=[InputRequired()]
    )
    starts_at = TimeField(
        lazy_gettext('Start time'), validators=[InputRequired()]
    )
    ends_on = DateField(lazy_gettext('End date'), validators=[InputRequired()])
    ends_at = TimeField(lazy_gettext('End time'), validators=[InputRequired()])
    max_ticket_quantity = IntegerField(


@@ 38,8 42,6 @@ class UpdateForm(_BaseForm):
    ticket_management_enabled = BooleanField(
        lazy_gettext('Ticket management open')
    )
    seat_management_enabled = BooleanField(
        lazy_gettext('Seat management open')
    )
    seat_management_enabled = BooleanField(lazy_gettext('Seat management open'))
    canceled = BooleanField(lazy_gettext('canceled'))
    archived = BooleanField(lazy_gettext('archived'))

M byceps/blueprints/admin/party/views.py => byceps/blueprints/admin/party/views.py +3 -1
@@ 81,7 81,9 @@ def index_for_brand(brand_id, page):
    )

    days_by_party_id = _get_days_by_party_id(parties.items)
    ticket_sale_stats_by_party_id = _get_ticket_sale_stats_by_party_id(parties.items)
    ticket_sale_stats_by_party_id = _get_ticket_sale_stats_by_party_id(
        parties.items
    )

    return {
        'brand': brand,

M byceps/blueprints/admin/seating/views.py => byceps/blueprints/admin/seating/views.py +4 -2
@@ 63,8 63,10 @@ def area_index(party_id, page):
    party = _get_party_or_404(party_id)

    per_page = request.args.get('per_page', type=int, default=15)
    areas_with_occupied_seat_counts = seating_area_service.get_areas_for_party_paginated(
        party.id, page, per_page
    areas_with_occupied_seat_counts = (
        seating_area_service.get_areas_for_party_paginated(
            party.id, page, per_page
        )
    )

    seat_total_per_area = seat_service.get_seat_total_per_area(party.id)

M byceps/blueprints/admin/shop/article/forms.py => byceps/blueprints/admin/shop/article/forms.py +6 -6
@@ 109,7 109,7 @@ class ArticleUpdateForm(_ArticleBaseForm):

        available_from = form._get_available_from()
        available_until = form._get_available_until()
        _validate_availability_range(available_from ,available_until )
        _validate_availability_range(available_from, available_until)

    @staticmethod
    def validate_available_until_time(form, field):


@@ 120,7 120,7 @@ class ArticleUpdateForm(_ArticleBaseForm):

        available_from = form._get_available_from()
        available_until = form._get_available_until()
        _validate_availability_range(available_from ,available_until )
        _validate_availability_range(available_from, available_until)

    def _get_available_from(self):
        d = self.available_from_date.data


@@ 140,9 140,7 @@ class ArticleUpdateForm(_ArticleBaseForm):


def _validate_date_and_time(d: date, t: time):
    if ((d is None) and (t is not None)) or (
        (d is not None) and (t is None)
    ):
    if ((d is None) and (t is not None)) or ((d is not None) and (t is None)):
        raise ValidationError(
            lazy_gettext(
                'Either date and time must be specified or neither of them.'


@@ 150,7 148,9 @@ def _validate_date_and_time(d: date, t: time):
        )


def _validate_availability_range(available_from: datetime, available_until: datetime):
def _validate_availability_range(
    available_from: datetime, available_until: datetime
):
    """Ensure that the availability range's begin is before its end."""
    if (
        (available_from is not None)

M byceps/blueprints/admin/shop/shop/views.py => byceps/blueprints/admin/shop/shop/views.py +2 -2
@@ 41,8 41,8 @@ def view(shop_id):

    brand = brand_service.get_brand(shop.brand_id)

    order_counts_by_payment_state = order_service.count_orders_per_payment_state(
        shop.id
    order_counts_by_payment_state = (
        order_service.count_orders_per_payment_state(shop.id)
    )

    return {

M byceps/blueprints/admin/shop/storefront/views.py => byceps/blueprints/admin/shop/storefront/views.py +2 -2
@@ 38,8 38,8 @@ def index_for_shop(shop_id):

    storefronts = storefront_service.get_storefronts_for_shop(shop.id)

    order_number_prefixes_by_sequence_id = _get_order_number_prefixes_by_sequence_id(
        storefronts, shop.id
    order_number_prefixes_by_sequence_id = (
        _get_order_number_prefixes_by_sequence_id(storefronts, shop.id)
    )

    return {

M byceps/blueprints/admin/terms/views.py => byceps/blueprints/admin/terms/views.py +2 -2
@@ 39,8 39,8 @@ def view_document(document_id):

    _add_version_creators(versions)

    consent_counts_by_version_id = terms_consent_service.count_consents_for_document_versions(
        document.id
    consent_counts_by_version_id = (
        terms_consent_service.count_consents_for_document_versions(document.id)
    )

    for version in versions:

M byceps/blueprints/admin/ticketing/checkin/views.py => byceps/blueprints/admin/ticketing/checkin/views.py +4 -2
@@ 73,8 73,10 @@ def _search_tickets(party_id, search_term, limit):
    page = 1
    per_page = limit

    tickets_pagination = ticket_service.get_tickets_with_details_for_party_paginated(
        party_id, page, per_page, search_term=search_term
    tickets_pagination = (
        ticket_service.get_tickets_with_details_for_party_paginated(
            party_id, page, per_page, search_term=search_term
        )
    )

    return tickets_pagination.items

M byceps/blueprints/admin/tourney/category/views.py => byceps/blueprints/admin/tourney/category/views.py +1 -5
@@ 90,11 90,7 @@ def update_form(category_id, erroneous_form=None):

    party = party_service.get_party(category.party_id)

    form = (
        erroneous_form
        if erroneous_form
        else UpdateForm(obj=category)
    )
    form = erroneous_form if erroneous_form else UpdateForm(obj=category)

    return {
        'category': category,

M byceps/blueprints/admin/user/models.py => byceps/blueprints/admin/user/models.py +10 -7
@@ 14,13 14,16 @@ from typing import Optional
from ....services.user.transfer.models import User


UserStateFilter = Enum('UserStateFilter', [
    'none',
    'active',
    'uninitialized',
    'suspended',
    'deleted',
])
UserStateFilter = Enum(
    'UserStateFilter',
    [
        'none',
        'active',
        'uninitialized',
        'suspended',
        'deleted',
    ],
)


@dataclass(frozen=True)

M byceps/blueprints/admin/user/views.py => byceps/blueprints/admin/user/views.py +6 -4
@@ 119,8 119,8 @@ def view(user_id):

    attended_parties = service.get_attended_parties(user.id)

    badges_with_awarding_quantity = badge_awarding_service.get_badges_awarded_to_user(
        user.id
    badges_with_awarding_quantity = (
        badge_awarding_service.get_badges_awarded_to_user(user.id)
    )

    return {


@@ 562,8 562,10 @@ def view_permissions(user_id):
    """Show user's permissions."""
    user = _get_user_or_404(user_id)

    permissions_by_role = authorization_service.get_permissions_by_roles_for_user_with_titles(
        user.id
    permissions_by_role = (
        authorization_service.get_permissions_by_roles_for_user_with_titles(
            user.id
        )
    )

    return {

M byceps/blueprints/api/v1/snippet/views.py => byceps/blueprints/api/v1/snippet/views.py +6 -4
@@ 53,9 53,11 @@ def _get_content(version):
    }

    if version.snippet.is_document:
        content.update({
            'title': context['title'],
            'head': context['head'],
        })
        content.update(
            {
                'title': context['title'],
                'head': context['head'],
            }
        )

    return content

M byceps/blueprints/api/v1/tourney/avatar/views.py => byceps/blueprints/api/v1/tourney/avatar/views.py +6 -4
@@ 23,10 23,12 @@ from .forms import CreateForm
blueprint = create_blueprint('api_v1_tourney_avatar', __name__)


ALLOWED_IMAGE_TYPES = frozenset([
    ImageType.jpeg,
    ImageType.png,
])
ALLOWED_IMAGE_TYPES = frozenset(
    [
        ImageType.jpeg,
        ImageType.png,
    ]
)


@blueprint.route('', methods=['POST'])

M byceps/blueprints/api/v1/tourney/match/comments/views.py => byceps/blueprints/api/v1/tourney/match/comments/views.py +10 -5
@@ 66,9 66,11 @@ def get_comments_for_match(match_id):

    comment_dtos = list(map(_comment_to_json, comments))

    return jsonify({
        'comments': comment_dtos,
    })
    return jsonify(
        {
            'comments': comment_dtos,
        }
    )


def _comment_to_json(comment: MatchComment) -> Dict[str, Any]:


@@ 111,7 113,9 @@ def _user_to_json(user: User) -> Dict[str, Any]:


blueprint.add_url_rule(
    '/match_comments/<uuid:comment_id>', endpoint='view', build_only=True,
    '/match_comments/<uuid:comment_id>',
    endpoint='view',
    build_only=True,
)




@@ 176,7 180,8 @@ def hide(comment_id):


@blueprint.route(
    '/match_comments/<uuid:comment_id>/flags/hidden', methods=['DELETE'],
    '/match_comments/<uuid:comment_id>/flags/hidden',
    methods=['DELETE'],
)
@api_token_required
@respond_no_content

M byceps/blueprints/site/authentication/login/views.py => byceps/blueprints/site/authentication/login/views.py +4 -4
@@ 91,8 91,8 @@ def login():
        abort(403)

    if _is_consent_required(user.id):
        verification_token = verification_token_service.create_for_terms_consent(
            user.id
        verification_token = (
            verification_token_service.create_for_terms_consent(user.id)
        )

        consent_form_url = url_for(


@@ 116,8 116,8 @@ def login():


def _is_consent_required(user_id: UserID) -> bool:
    required_subject_ids = consent_subject_service.get_subject_ids_required_for_brand(
        g.brand_id
    required_subject_ids = (
        consent_subject_service.get_subject_ids_required_for_brand(g.brand_id)
    )

    return not consent_service.has_user_consented_to_all_subjects(

M byceps/blueprints/site/board/service.py => byceps/blueprints/site/board/service.py +4 -2
@@ 50,8 50,10 @@ def add_unseen_postings_flag_to_categories(
            )
        )

        category_with_flag = CategoryWithLastUpdateAndUnseenFlag.from_category_with_last_update(
            category, contains_unseen_postings
        category_with_flag = (
            CategoryWithLastUpdateAndUnseenFlag.from_category_with_last_update(
                category, contains_unseen_postings
            )
        )

        categories_with_flag.append(category_with_flag)

M byceps/blueprints/site/board/views_topic.py => byceps/blueprints/site/board/views_topic.py +6 -4
@@ 118,10 118,12 @@ def topic_view(topic_id, page):
    }

    if is_last_page:
        context.update({
            'form': PostingCreateForm(),
            'smileys': get_smileys(),
        })
        context.update(
            {
                'form': PostingCreateForm(),
                'smileys': get_smileys(),
            }
        )

    return context


M byceps/blueprints/site/consent/views.py => byceps/blueprints/site/consent/views.py +2 -2
@@ 101,8 101,8 @@ def _get_unconsented_subjects_for_user(user_id):


def _get_verification_token_or_404(token_value):
    verification_token = verification_token_service.find_for_terms_consent_by_token(
        token_value
    verification_token = (
        verification_token_service.find_for_terms_consent_by_token(token_value)
    )

    if verification_token is None:

M byceps/blueprints/site/shop/order/views.py => byceps/blueprints/site/shop/order/views.py +12 -8
@@ 52,8 52,8 @@ def order_form(erroneous_form=None):
        flash_notice(gettext('The shop is closed.'))
        return {'article_compilation': None}

    article_compilation = article_service.get_article_compilation_for_orderable_articles(
        shop.id
    article_compilation = (
        article_service.get_article_compilation_for_orderable_articles(shop.id)
    )

    if article_compilation.is_empty():


@@ 101,8 101,8 @@ def order():
        flash_notice(gettext('The shop is closed.'))
        return order_form()

    article_compilation = article_service.get_article_compilation_for_orderable_articles(
        shop.id
    article_compilation = (
        article_service.get_article_compilation_for_orderable_articles(shop.id)
    )

    if article_compilation.is_empty():


@@ 155,8 155,10 @@ def order_single_form(article_id, erroneous_form=None):
            'article': None,
        }

    article_compilation = article_service.get_article_compilation_for_single_article(
        article.id, fixed_quantity=1
    article_compilation = (
        article_service.get_article_compilation_for_single_article(
            article.id, fixed_quantity=1
        )
    )

    country_names = country_service.get_country_names()


@@ 210,8 212,10 @@ def order_single(article_id):
        flash_error(gettext('The article cannot be ordered directly.'))
        return order_single_form(article.id)

    article_compilation = article_service.get_article_compilation_for_single_article(
        article.id, fixed_quantity=quantity
    article_compilation = (
        article_service.get_article_compilation_for_single_article(
            article.id, fixed_quantity=quantity
        )
    )

    user = g.user

M byceps/blueprints/site/user/avatar/views.py => byceps/blueprints/site/user/avatar/views.py +6 -4
@@ 25,10 25,12 @@ from .forms import UpdateForm
blueprint = create_blueprint('user_avatar', __name__)


ALLOWED_IMAGE_TYPES = frozenset([
    ImageType.jpeg,
    ImageType.png,
])
ALLOWED_IMAGE_TYPES = frozenset(
    [
        ImageType.jpeg,
        ImageType.png,
    ]
)


@blueprint.route('/me/avatar/update')

M byceps/blueprints/site/user/creation/forms.py => byceps/blueprints/site/user/creation/forms.py +6 -8
@@ 48,9 48,7 @@ class UserCreateForm(LocalizedForm):
    @staticmethod
    def validate_screen_name(form, field):
        if user_service.is_screen_name_already_assigned(field.data):
            raise ValueError(
                lazy_gettext('This username is not available.')
            )
            raise ValueError(lazy_gettext('This username is not available.'))

    @staticmethod
    def validate_email_address(form, field):


@@ 59,9 57,7 @@ class UserCreateForm(LocalizedForm):

        if user_service.is_email_address_already_assigned(field.data):
            raise ValueError(
                lazy_gettext(
                    'This email address is not available.'
                )
                lazy_gettext('This email address is not available.')
            )

    @staticmethod


@@ 83,10 79,12 @@ def assemble_user_create_form(

    if real_name_required:
        extra_fields['first_names'] = StringField(
            lazy_gettext('First name(s)'), [InputRequired(), Length(min=2, max=40)]
            lazy_gettext('First name(s)'),
            [InputRequired(), Length(min=2, max=40)],
        )
        extra_fields['last_name'] = StringField(
            lazy_gettext('Last name(s)'), [InputRequired(), Length(min=2, max=80)]
            lazy_gettext('Last name(s)'),
            [InputRequired(), Length(min=2, max=80)],
        )

    for subject in required_consent_subjects:

M byceps/blueprints/site/user/settings/forms.py => byceps/blueprints/site/user/settings/forms.py +1 -3
@@ 43,9 43,7 @@ class ChangeScreenNameForm(LocalizedForm):
            )

        if user_service.is_screen_name_already_assigned(field.data):
            raise ValueError(
                lazy_gettext('This username is not available.')
            )
            raise ValueError(lazy_gettext('This username is not available.'))

    @staticmethod
    def validate_password(form, field):

M byceps/blueprints/site/user_profile/views.py => byceps/blueprints/site/user_profile/views.py +2 -2
@@ 29,8 29,8 @@ def view(user_id):
    if user is None:
        abort(404)

    badges_with_awarding_quantity = badge_awarding_service.get_badges_awarded_to_user(
        user.id
    badges_with_awarding_quantity = (
        badge_awarding_service.get_badges_awarded_to_user(user.id)
    )

    orga_team = orga_team_service.find_orga_team_for_user_and_party(

M byceps/translations/de/LC_MESSAGES/messages.po => byceps/translations/de/LC_MESSAGES/messages.po +80 -80
@@ 85,22 85,22 @@ msgstr "Passwort vergessen?"
msgid "Set new password"
msgstr "Neues Passwort setzen"

#: byceps/blueprints/admin/board/forms.py:17
#: byceps/blueprints/admin/board/forms.py:18
#: byceps/blueprints/admin/brand/forms.py:25
#: byceps/blueprints/admin/news/forms.py:24
#: byceps/blueprints/admin/party/forms.py:33
#: byceps/blueprints/admin/party/forms.py:37
#: byceps/blueprints/admin/shop/storefront/forms.py:38
#: byceps/blueprints/admin/site/forms.py:84
msgid "ID"
msgstr "ID"

#: byceps/blueprints/admin/board/forms.py:21
#: byceps/blueprints/admin/board/forms.py:23
#: byceps/blueprints/admin/news/forms.py:47
#: byceps/blueprints/admin/user_badge/forms.py:23
msgid "Slug"
msgstr "Slug"

#: byceps/blueprints/admin/board/forms.py:22
#: byceps/blueprints/admin/board/forms.py:25
#: byceps/blueprints/admin/brand/forms.py:18
#: byceps/blueprints/admin/news/forms.py:60
#: byceps/blueprints/admin/orga_team/forms.py:18


@@ 115,7 115,7 @@ msgstr "Slug"
msgid "Title"
msgstr "Titel"

#: byceps/blueprints/admin/board/forms.py:23
#: byceps/blueprints/admin/board/forms.py:28
#: byceps/blueprints/admin/news/forms.py:62
#: byceps/blueprints/admin/snippet/forms.py:35
#: byceps/blueprints/site/board/forms.py:17


@@ 135,7 135,7 @@ msgid "Category \"%(category_title)s\" has been created."
msgstr "Die Kategorie \"%(category_title)s\" wurde angelegt."

#: byceps/blueprints/admin/board/views.py:225
#: byceps/blueprints/admin/tourney/category/views.py:119
#: byceps/blueprints/admin/tourney/category/views.py:115
#, python-format
msgid "Category \"%(category_title)s\" has been updated."
msgstr "Die Kategorie \"%(category_title)s\" wurde aktualisiert."


@@ 151,13 151,13 @@ msgid "Category \"%(category_title)s\" has been made visible."
msgstr "Die Kategorie \"%(category_title)s\" wurde sichtbar gemacht."

#: byceps/blueprints/admin/board/views.py:282
#: byceps/blueprints/admin/tourney/category/views.py:138
#: byceps/blueprints/admin/tourney/category/views.py:134
#, python-format
msgid "Category \"%(category_title)s\" is already at the top."
msgstr "Die Kategorie \"%(category_title)s\" befindet sich bereits ganz oben."

#: byceps/blueprints/admin/board/views.py:289
#: byceps/blueprints/admin/tourney/category/views.py:145
#: byceps/blueprints/admin/tourney/category/views.py:141
#, python-format
msgid "Category \"%(category_title)s\" has been moved upwards by one position."
msgstr ""


@@ 165,13 165,13 @@ msgstr ""
"verschoben."

#: byceps/blueprints/admin/board/views.py:307
#: byceps/blueprints/admin/tourney/category/views.py:162
#: byceps/blueprints/admin/tourney/category/views.py:158
#, python-format
msgid "Category \"%(category_title)s\" is already at the bottom."
msgstr "Die Kategorie \"%(category_title)s\" befindet sich bereits ganz unten."

#: byceps/blueprints/admin/board/views.py:314
#: byceps/blueprints/admin/tourney/category/views.py:169
#: byceps/blueprints/admin/tourney/category/views.py:165
#, python-format
msgid "Category \"%(category_title)s\" has been moved downwards by one position."
msgstr ""


@@ 545,27 545,27 @@ msgstr "Der News-Kanal mit der ID \"%(channel_id)s\" wurde angelegt."
msgid "News image #%(image_number)s has been created."
msgstr "Das Newsbild #%(image_number)s wurde hinzugefügt."

#: byceps/blueprints/admin/news/views.py:246
#: byceps/blueprints/admin/news/views.py:249
#, python-format
msgid "News image #%(image_number)s has been updated."
msgstr "Das Newsbild #%(image_number)s wurde aktualisiert."

#: byceps/blueprints/admin/news/views.py:406
#: byceps/blueprints/admin/news/views.py:413
#, python-format
msgid "News item \"%(title)s\" has been created."
msgstr "Die News \"%(title)s\" wurde angelegt."

#: byceps/blueprints/admin/news/views.py:454
#: byceps/blueprints/admin/news/views.py:461
#, python-format
msgid "News item \"%(title)s\" has been updated."
msgstr "Die News \"%(title)s\" wurde aktualisiert."

#: byceps/blueprints/admin/news/views.py:496
#: byceps/blueprints/admin/news/views.py:503
#, python-format
msgid "News item \"%(title)s\" will be published later."
msgstr "Die News \"%(title)s\" wird später veröffentlicht."

#: byceps/blueprints/admin/news/views.py:516
#: byceps/blueprints/admin/news/views.py:523
#, python-format
msgid "News item \"%(title)s\" has been published."
msgstr "Die News \"%(title)s\" wurde veröffentlicht."


@@ 701,49 701,49 @@ msgstr "%(screen_name)s wurde aus dem Team \"%(team_title)s\" entfernt."
msgid "Copy"
msgstr "Kopieren"

#: byceps/blueprints/admin/party/forms.py:22
#: byceps/blueprints/admin/party/forms.py:23
msgid "Start date"
msgstr "Startdatum"

#: byceps/blueprints/admin/party/forms.py:23
#: byceps/blueprints/admin/party/forms.py:26
msgid "Start time"
msgstr "Startzeit"

#: byceps/blueprints/admin/party/forms.py:24
#: byceps/blueprints/admin/party/forms.py:28
msgid "End date"
msgstr "Enddatum"

#: byceps/blueprints/admin/party/forms.py:25
#: byceps/blueprints/admin/party/forms.py:29
msgid "End time"
msgstr "Endzeit"

#: byceps/blueprints/admin/party/forms.py:27
#: byceps/blueprints/admin/party/forms.py:31
msgid "Maximum number of tickets"
msgstr "Maximale Anzahl Tickets"

#: byceps/blueprints/admin/party/forms.py:39
#: byceps/blueprints/admin/party/forms.py:43
msgid "Ticket management open"
msgstr "Ticketverwaltung geöffnet"

#: byceps/blueprints/admin/party/forms.py:42
#: byceps/blueprints/admin/party/forms.py:45
msgid "Seat management open"
msgstr "Sitzplatzverwaltung geöffnet"

#: byceps/blueprints/admin/party/forms.py:44
#: byceps/blueprints/admin/party/forms.py:46
msgid "canceled"
msgstr "abgesagt"

#: byceps/blueprints/admin/party/forms.py:45
#: byceps/blueprints/admin/party/forms.py:47
#: byceps/blueprints/admin/site/forms.py:90
msgid "archived"
msgstr "archiviert"

#: byceps/blueprints/admin/party/views.py:173
#: byceps/blueprints/admin/party/views.py:175
#, python-format
msgid "Party \"%(title)s\" has been created."
msgstr "Die Party \"%(title)s\" wurde angelegt."

#: byceps/blueprints/admin/party/views.py:251
#: byceps/blueprints/admin/party/views.py:253
#, python-format
msgid "Party \"%(title)s\" has been updated."
msgstr "Die Party \"%(title)s\" wurde aktualisiert."


@@ 808,7 808,7 @@ msgstr "muss separat bestellt werden"
msgid "Shipping required"
msgstr "Versand erforderlich"

#: byceps/blueprints/admin/shop/article/forms.py:147
#: byceps/blueprints/admin/shop/article/forms.py:145
msgid "Either date and time must be specified or neither of them."
msgstr "Entweder Datum und Uhrzeit müssen angegeben werden oder keines von beiden."



@@ 1191,7 1191,7 @@ msgstr "Ticket-Kategorie \"%(title)s\" wurde erstellt."
msgid "Category \"%(title)s\" has been updated."
msgstr "Ticket-Kategorie \"%(title)s\" wurde aktualisiert."

#: byceps/blueprints/admin/ticketing/checkin/views.py:125
#: byceps/blueprints/admin/ticketing/checkin/views.py:127
msgid ""
"The user account assigned to this ticket has been deleted. Check-in "
"denied."


@@ 1199,7 1199,7 @@ msgstr ""
"Das dem Ticket zugewiesene Benutzerkonto ist gelöscht worden. Der Check-"
"In ist nicht erlaubt."

#: byceps/blueprints/admin/ticketing/checkin/views.py:132
#: byceps/blueprints/admin/ticketing/checkin/views.py:134
msgid ""
"The user account assigned to this ticket has been suspended. Check-in "
"denied."


@@ 1207,7 1207,7 @@ msgstr ""
"Das dem Ticket zugewiesene Benutzerkonto ist gesperrt. Der Check-In ist "
"nicht erlaubt."

#: byceps/blueprints/admin/ticketing/checkin/views.py:143
#: byceps/blueprints/admin/ticketing/checkin/views.py:145
#, python-format
msgid ""
"User <em>%(screen_name)s</em> has been checked in with ticket <a "


@@ 1216,7 1216,7 @@ msgstr ""
"Benutzer <em>%(screen_name)s</em> wurde mit Ticket <a "
"href=\"%(ticket_url)s\">%(ticket_code)s</a> eingecheckt."

#: byceps/blueprints/admin/ticketing/checkin/views.py:155
#: byceps/blueprints/admin/ticketing/checkin/views.py:157
#, python-format
msgid ""
"Ticket <a href=\"%(ticket_url)s\">%(ticket_code)s</a> does not occupy a "


@@ 1225,7 1225,7 @@ msgstr ""
"Ticket <a href=\"%(ticket_url)s\">%(ticket_code)s</a> belegt noch keinen "
"Sitzplatz."

#: byceps/blueprints/admin/ticketing/checkin/views.py:178
#: byceps/blueprints/admin/ticketing/checkin/views.py:180
msgid "Check-in has been reverted."
msgstr "Der Check-In wurde rückgängig gemacht."



@@ 1288,15 1288,15 @@ msgstr "Neuer Benutzername"

#: byceps/blueprints/admin/user/forms.py:66
#: byceps/blueprints/site/shop/order/forms.py:20
#: byceps/blueprints/site/user/creation/forms.py:86
#: byceps/blueprints/site/user/settings/forms.py:61
#: byceps/blueprints/site/user/creation/forms.py:82
#: byceps/blueprints/site/user/settings/forms.py:59
msgid "First name(s)"
msgstr "Vorname(n)"

#: byceps/blueprints/admin/user/forms.py:69
#: byceps/blueprints/site/shop/order/forms.py:23
#: byceps/blueprints/site/user/creation/forms.py:89
#: byceps/blueprints/site/user/settings/forms.py:64
#: byceps/blueprints/site/user/creation/forms.py:86
#: byceps/blueprints/site/user/settings/forms.py:62
msgid "Last name(s)"
msgstr "Nachname(n)"



@@ 1396,12 1396,12 @@ msgstr ""
"Das Benutzerkonto '%(old_screen_name)s' wurde umbenannt in "
"'%(new_screen_name)s'."

#: byceps/blueprints/admin/user/views.py:609
#: byceps/blueprints/admin/user/views.py:611
#, python-format
msgid "%(role_title)s has been assigned to \"%(screen_name)s\"."
msgstr "%(screen_name)s wurde die Rolle \"%(role_title)s\" zugewiesen."

#: byceps/blueprints/admin/user/views.py:631
#: byceps/blueprints/admin/user/views.py:633
#, python-format
msgid "%(role_title)s has been withdrawn from \"%(screen_name)s\"."
msgstr "%(screen_name)s wurde die Rolle \"%(role_title)s\" genommen."


@@ 1654,62 1654,62 @@ msgstr "Der Beitrag wurde versteckt."
msgid "The posting has been made visible again."
msgstr "Der Beitrag wurde wieder sichtbar gemacht."

#: byceps/blueprints/site/board/views_topic.py:165
#: byceps/blueprints/site/board/views_topic.py:167
#, python-format
msgid "Topic \"%(title)s\" has been created."
msgstr "Das Thema \"%(title)s\" wurde hinzugefügt."

#: byceps/blueprints/site/board/views_topic.py:186
#: byceps/blueprints/site/board/views_topic.py:222
#: byceps/blueprints/site/board/views_topic.py:188
#: byceps/blueprints/site/board/views_topic.py:224
msgid "The topic must not be updated because it is locked."
msgstr "Das Thema darf nicht bearbeitet werden weil es gesperrt ist."

#: byceps/blueprints/site/board/views_topic.py:191
#: byceps/blueprints/site/board/views_topic.py:227
#: byceps/blueprints/site/board/views_topic.py:193
#: byceps/blueprints/site/board/views_topic.py:229
msgid "The topic must not be updated."
msgstr "Das Thema darf nicht bearbeitet werden."

#: byceps/blueprints/site/board/views_topic.py:195
#: byceps/blueprints/site/board/views_topic.py:231
#: byceps/blueprints/site/board/views_topic.py:197
#: byceps/blueprints/site/board/views_topic.py:233
msgid "You are not allowed to update this topic."
msgstr "Du darfst dieses Thema nicht bearbeiten."

#: byceps/blueprints/site/board/views_topic.py:243
#: byceps/blueprints/site/board/views_topic.py:245
#, python-format
msgid "Topic \"%(title)s\" has been updated."
msgstr "Das Thema \"%(title)s\" wurde aktualisiert."

#: byceps/blueprints/site/board/views_topic.py:279
#: byceps/blueprints/site/board/views_topic.py:281
#, python-format
msgid "Topic \"%(title)s\" has been hidden."
msgstr "Das Thema \"%(title)s\" wurde versteckt."

#: byceps/blueprints/site/board/views_topic.py:302
#: byceps/blueprints/site/board/views_topic.py:304
#, python-format
msgid "Topic \"%(title)s\" has been made visible again."
msgstr "Das Thema \"%(title)s\" wurde wieder sichtbar gemacht."

#: byceps/blueprints/site/board/views_topic.py:328
#: byceps/blueprints/site/board/views_topic.py:330
#, python-format
msgid "Topic \"%(title)s\" has been locked."
msgstr "Das Thema \"%(title)s\" wurde geschlossen."

#: byceps/blueprints/site/board/views_topic.py:351
#: byceps/blueprints/site/board/views_topic.py:353
#, python-format
msgid "Topic \"%(title)s\" has been unlocked."
msgstr "Das Thema \"%(title)s\" wurde wieder geöffnet."

#: byceps/blueprints/site/board/views_topic.py:374
#: byceps/blueprints/site/board/views_topic.py:376
#, python-format
msgid "Topic \"%(title)s\" has been pinned."
msgstr "Das Thema \"%(title)s\" wurde angepinnt."

#: byceps/blueprints/site/board/views_topic.py:397
#: byceps/blueprints/site/board/views_topic.py:399
#, python-format
msgid "Topic \"%(title)s\" has been unpinned."
msgstr "Das Thema \"%(title)s\" wurde wieder gelöst."

#: byceps/blueprints/site/board/views_topic.py:428
#: byceps/blueprints/site/board/views_topic.py:430
#, python-format
msgid ""
"Topic \"%(topic_title)s\" has been moved from category "


@@ 1719,12 1719,12 @@ msgstr ""
"\"%(old_category_title)s\" in die Kategorie \"%(new_category_title)s\" "
"verschoben."

#: byceps/blueprints/site/board/views_topic.py:458
#: byceps/blueprints/site/board/views_topic.py:460
#, python-format
msgid "Topic \"%(title)s\" has been limited to announcements."
msgstr "Das Thema \"%(title)s\" wurde auf Ankündigungen beschränkt."

#: byceps/blueprints/site/board/views_topic.py:480
#: byceps/blueprints/site/board/views_topic.py:482
#, python-format
msgid "Topic \"%(title)s\" has been reopened for regular replies."
msgstr "Das Thema \"%(title)s\" wurde für normale Beiträge geöffnet."


@@ 1879,29 1879,29 @@ msgid "%(seat_label)s has been released."
msgstr "%(seat_label)s wurde freigegeben."

#: byceps/blueprints/site/shop/order/forms.py:26
#: byceps/blueprints/site/user/settings/forms.py:67
#: byceps/blueprints/site/user/settings/forms.py:65
msgid "Country"
msgstr "Land"

#: byceps/blueprints/site/shop/order/forms.py:29
#: byceps/blueprints/site/user/settings/forms.py:68
#: byceps/blueprints/site/user/settings/forms.py:66
msgid "Zip code"
msgstr "PLZ"

#: byceps/blueprints/site/shop/order/forms.py:31
#: byceps/blueprints/site/user/settings/forms.py:69
#: byceps/blueprints/site/user/settings/forms.py:67
msgid "City"
msgstr "Stadt"

#: byceps/blueprints/site/shop/order/forms.py:32
#: byceps/blueprints/site/user/settings/forms.py:70
#: byceps/blueprints/site/user/settings/forms.py:68
msgid "Street"
msgstr "Straße"

#: byceps/blueprints/site/shop/order/views.py:52
#: byceps/blueprints/site/shop/order/views.py:101
#: byceps/blueprints/site/shop/order/views.py:152
#: byceps/blueprints/site/shop/order/views.py:206
#: byceps/blueprints/site/shop/order/views.py:208
msgid "The shop is closed."
msgstr "Der Shop ist derzeit geschlossen."



@@ 1915,26 1915,26 @@ msgid "No articles have been selected."
msgstr "Es wurden keine Artikel ausgewählt."

#: byceps/blueprints/site/shop/order/views.py:129
#: byceps/blueprints/site/shop/order/views.py:240
#: byceps/blueprints/site/shop/order/views.py:244
msgid "Placing the order has failed."
msgstr "Die Bestellung ist fehlgeschlagen."

#: byceps/blueprints/site/shop/order/views.py:165
#: byceps/blueprints/site/shop/order/views.py:210
#: byceps/blueprints/site/shop/order/views.py:167
#: byceps/blueprints/site/shop/order/views.py:212
msgid "The article cannot be ordered directly."
msgstr "Der Artikel kann nicht direkt bestellt werden."

#: byceps/blueprints/site/shop/order/views.py:172
#: byceps/blueprints/site/shop/order/views.py:220
#: byceps/blueprints/site/shop/order/views.py:174
#: byceps/blueprints/site/shop/order/views.py:224
msgid "You cannot place another order."
msgstr "Du kannst keine weitere Bestellung aufgeben."

#: byceps/blueprints/site/shop/order/views.py:181
#: byceps/blueprints/site/shop/order/views.py:226
#: byceps/blueprints/site/shop/order/views.py:183
#: byceps/blueprints/site/shop/order/views.py:230
msgid "The article is not available."
msgstr "Der Artikel ist nicht verfügbar."

#: byceps/blueprints/site/shop/order/views.py:289
#: byceps/blueprints/site/shop/order/views.py:293
#, python-format
msgid "Your order <strong>%(order_number)s</strong> has been placed. Thank you!"
msgstr ""


@@ 2018,15 2018,15 @@ msgstr "Tickets können derzeit nicht verändert werden."
msgid "Somebody has already been checked in with this ticket."
msgstr "Es ist bereits jemand mit diesem Ticket eingecheckt worden."

#: byceps/blueprints/site/user/avatar/views.py:70
#: byceps/blueprints/site/user/avatar/views.py:72
msgid "Avatar image has been updated."
msgstr "Dein Avatarbild wurde aktualisiert."

#: byceps/blueprints/site/user/avatar/views.py:103
#: byceps/blueprints/site/user/avatar/views.py:105
msgid "No avatar image is set that could be removed."
msgstr "Es ist kein Avatarbild gesetzt, das entfernt werden könnte."

#: byceps/blueprints/site/user/avatar/views.py:105
#: byceps/blueprints/site/user/avatar/views.py:107
msgid "Avatar image has been removed."
msgstr "Dein Avatarbild wurde entfernt."



@@ 2038,24 2038,24 @@ msgstr "Hochladen"
msgid "Bot"
msgstr "Bot"

#: byceps/blueprints/site/user/creation/forms.py:52
#: byceps/blueprints/site/user/settings/forms.py:47
#: byceps/blueprints/site/user/creation/forms.py:51
#: byceps/blueprints/site/user/settings/forms.py:46
msgid "This username is not available."
msgstr "Dieser Benutzername kann nicht verwendet werden."

#: byceps/blueprints/site/user/creation/forms.py:58
#: byceps/blueprints/site/user/creation/forms.py:56
msgid "Invalid email address"
msgstr "Die E-Mail-Adresse ist ungültig."

#: byceps/blueprints/site/user/creation/forms.py:62
#: byceps/blueprints/site/user/creation/forms.py:60
msgid "This email address is not available."
msgstr "Diese E-Mail-Adresse kann nicht verwendet werden."

#: byceps/blueprints/site/user/creation/forms.py:70
#: byceps/blueprints/site/user/creation/forms.py:66
msgid "Bots are not permitted."
msgstr "Bots sind nicht erlaubt."

#: byceps/blueprints/site/user/creation/forms.py:98
#: byceps/blueprints/site/user/creation/forms.py:96
msgid "Newsletter"
msgstr "Newsletter"



@@ 2115,15 2115,15 @@ msgstr "Aktuelles Passwort"
msgid "This already is the current username."
msgstr "Dies ist bereits der aktuelle Benutzername."

#: byceps/blueprints/site/user/settings/forms.py:56
#: byceps/blueprints/site/user/settings/forms.py:54
msgid "Wrong password."
msgstr "Das Passwort ist nicht korrekt."

#: byceps/blueprints/site/user/settings/forms.py:66
#: byceps/blueprints/site/user/settings/forms.py:64
msgid "Date of birth"
msgstr "Geburtsdatum"

#: byceps/blueprints/site/user/settings/forms.py:72
#: byceps/blueprints/site/user/settings/forms.py:70
msgid "Phone number"
msgstr "Telefonnummer"


M byceps/util/sentry.py => byceps/util/sentry.py +6 -2
@@ 21,7 21,9 @@ def configure_sentry_for_webapp(dsn: str, environment: str, app: Flask) -> None:
    from sentry_sdk.integrations.flask import FlaskIntegration

    sentry_sdk.init(
        dsn=dsn, environment=environment, integrations=[FlaskIntegration()],
        dsn=dsn,
        environment=environment,
        integrations=[FlaskIntegration()],
    )

    app_mode = app.config.get('APP_MODE')


@@ 37,7 39,9 @@ def configure_sentry_for_worker(dsn: str, environment: str) -> None:
    from sentry_sdk.integrations.rq import RqIntegration

    sentry_sdk.init(
        dsn=dsn, environment=environment, integrations=[RqIntegration()],
        dsn=dsn,
        environment=environment,
        integrations=[RqIntegration()],
    )

    sentry_sdk.set_tag('app_mode', 'worker')

M scripts/grant_board_access.py => scripts/grant_board_access.py +0 -1
@@ 16,7 16,6 @@ from _util import app_context
from _validators import validate_user_screen_name



def validate_board(ctx, param, board_id: str) -> Board:
    board = board_service.find_board(board_id)