[build-system]
requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"

[tool.black]
target-version = ['py39', 'py310', 'py311', 'py312', 'py313']

[tool.cibuildwheel]
build = "cp39* cp310* cp311* cp312* cp313*"
test-command = "python -m tornado.test"

[tool.cibuildwheel.macos]
archs = "x86_64 universal2"

[tool.cibuildwheel.windows]
archs = "AMD64 x86 ARM64"
# TODO: figure out what's going on with these occasional log messages.
test-command = "python -m tornado.test --fail-if-logs=false"
# Arm builds are cross-compiled and cannot be tested on the x86 host
test-skip = "*-win_arm64"

[tool.cibuildwheel.linux]
# This configuration has a bug which appears unrelated to Tornado:
# https://github.com/python/cpython/issues/130522
# If the underlying bug is not fixed by the time 3.14 is released,
# we may need to skip that in musllinux_i686 as well.
#
# Note that because we use the stable ABI, the wheels built for
# cp39-musllinux_i686 will still be available for users of 3.13, this just
# means we won't be testing them in this configuration.
test-skip = "cp313-musllinux_i686"
