Warning: [0001]
    ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:30:4 ]
    │
 30 │ fn is_decodable_label(b : ImageFormat) -> String {
    │    ─────────┬────────  
    │             ╰────────── Warning (unused_value): Unused function 'is_decodable_label'
────╯
Warning: [0001]
    ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:39:4 ]
    │
 39 │ fn is_encodable_label(b : ImageFormat) -> String {
    │    ─────────┬────────  
    │             ╰────────── Warning (unused_value): Unused function 'is_encodable_label'
────╯
Error: [4069]
Warning: [0020]
    ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:78:37 ]
    │
 78 │       check("PNG is NOT encodable", not(f.is_encodable()))
    │                                     ─┬─  
    │                                      ╰─── Warning (deprecated): Use !expr instead
────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:100:30 ]
     │
 100 │   let img = Image::new(1, 1, PixelFormat::RGB8, Bytes::from_array([b'\xFF', b'\x00', b'\x00']))
     │                              ────────┬────────  
     │                                      ╰────────── Cannot create values of the read-only type: RGB8.
─────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:101:15 ]
     │
 101 │   for fmt in [ImageFormat::PNG, ImageFormat::GIF, ImageFormat::JPEG, ImageFormat::TGA] {
     │               ────────┬───────  
     │                       ╰───────── Cannot create values of the read-only type: PNG.
─────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:101:33 ]
     │
 101 │   for fmt in [ImageFormat::PNG, ImageFormat::GIF, ImageFormat::JPEG, ImageFormat::TGA] {
     │                                 ────────┬───────  
     │                                         ╰───────── Cannot create values of the read-only type: GIF.
─────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:101:51 ]
     │
 101 │   for fmt in [ImageFormat::PNG, ImageFormat::GIF, ImageFormat::JPEG, ImageFormat::TGA] {
     │                                                   ────────┬────────  
     │                                                           ╰────────── Cannot create values of the read-only type: JPEG.
─────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:101:70 ]
     │
 101 │   for fmt in [ImageFormat::PNG, ImageFormat::GIF, ImageFormat::JPEG, ImageFormat::TGA] {
     │                                                                      ────────┬───────  
     │                                                                              ╰───────── Cannot create values of the read-only type: TGA.
─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:103:44 ]
     │
 103 │     let got : Result[Bytes, DecodeError] = try? encode(img, fmt)
     │                                            ──┬─  
     │                                              ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Error: [4122]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:112:12 ]
     │
 112 │   let bm = encode(img, ImageFormat::BMP)
     │            ──────────────┬──────────────  
     │                          ╰──────────────── Function with error is not allowed in `fn main`. You could use `fn main raise` to declare the main function with an error type.
─────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:112:24 ]
     │
 112 │   let bm = encode(img, ImageFormat::BMP)
     │                        ────────┬───────  
     │                                ╰───────── Cannot create values of the read-only type: BMP.
─────╯
Error: [4122]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:120:12 ]
     │
 120 │   let qm = encode(img, ImageFormat::QOI)
     │            ──────────────┬──────────────  
     │                          ╰──────────────── Function with error is not allowed in `fn main`. You could use `fn main raise` to declare the main function with an error type.
─────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:120:24 ]
     │
 120 │   let qm = encode(img, ImageFormat::QOI)
     │                        ────────┬───────  
     │                                ╰───────── Cannot create values of the read-only type: QOI.
─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:129:44 ]
     │
 129 │   let bogus : Result[Image, DecodeError] = try? decode(b"definitely not an image")
     │                                            ──┬─  
     │                                              ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:137:50 ]
     │
 137 │   let corrupt_bmp : Result[Image, DecodeError] = try? decode(b"BM\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00")
     │                                                  ──┬─  
     │                                                    ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Error: [4018]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:147:61 ]
     │
 147 │   check("image_dimensions(PNG) returns (16, 11, PNG)", dims == (16, 11, ImageFormat::PNG))
     │                                                             ─┬  
     │                                                              ╰── Type @riantr/moonbit_image.ImageFormat does not implement trait Eq: no `impl` is defined
  note: this constraint is required by `impl` of Eq for type Tuple3 at moonbitlang\core\builtin\tuple_eq.mbt:24:1
─────╯
Error: [4036]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\blackbox_test.mbt:147:73 ]
     │
 147 │   check("image_dimensions(PNG) returns (16, 11, PNG)", dims == (16, 11, ImageFormat::PNG))
     │                                                                         ────────┬───────  
     │                                                                                 ╰───────── Cannot create values of the read-only type: PNG.
─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\lib.mbt:149:14 ]
     │
 149 │       match (try? decode_by_format_raw(data, format)) {
     │              ──┬─  
     │                ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\lib.mbt:164:10 ]
     │
 164 │   match (try? decode_by_format_raw(data, format)) {
     │          ──┬─  
     │            ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\lib.mbt:199:14 ]
     │
 199 │       match (try? image_dimensions_raw(data, format)) {
     │              ──┬─  
     │                ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\lib.mbt:329:14 ]
     │
 329 │       match (try? encode_bmp(img)) {
     │              ──┬─  
     │                ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Warning: [0020]
     ╭─[ D:\src\MiniMax\Projects\MoonBit\moonbit-labeler\staging-moonbit-image\lib.mbt:334:14 ]
     │
 334 │       match (try? encode_qoi(img)) {
     │              ──┬─  
     │                ╰─── Warning (deprecated): `try?` is deprecated.

  Do not mechanically replace this with `try expr |> Ok catch { e => Err(e) }`; that still creates a local `Result` wrapper and usually misses theintended migration.
  Only create `Ok`/`Err` when the `Result` value must escape this local expression: stored, returned, passed to a Result-taking API, or kept for later comparison as data.

  Migration in inspect-based tests:
  1. If the expected behavior is success, remove `try?` and run the raising expression directly:

    inspect(expr, content=...)

  2. If the expected behavior is an error, replace `try?` with `try ... catch ... noraise`:

    try expr catch {
      e => inspect(e, content=...)
    } noraise {
      _ => fail("expected expr to raise")
    }

─────╯
Failed with 11 warnings, 12 errors.
Error: failed to run check for target Native

Caused by:
    failed when checking project
