content: [tool.poetry]
  name = "firefox-translations"
  version = "0.1.0"
  description = ""
  authors = []
  readme = "README.md"
  
  [tool.poetry.dependencies]
  python = "^3.10"
  # pip-compile --generate-hashes doesn't work with pip v25.1: https://github.com/jazzband/pip-tools/issues/2176
  pip = "<25.3"
  pip-tools = "^7.3.0"
  zstandard = "^0.22.0"
  # https://github.com/mozilla/translations/issues/689
  numpy = "<2"
  
  [tool.poetry.group.pyright.dependencies]
  pyright = "^1.1.390"
  
  [tool.poetry.group.black.dependencies]
  black = "^23.7.0"
  
  [tool.poetry.group.lint.dependencies]
  ruff = "^0.1.13"
  translations_parser = {path="./tracking/", develop=true}
  
  [tool.poetry.group.opuscleaner.dependencies]
  opuscleaner = "0.6.3"
  sacremoses = "0.1.1"
  opusfilter = "3.2.0"
  
  [tool.poetry.group.taskcluster.dependencies]
  taskcluster = "^56.0.3"
  
  [tool.poetry.group.tensorboard.dependencies]
  marian-tensorboard = "^0.2.1"
  
  # This install group is for running local utilities.
  [tool.poetry.group.utils.dependencies]
  sacrebleu = {extras = ["ja", "ko"], version = "2.4.2"}
  mtdata="0.4.1"
  requests="^2.26.0"
  humanize = "^4.9.0"
  blessed = "^1.20.0"
  huggingface-hub = "^0.20.3"
  websocket_client ="^1.8.0"
  PyGithub="2.4.0"
  pyperclip="1.9.0"
  ruamel-yaml = "^0.18.6"
  taskcluster = "^56.0.3"
  # This package is specifically pinned to ensure the version stays in sync
  # between the two instances of it in this file, and the decision image version
  # pin in `.taskcluster.yml`. All three should be adjusted at the same time
  # to ensure that decision tasks & tests use the same version of taskgraph.
  taskcluster-taskgraph = "15.1.3"
  mozilla-taskgraph = "3.4.1"
  kinto-http="11.7.1"
  # Use an outdated version of pydantic due to dependency requirements conflict.
  pydantic="1.10.19"
  OpenCC = "1.1.9"
  hanzidentifier = "1.2.0"
  psutil= "6.0.0"
  
  [tool.poetry.group.utils-docker.dependencies]
  PyICU = "2.15.2"
  
  # This install group is for running tests. Note that any dependencies in the
  # pipeline are installed separately through the run_task test abstraction. This
  # list is only for things imported directly in the tests.
  mkdocs = "^1.6.1"
  [tool.poetry.group.tests.dependencies]
  sacrebleu = {extras = ["ja", "ko"], version = "2.4.2"}
  mtdata="0.4.1"
  requests="^2.26.0"
  pytest="7.4.3"
  opustrainer = "0.5"
  requests-mock = "^1.11.0"
  sh = "^2.0.6"
  zstandard = "^0.22.0"
  translations_parser = {path="./tracking/", develop=true}
  # This package is specifically pinned to ensure the version stays in sync
  # between the two instances of it in this file, and the decision image version
  # pin in `.taskcluster.yml`. All three should be adjusted at the same time
  # to ensure that decision tasks & tests use the same version of taskgraph.
  taskcluster-taskgraph = "15.1.3"
  mozilla-taskgraph = "3.4.1"
  translations_taskgraph = {path="./taskcluster/", develop=true}
  sacremoses = "0.1.1"
  hanzidentifier = "1.2.0"
  OpenCC = "1.1.9"
  PyICU = "2.15.2"
  jsonschema = "^4.23.0"
  
  [tool.black]
  extend-exclude= "/3rd_party"
  line-length = 99
  
  # Match the rules from mozilla-central.
  # https://searchfox.org/mozilla-central/source/pyproject.toml
  [tool.ruff]
  line-length = 99
  # See https://beta.ruff.rs/docs/rules/ for a full list of rules.
  select = [
    "E", "W",    # pycodestyle
    "F",         # pyflakes
    "I",         # isort
    "PL",        # pylint
  ]
  ignore = [
    # These are intentionally ignored.
    "E741",      # ambiguous-variable-name
    "PLR09",     # too-many-return-statements, too-many-branches, too-many-arguments, too-many-statements
    "PLR2004",   # magic-value-comparison
    "PLW0603",   # global-statement
    "I001",      # This is broken, see #614
  
    # These are handled by black.
    "E1", "E4", "E5", "W2", "W5"
  ]
  exclude = [
    "3rd_party"
  ]
  
  [build-system]
  requires = ["poetry-core"]
  build-backend = "poetry.core.masonry.api"
  
  [tool.pytest.ini_options]
  testpaths = ["tests"]
  markers = [
    # Run tests outside of docker:
    #   task test -- -m "not docker_amd64
    "docker_amd64: These tests require the local docker image.",
    # Run only quick tests:
    #   task test -- -m "not slow
    "slow: Tests that run slower"
  ]
  
  [tool.pyright]
  # When adding directories, add the entire subfolder to "include", and then
  # exclude individual files that still need typing. This will make it so that all
  # new files default to being typed.
  include = [
    "utils/**/*",
    "taskcluster/**/*",
    "tests/**/*",
    "pipeline/alignments/align.py",
    "pipeline/data/lang_script.py",
    "pipeline/data/parallel_downloaders.py",
    "pipeline/data/parallel_importer.py",
    "inference/scripts/**/*",
  ]
  exclude = [
    # TODO - Fix the types and remove the files from this list.
  
    "taskcluster/translations_taskgraph/transforms/marian_args.py",
    "taskcluster/translations_taskgraph/transforms/find_upstreams.py",
  
    "tests/test_common_datasets.py",
    "tests/test_cjk.py",
    "tests/test_preflight_check.py",
    "tests/test_split_collect.py",
    "tests/test_tracking_utils.py",
    "tests/test_common_downloads.py",
    "tests/test_spm_vocab.py",
    "tests/test_alignments.py",
    "tests/test_merge_mono.py",
    "tests/test_merge_corpus.py",
    "tests/test_split_corpus.py",
    "tests/fixtures/__init__.py",
    "tests/test_train_taskcluster.py",
    "tests/test_eval.py",
  ]
  # Additional search paths that will be used when searching for modules imported by files.
  extraPaths = [
    ".",
    "./taskcluster",
    "./tracking",
    "./taskcluster/scripts/pipeline"
  ]
  pythonVersion="3.10"
  