github.com/opentofu/opentofu@v1.7.1/internal/command/testdata/validate-invalid/incorrectmodulename/output.json (about)

     1  {
     2    "format_version": "1.0",
     3    "valid": false,
     4    "error_count": 4,
     5    "warning_count": 0,
     6    "diagnostics": [
     7      {
     8        "severity": "error",
     9        "summary": "Missing required argument",
    10        "detail": "The argument \"source\" is required, but no definition was found.",
    11        "range": {
    12          "filename": "testdata/validate-invalid/incorrectmodulename/main.tf",
    13          "start": {
    14            "line": 1,
    15            "column": 23,
    16            "byte": 22
    17          },
    18          "end": {
    19            "line": 1,
    20            "column": 24,
    21            "byte": 23
    22          }
    23        },
    24        "snippet": {
    25          "context": "module \"super#module\"",
    26          "code": "module \"super#module\" {",
    27          "start_line": 1,
    28          "highlight_start_offset": 22,
    29          "highlight_end_offset": 23,
    30          "values": []
    31        }
    32      },
    33      {
    34        "severity": "error",
    35        "summary": "Invalid module instance name",
    36        "detail": "A name must start with a letter or underscore and may contain only letters, digits, underscores, and dashes.",
    37        "range": {
    38          "filename": "testdata/validate-invalid/incorrectmodulename/main.tf",
    39          "start": {
    40            "line": 1,
    41            "column": 8,
    42            "byte": 7
    43          },
    44          "end": {
    45            "line": 1,
    46            "column": 22,
    47            "byte": 21
    48          }
    49        },
    50        "snippet": {
    51          "context": "module \"super#module\"",
    52          "code": "module \"super#module\" {",
    53          "start_line": 1,
    54          "highlight_start_offset": 7,
    55          "highlight_end_offset": 21,
    56          "values": []
    57        }
    58      },
    59      {
    60        "severity": "error",
    61        "summary": "Variables not allowed",
    62        "detail": "Variables may not be used here.",
    63        "range": {
    64          "filename": "testdata/validate-invalid/incorrectmodulename/main.tf",
    65          "start": {
    66            "line": 5,
    67            "column": 12,
    68            "byte": 55
    69          },
    70          "end": {
    71            "line": 5,
    72            "column": 15,
    73            "byte": 58
    74          }
    75        },
    76        "snippet": {
    77          "context": "module \"super\"",
    78          "code": "  source = var.modulename",
    79          "start_line": 5,
    80          "highlight_start_offset": 11,
    81          "highlight_end_offset": 14,
    82          "values": []
    83        }
    84      },
    85      {
    86        "severity": "error",
    87        "summary": "Unsuitable value type",
    88        "detail": "Unsuitable value: value must be known",
    89        "range": {
    90          "filename": "testdata/validate-invalid/incorrectmodulename/main.tf",
    91          "start": {
    92            "line": 5,
    93            "column": 12,
    94            "byte": 55
    95          },
    96          "end": {
    97            "line": 5,
    98            "column": 26,
    99            "byte": 69
   100          }
   101        },
   102        "snippet": {
   103          "context": "module \"super\"",
   104          "code": "  source = var.modulename",
   105          "start_line": 5,
   106          "highlight_start_offset": 11,
   107          "highlight_end_offset": 25,
   108          "values": []
   109        }
   110      }
   111    ]
   112  }