{
  "module_name": "sinkronisasi",
  "module_root": "pypos/modules/sinkronisasi",
  "effective_date": "2026-04-13",
  "score": {
    "max": 100,
    "pass_score": 90
  },
  "kpis": [
    {
      "id": "KPI-01",
      "name": "Function Budget",
      "weight": 20
    },
    {
      "id": "KPI-02",
      "name": "Exception Hygiene",
      "weight": 25
    },
    {
      "id": "KPI-03",
      "name": "Error Contract",
      "weight": 20
    },
    {
      "id": "KPI-04",
      "name": "Test Maturity",
      "weight": 25
    },
    {
      "id": "KPI-05",
      "name": "Governance Controls",
      "weight": 5
    },
    {
      "id": "KPI-06",
      "name": "Structural Health",
      "weight": 5
    }
  ],
  "critical_functions": [
    {
      "file_path": "pypos/modules/sinkronisasi/services/export_upload_api_service.py",
      "class_name": "ExportUploadApiService",
      "function_name": "upload_file",
      "max_loc": 240
    },
    {
      "file_path": "pypos/modules/sinkronisasi/services/export_upload_api_service.py",
      "class_name": "ExportUploadApiService",
      "function_name": "fetch_compile_status",
      "max_loc": 260
    },
    {
      "file_path": "pypos/modules/sinkronisasi/services/transaction_export_hotspot_use_case_service.py",
      "class_name": "TransactionExportHotspotUseCaseService",
      "function_name": "normalize_rows_for_export",
      "max_loc": 260
    },
    {
      "file_path": "pypos/modules/sinkronisasi/services/transaction_export_hotspot_use_case_service.py",
      "class_name": "TransactionExportHotspotUseCaseService",
      "function_name": "backfill_transaksi_rows_in_db",
      "max_loc": 320
    },
    {
      "file_path": "pypos/modules/sinkronisasi/services/transaction_export_legacy_rows_builder_service.py",
      "class_name": "TransactionExportLegacyRowsBuilderService",
      "function_name": "build_legacy_return_rows_payload",
      "max_loc": 340
    },
    {
      "file_path": "pypos/modules/sinkronisasi/services/transaction_export_legacy_rows_builder_service.py",
      "class_name": "TransactionExportLegacyRowsBuilderService",
      "function_name": "build_legacy_transaksi_rows",
      "max_loc": 320
    }
  ],
  "exception_hygiene": {
    "baseline_generic_exception": 62,
    "max_allowed_generic_exception": 20,
    "min_reduction_pct": 60
  },
  "error_contract_targets": [
    {
      "file_path": "pypos/modules/sinkronisasi/services/export_upload_api_service.py",
      "required_tokens": [
        "error_code",
        "reason",
        "trace_id"
      ]
    }
  ],
  "test_matrix": {
    "sinkronisasi_core": {
      "files": [
        "tests/test_export_upload_api_service.py",
        "tests/test_export_upload_service.py",
        "tests/test_settlement_direct_service.py"
      ],
      "min_cases": 18
    }
  },
  "governance_checks": [
    {
      "file_path": "pypos/modules/sinkronisasi/services/event_outbox_service.py",
      "required_tokens": [
        "event_outbox",
        "lease_until",
        "purge_sent"
      ]
    }
  ],
  "structural_health": {
    "max_file_loc": 4000,
    "max_files_over_1500": 1,
    "max_service_to_controller_imports": 0,
    "max_model_to_upper_layer_imports": 0
  }
}
