"""Generate mypy config."""
from __future__ import annotations

import configparser
import io
import os
from pathlib import Path
from typing import Final

from homeassistant.const import REQUIRED_PYTHON_VER

from .model import Config, Integration

# Modules which have type hints which known to be broken.
# If you are an author of component listed here, please fix these errors and
# remove your component from this list to enable type checks.
# Do your best to not add anything new here.
IGNORED_MODULES: Final[list[str]] = [
    "homeassistant.components.blueprint.importer",
    "homeassistant.components.blueprint.models",
    "homeassistant.components.blueprint.websocket_api",
    "homeassistant.components.cloud.client",
    "homeassistant.components.cloud.http_api",
    "homeassistant.components.conversation",
    "homeassistant.components.conversation.default_agent",
    "homeassistant.components.deconz.alarm_control_panel",
    "homeassistant.components.deconz.binary_sensor",
    "homeassistant.components.deconz.climate",
    "homeassistant.components.deconz.cover",
    "homeassistant.components.deconz.fan",
    "homeassistant.components.deconz.light",
    "homeassistant.components.deconz.lock",
    "homeassistant.components.deconz.logbook",
    "homeassistant.components.deconz.number",
    "homeassistant.components.deconz.sensor",
    "homeassistant.components.deconz.siren",
    "homeassistant.components.deconz.switch",
    "homeassistant.components.denonavr.config_flow",
    "homeassistant.components.denonavr.media_player",
    "homeassistant.components.denonavr.receiver",
    "homeassistant.components.evohome",
    "homeassistant.components.evohome.climate",
    "homeassistant.components.evohome.water_heater",
    "homeassistant.components.google_assistant.helpers",
    "homeassistant.components.google_assistant.http",
    "homeassistant.components.google_assistant.report_state",
    "homeassistant.components.google_assistant.trait",
    "homeassistant.components.gree.climate",
    "homeassistant.components.gree.switch",
    "homeassistant.components.harmony",
    "homeassistant.components.harmony.config_flow",
    "homeassistant.components.harmony.data",
    "homeassistant.components.hassio",
    "homeassistant.components.hassio.auth",