[flake8]
ignore = N802,W503,E402,C901,E722,W504,E252,N812,N806,N818,E741
max-line-length = 160
exclude = migrations,.ropeproject,static,mt940.py,_static,build,make_testdata.py,*/testutils/settings.py,tests/settings.py,pretix/base/models/__init__.py,pretix/base/secretgenerators/pretix_sig1_pb2.py,.eggs/*
max-complexity = 11

[isort]
combine_as_imports = true
include_trailing_comma = true
known_first_party = pretix
known_third_party = versions,tests
extra_standard_library = typing,enum,mimetypes
multi_line_output = 5
line_length = 79
honor_noqa = true
skip_glob = make_testdata.py,wsgi.py,bootstrap,celery_app.py,pretix/settings.py,tests/settings.py,pretix/testutils/settings.py,.eggs/**

[tool:pytest]
DJANGO_SETTINGS_MODULE = tests.settings
addopts = --reruns 3 -rw
filterwarnings =
    error
    ignore:The 'warn' method is deprecated:DeprecationWarning
    ignore::DeprecationWarning:mt940
    ignore::DeprecationWarning:cbor2
    ignore::DeprecationWarning:markdown
    ignore::DeprecationWarning:celery
    ignore::DeprecationWarning:kombu
    ignore::DeprecationWarning:django
    ignore::DeprecationWarning:cgi
    ignore::DeprecationWarning:vat_moss
    ignore::pytz_deprecation_shim._exceptions.PytzUsageWarning:vobject
    ignore:the load_module.* method is deprecated:DeprecationWarning
    ignore::ImportWarning
    ignore::ResourceWarning
    ignore:django.contrib.staticfiles.templatetags.static:DeprecationWarning
    ignore::DeprecationWarning:compressor
    ignore:pkg_resources is deprecated as an API:
    ignore:.*pkg_resources.declare_namespace.*:


[coverage:run]
source = pretix
omit = */migrations/*,*/urls.py,*/tests/*,*/testdummy/*,*/admin.py,pretix/wsgi.py,pretix/settings.py,.eggs/*

[coverage:report]
exclude_lines =
	pragma: no cover
	def __str__
	der __repr__
	if settings.DEBUG
	NOQA
	NotImplementedError

[potypo]
default_language = en_US
locales_dir = pretix/locale
no_fail =
    ar
    cs
    da
    es
    fr
    it
    nl
    nl_BE
    pt_BR
wl_dir = pretix/locale
edgecase_words =
    add-ons
    add-on's
    same-origin"-requests
    MT940
    MT940-Format
    pre-selected
    support@pretix.eu
    pretix.eu
    pretix.eu-Blog
    pretix.eu-Server
    Prüf-Ergebnisse
    Transaktions-ID
    translate.pretix.eu
    AGPLv3
    4th
	214th
	INV-001
	INV-00001
    to-do
    To-Do
    Use-Case
    Use-Cases
phrases =
    ticketing powered by
    powered by
    Stripe Connect
chunkers = enchant.tokenize.HTMLChunker
filters = PythonFormatFilter,enchant.tokenize.URLFilter,HTMLFilter
