Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ mod testgen_hs {
return;
}

let testgen_lib_version = "10.4.1.0";
let testgen_lib_version = "10.4.1.1";

let suffix = if target_os == "windows" {
".zip"
Expand Down
8 changes: 4 additions & 4 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
flake-compat.flake = false;
cardano-node.url = "github:IntersectMBO/cardano-node/10.4.1";
cardano-node.flake = false; # otherwise, +2k dependencies we don’t really use
testgen-hs.url = "github:input-output-hk/testgen-hs/10.4.1.0"; # make sure it follows cardano-node
testgen-hs.url = "github:input-output-hk/testgen-hs/10.4.1.1"; # make sure it follows cardano-node
testgen-hs.flake = false; # otherwise, +2k dependencies we don’t really use
devshell.url = "github:numtide/devshell";
devshell.inputs.nixpkgs.follows = "nixpkgs";
Expand Down
4 changes: 4 additions & 0 deletions nix/devshells.nix
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ in {
name = "TESTGEN_HS_PATH";
value = lib.getExe internal.testgen-hs;
}
{
name = "RUST_SRC_PATH";
value = "${internal.rustPackages.rust-src}/lib/rustlib/src/rust/library";
}
]
++ lib.optionals pkgs.stdenv.isDarwin [
{
Expand Down
127 changes: 0 additions & 127 deletions nix/internal/testgen-hs--enable-aarch64-linux.diff

This file was deleted.

19 changes: 1 addition & 18 deletions nix/internal/unix.nix
Original file line number Diff line number Diff line change
Expand Up @@ -217,24 +217,7 @@ in
done
'';

testgen-hs-flake = let
unpatched = inputs.testgen-hs;
in
(import inputs.flake-compat {
src =
if targetSystem != "aarch64-linux"
then unpatched
else {
outPath = toString (pkgs.runCommand "source" {} ''
cp -r ${unpatched} $out
chmod -R +w $out
cd $out
patch -p1 -i ${./testgen-hs--enable-aarch64-linux.diff}
'');
inherit (unpatched) rev shortRev lastModified lastModifiedDate;
};
})
.defaultNix;
testgen-hs-flake = (import inputs.flake-compat {src = inputs.testgen-hs;}).defaultNix;

testgen-hs = testgen-hs-flake.packages.${targetSystem}.default;

Expand Down
12 changes: 6 additions & 6 deletions src/api/utils/txs/evaluate/model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ pub struct TxEvaluationRequest {
}

pub type AdditionalUtxoSet = Vec<(TxIn, TxOut)>;
#[derive(Deserialize)]
#[derive(Deserialize, Debug)]
pub struct TxIn {
#[serde(rename = "txId")]
pub tx_id: String,
pub index: u64,
}
#[derive(Deserialize)]
#[derive(Deserialize, Debug)]
pub struct TxOut {
pub address: String,
pub value: Value,
Expand Down Expand Up @@ -77,21 +77,21 @@ impl From<ScriptNative> for NativeScript {
}
}

#[derive(Deserialize)]
#[derive(Deserialize, Debug)]
#[serde(untagged)]
pub enum Datum {
String(String),
Map(HashMap<String, String>),
}

#[derive(Deserialize)]
#[derive(Deserialize, Debug)]
pub struct Value {
pub coins: u64,
pub assets: Option<HashMap<String, u64>>, // asset name and number. Asset number can be negative when burning assets but this behaviour changed in Conway. Now it can be only PositiveCoin
}

// This is originally missing PlutusV3 since blockfrost uses Ogmios v5.6 which has slightly different data structure
#[derive(Deserialize)]
#[derive(Deserialize, Debug)]
//#[serde(untagged)]
pub enum Script {
#[serde(rename = "plutus:v1")]
Expand All @@ -104,7 +104,7 @@ pub enum Script {
Native(ScriptNative),
}

#[derive(Deserialize)]
#[derive(Deserialize, Debug)]
pub enum ScriptNative {
#[serde(rename = "any")]
Any(Vec<ScriptNative>),
Expand Down
3 changes: 3 additions & 0 deletions src/cbor/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ use std::process::Command;
#[cfg(not(feature = "tarpaulin"))]
mod random;
#[cfg(not(feature = "tarpaulin"))]
mod random_eval_tx;
#[cfg(not(feature = "tarpaulin"))]
mod specific;

#[derive(Deserialize, Debug)]
Expand All @@ -30,6 +32,7 @@ pub struct CborTestSeed {
#[derive(Debug, Clone, Copy)]
#[allow(non_camel_case_types, dead_code)]
pub enum CaseType {
Tx_Conway,
ApplyTxErr_Byron,
ApplyTxErr_Shelley,
ApplyTxErr_Allegra,
Expand Down
Loading
Loading