diff --git a/.github/actions/install-nomos-circuits-compatibility/action.yml b/.github/actions/install-nomos-circuits-compatibility/action.yml deleted file mode 100644 index 74e314cd..00000000 --- a/.github/actions/install-nomos-circuits-compatibility/action.yml +++ /dev/null @@ -1,10 +0,0 @@ -name: Install Nomos circuits -description: Installs Nomos circuits for compatibility -runs: - using: "composite" - steps: - - name: Install risc0 - run: | - chmod 777 /home/runner/work/lssa/lssa/ci_scripts/setup-nomos-circuits.sh - /home/runner/work/lssa/lssa/ci_scripts/setup-nomos-circuits.sh - shell: bash diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2a90d2ec..21c73d29 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -70,8 +70,6 @@ jobs: - uses: ./.github/actions/install-risc0 - - uses: ./.github/actions/install-nomos-circuits-compatibility - - name: Install active toolchain run: rustup install @@ -97,8 +95,6 @@ jobs: - uses: ./.github/actions/install-risc0 - - uses: ./.github/actions/install-nomos-circuits-compatibility - - name: Install active toolchain run: rustup install @@ -122,8 +118,6 @@ jobs: - uses: ./.github/actions/install-risc0 - - uses: ./.github/actions/install-nomos-circuits-compatibility - - name: Install active toolchain run: rustup install @@ -145,8 +139,6 @@ jobs: - uses: ./.github/actions/install-risc0 - - uses: ./.github/actions/install-nomos-circuits-compatibility - - name: Install active toolchain run: rustup install @@ -169,8 +161,6 @@ jobs: - uses: ./.github/actions/install-risc0 - - uses: ./.github/actions/install-nomos-circuits-compatibility - - name: Install just run: cargo install just diff --git a/Cargo.lock b/Cargo.lock index df1c9ca6..92f29eff 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -367,15 +367,6 @@ version = "1.0.100" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a23eb6b1614318a8071c9b2521f36b424b2c83db5eb3a0fead4a6c0809af6e61" -[[package]] -name = "archery" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70e0a5f99dfebb87bb342d0f53bb92c81842e100bbb915223e38349580e5441d" -dependencies = [ - "triomphe", -] - [[package]] name = "ark-bls12-381" version = "0.4.0" @@ -1107,7 +1098,7 @@ dependencies = [ [[package]] name = "broadcast-service" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "async-trait", "derivative", @@ -1276,35 +1267,6 @@ dependencies = [ "cpufeatures", ] -[[package]] -name = "chain-service" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "async-trait", - "broadcast-service", - "bytes", - "cryptarchia-engine", - "cryptarchia-sync", - "futures", - "groth16", - "nomos-core", - "nomos-ledger", - "nomos-network", - "nomos-storage", - "nomos-utils", - "num-bigint", - "overwatch", - "serde", - "serde_with", - "services-utils", - "strum", - "thiserror 1.0.69", - "tokio", - "tracing", - "tracing-futures", -] - [[package]] name = "chrono" version = "0.4.42" @@ -1332,7 +1294,7 @@ dependencies = [ [[package]] name = "circuits-prover" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "circuits-utils", "tempfile", @@ -1341,7 +1303,7 @@ dependencies = [ [[package]] name = "circuits-utils" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "dirs", ] @@ -1433,10 +1395,9 @@ dependencies = [ [[package]] name = "common-http-client" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "broadcast-service", - "chain-service", "futures", "nomos-core", "nomos-da-messages", @@ -1491,15 +1452,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" -[[package]] -name = "convert_case" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baaaa0ecca5b51987b9423ccdc971514dd8b0bb7b4060b983d3664dad3f1f89f" -dependencies = [ - "unicode-segmentation", -] - [[package]] name = "convert_case" version = "0.10.0" @@ -1578,7 +1530,7 @@ checksum = "460fbee9c2c2f33933d720630a6a0bac33ba7053db5344fac858d4b8952d77d5" [[package]] name = "cryptarchia-engine" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "cfg_eval", "nomos-utils", @@ -1589,23 +1541,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "cryptarchia-sync" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "bytes", - "cryptarchia-engine", - "futures", - "nomos-core", - "rand 0.8.5", - "serde", - "serde_with", - "thiserror 1.0.69", - "tokio", - "tracing", -] - [[package]] name = "crypto-bigint" version = "0.5.5" @@ -2409,7 +2344,7 @@ dependencies = [ [[package]] name = "groth16" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "ark-bn254 0.4.0", "ark-ec 0.4.2", @@ -3082,7 +3017,7 @@ dependencies = [ [[package]] name = "key-management-system-keys" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "async-trait", "bytes", @@ -3107,7 +3042,7 @@ dependencies = [ [[package]] name = "key-management-system-macros" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "proc-macro2", "quote", @@ -3138,7 +3073,7 @@ dependencies = [ [[package]] name = "kzgrs" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "ark-bls12-381", "ark-ec 0.4.2", @@ -3157,7 +3092,7 @@ dependencies = [ [[package]] name = "kzgrs-backend" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "ark-ff 0.4.2", "ark-poly 0.4.2", @@ -3239,7 +3174,6 @@ dependencies = [ "bs58", "hkdf", "multihash", - "serde", "sha2", "thiserror 2.0.17", "tracing", @@ -3442,18 +3376,6 @@ dependencies = [ "windows-sys 0.61.2", ] -[[package]] -name = "mmr" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "ark-ff 0.4.2", - "groth16", - "poseidon2", - "rpds", - "serde", -] - [[package]] name = "multiaddr" version = "0.18.2" @@ -3563,7 +3485,7 @@ dependencies = [ [[package]] name = "nomos-blend-crypto" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "blake2", "groth16", @@ -3578,32 +3500,10 @@ dependencies = [ "zeroize", ] -[[package]] -name = "nomos-blend-message" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "blake2", - "derivative", - "groth16", - "itertools 0.14.0", - "key-management-system-keys", - "nomos-blend-crypto", - "nomos-blend-proofs", - "nomos-core", - "nomos-utils", - "serde", - "serde-big-array", - "serde_with", - "thiserror 1.0.69", - "tracing", - "zeroize", -] - [[package]] name = "nomos-blend-proofs" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "ed25519-dalek", "generic-array 1.3.5", @@ -3618,7 +3518,7 @@ dependencies = [ [[package]] name = "nomos-core" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "ark-ff 0.4.2", "async-trait", @@ -3648,7 +3548,7 @@ dependencies = [ [[package]] name = "nomos-da-messages" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "blake2", "futures", @@ -3661,7 +3561,7 @@ dependencies = [ [[package]] name = "nomos-http-api-common" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "axum", "governor", @@ -3673,68 +3573,10 @@ dependencies = [ "tower_governor", ] -[[package]] -name = "nomos-ledger" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "cryptarchia-engine", - "groth16", - "key-management-system-keys", - "mmr", - "nomos-blend-crypto", - "nomos-blend-message", - "nomos-blend-proofs", - "nomos-core", - "nomos-utils", - "num-bigint", - "rand 0.8.5", - "rpds", - "serde", - "thiserror 1.0.69", - "tracing", - "utxotree", -] - -[[package]] -name = "nomos-network" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "async-trait", - "cryptarchia-sync", - "futures", - "nomos-core", - "overwatch", - "serde", - "tokio", - "tokio-stream", - "tracing", -] - -[[package]] -name = "nomos-storage" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "async-trait", - "bytes", - "cryptarchia-engine", - "futures", - "libp2p-identity", - "multiaddr", - "nomos-core", - "overwatch", - "serde", - "thiserror 1.0.69", - "tokio", - "tracing", -] - [[package]] name = "nomos-utils" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "async-trait", "blake2", @@ -3975,7 +3817,6 @@ source = "git+https://github.com/logos-co/Overwatch?rev=f5a9902#f5a99022f389d65a dependencies = [ "async-trait", "futures", - "overwatch-derive", "thiserror 2.0.17", "tokio", "tokio-stream", @@ -3983,18 +3824,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "overwatch-derive" -version = "0.1.0" -source = "git+https://github.com/logos-co/Overwatch?rev=f5a9902#f5a99022f389d65adbd55e51f1e3f9eead62432a" -dependencies = [ - "convert_case 0.8.0", - "proc-macro-error2", - "proc-macro2", - "quote", - "syn 2.0.111", -] - [[package]] name = "parking_lot" version = "0.12.5" @@ -4101,7 +3930,7 @@ checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c" [[package]] name = "pol" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "circuits-prover", "circuits-utils", @@ -4129,7 +3958,7 @@ dependencies = [ [[package]] name = "poq" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "circuits-prover", "circuits-utils", @@ -4151,7 +3980,7 @@ checksum = "f84267b20a16ea918e43c6a88433c2d54fa145c92a811b5b047ccbe153674483" [[package]] name = "poseidon2" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "ark-bn254 0.4.0", "ark-ff 0.4.2", @@ -4204,28 +4033,6 @@ dependencies = [ "toml_edit 0.23.10+spec-1.0.0", ] -[[package]] -name = "proc-macro-error-attr2" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96de42df36bb9bba5542fe9f1a054b8cc87e172759a1868aa05c1f3acc89dfc5" -dependencies = [ - "proc-macro2", - "quote", -] - -[[package]] -name = "proc-macro-error2" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ec05c52be0a07b08061f7dd003e7d7092e0472bc731b4af7bb1ef876109802" -dependencies = [ - "proc-macro-error-attr2", - "proc-macro2", - "quote", - "syn 2.0.111", -] - [[package]] name = "proc-macro2" version = "1.0.103" @@ -4848,16 +4655,6 @@ dependencies = [ "librocksdb-sys", ] -[[package]] -name = "rpds" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e75f485e819d4d3015e6c0d55d02a4fd3db47c1993d9e603e0361fba2bffb34" -dependencies = [ - "archery", - "serde", -] - [[package]] name = "rrs-lib" version = "0.1.0" @@ -5200,15 +4997,6 @@ dependencies = [ "serde_derive", ] -[[package]] -name = "serde-big-array" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11fc7cc2c76d73e0f27ee52abbd64eec84d46f370c88371120433196934e4b7f" -dependencies = [ - "serde", -] - [[package]] name = "serde_core" version = "1.0.228" @@ -5315,21 +5103,6 @@ dependencies = [ "serde", ] -[[package]] -name = "services-utils" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "async-trait", - "futures", - "log", - "overwatch", - "serde", - "serde_json", - "thiserror 1.0.69", - "tracing", -] - [[package]] name = "sha1" version = "0.10.6" @@ -5973,16 +5746,6 @@ dependencies = [ "valuable", ] -[[package]] -name = "tracing-futures" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97d095ae15e245a057c8e8451bab9b3ee1e1f68e9ba2b4fbc18d0ac5237835f2" -dependencies = [ - "pin-project", - "tracing", -] - [[package]] name = "tracing-subscriber" version = "0.2.25" @@ -5992,12 +5755,6 @@ dependencies = [ "tracing-core", ] -[[package]] -name = "triomphe" -version = "0.1.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd69c5aa8f924c7519d6372789a74eac5b94fb0f8fcf0d4a97eb0bfc3e785f39" - [[package]] name = "try-lock" version = "0.2.5" @@ -6101,20 +5858,6 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" -[[package]] -name = "utxotree" -version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" -dependencies = [ - "ark-ff 0.4.2", - "groth16", - "num-bigint", - "poseidon2", - "rpds", - "serde", - "thiserror 1.0.69", -] - [[package]] name = "valuable" version = "0.1.1" @@ -6561,7 +6304,7 @@ checksum = "f17a85883d4e6d00e8a97c586de764dabcc06133f7f1d55dce5cdc070ad7fe59" [[package]] name = "witness-generator" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "circuits-utils", "tempfile", @@ -6716,7 +6459,7 @@ dependencies = [ [[package]] name = "zksign" version = "0.1.0" -source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=marbella-offsite-2025-12#b47525f893353b0441a34a62b87c85ad27fb8519" +source = "git+https://github.com/logos-blockchain/logos-blockchain.git?branch=feat-skip-zk-build#fde542bb8398189fe5e9bad688a527618261f63d" dependencies = [ "circuits-prover", "circuits-utils", diff --git a/Cargo.toml b/Cargo.toml index 35d0a408..aa9da563 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -79,7 +79,7 @@ base58 = "0.2.0" itertools = "0.14.0" url = "2.5.4" -common-http-client = { git = "https://github.com/logos-blockchain/logos-blockchain.git", branch = "marbella-offsite-2025-12" } +common-http-client = { git = "https://github.com/logos-blockchain/logos-blockchain.git", branch = "feat-skip-zk-build" } rocksdb = { version = "0.24.0", default-features = false, features = [ "snappy", diff --git a/ci_scripts/deploy.sh b/ci_scripts/deploy.sh index da23c4ac..e84cac72 100644 --- a/ci_scripts/deploy.sh +++ b/ci_scripts/deploy.sh @@ -56,10 +56,6 @@ else git checkout main fi -# Install Nomos circuits for compatibility -chmod 777 /ci_scripts/setup-nomos-circuits.sh -/ci_scripts/setup-nomos-circuits.sh - # Build sequencer_runner and wallet in release mode echo "Building sequencer_runner" # That could be just `cargo build --release --bin sequencer_runner --bin wallet` diff --git a/ci_scripts/setup-nomos-circuits.sh b/ci_scripts/setup-nomos-circuits.sh deleted file mode 100644 index 151c42a4..00000000 --- a/ci_scripts/setup-nomos-circuits.sh +++ /dev/null @@ -1,203 +0,0 @@ -#!/bin/bash -# -# Setup script for nomos-circuits -# -# Usage: ./setup-nomos-circuits.sh [VERSION] [INSTALL_DIR] -# -# Arguments: -# VERSION - Optional. Version to install (default: v0.3.1) -# INSTALL_DIR - Optional. Installation directory (default: $HOME/.nomos-circuits) -# -# Examples: -# ./setup-nomos-circuits.sh # Install default version to default location -# ./setup-nomos-circuits.sh v0.2.0 # Install specific version to default location -# ./setup-nomos-circuits.sh v0.2.0 /opt/circuits # Install to custom location - -# LSSA: needed for compatibility - -set -e - -# Default values -VERSION="${1:-v0.3.1}" -DEFAULT_INSTALL_DIR="$HOME/.nomos-circuits" -INSTALL_DIR="${2:-$DEFAULT_INSTALL_DIR}" -REPO="logos-co/nomos-circuits" - -# Colors for output -RED='\033[0;31m' -GREEN='\033[0;32m' -YELLOW='\033[1;33m' -BLUE='\033[0;34m' -NC='\033[0m' # No Color - -print_info() { - echo -e "${BLUE}ℹ${NC} $1" -} - -print_success() { - echo -e "${GREEN}✓${NC} $1" -} - -print_warning() { - echo -e "${YELLOW}⚠${NC} $1" -} - -print_error() { - echo -e "${RED}✗${NC} $1" -} - -# Detect OS and architecture -detect_platform() { - local os="" - local arch="" - - # Detect OS - case "$(uname -s)" in - Linux*) os="linux";; - Darwin*) os="macos";; - MINGW*|MSYS*|CYGWIN*) os="windows";; - *) print_error "Unsupported operating system: $(uname -s)"; exit 1;; - esac - - # Detect architecture - case "$(uname -m)" in - x86_64) arch="x86_64";; - aarch64) arch="aarch64";; - arm64) arch="aarch64";; - *) print_error "Unsupported architecture: $(uname -m)"; exit 1;; - esac - - echo "${os}-${arch}" -} - -# Check if installation directory exists and get confirmation -check_existing_installation() { - if [ -d "$INSTALL_DIR" ]; then - print_warning "Installation directory already exists: $INSTALL_DIR" - - # Check if it has a VERSION file - if [ -f "$INSTALL_DIR/VERSION" ]; then - local current_version=$(cat "$INSTALL_DIR/VERSION") - print_info "Currently installed version: $current_version" - fi - - # In non-interactive environments (CI), automatically overwrite - if [ ! -t 0 ]; then - print_info "Non-interactive environment detected, automatically overwriting..." - else - # Interactive environment - ask for confirmation - echo - read -p "Do you want to overwrite it? (y/N): " -n 1 -r - echo - if [[ ! $REPLY =~ ^[Yy]$ ]]; then - print_info "Installation cancelled." - exit 0 - fi - fi - - print_info "Removing existing installation..." - rm -rf "$INSTALL_DIR" - fi -} - -# Download and extract the release -download_release() { - local platform="$1" - local artifact="nomos-circuits-${VERSION}-${platform}.tar.gz" - local url="https://github.com/${REPO}/releases/download/${VERSION}/${artifact}" - local temp_dir=$(mktemp -d) - - print_info "Downloading nomos-circuits ${VERSION} for ${platform}..." - print_info "URL: $url" - - # Build curl command with optional authentication - local curl_cmd="curl -L" - if [ -n "$GITHUB_TOKEN" ]; then - curl_cmd="$curl_cmd --header 'authorization: Bearer ${GITHUB_TOKEN}'" - fi - curl_cmd="$curl_cmd -o ${temp_dir}/${artifact} $url" - - if ! eval "$curl_cmd"; then - print_error "Failed to download release artifact" - print_error "Please check that version ${VERSION} exists for platform ${platform}" - print_error "Available releases: https://github.com/${REPO}/releases" - rm -rf "$temp_dir" - exit 1 - fi - - print_success "Download complete" - - print_info "Extracting to ${INSTALL_DIR}..." - mkdir -p "$INSTALL_DIR" - - if ! tar -xzf "${temp_dir}/${artifact}" -C "$INSTALL_DIR" --strip-components=1; then - print_error "Failed to extract archive" - rm -rf "$temp_dir" - exit 1 - fi - - rm -rf "$temp_dir" - print_success "Extraction complete" -} - -# Handle macOS code signing/quarantine issues -handle_macos_quarantine() { - print_info "macOS detected: Removing quarantine attributes from executables..." - - # Remove quarantine attribute from all executable files - if find "$INSTALL_DIR" -type f -perm +111 -exec xattr -d com.apple.quarantine {} \; 2>/dev/null; then - print_success "Quarantine attributes removed" - else - print_warning "Could not remove quarantine attributes (they may not exist)" - fi -} - -# Main installation process -main() { - print_info "Setting up nomos-circuits ${VERSION}" - print_info "Installation directory: $INSTALL_DIR" - echo - - # Detect platform - local platform=$(detect_platform) - print_info "Detected platform: $platform" - - # Check existing installation - check_existing_installation - - # Download and extract - download_release "$platform" - - # Handle macOS quarantine if needed - if [[ "$platform" == macos-* ]]; then - echo - handle_macos_quarantine - fi - - echo - print_success "Installation complete!" - echo - print_info "nomos-circuits ${VERSION} is now installed at: $INSTALL_DIR" - print_info "The following circuits are available:" - - # Discover circuits by finding directories that contain a witness_generator - for dir in "$INSTALL_DIR"/*/; do - if [ -d "$dir" ]; then - local circuit_name=$(basename "$dir") - if [ -f "$dir/witness_generator" ]; then - echo " • $circuit_name" - fi - fi - done - - # Only show export instructions if not using the default location - if [ "$INSTALL_DIR" != "$DEFAULT_INSTALL_DIR" ]; then - echo - print_info "Since you're using a custom installation directory, set the environment variable:" - print_info " export NOMOS_CIRCUITS=$INSTALL_DIR" - echo - fi -} - -# Run main -main diff --git a/sequencer_runner/Dockerfile b/sequencer_runner/Dockerfile index b8b79b59..3b2153c3 100644 --- a/sequencer_runner/Dockerfile +++ b/sequencer_runner/Dockerfile @@ -9,10 +9,6 @@ RUN apt-get update && apt-get install -y \ clang \ && rm -rf /var/lib/apt/lists/* -# Nomos circuits for compatibility -RUN chmod 777 /ci_scripts/setup-nomos-circuits.sh - && /ci_scripts/setup-nomos-circuits.sh - WORKDIR /sequencer_runner # Planner stage - generates dependency recipe