Skip to content

Crash when parsing datum #1359

Description

@Quantumplation

What Git revision are you using?

Version: v1.1.21+unknown

What operating system are you using, and which version?

  • Linux / Ubuntu
  • Linux / Other
  • macOS
  • Windows

Describe what the problem is?

aiken::fatal::error
Whoops! You found a bug in the Aiken compiler.

Please report this error at https://github.com/aiken-lang/aiken/issues/new.
In your bug report please provide the information below and if possible the code
that produced it.

Operating System: linux
Architecture: x86_64
Version: v1.1.21+unknown

crates/uplc/src/machine/runtime.rs:879:43

   called `Result::unwrap()` on an `Err` value: TryFromBigIntError { original: () }

When trying to run this test:

fn amaru() -> OrderDatum {
  let bytes = #"d818590157d8799fd8799f581c64f35d26b237ad58e099041bc14c687ea7fdc58969d7d5b66e2540efffd87c9f029fd8799f581c7095faf3d48d582fbae8b3f2e726670d7a35e2400c783d992bbdeffbffd8799f581cf3ab64b0f97dcf0f91232754603283df5d75a1201337432c04d23e2effd8799f581c8bd03209d227956aaf9670751e0aa2057b51c1537a43f155b24fb1c1ffd8799f581c97e0f6d6c86dbebf15cc8fdf0981f939b2f2b70928a46511edd49df2ffffff1a00138800d8799fd8799fd87a9f581c5fbb3e5295c211c7595ddd23db2e0a0833131e0681cc7ea800f85d34ffd8799fd8799fd87a9f581c5fbb3e5295c211c7595ddd23db2e0a0833131e0681cc7ea800f85d34ffffffffd87980ffd87a9f9f40401b0000000b9567bc06ff9f581cc48cbb3d5e57ed56e276bc45f99ab39abe94e6cd7ac39fb402da47ad480014df105553444d1b00000001bf08eb00ffffd87980ff"
  expect Some(datum) = cbor.deserialise(bytes)
  expect datum: OrderDatum = datum
  datum
}

test amaru_test() {
  trace amaru()
  True
}

What should be the expected behavior?

Not crash

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Fields

    No fields configured for Bug.

    Projects

    Status
    🔨 Todo

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions