From 11cc6967f571dcb8d2f2aae5f468e5e92e68c209 Mon Sep 17 00:00:00 2001 From: David Meister Date: Fri, 22 May 2026 10:19:53 +0000 Subject: [PATCH 1/7] feat: migrate raindex to soldeer for dependency management Replaces lib/ submodules (rain.interpreter, rain.deploy, rain.raindex.interface) with soldeer registry deps. Rewrites 146 source files' imports to versioned soldeer paths (rain-interpreter-interface-0.1.0/ src/, raindex-interface-0.1.1/src/, rainlang-0.1.2/src/, etc.). sushixswap-v2 remains a submodule (not on the Soldeer registry). OpenZeppelin pinned at 5.6.1 for raindex source plus 4.8.3 side-by-side for rain-math-fixedpoint-0.1.0's transitive dep. Co-Authored-By: Claude Opus 4.7 --- .gitignore | 2 + foundry.toml | 51 ++++--- remappings.txt | 19 +++ script/BuildAuthoringMeta.sol | 2 +- script/BuildPointers.sol | 10 +- script/Deploy.sol | 14 +- script/DiagOrder.sol | 2 +- soldeer.lock | 125 ++++++++++++++++++ src/abstract/RaindexV6ArbCommon.sol | 2 +- src/abstract/RaindexV6ArbOrderTaker.sol | 16 +-- src/abstract/RaindexV6ArbTaskGated.sol | 2 +- src/abstract/RaindexV6FlashBorrower.sol | 18 +-- src/abstract/RaindexV6FlashLender.sol | 10 +- .../RouteProcessorRaindexV6ArbOrderTaker.sol | 8 +- src/concrete/parser/RaindexV6SubParser.sol | 12 +- src/concrete/raindex/RaindexV6.sol | 48 +++---- src/lib/LibGenericPoolExchange.sol | 6 +- src/lib/LibOrder.sol | 2 +- src/lib/LibRaindex.sol | 8 +- src/lib/LibRaindexArb.sol | 10 +- src/lib/LibRaindexSubParser.sol | 8 +- .../RaindexV6ArbOrderTaker.context.t.sol | 10 +- .../RaindexV6ArbOrderTaker.ierc165.t.sol | 8 +- .../RaindexV6ArbOrderTaker.noOrders.t.sol | 6 +- ...RaindexV6ArbOrderTaker.onTakeOrders2.t.sol | 16 +-- ...xV6ArbOrderTaker.onTakeOrders2Direct.t.sol | 8 +- .../RaindexV6ArbOrderTaker.reentrancy.t.sol | 14 +- ...6ArbTaskGated.checkTaskHashPassMatch.t.sol | 10 +- ...V6ArbTaskGated.checkTaskHashPassZero.t.sol | 10 +- ...6ArbTaskGated.checkTaskHashWrongTask.t.sol | 10 +- .../RaindexV6ArbTaskGated.construct.t.sol | 10 +- ...indexV6ArbTaskGated.iTaskHashNonzero.t.sol | 10 +- .../RaindexV6ArbTaskGated.iTaskHashZero.t.sol | 10 +- .../RaindexV6FlashBorrower.badInitiator.t.sol | 2 +- ...dexV6FlashBorrower.badLenderApproval.t.sol | 16 +-- ...indexV6FlashBorrower.flashLoanFailed.t.sol | 16 +-- .../RaindexV6FlashBorrower.ierc165.t.sol | 4 +- ...ndexV6FlashBorrower.lenderValidation.t.sol | 2 +- ...RaindexV6FlashBorrower.mixedDecimals.t.sol | 16 +-- .../RaindexV6FlashBorrower.noOrders.t.sol | 6 +- ...exV6FlashBorrower.realTokenTransfers.t.sol | 16 +-- .../RaindexV6FlashBorrower.reentrancy.t.sol | 14 +- .../RaindexV6FlashLender.griefRecipient.t.sol | 4 +- .../RaindexV6FlashLender.ierc165.t.sol | 4 +- .../RaindexV6FlashLender.maxFlashLoan.t.sol | 2 +- .../RaindexV6FlashLender.mockSuccess.t.sol | 4 +- .../RaindexV6FlashLender.reentrant.t.sol | 10 +- .../RaindexV6FlashLender.transfers.t.sol | 12 +- ...indexV6ArbOrderTaker.approvalRevoked.t.sol | 2 +- ...aindexV6ArbOrderTaker.exchangeRevert.t.sol | 2 +- ...ricPoolRaindexV6ArbOrderTaker.sender.t.sol | 6 +- ...indexV6FlashBorrower.approvalRevoked.t.sol | 2 +- ...lRaindexV6FlashBorrower.ethForwarded.t.sol | 2 +- ...aindexV6FlashBorrower.exchangeRevert.t.sol | 2 +- ...ricPoolRaindexV6FlashBorrower.sender.t.sol | 6 +- ...RaindexV6ArbOrderTaker.lossyRounding.t.sol | 10 +- ...xV6ArbOrderTaker.nonStandardDecimals.t.sol | 18 +-- ...RaindexV6ArbOrderTaker.onTakeOrders2.t.sol | 16 +-- ...xV6ArbOrderTaker.onTakeOrders2Direct.t.sol | 8 +- ...ocessorRaindexV6ArbOrderTaker.sender.t.sol | 6 +- .../RaindexV6SubParser.describedByMeta.t.sol | 2 +- .../parser/RaindexV6SubParser.ierc165.t.sol | 12 +- .../parser/RaindexV6SubParser.pointers.t.sol | 4 +- .../RaindexV6SubParser.signedContext.t.sol | 8 +- .../parser/RaindexV6SubParser.signers.t.sol | 8 +- .../raindex/RaindexV6.addOrder.entask.t.sol | 4 +- .../raindex/RaindexV6.addOrder.mock.t.sol | 8 +- .../raindex/RaindexV6.addOrder.nonce.t.sol | 2 +- .../raindex/RaindexV6.addOrder.owner.t.sol | 2 +- .../concrete/raindex/RaindexV6.addOrder.t.sol | 4 +- .../raindex/RaindexV6.clear.badStack.t.sol | 4 +- .../raindex/RaindexV6.clear.context.t.sol | 10 +- .../RaindexV6.clear.handleIO.revert.t.sol | 8 +- .../raindex/RaindexV6.clear.mock.t.sol | 22 +-- .../raindex/RaindexV6.clear.sameOwner.t.sol | 4 +- .../raindex/RaindexV6.clear.sameToken.t.sol | 2 +- .../raindex/RaindexV6.clear.zeroAmount.t.sol | 2 +- .../raindex/RaindexV6.deposit.entask.t.sol | 10 +- test/concrete/raindex/RaindexV6.deposit.t.sol | 14 +- test/concrete/raindex/RaindexV6.entask.t.sol | 2 +- .../raindex/RaindexV6.quote.sameToken.t.sol | 4 +- test/concrete/raindex/RaindexV6.quote.t.sol | 12 +- .../RaindexV6.removeOrder.entask.t.sol | 4 +- .../raindex/RaindexV6.removeOrder.mock.t.sol | 2 +- .../raindex/RaindexV6.removeOrder.owner.t.sol | 2 +- .../RaindexV6.takeOrder.badStack.t.sol | 2 +- .../RaindexV6.takeOrder.exceedsMaxRatio.t.sol | 6 +- .../RaindexV6.takeOrder.handleIO.revert.t.sol | 10 +- .../RaindexV6.takeOrder.maximumInput.t.sol | 10 +- .../RaindexV6.takeOrder.maximumOutput.t.sol | 6 +- .../RaindexV6.takeOrder.minimumIO.t.sol | 6 +- .../raindex/RaindexV6.takeOrder.noop.t.sol | 8 +- .../RaindexV6.takeOrder.precision.t.sol | 8 +- .../RaindexV6.takeOrder.sameToken.t.sol | 4 +- .../RaindexV6.takeOrder.tokenMismatch.t.sol | 4 +- .../raindex/RaindexV6.vaultBalance.t.sol | 4 +- .../raindex/RaindexV6.withdraw.entask.t.sol | 16 +-- .../concrete/raindex/RaindexV6.withdraw.t.sol | 14 +- test/lib/LibOrder.t.sol | 2 +- .../LibRaindexArb.finalizeArbNativeGas.t.sol | 2 +- ...ndexArb.finalizeArbOutputTokenProfit.t.sol | 2 +- ...LibRaindexArb.finalizeArbTaskContext.t.sol | 12 +- ...RaindexArb.finalizeArbTokenTransfers.t.sol | 2 +- test/lib/deploy/LibRaindexDeploy.t.sol | 4 +- ...LibRaindexDeployIsStartBlockArbitrum.t.sol | 4 +- .../LibRaindexDeployIsStartBlockBase.t.sol | 4 +- .../LibRaindexDeployIsStartBlockFlare.t.sol | 4 +- .../LibRaindexDeployIsStartBlockPolygon.t.sol | 4 +- ...ibRaindexDeployNetworksJsonAddresses.t.sol | 2 +- ...DeployNetworksJsonStartBlockArbitrum.t.sol | 2 +- ...ndexDeployNetworksJsonStartBlockBase.t.sol | 2 +- ...dexDeployNetworksJsonStartBlockFlare.t.sol | 2 +- ...xDeployNetworksJsonStartBlockPolygon.t.sol | 2 +- test/lib/deploy/LibRaindexDeployProd.t.sol | 4 +- .../LibRaindexDeployStartBlockArbitrum.t.sol | 4 +- .../LibRaindexDeployStartBlockBase.t.sol | 4 +- .../LibRaindexDeployStartBlockFlare.t.sol | 4 +- .../LibRaindexDeployStartBlockPolygon.t.sol | 4 +- .../LibRaindexDeploySubgraphYamlAddress.t.sol | 2 +- .../LibRouteProcessor4CreationCode.t.sol | 2 +- test/util/abstract/ArbTest.sol | 8 +- test/util/abstract/IRaindexV6Stub.sol | 6 +- test/util/abstract/MockRaindexBase.sol | 8 +- .../abstract/RaindexV6ExternalMockTest.sol | 20 +-- .../abstract/RaindexV6ExternalRealTest.sol | 20 +-- test/util/abstract/RaindexV6SelfTest.sol | 2 +- .../RaindexV6SubParserContextTest.sol | 6 +- .../concrete/AllowanceCheckingExchange.sol | 4 +- .../concrete/ChildRaindexV6ArbTaskGated.sol | 2 +- .../util/concrete/FlashLendingMockRaindex.sol | 4 +- test/util/concrete/MaliciousLender.sol | 4 +- test/util/concrete/MaliciousRaindex.sol | 4 +- test/util/concrete/MockExchange.sol | 4 +- test/util/concrete/MockRouteProcessor.sol | 4 +- test/util/concrete/MockToken.sol | 2 +- .../RealisticFlashLendingMockRaindex.sol | 8 +- .../RealisticOrderTakerMockRaindex.sol | 8 +- test/util/concrete/Reenteroor.sol | 6 +- test/util/concrete/ReentrantExchange.sol | 8 +- test/util/concrete/ReentrantMockRaindex.sol | 10 +- test/util/concrete/RevertingExchange.sol | 2 +- test/util/lib/LibEtchRaindex.sol | 2 +- test/util/lib/LibTestAddOrder.sol | 12 +- test/util/lib/LibTestArb.sol | 18 +-- test/util/lib/LibTestFlashBorrowerArb.sol | 18 +-- test/util/lib/LibTestTakeOrder.sol | 16 +-- 146 files changed, 703 insertions(+), 536 deletions(-) create mode 100644 remappings.txt create mode 100644 soldeer.lock diff --git a/.gitignore b/.gitignore index 01a26e9273..c83d6007f4 100644 --- a/.gitignore +++ b/.gitignore @@ -24,3 +24,5 @@ packages/raindex/esm.d.ts .ai_docs/ .ai_spec/ .cursor/ + +dependencies/ diff --git a/foundry.toml b/foundry.toml index 57fc4ef680..5f34ef9a79 100644 --- a/foundry.toml +++ b/foundry.toml @@ -1,7 +1,9 @@ [profile.default] src = 'src' out = 'out' -libs = ['lib'] +# 'dependencies' for soldeer-managed packages, 'lib' kept for the +# remaining git submodule (sushixswap-v2, which isn't on soldeer). +libs = ['dependencies', 'lib'] # See more config options https://github.com/foundry-rs/foundry/tree/master/config @@ -28,32 +30,51 @@ cbor_metadata = false # Build metadata used for testing rain meta aware contracts in this folder rather # than expose ffi to forge. fs_permissions = [ - { access = "read", path = "./meta"}, {access = "read", path = "./lib/rain.interpreter/meta/RainterpreterExpressionDeployerNPE2.rain.meta"}, + { access = "read", path = "./meta" }, + { access = "read", path = "./lib/rain.interpreter/meta/RainterpreterExpressionDeployerNPE2.rain.meta" }, { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterParserNPE2" }, { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterStoreNPE2" }, { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterNPE2" }, { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterExpressionDeployerNPE2" }, - { access = "read-write", path = "./meta/RaindexV6SubParserAuthoringMeta.rain.meta"}, + { access = "read-write", path = "./meta/RaindexV6SubParserAuthoringMeta.rain.meta" }, { access = "read-write", path = "src/generated" }, { access = "read", path = "./subgraph" }, ] remappings = [ - "forge-std/=lib/rain.interpreter/lib/rain.interpreter.interface/lib/forge-std/src/", - "openzeppelin-contracts/=lib/rain.raindex.interface/lib/rain.interpreter.interface/lib/openzeppelin-contracts/", - "rain.interpreter/=lib/rain.interpreter/src/", - "rain.metadata/=lib/rain.interpreter/lib/rain.metadata/src/", - "rain.interpreter.interface/=lib/rain.raindex.interface/lib/rain.interpreter.interface/src/", - "rain.intorastring/=lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.intorastring/src/", - "rain.sol.codegen/=lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.sol.codegen/src/", - "rain.solmem/=lib/rain.raindex.interface/lib/rain.interpreter.interface/lib/rain.solmem/src", - "rain.math.float/=lib/rain.raindex.interface/lib/rain.interpreter.interface/lib/rain.math.float/src/", - "rain.tofu.erc20-decimals/=lib/rain.interpreter/lib/rain.tofu.erc20-decimals/src/", - "rain.deploy/=lib/rain.deploy/src/", - "rain.lib.typecast/=lib/rain.raindex.interface/lib/rain.interpreter.interface/lib/rain.lib.typecast/src/", + # Custom remap so @openzeppelin packages' own internal imports resolve. + "@openzeppelin/contracts/=dependencies/@openzeppelin-contracts-5.6.1/", + # Submodule for sushixswap-v2 (not on Soldeer). "sushixswap-v2/=lib/sushixswap-v2/", ] +[dependencies] +forge-std = "1.16.1" +"@openzeppelin-contracts" = "5.6.1" +# rainlanguage/rain.interpreter was renamed to rainlanguage/rainlang; +# its Soldeer registry name follows. +rainlang = "0.1.2" +rain-interpreter-interface = "0.1.0" +# rainlanguage/rain.raindex.interface was renamed to +# rainlanguage/raindex.interface; Soldeer registry name follows. +raindex-interface = "0.1.1" +rain-metadata = "0.1.0" +rain-intorastring = "0.1.0" +rain-sol-codegen = "0.1.0" +rain-solmem = "0.1.3" +rain-math-float = "0.1.1" +rain-tofu-erc20-decimals = "0.1.1" +rain-deploy = "0.1.2" +rain-lib-typecast = "0.1.0" +rain-lib-hash = "0.1.0" +rain-math-binary = "0.1.1" +rain-string = "0.2.0" +rain-lib-memkv = "0.1.0" +rain-math-fixedpoint = "0.1.0" + +[soldeer] +recursive_deps = false + [fuzz] runs = 5096 diff --git a/remappings.txt b/remappings.txt new file mode 100644 index 0000000000..4afac64043 --- /dev/null +++ b/remappings.txt @@ -0,0 +1,19 @@ +@openzeppelin-contracts-4.8.3/=dependencies/@openzeppelin-contracts-4.8.3/ +@openzeppelin-contracts-5.6.1/=dependencies/@openzeppelin-contracts-5.6.1/ +forge-std-1.16.1/=dependencies/forge-std-1.16.1/ +rain-deploy-0.1.2/=dependencies/rain-deploy-0.1.2/ +rain-interpreter-interface-0.1.0/=dependencies/rain-interpreter-interface-0.1.0/ +rain-intorastring-0.1.0/=dependencies/rain-intorastring-0.1.0/ +rain-lib-hash-0.1.0/=dependencies/rain-lib-hash-0.1.0/ +rain-lib-memkv-0.1.0/=dependencies/rain-lib-memkv-0.1.0/ +rain-lib-typecast-0.1.0/=dependencies/rain-lib-typecast-0.1.0/ +rain-math-binary-0.1.1/=dependencies/rain-math-binary-0.1.1/ +rain-math-fixedpoint-0.1.0/=dependencies/rain-math-fixedpoint-0.1.0/ +rain-math-float-0.1.1/=dependencies/rain-math-float-0.1.1/ +rain-metadata-0.1.0/=dependencies/rain-metadata-0.1.0/ +rain-sol-codegen-0.1.0/=dependencies/rain-sol-codegen-0.1.0/ +rain-solmem-0.1.3/=dependencies/rain-solmem-0.1.3/ +rain-string-0.2.0/=dependencies/rain-string-0.2.0/ +rain-tofu-erc20-decimals-0.1.1/=dependencies/rain-tofu-erc20-decimals-0.1.1/ +raindex-interface-0.1.1/=dependencies/raindex-interface-0.1.1/ +rainlang-0.1.2/=dependencies/rainlang-0.1.2/ diff --git a/script/BuildAuthoringMeta.sol b/script/BuildAuthoringMeta.sol index 392aab23f4..2faf6904aa 100644 --- a/script/BuildAuthoringMeta.sol +++ b/script/BuildAuthoringMeta.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Script} from "forge-std/Script.sol"; +import {Script} from "forge-std-1.16.1/src/Script.sol"; import {LibRaindexSubParser} from "../src/lib/LibRaindexSubParser.sol"; /// @title Raindex subparser Authoring Meta diff --git a/script/BuildPointers.sol b/script/BuildPointers.sol index 7fe742e1bd..f3379fab0a 100644 --- a/script/BuildPointers.sol +++ b/script/BuildPointers.sol @@ -2,14 +2,14 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Script} from "forge-std/Script.sol"; -import {LibCodeGen} from "rain.sol.codegen/lib/LibCodeGen.sol"; -import {LibFs} from "rain.sol.codegen/lib/LibFs.sol"; +import {Script} from "forge-std-1.16.1/src/Script.sol"; +import {LibCodeGen} from "rain-sol-codegen-0.1.0/src/lib/LibCodeGen.sol"; +import {LibFs} from "rain-sol-codegen-0.1.0/src/lib/LibFs.sol"; import {RaindexV6} from "../src/concrete/raindex/RaindexV6.sol"; import {RaindexV6SubParser} from "../src/concrete/parser/RaindexV6SubParser.sol"; import {LibRaindexSubParser, EXTERN_PARSE_META_BUILD_DEPTH} from "../src/lib/LibRaindexSubParser.sol"; -import {LibGenParseMeta} from "rain.interpreter.interface/lib/codegen/LibGenParseMeta.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {LibGenParseMeta} from "rain-interpreter-interface-0.1.0/src/lib/codegen/LibGenParseMeta.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {ROUTE_PROCESSOR_4_CREATION_CODE} from "../src/lib/deploy/LibRouteProcessor4CreationCode.sol"; import {GenericPoolRaindexV6ArbOrderTaker} from "../src/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sol"; import {RouteProcessorRaindexV6ArbOrderTaker} from "../src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol"; diff --git a/script/Deploy.sol b/script/Deploy.sol index 9c0e2c463d..47970dbfbc 100644 --- a/script/Deploy.sol +++ b/script/Deploy.sol @@ -2,14 +2,14 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Script, console2} from "forge-std/Script.sol"; +import {Script, console2} from "forge-std-1.16.1/src/Script.sol"; import {RaindexV6SubParser} from "../src/concrete/parser/RaindexV6SubParser.sol"; -import {IMetaBoardV1_2} from "rain.metadata/interface/unstable/IMetaBoardV1_2.sol"; -import {LibDescribedByMeta} from "rain.metadata/lib/LibDescribedByMeta.sol"; -import {LibMetaBoardDeploy} from "rain.metadata/lib/deploy/LibMetaBoardDeploy.sol"; -import {LibDecimalFloatDeploy} from "rain.math.float/lib/deploy/LibDecimalFloatDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {IMetaBoardV1_2} from "rain-metadata-0.1.0/src/interface/unstable/IMetaBoardV1_2.sol"; +import {LibDescribedByMeta} from "rain-metadata-0.1.0/src/lib/LibDescribedByMeta.sol"; +import {LibMetaBoardDeploy} from "rain-metadata-0.1.0/src/lib/deploy/LibMetaBoardDeploy.sol"; +import {LibDecimalFloatDeploy} from "rain-math-float-0.1.1/src/lib/deploy/LibDecimalFloatDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "../src/lib/deploy/LibRaindexDeploy.sol"; import {CREATION_CODE as RAINDEX_CREATION_CODE} from "../src/generated/RaindexV6.pointers.sol"; import {CREATION_CODE as SUB_PARSER_CREATION_CODE} from "../src/generated/RaindexV6SubParser.pointers.sol"; diff --git a/script/DiagOrder.sol b/script/DiagOrder.sol index 8b2d3703ef..4140b9507d 100644 --- a/script/DiagOrder.sol +++ b/script/DiagOrder.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Script} from "forge-std/Script.sol"; +import {Script} from "forge-std-1.16.1/src/Script.sol"; contract DiagOrder is Script { function run() external { diff --git a/soldeer.lock b/soldeer.lock new file mode 100644 index 0000000000..b80a2d19ff --- /dev/null +++ b/soldeer.lock @@ -0,0 +1,125 @@ +[[dependencies]] +name = "@openzeppelin-contracts" +version = "4.8.3" +url = "https://soldeer-revisions.s3.amazonaws.com/@openzeppelin-contracts/4_8_3_22-01-2024_13:13:46_contracts.zip" +checksum = "c6c0f1d430120cf45a3531a2fe740a4dffa1434ebccac753a59c54bc1ce65db9" +integrity = "3ecc700e5d25af23c53959baf3cfd3cbadbc0013e80dfca40cee9e7ea34e141d" + +[[dependencies]] +name = "forge-std" +version = "1.16.1" +url = "https://soldeer-revisions.s3.amazonaws.com/forge-std/1_16_1_08-05-2026_08:51:16_forge-std-1.16.zip" +checksum = "839b61832925c7152c7b6dffbfa4998d9e606211179bd8f604733124e8a7cb57" +integrity = "60e55d10150354ca4a1e2985c5456c834b92b82ef85ab0e1d92a7786cddbd219" + +[[dependencies]] +name = "rain-deploy" +version = "0.1.2" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-deploy/0_1_2_09-05-2026_19:49:20_rain.zip" +checksum = "94d3daf2f9f90062d2e676077c2b4ccd2bdd66201665a2209e98016e155f619a" +integrity = "10bff708d9e5d8b77655b8a8fc0c755cef8e3fc876cc3ff100425d27b08294a0" + +[[dependencies]] +name = "rain-interpreter-interface" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-interpreter-interface/0_1_0_12-05-2026_18:43:02_rain.interpreter.zip" +checksum = "887c4d5f1a87713c49f015b3fcdb295defbb495b126d15f9850c0ce72ef79639" +integrity = "c1b89f8a7ad02507ceb051b6c0f2750f6abe1ba99ffdfe1c9ac93905db90e75d" + +[[dependencies]] +name = "rain-intorastring" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-intorastring/0_1_0_12-05-2026_19:21:48_rain.zip" +checksum = "6cd4b0e5ea0a7ffc8adef762b3687d180e4c1408ec4ff8bf8d88d5f9712bf5af" +integrity = "cad9d7a463dd388f73b1f2cf85dd212fd46320203f8d39cb0938ffb451295384" + +[[dependencies]] +name = "rain-lib-hash" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-lib-hash/0_1_0_12-05-2026_16:24:56_rain.lib.zip" +checksum = "648f3e38b297dbd3ecb32b82c8b24c322f484e1734eb50fd393bc547c72b59b0" +integrity = "91f5f679a0a27f096fdbc1e41195dd9f42cacfab15735efeb1101cc1b9215b47" + +[[dependencies]] +name = "rain-lib-memkv" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-lib-memkv/0_1_0_12-05-2026_19:04:20_rain.lib.zip" +checksum = "69142c50851359c0b19ba0e59c387623a90debd16fb1c3a907aa2809a6873b1f" +integrity = "f2a63c0466c50cbfb3b3545094890c74dd1116b55fcb738bb631471252cee5b8" + +[[dependencies]] +name = "rain-lib-typecast" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-lib-typecast/0_1_0_12-05-2026_16:31:39_rain.lib.zip" +checksum = "5c0419501e4c763ef161a3489934af192219f994cb2c9187699bc4dee0b4e2bb" +integrity = "092781f87fd9227c4c95aafde59300c503d6a9a355beaeb5c5732fe6e36676d6" + +[[dependencies]] +name = "rain-math-binary" +version = "0.1.1" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-math-binary/0_1_1_09-05-2026_19:49:57_rain.math.zip" +checksum = "6f966e4f5f59103b62de2004005db508824622495b893a646d0e2a35511f0093" +integrity = "4cfaa11c0e48ac46824a10fec2184863d114f09c171544b721d782386708dca7" + +[[dependencies]] +name = "rain-math-fixedpoint" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-math-fixedpoint/0_1_0_09-05-2026_20:41:06_rain.math.zip" +checksum = "3b19166f9f12ed84047f6570992d1bc445eed7705d5ba7e5a94de9f8cc51d572" +integrity = "8578d71cf511ea2ab2044821c733f06ad5d2a08afc4eb3ff7c14b1af809ab39c" + +[[dependencies]] +name = "rain-math-float" +version = "0.1.1" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-math-float/0_1_1_13-05-2026_13:48:34_rain.math.zip" +checksum = "322956f272ae3073ee02b0e7301b8834f08f2de62bcd6c309c44e946d7cd7056" +integrity = "dccdd4406a37db6af690872b805084a7dbe5211c57961a61ef083a7912ddbdc9" + +[[dependencies]] +name = "rain-metadata" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-metadata/0_1_0_12-05-2026_20:20:51_rain.zip" +checksum = "801d2b97b393d346c19a2f4f454d0279ba8f7d0f81fa3eb4fe8609da7291203d" +integrity = "f17f10aa50e9e2b254c689c83f41b3cabab81c95bad06424b9b3e9c92d02e577" + +[[dependencies]] +name = "rain-sol-codegen" +version = "0.1.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-sol-codegen/0_1_0_09-05-2026_20:30:25_rain.sol.zip" +checksum = "6b5abd394c5db86ac64214262b7a5115158f480b2fbd74442672dfe52bb67310" +integrity = "e22748ce2ba7eca3ce71e23b2271d1c0f370b989507e784b0a4850a7a9e52157" + +[[dependencies]] +name = "rain-solmem" +version = "0.1.3" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-solmem/0_1_3_09-05-2026_19:49:33_rain.zip" +checksum = "1d405bb81f7c9e56d1717de0d60da918d2fc2fa4db083efd2abe9906378d019f" +integrity = "e879d2743f9d884f647b9dd489889a83f2cea5f76eb69409a113e1baa69d3643" + +[[dependencies]] +name = "rain-string" +version = "0.2.0" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-string/0_2_0_09-05-2026_21:16:31_rain.zip" +checksum = "847b9366128c5dcc5849c6938ae7ac92561ed8185bf304f1b1eb9ef59d77954e" +integrity = "7cb6ee638b59b840ea59e014e2610fdccc30a1593e763590e298314f00700561" + +[[dependencies]] +name = "rain-tofu-erc20-decimals" +version = "0.1.1" +url = "https://soldeer-revisions.s3.amazonaws.com/rain-tofu-erc20-decimals/0_1_1_12-05-2026_15:44:19_rain.tofu.zip" +checksum = "2a48a362ac80a85a8792492fcaf943a86a95009a8aeaced3b50554bbed1e5874" +integrity = "9e1fccf893dd0d90aeb445c78f9eee3904bc50287ff1da30b954508f18412cd2" + +[[dependencies]] +name = "raindex-interface" +version = "0.1.1" +url = "https://soldeer-revisions.s3.amazonaws.com/raindex-interface/0_1_1_21-05-2026_18:36:45_raindex.zip" +checksum = "d744aec8e9dc1bcce58de546d1a419f7eb87610e1541ce5459a140fd45626c99" +integrity = "df40e42221d1ecd4e6e6ae6a3511b00fc182e1a46f99401f564d94f299d63730" + +[[dependencies]] +name = "rainlang" +version = "0.1.2" +url = "https://soldeer-revisions.s3.amazonaws.com/rainlang/0_1_2_14-05-2026_19:37:46_rainlang.zip" +checksum = "87f4056d17bc103d6ca8d1881fe64c67d74d36f67ec1d858d071e3f77a449845" +integrity = "8c93188eddb2df33bc3c0e4f529f5de8476e813803bbaadc59500f6d37baebce" diff --git a/src/abstract/RaindexV6ArbCommon.sol b/src/abstract/RaindexV6ArbCommon.sol index 4c801b28e8..991f75ee99 100644 --- a/src/abstract/RaindexV6ArbCommon.sol +++ b/src/abstract/RaindexV6ArbCommon.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; /// @param task The task to run as post for each arb. struct RaindexV6ArbConfig { diff --git a/src/abstract/RaindexV6ArbOrderTaker.sol b/src/abstract/RaindexV6ArbOrderTaker.sol index 691ed97cdb..538dc5041a 100644 --- a/src/abstract/RaindexV6ArbOrderTaker.sol +++ b/src/abstract/RaindexV6ArbOrderTaker.sol @@ -2,16 +2,16 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {ERC165, IERC165} from "openzeppelin-contracts/contracts/utils/introspection/ERC165.sol"; -import {ReentrancyGuard} from "openzeppelin-contracts/contracts/utils/ReentrancyGuard.sol"; -import {IERC20, SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; -import {IRaindexV6} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IRaindexV6ArbOrderTaker, TaskV2} from "rain.raindex.interface/interface/IRaindexV6ArbOrderTaker.sol"; -import {TakeOrdersConfigV5, Float} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {ERC165, IERC165} from "@openzeppelin-contracts-5.6.1/utils/introspection/ERC165.sol"; +import {ReentrancyGuard} from "@openzeppelin-contracts-5.6.1/utils/ReentrancyGuard.sol"; +import {IERC20, SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; +import {IRaindexV6} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IRaindexV6ArbOrderTaker, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6ArbOrderTaker.sol"; +import {TakeOrdersConfigV5, Float} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {RaindexV6ArbCommon} from "./RaindexV6ArbCommon.sol"; import {LibRaindexArb} from "../lib/LibRaindexArb.sol"; -import {IRaindexV6OrderTaker} from "rain.raindex.interface/interface/IRaindexV6OrderTaker.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +import {IRaindexV6OrderTaker} from "raindex-interface-0.1.1/src/interface/IRaindexV6OrderTaker.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; /// @title RaindexV6ArbOrderTaker /// @notice Arb contract that takes orders directly from a `Raindex` without diff --git a/src/abstract/RaindexV6ArbTaskGated.sol b/src/abstract/RaindexV6ArbTaskGated.sol index c1f4d9a4b2..b6c123cd50 100644 --- a/src/abstract/RaindexV6ArbTaskGated.sol +++ b/src/abstract/RaindexV6ArbTaskGated.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.19; import {RaindexV6ArbCommon, RaindexV6ArbConfig, WrongTask} from "./RaindexV6ArbCommon.sol"; -import {TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; /// @title RaindexV6ArbTaskGated /// @notice Mixin that adds task-hash gating to arb contracts. Stores a task diff --git a/src/abstract/RaindexV6FlashBorrower.sol b/src/abstract/RaindexV6FlashBorrower.sol index 2a206264aa..4fd1008d96 100644 --- a/src/abstract/RaindexV6FlashBorrower.sol +++ b/src/abstract/RaindexV6FlashBorrower.sol @@ -2,18 +2,18 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {ERC165, IERC165} from "openzeppelin-contracts/contracts/utils/introspection/ERC165.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {ReentrancyGuard} from "openzeppelin-contracts/contracts/utils/ReentrancyGuard.sol"; -import {ON_FLASH_LOAN_CALLBACK_SUCCESS} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; -import {IRaindexV6, TakeOrdersConfigV5, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC3156FlashBorrower} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {ERC165, IERC165} from "@openzeppelin-contracts-5.6.1/utils/introspection/ERC165.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {ReentrancyGuard} from "@openzeppelin-contracts-5.6.1/utils/ReentrancyGuard.sol"; +import {ON_FLASH_LOAN_CALLBACK_SUCCESS} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IRaindexV6, TakeOrdersConfigV5, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC3156FlashBorrower} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; import {RaindexV6ArbCommon} from "./RaindexV6ArbCommon.sol"; import {LibRaindexArb} from "../lib/LibRaindexArb.sol"; import {LibRaindexDeploy} from "../lib/deploy/LibRaindexDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; /// Thrown when the flash loan initiator is not this contract. /// @param badInitiator The untrusted initiator of the flash loan. diff --git a/src/abstract/RaindexV6FlashLender.sol b/src/abstract/RaindexV6FlashLender.sol index 98d70605f5..aa37fc2090 100644 --- a/src/abstract/RaindexV6FlashLender.sol +++ b/src/abstract/RaindexV6FlashLender.sol @@ -2,15 +2,15 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {ERC165, IERC165} from "openzeppelin-contracts/contracts/utils/introspection/ERC165.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {ERC165, IERC165} from "@openzeppelin-contracts-5.6.1/utils/introspection/ERC165.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; import { IERC3156FlashBorrower, ON_FLASH_LOAN_CALLBACK_SUCCESS -} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; -import {IERC3156FlashLender} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashLender.sol"; +} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IERC3156FlashLender} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashLender.sol"; /// Thrown when the `onFlashLoan` callback returns anything other than /// ON_FLASH_LOAN_CALLBACK_SUCCESS. diff --git a/src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol b/src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol index 012d1834fe..320c2fde1a 100644 --- a/src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol +++ b/src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol @@ -3,12 +3,12 @@ pragma solidity =0.8.25; import {IRouteProcessor} from "sushixswap-v2/src/interfaces/IRouteProcessor.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; import {RaindexV6ArbOrderTaker, Float} from "../../abstract/RaindexV6ArbOrderTaker.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; import {LibRaindexDeploy} from "../../lib/deploy/LibRaindexDeploy.sol"; /// @title RouteProcessorRaindexV6ArbOrderTaker diff --git a/src/concrete/parser/RaindexV6SubParser.sol b/src/concrete/parser/RaindexV6SubParser.sol index a7a38ef674..259ab159a1 100644 --- a/src/concrete/parser/RaindexV6SubParser.sol +++ b/src/concrete/parser/RaindexV6SubParser.sol @@ -7,9 +7,9 @@ import { BaseRainlangSubParser, OperandV2, IParserToolingV1 -} from "rain.interpreter/abstract/BaseRainlangSubParser.sol"; -import {LibConvert} from "rain.lib.typecast/LibConvert.sol"; -import {LibUint256Matrix} from "rain.solmem/lib/LibUint256Matrix.sol"; +} from "rainlang-0.1.2/src/abstract/BaseRainlangSubParser.sol"; +import {LibConvert} from "rain-lib-typecast-0.1.0/src/LibConvert.sol"; +import {LibUint256Matrix} from "rain-solmem-0.1.3/src/lib/LibUint256Matrix.sol"; import { LibRaindexSubParser, @@ -33,7 +33,7 @@ import { CONTEXT_BASE_ROW_SENDER, CONTEXT_BASE_ROW_CALLING_CONTRACT, CONTEXT_BASE_ROWS -} from "rain.interpreter.interface/lib/caller/LibContext.sol"; +} from "rain-interpreter-interface-0.1.0/src/lib/caller/LibContext.sol"; import { CONTEXT_COLUMNS_EXTENDED, CONTEXT_VAULT_OUTPUTS_COLUMN, @@ -66,8 +66,8 @@ import { SUB_PARSER_WORD_PARSERS, OPERAND_HANDLER_FUNCTION_POINTERS as SUB_PARSER_OPERAND_HANDLERS } from "../../generated/RaindexV6SubParser.pointers.sol"; -import {IDescribedByMetaV1} from "rain.metadata/interface/IDescribedByMetaV1.sol"; -import {ISubParserToolingV1} from "rain.sol.codegen/interface/ISubParserToolingV1.sol"; +import {IDescribedByMetaV1} from "rain-metadata-0.1.0/src/interface/IDescribedByMetaV1.sol"; +import {ISubParserToolingV1} from "rain-sol-codegen-0.1.0/src/interface/ISubParserToolingV1.sol"; /// @title RaindexV6SubParser /// @notice Sub-parser that provides raindex-specific context words (sender, diff --git a/src/concrete/raindex/RaindexV6.sol b/src/concrete/raindex/RaindexV6.sol index cce56a1572..c8f509a8cc 100644 --- a/src/concrete/raindex/RaindexV6.sol +++ b/src/concrete/raindex/RaindexV6.sol @@ -2,32 +2,32 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Math} from "openzeppelin-contracts/contracts/utils/math/Math.sol"; -import {Multicall} from "openzeppelin-contracts/contracts/utils/Multicall.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; -import {ReentrancyGuard} from "openzeppelin-contracts/contracts/utils/ReentrancyGuard.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; - -import {LibContext} from "rain.interpreter.interface/lib/caller/LibContext.sol"; -import {LibBytecode} from "rain.interpreter.interface/lib/bytecode/LibBytecode.sol"; +import {Math} from "@openzeppelin-contracts-5.6.1/utils/math/Math.sol"; +import {Multicall} from "@openzeppelin-contracts-5.6.1/utils/Multicall.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; +import {ReentrancyGuard} from "@openzeppelin-contracts-5.6.1/utils/ReentrancyGuard.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; + +import {LibContext} from "rain-interpreter-interface-0.1.0/src/lib/caller/LibContext.sol"; +import {LibBytecode} from "rain-interpreter-interface-0.1.0/src/lib/bytecode/LibBytecode.sol"; import { SourceIndexV2, StateNamespace, IInterpreterV4, StackItem, EvalV4 -} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {LibUint256Array} from "rain.solmem/lib/LibUint256Array.sol"; -import {LibUint256Matrix} from "rain.solmem/lib/LibUint256Matrix.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibNamespace} from "rain.interpreter.interface/lib/ns/LibNamespace.sol"; -import {LibMeta} from "rain.metadata/lib/LibMeta.sol"; -import {IMetaV1_2} from "rain.metadata/interface/unstable/IMetaV1_2.sol"; +} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {LibUint256Array} from "rain-solmem-0.1.3/src/lib/LibUint256Array.sol"; +import {LibUint256Matrix} from "rain-solmem-0.1.3/src/lib/LibUint256Matrix.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibNamespace} from "rain-interpreter-interface-0.1.0/src/lib/ns/LibNamespace.sol"; +import {LibMeta} from "rain-metadata-0.1.0/src/lib/LibMeta.sol"; +import {IMetaV1_2} from "rain-metadata-0.1.0/src/interface/unstable/IMetaV1_2.sol"; import {LibRaindex} from "../../lib/LibRaindex.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibTOFUTokenDecimals, TOFUOutcome} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; -import {ITOFUTokenDecimals} from "rain.tofu.erc20-decimals/interface/ITOFUTokenDecimals.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibTOFUTokenDecimals, TOFUOutcome} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; +import {ITOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/interface/ITOFUTokenDecimals.sol"; import { IRaindexV6, @@ -45,8 +45,8 @@ import { QuoteV2, Float, IOV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IRaindexV6OrderTaker} from "rain.raindex.interface/interface/IRaindexV6OrderTaker.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IRaindexV6OrderTaker} from "raindex-interface-0.1.1/src/interface/IRaindexV6OrderTaker.sol"; import {LibOrder} from "../../lib/LibOrder.sol"; import { CALLING_CONTEXT_COLUMNS, @@ -59,10 +59,10 @@ import { CONTEXT_VAULT_IO_VAULT_ID } from "../../lib/LibRaindex.sol"; import {RaindexV6FlashLender} from "../../abstract/RaindexV6FlashLender.sol"; -import {LibBytes32Array} from "rain.solmem/lib/LibBytes32Array.sol"; -import {LibBytes32Matrix} from "rain.solmem/lib/LibBytes32Matrix.sol"; +import {LibBytes32Array} from "rain-solmem-0.1.3/src/lib/LibBytes32Array.sol"; +import {LibBytes32Matrix} from "rain-solmem-0.1.3/src/lib/LibBytes32Matrix.sol"; -import {LibFormatDecimalFloat} from "rain.math.float/lib/format/LibFormatDecimalFloat.sol"; +import {LibFormatDecimalFloat} from "rain-math-float-0.1.1/src/lib/format/LibFormatDecimalFloat.sol"; /// This will exist in a future version of Open Zeppelin if their main branch is /// to be believed. diff --git a/src/lib/LibGenericPoolExchange.sol b/src/lib/LibGenericPoolExchange.sol index 3920e25009..41ca096487 100644 --- a/src/lib/LibGenericPoolExchange.sol +++ b/src/lib/LibGenericPoolExchange.sol @@ -2,9 +2,9 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; -import {Address} from "openzeppelin-contracts/contracts/utils/Address.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; +import {Address} from "@openzeppelin-contracts-5.6.1/utils/Address.sol"; /// @title LibGenericPoolExchange /// @notice Shared approve-call-revoke pattern for generic pool exchanges. diff --git a/src/lib/LibOrder.sol b/src/lib/LibOrder.sol index 5fd8252cf5..c3a1119c3f 100644 --- a/src/lib/LibOrder.sol +++ b/src/lib/LibOrder.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {OrderV4} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderV4} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; /// @title LibOrder /// @notice Consistent handling of `OrderV4` for where it matters w.r.t. diff --git a/src/lib/LibRaindex.sol b/src/lib/LibRaindex.sol index e7e58d2f5c..96fcdf2fdf 100644 --- a/src/lib/LibRaindex.sol +++ b/src/lib/LibRaindex.sol @@ -2,15 +2,15 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import { SourceIndexV2, StateNamespace, StackItem, EvalV4 -} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {LibNamespace, FullyQualifiedNamespace} from "rain.interpreter.interface/lib/ns/LibNamespace.sol"; -import {LibContext} from "rain.interpreter.interface/lib/caller/LibContext.sol"; +} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {LibNamespace, FullyQualifiedNamespace} from "rain-interpreter-interface-0.1.0/src/lib/ns/LibNamespace.sol"; +import {LibContext} from "rain-interpreter-interface-0.1.0/src/lib/caller/LibContext.sol"; /// @dev Raindex context is actually fairly complex. The calling context column /// is populated before calculate order, but the remaining columns are only diff --git a/src/lib/LibRaindexArb.sol b/src/lib/LibRaindexArb.sol index 4c27735ff3..ff578cb3bd 100644 --- a/src/lib/LibRaindexArb.sol +++ b/src/lib/LibRaindexArb.sol @@ -2,12 +2,12 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {LibRaindex} from "./LibRaindex.sol"; -import {Address} from "openzeppelin-contracts/contracts/utils/Address.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {Address} from "@openzeppelin-contracts-5.6.1/utils/Address.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; /// @title LibRaindexArb library LibRaindexArb { diff --git a/src/lib/LibRaindexSubParser.sol b/src/lib/LibRaindexSubParser.sol index bb03cca804..d380af9500 100644 --- a/src/lib/LibRaindexSubParser.sol +++ b/src/lib/LibRaindexSubParser.sol @@ -2,15 +2,15 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {AuthoringMetaV2, OperandV2} from "rain.interpreter.interface/interface/ISubParserV4.sol"; -import {LibUint256Matrix} from "rain.solmem/lib/LibUint256Matrix.sol"; -import {LibSubParse} from "rain.interpreter/lib/parse/LibSubParse.sol"; +import {AuthoringMetaV2, OperandV2} from "rain-interpreter-interface-0.1.0/src/interface/ISubParserV4.sol"; +import {LibUint256Matrix} from "rain-solmem-0.1.3/src/lib/LibUint256Matrix.sol"; +import {LibSubParse} from "rainlang-0.1.2/src/lib/parse/LibSubParse.sol"; import { CONTEXT_BASE_COLUMN, CONTEXT_BASE_ROW_SENDER, CONTEXT_BASE_ROW_CALLING_CONTRACT, CONTEXT_BASE_ROWS -} from "rain.interpreter.interface/lib/caller/LibContext.sol"; +} from "rain-interpreter-interface-0.1.0/src/lib/caller/LibContext.sol"; import { CONTEXT_COLUMNS, CONTEXT_COLUMNS_EXTENDED, diff --git a/test/abstract/RaindexV6ArbOrderTaker.context.t.sol b/test/abstract/RaindexV6ArbOrderTaker.context.t.sol index 6532ce2f72..4a8ae98a42 100644 --- a/test/abstract/RaindexV6ArbOrderTaker.context.t.sol +++ b/test/abstract/RaindexV6ArbOrderTaker.context.t.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {ChildRaindexV6ArbOrderTaker} from "../util/concrete/ChildRaindexV6ArbOrderTaker.sol"; -import {TaskV2, SignedContextV1, EvaluableV4} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {TaskV2, SignedContextV1, EvaluableV4} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {RaindexV6ExternalRealTest} from "../util/abstract/RaindexV6ExternalRealTest.sol"; import { TakeOrdersConfigV5, @@ -12,11 +12,11 @@ import { OrderConfigV4, OrderV4, IInterpreterV4 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; import {StateNamespace, LibNamespace} from "../../src/concrete/raindex/RaindexV6.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; contract RaindexV6ArbOrderTakerContextTest is RaindexV6ExternalRealTest { function testRaindexV6ArbOrderTakerContext() external { diff --git a/test/abstract/RaindexV6ArbOrderTaker.ierc165.t.sol b/test/abstract/RaindexV6ArbOrderTaker.ierc165.t.sol index 459296413d..42f0e12062 100644 --- a/test/abstract/RaindexV6ArbOrderTaker.ierc165.t.sol +++ b/test/abstract/RaindexV6ArbOrderTaker.ierc165.t.sol @@ -2,10 +2,10 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC165} from "openzeppelin-contracts/contracts/utils/introspection/IERC165.sol"; -import {IRaindexV6ArbOrderTaker} from "rain.raindex.interface/interface/IRaindexV6ArbOrderTaker.sol"; -import {IRaindexV6OrderTaker} from "rain.raindex.interface/interface/IRaindexV6OrderTaker.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC165} from "@openzeppelin-contracts-5.6.1/utils/introspection/IERC165.sol"; +import {IRaindexV6ArbOrderTaker} from "raindex-interface-0.1.1/src/interface/IRaindexV6ArbOrderTaker.sol"; +import {IRaindexV6OrderTaker} from "raindex-interface-0.1.1/src/interface/IRaindexV6OrderTaker.sol"; import {ChildRaindexV6ArbOrderTaker} from "../util/concrete/ChildRaindexV6ArbOrderTaker.sol"; contract RaindexV6ArbOrderTakerIERC165Test is Test { diff --git a/test/abstract/RaindexV6ArbOrderTaker.noOrders.t.sol b/test/abstract/RaindexV6ArbOrderTaker.noOrders.t.sol index 4654b6d46a..be14720421 100644 --- a/test/abstract/RaindexV6ArbOrderTaker.noOrders.t.sol +++ b/test/abstract/RaindexV6ArbOrderTaker.noOrders.t.sol @@ -14,9 +14,9 @@ import { IInterpreterStoreV3, TaskV2, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; contract RaindexV6ArbOrderTakerNoOrdersTest is GenericPoolRaindexV6ArbOrderTakerTest { /// arb5 MUST revert with NoOrders when given an empty orders array. diff --git a/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2.t.sol b/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2.t.sol index 2c9a893057..1243328c0b 100644 --- a/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2.t.sol +++ b/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {GenericPoolRaindexV6ArbOrderTaker} from "../../src/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sol"; import { @@ -16,12 +16,12 @@ import { SignedContextV1, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockExchange} from "test/util/concrete/MockExchange.sol"; import {RealisticOrderTakerMockRaindex} from "test/util/concrete/RealisticOrderTakerMockRaindex.sol"; diff --git a/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol b/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol index 342debc540..b6abfa6612 100644 --- a/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol +++ b/test/abstract/RaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol @@ -2,12 +2,12 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {GenericPoolRaindexV6ArbOrderTaker} from "../../src/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sol"; -import {Float} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +import {Float} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; contract RaindexV6ArbOrderTakerOnTakeOrders2DirectTest is Test { diff --git a/test/abstract/RaindexV6ArbOrderTaker.reentrancy.t.sol b/test/abstract/RaindexV6ArbOrderTaker.reentrancy.t.sol index 341210eabc..c9c3be2bde 100644 --- a/test/abstract/RaindexV6ArbOrderTaker.reentrancy.t.sol +++ b/test/abstract/RaindexV6ArbOrderTaker.reentrancy.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {GenericPoolRaindexV6ArbOrderTaker} from "../../src/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sol"; import { @@ -14,12 +14,12 @@ import { EvaluableV4, SignedContextV1, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {ReentrantMockRaindex} from "test/util/concrete/ReentrantMockRaindex.sol"; diff --git a/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassMatch.t.sol b/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassMatch.t.sol index 2d9d952e22..ae907ba286 100644 --- a/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassMatch.t.sol +++ b/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassMatch.t.sol @@ -2,13 +2,13 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {ChildRaindexV6ArbTaskGated} from "test/util/concrete/ChildRaindexV6ArbTaskGated.sol"; import {RaindexV6ArbConfig} from "../../src/abstract/RaindexV6ArbCommon.sol"; -import {TaskV2, EvaluableV4, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {TaskV2, EvaluableV4, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; /// _checkTaskHash MUST pass when the runtime task matches the configured task. contract RaindexV6ArbTaskGatedCheckTaskHashPassMatchTest is Test { diff --git a/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassZero.t.sol b/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassZero.t.sol index b44a52ba6e..11cbeda465 100644 --- a/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassZero.t.sol +++ b/test/abstract/RaindexV6ArbTaskGated.checkTaskHashPassZero.t.sol @@ -2,13 +2,13 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {ChildRaindexV6ArbTaskGated} from "test/util/concrete/ChildRaindexV6ArbTaskGated.sol"; import {RaindexV6ArbConfig} from "../../src/abstract/RaindexV6ArbCommon.sol"; -import {TaskV2, EvaluableV4, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {TaskV2, EvaluableV4, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; /// _checkTaskHash MUST pass through when iTaskHash is zero, regardless of /// the task provided at runtime. diff --git a/test/abstract/RaindexV6ArbTaskGated.checkTaskHashWrongTask.t.sol b/test/abstract/RaindexV6ArbTaskGated.checkTaskHashWrongTask.t.sol index 2ac7ec871e..ba7a8bdea4 100644 --- a/test/abstract/RaindexV6ArbTaskGated.checkTaskHashWrongTask.t.sol +++ b/test/abstract/RaindexV6ArbTaskGated.checkTaskHashWrongTask.t.sol @@ -2,13 +2,13 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {ChildRaindexV6ArbTaskGated} from "test/util/concrete/ChildRaindexV6ArbTaskGated.sol"; import {RaindexV6ArbConfig, WrongTask} from "../../src/abstract/RaindexV6ArbCommon.sol"; -import {TaskV2, EvaluableV4, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {TaskV2, EvaluableV4, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; /// _checkTaskHash MUST revert with WrongTask when iTaskHash is nonzero and /// the runtime task does not match. diff --git a/test/abstract/RaindexV6ArbTaskGated.construct.t.sol b/test/abstract/RaindexV6ArbTaskGated.construct.t.sol index b271acfef5..d11ef45876 100644 --- a/test/abstract/RaindexV6ArbTaskGated.construct.t.sol +++ b/test/abstract/RaindexV6ArbTaskGated.construct.t.sol @@ -2,13 +2,13 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {ChildRaindexV6ArbTaskGated} from "test/util/concrete/ChildRaindexV6ArbTaskGated.sol"; import {RaindexV6ArbConfig, RaindexV6ArbCommon} from "../../src/abstract/RaindexV6ArbCommon.sol"; -import {TaskV2, EvaluableV4, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {TaskV2, EvaluableV4, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; /// Construction MUST emit the Construct event with the sender and config. contract RaindexV6ArbTaskGatedConstructTest is Test { diff --git a/test/abstract/RaindexV6ArbTaskGated.iTaskHashNonzero.t.sol b/test/abstract/RaindexV6ArbTaskGated.iTaskHashNonzero.t.sol index 2956fd2945..25090b5544 100644 --- a/test/abstract/RaindexV6ArbTaskGated.iTaskHashNonzero.t.sol +++ b/test/abstract/RaindexV6ArbTaskGated.iTaskHashNonzero.t.sol @@ -2,13 +2,13 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {ChildRaindexV6ArbTaskGated} from "test/util/concrete/ChildRaindexV6ArbTaskGated.sol"; import {RaindexV6ArbConfig} from "../../src/abstract/RaindexV6ArbCommon.sol"; -import {TaskV2, EvaluableV4, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {TaskV2, EvaluableV4, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; /// When constructed with non-empty bytecode the task hash MUST be the /// keccak256 of the abi-encoded task. diff --git a/test/abstract/RaindexV6ArbTaskGated.iTaskHashZero.t.sol b/test/abstract/RaindexV6ArbTaskGated.iTaskHashZero.t.sol index b0779eff55..07a768a37d 100644 --- a/test/abstract/RaindexV6ArbTaskGated.iTaskHashZero.t.sol +++ b/test/abstract/RaindexV6ArbTaskGated.iTaskHashZero.t.sol @@ -2,13 +2,13 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {ChildRaindexV6ArbTaskGated} from "test/util/concrete/ChildRaindexV6ArbTaskGated.sol"; import {RaindexV6ArbConfig} from "../../src/abstract/RaindexV6ArbCommon.sol"; -import {TaskV2, EvaluableV4, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {TaskV2, EvaluableV4, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; /// When constructed with empty bytecode the task hash MUST be zero. contract RaindexV6ArbTaskGatedITaskHashZeroTest is Test { diff --git a/test/abstract/RaindexV6FlashBorrower.badInitiator.t.sol b/test/abstract/RaindexV6FlashBorrower.badInitiator.t.sol index 71759c20e6..764309c469 100644 --- a/test/abstract/RaindexV6FlashBorrower.badInitiator.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.badInitiator.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import {BadInitiator} from "../../src/abstract/RaindexV6FlashBorrower.sol"; diff --git a/test/abstract/RaindexV6FlashBorrower.badLenderApproval.t.sol b/test/abstract/RaindexV6FlashBorrower.badLenderApproval.t.sol index ae297e1780..b4b84d69de 100644 --- a/test/abstract/RaindexV6FlashBorrower.badLenderApproval.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.badLenderApproval.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import {BadLender} from "../../src/abstract/RaindexV6FlashBorrower.sol"; @@ -16,12 +16,12 @@ import { EvaluableV4, SignedContextV1, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MaliciousRaindex} from "test/util/concrete/MaliciousRaindex.sol"; diff --git a/test/abstract/RaindexV6FlashBorrower.flashLoanFailed.t.sol b/test/abstract/RaindexV6FlashBorrower.flashLoanFailed.t.sol index d4b5a1e418..86938ad92c 100644 --- a/test/abstract/RaindexV6FlashBorrower.flashLoanFailed.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.flashLoanFailed.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import {FlashLoanFailed} from "../../src/abstract/RaindexV6FlashBorrower.sol"; @@ -17,12 +17,12 @@ import { SignedContextV1, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../src/lib/deploy/LibRaindexDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockRaindexBase} from "test/util/abstract/MockRaindexBase.sol"; diff --git a/test/abstract/RaindexV6FlashBorrower.ierc165.t.sol b/test/abstract/RaindexV6FlashBorrower.ierc165.t.sol index 76cc6d9348..186210c8c9 100644 --- a/test/abstract/RaindexV6FlashBorrower.ierc165.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.ierc165.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC165} from "openzeppelin-contracts/contracts/utils/introspection/IERC165.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC165} from "@openzeppelin-contracts-5.6.1/utils/introspection/IERC165.sol"; import {RaindexV6FlashBorrower, IERC3156FlashBorrower} from "../../src/abstract/RaindexV6FlashBorrower.sol"; /// @dev We need a contract that is deployable in order to test the abstract diff --git a/test/abstract/RaindexV6FlashBorrower.lenderValidation.t.sol b/test/abstract/RaindexV6FlashBorrower.lenderValidation.t.sol index 09523b041c..7e2d19a3bc 100644 --- a/test/abstract/RaindexV6FlashBorrower.lenderValidation.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.lenderValidation.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import {BadLender} from "../../src/abstract/RaindexV6FlashBorrower.sol"; diff --git a/test/abstract/RaindexV6FlashBorrower.mixedDecimals.t.sol b/test/abstract/RaindexV6FlashBorrower.mixedDecimals.t.sol index f20ff335bf..5eb252d4a4 100644 --- a/test/abstract/RaindexV6FlashBorrower.mixedDecimals.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.mixedDecimals.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import { @@ -16,12 +16,12 @@ import { SignedContextV1, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../src/lib/deploy/LibRaindexDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockExchange} from "test/util/concrete/MockExchange.sol"; diff --git a/test/abstract/RaindexV6FlashBorrower.noOrders.t.sol b/test/abstract/RaindexV6FlashBorrower.noOrders.t.sol index d0e52a4107..c7f482bb59 100644 --- a/test/abstract/RaindexV6FlashBorrower.noOrders.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.noOrders.t.sol @@ -14,9 +14,9 @@ import { IInterpreterStoreV3, TaskV2, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; contract RaindexV6FlashBorrowerNoOrdersTest is ArbTest { function buildArb() internal override returns (address payable) { diff --git a/test/abstract/RaindexV6FlashBorrower.realTokenTransfers.t.sol b/test/abstract/RaindexV6FlashBorrower.realTokenTransfers.t.sol index 1d9f98669a..c13ed8cacb 100644 --- a/test/abstract/RaindexV6FlashBorrower.realTokenTransfers.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.realTokenTransfers.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import { @@ -16,12 +16,12 @@ import { SignedContextV1, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../src/lib/deploy/LibRaindexDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockExchange} from "test/util/concrete/MockExchange.sol"; diff --git a/test/abstract/RaindexV6FlashBorrower.reentrancy.t.sol b/test/abstract/RaindexV6FlashBorrower.reentrancy.t.sol index fc0672db6e..4d4e0f510e 100644 --- a/test/abstract/RaindexV6FlashBorrower.reentrancy.t.sol +++ b/test/abstract/RaindexV6FlashBorrower.reentrancy.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import { @@ -14,12 +14,12 @@ import { EvaluableV4, SignedContextV1, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../src/lib/deploy/LibRaindexDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {FlashLendingMockRaindex} from "test/util/concrete/FlashLendingMockRaindex.sol"; diff --git a/test/abstract/RaindexV6FlashLender.griefRecipient.t.sol b/test/abstract/RaindexV6FlashLender.griefRecipient.t.sol index d19bbf4fec..ed600c2e3e 100644 --- a/test/abstract/RaindexV6FlashLender.griefRecipient.t.sol +++ b/test/abstract/RaindexV6FlashLender.griefRecipient.t.sol @@ -6,8 +6,8 @@ import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMoc import { IERC3156FlashBorrower, ON_FLASH_LOAN_CALLBACK_SUCCESS -} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {FlashLenderCallbackFailed} from "../../src/abstract/RaindexV6FlashLender.sol"; /// @title RaindexV6FlashLenderGriefRecipientTest diff --git a/test/abstract/RaindexV6FlashLender.ierc165.t.sol b/test/abstract/RaindexV6FlashLender.ierc165.t.sol index 282cf84990..ed645f50ed 100644 --- a/test/abstract/RaindexV6FlashLender.ierc165.t.sol +++ b/test/abstract/RaindexV6FlashLender.ierc165.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC165} from "openzeppelin-contracts/contracts/utils/introspection/IERC165.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC165} from "@openzeppelin-contracts-5.6.1/utils/introspection/IERC165.sol"; import {RaindexV6FlashLender, IERC3156FlashLender} from "../../src/abstract/RaindexV6FlashLender.sol"; /// @dev We need a contract that is deployable in order to test the abstract diff --git a/test/abstract/RaindexV6FlashLender.maxFlashLoan.t.sol b/test/abstract/RaindexV6FlashLender.maxFlashLoan.t.sol index 052f59d2ad..f926b7d164 100644 --- a/test/abstract/RaindexV6FlashLender.maxFlashLoan.t.sol +++ b/test/abstract/RaindexV6FlashLender.maxFlashLoan.t.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; /// @title RaindexV6FlashLenderMaxFlashLoanTest /// Tests the maximum flash loan amount for `RaindexV6FlashLender`. diff --git a/test/abstract/RaindexV6FlashLender.mockSuccess.t.sol b/test/abstract/RaindexV6FlashLender.mockSuccess.t.sol index 29734fea43..1912530d17 100644 --- a/test/abstract/RaindexV6FlashLender.mockSuccess.t.sol +++ b/test/abstract/RaindexV6FlashLender.mockSuccess.t.sol @@ -6,8 +6,8 @@ import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMoc import { IERC3156FlashBorrower, ON_FLASH_LOAN_CALLBACK_SUCCESS -} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; /// @title RaindexV6FlashLenderMockSuccessTest /// Show that if the receiver is `RaindexV6FlashBorrower` and the token diff --git a/test/abstract/RaindexV6FlashLender.reentrant.t.sol b/test/abstract/RaindexV6FlashLender.reentrant.t.sol index db8773a0fa..1b5fc7e501 100644 --- a/test/abstract/RaindexV6FlashLender.reentrant.t.sol +++ b/test/abstract/RaindexV6FlashLender.reentrant.t.sol @@ -11,13 +11,13 @@ import { TakeOrdersConfigV5, ClearConfigV2, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC3156FlashBorrower} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC3156FlashBorrower} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; -import {EvaluableV4, SignedContextV1} from "rain.interpreter.interface/interface/IInterpreterCallerV4.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {EvaluableV4, SignedContextV1} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterCallerV4.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; /// @title RaindexV6FlashLenderReentrant /// Test that flash borrowers can reenter the raindex, which is necessary for diff --git a/test/abstract/RaindexV6FlashLender.transfers.t.sol b/test/abstract/RaindexV6FlashLender.transfers.t.sol index d50933680f..d8d53f7354 100644 --- a/test/abstract/RaindexV6FlashLender.transfers.t.sol +++ b/test/abstract/RaindexV6FlashLender.transfers.t.sol @@ -2,17 +2,17 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {stdError} from "forge-std/Test.sol"; +import {stdError} from "forge-std-1.16.1/src/Test.sol"; import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; -import {ERC20, IERC20Errors} from "openzeppelin-contracts/contracts/token/ERC20/ERC20.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {ERC20, IERC20Errors} from "@openzeppelin-contracts-5.6.1/token/ERC20/ERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; import { IERC3156FlashBorrower, ON_FLASH_LOAN_CALLBACK_SUCCESS -} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; -import {IERC3156FlashLender} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashLender.sol"; +} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IERC3156FlashLender} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashLender.sol"; import {FlashLenderCallbackFailed} from "../../src/abstract/RaindexV6FlashLender.sol"; contract TKN is ERC20 { diff --git a/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.approvalRevoked.t.sol b/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.approvalRevoked.t.sol index ec2097de67..14caf1962e 100644 --- a/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.approvalRevoked.t.sol +++ b/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.approvalRevoked.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestArb, OrderTakerSetup} from "test/util/lib/LibTestArb.sol"; import {AllowanceCheckingExchange} from "test/util/concrete/AllowanceCheckingExchange.sol"; diff --git a/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.exchangeRevert.t.sol b/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.exchangeRevert.t.sol index 7c51a62d5e..3264f54dc0 100644 --- a/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.exchangeRevert.t.sol +++ b/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.exchangeRevert.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestArb, OrderTakerSetup} from "test/util/lib/LibTestArb.sol"; import {RevertingExchange} from "test/util/concrete/RevertingExchange.sol"; diff --git a/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sender.t.sol b/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sender.t.sol index c49653ed30..d91fdaa427 100644 --- a/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sender.t.sol +++ b/test/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sender.t.sol @@ -14,9 +14,9 @@ import { IInterpreterStoreV3, TaskV2, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; contract GenericPoolRaindexV6ArbOrderTakerSenderTest is GenericPoolRaindexV6ArbOrderTakerTest { /// forge-config: default.fuzz.runs = 10 diff --git a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.approvalRevoked.t.sol b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.approvalRevoked.t.sol index 8c45400b1b..1d3b0126ac 100644 --- a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.approvalRevoked.t.sol +++ b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.approvalRevoked.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestFlashBorrowerArb, FlashBorrowerSetup} from "test/util/lib/LibTestFlashBorrowerArb.sol"; import {LibTestArb} from "test/util/lib/LibTestArb.sol"; import {AllowanceCheckingExchange} from "test/util/concrete/AllowanceCheckingExchange.sol"; diff --git a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.ethForwarded.t.sol b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.ethForwarded.t.sol index eb63f98c16..465acbb55e 100644 --- a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.ethForwarded.t.sol +++ b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.ethForwarded.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestFlashBorrowerArb, FlashBorrowerSetup} from "test/util/lib/LibTestFlashBorrowerArb.sol"; import {LibTestArb} from "test/util/lib/LibTestArb.sol"; import {AllowanceCheckingExchange} from "test/util/concrete/AllowanceCheckingExchange.sol"; diff --git a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.exchangeRevert.t.sol b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.exchangeRevert.t.sol index 8d8f8b8784..4c0118d0c3 100644 --- a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.exchangeRevert.t.sol +++ b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.exchangeRevert.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestFlashBorrowerArb, FlashBorrowerSetup} from "test/util/lib/LibTestFlashBorrowerArb.sol"; import {LibTestArb} from "test/util/lib/LibTestArb.sol"; import {RevertingExchange} from "test/util/concrete/RevertingExchange.sol"; diff --git a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.sender.t.sol b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.sender.t.sol index e6bb8e83c1..9c9c305c50 100644 --- a/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.sender.t.sol +++ b/test/concrete/arb/GenericPoolRaindexV6FlashBorrower.sender.t.sol @@ -14,9 +14,9 @@ import { IInterpreterStoreV3, TaskV2, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; contract GenericPoolRaindexV6FlashBorrowerTest is ArbTest { function buildArb() internal override returns (address payable) { diff --git a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.lossyRounding.t.sol b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.lossyRounding.t.sol index b126499459..17c55ff74f 100644 --- a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.lossyRounding.t.sol +++ b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.lossyRounding.t.sol @@ -2,14 +2,14 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {IRouteProcessor} from "sushixswap-v2/src/interfaces/IRouteProcessor.sol"; import {RouteProcessorRaindexV6ArbOrderTaker} from "../../../src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol"; -import {Float} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +import {Float} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockRouteProcessor} from "test/util/concrete/MockRouteProcessor.sol"; diff --git a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.nonStandardDecimals.t.sol b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.nonStandardDecimals.t.sol index aecc70a974..9b14299a9a 100644 --- a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.nonStandardDecimals.t.sol +++ b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.nonStandardDecimals.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RouteProcessorRaindexV6ArbOrderTaker} from "../../../src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol"; import { @@ -16,14 +16,14 @@ import { SignedContextV1, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockRouteProcessor} from "test/util/concrete/MockRouteProcessor.sol"; import {RealisticOrderTakerMockRaindex} from "test/util/concrete/RealisticOrderTakerMockRaindex.sol"; diff --git a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2.t.sol b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2.t.sol index 0e5bfa1570..7d353ee33e 100644 --- a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2.t.sol +++ b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RouteProcessorRaindexV6ArbOrderTaker} from "../../../src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol"; import { @@ -16,12 +16,12 @@ import { SignedContextV1, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockRouteProcessor} from "test/util/concrete/MockRouteProcessor.sol"; diff --git a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol index 75c84c4ca1..b9055f0e3b 100644 --- a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol +++ b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.onTakeOrders2Direct.t.sol @@ -2,12 +2,12 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {RouteProcessorRaindexV6ArbOrderTaker} from "../../../src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol"; -import {Float} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +import {Float} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockRouteProcessor} from "test/util/concrete/MockRouteProcessor.sol"; diff --git a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sender.t.sol b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sender.t.sol index 0355db8a1b..6dba848f7c 100644 --- a/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sender.t.sol +++ b/test/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sender.t.sol @@ -14,10 +14,10 @@ import { IInterpreterStoreV3, TaskV2, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {RouteProcessorRaindexV6ArbOrderTaker} from "../../../src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; contract RouteProcessorRaindexV6ArbOrderTakerSenderTest is RouteProcessorRaindexV6ArbOrderTakerTest { /// forge-config: default.fuzz.runs = 100 diff --git a/test/concrete/parser/RaindexV6SubParser.describedByMeta.t.sol b/test/concrete/parser/RaindexV6SubParser.describedByMeta.t.sol index 64cab2cfb2..3434803a75 100644 --- a/test/concrete/parser/RaindexV6SubParser.describedByMeta.t.sol +++ b/test/concrete/parser/RaindexV6SubParser.describedByMeta.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {RaindexV6SubParser} from "../../../src/concrete/parser/RaindexV6SubParser.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; diff --git a/test/concrete/parser/RaindexV6SubParser.ierc165.t.sol b/test/concrete/parser/RaindexV6SubParser.ierc165.t.sol index 819c9d57c9..b30edef316 100644 --- a/test/concrete/parser/RaindexV6SubParser.ierc165.t.sol +++ b/test/concrete/parser/RaindexV6SubParser.ierc165.t.sol @@ -2,14 +2,14 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; -import {IERC165} from "openzeppelin-contracts/contracts/utils/introspection/IERC165.sol"; +import {IERC165} from "@openzeppelin-contracts-5.6.1/utils/introspection/IERC165.sol"; import {RaindexV6SubParser} from "../../../src/concrete/parser/RaindexV6SubParser.sol"; -import {ISubParserV4} from "rain.interpreter.interface/interface/ISubParserV4.sol"; -import {IDescribedByMetaV1} from "rain.metadata/interface/IDescribedByMetaV1.sol"; -import {IParserToolingV1} from "rain.sol.codegen/interface/IParserToolingV1.sol"; -import {ISubParserToolingV1} from "rain.sol.codegen/interface/ISubParserToolingV1.sol"; +import {ISubParserV4} from "rain-interpreter-interface-0.1.0/src/interface/ISubParserV4.sol"; +import {IDescribedByMetaV1} from "rain-metadata-0.1.0/src/interface/IDescribedByMetaV1.sol"; +import {IParserToolingV1} from "rain-sol-codegen-0.1.0/src/interface/IParserToolingV1.sol"; +import {ISubParserToolingV1} from "rain-sol-codegen-0.1.0/src/interface/ISubParserToolingV1.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; diff --git a/test/concrete/parser/RaindexV6SubParser.pointers.t.sol b/test/concrete/parser/RaindexV6SubParser.pointers.t.sol index e292cda33f..e321f4a93d 100644 --- a/test/concrete/parser/RaindexV6SubParser.pointers.t.sol +++ b/test/concrete/parser/RaindexV6SubParser.pointers.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import { LibRaindexSubParser, AuthoringMetaV2, @@ -14,7 +14,7 @@ import { SUB_PARSER_OPERAND_HANDLERS, RaindexV6SubParser } from "../../../src/concrete/parser/RaindexV6SubParser.sol"; -import {LibGenParseMeta} from "rain.interpreter.interface/lib/codegen/LibGenParseMeta.sol"; +import {LibGenParseMeta} from "rain-interpreter-interface-0.1.0/src/lib/codegen/LibGenParseMeta.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; diff --git a/test/concrete/parser/RaindexV6SubParser.signedContext.t.sol b/test/concrete/parser/RaindexV6SubParser.signedContext.t.sol index 8925821aa7..fe70cfa5ce 100644 --- a/test/concrete/parser/RaindexV6SubParser.signedContext.t.sol +++ b/test/concrete/parser/RaindexV6SubParser.signedContext.t.sol @@ -2,10 +2,10 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {StackAllocationMismatch} from "rain.interpreter/error/ErrIntegrity.sol"; -import {ExpectedOperand, UnexpectedOperandValue} from "rain.interpreter/error/ErrParse.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; -import {OpTest, StackItem} from "rain.interpreter/../test/abstract/OpTest.sol"; +import {StackAllocationMismatch} from "rainlang-0.1.2/src/error/ErrIntegrity.sol"; +import {ExpectedOperand, UnexpectedOperandValue} from "rainlang-0.1.2/src/error/ErrParse.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; +import {OpTest, StackItem} from "rainlang-0.1.2/src/../test/abstract/OpTest.sol"; import {LibRaindexSubParserContextFixture} from "test/util/fixture/LibRaindexSubParserContextFixture.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; diff --git a/test/concrete/parser/RaindexV6SubParser.signers.t.sol b/test/concrete/parser/RaindexV6SubParser.signers.t.sol index 6249ebb3d0..1b90ab5739 100644 --- a/test/concrete/parser/RaindexV6SubParser.signers.t.sol +++ b/test/concrete/parser/RaindexV6SubParser.signers.t.sol @@ -2,10 +2,10 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {StackAllocationMismatch} from "rain.interpreter/error/ErrIntegrity.sol"; -import {ExpectedOperand, UnexpectedOperandValue} from "rain.interpreter/error/ErrParse.sol"; -import {OpTest, StackItem} from "rain.interpreter/../test/abstract/OpTest.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; +import {StackAllocationMismatch} from "rainlang-0.1.2/src/error/ErrIntegrity.sol"; +import {ExpectedOperand, UnexpectedOperandValue} from "rainlang-0.1.2/src/error/ErrParse.sol"; +import {OpTest, StackItem} from "rainlang-0.1.2/src/../test/abstract/OpTest.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; import {LibRaindexSubParserContextFixture} from "test/util/fixture/LibRaindexSubParserContextFixture.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; diff --git a/test/concrete/raindex/RaindexV6.addOrder.entask.t.sol b/test/concrete/raindex/RaindexV6.addOrder.entask.t.sol index 29cccbb270..8bac05aa73 100644 --- a/test/concrete/raindex/RaindexV6.addOrder.entask.t.sol +++ b/test/concrete/raindex/RaindexV6.addOrder.entask.t.sol @@ -9,11 +9,11 @@ import { TaskV2, OrderV4, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; contract RaindexV6AddOrderEnactTest is RaindexV6ExternalRealTest { using LibOrder for OrderV4; diff --git a/test/concrete/raindex/RaindexV6.addOrder.mock.t.sol b/test/concrete/raindex/RaindexV6.addOrder.mock.t.sol index c7a3014d28..72305201a8 100644 --- a/test/concrete/raindex/RaindexV6.addOrder.mock.t.sol +++ b/test/concrete/raindex/RaindexV6.addOrder.mock.t.sol @@ -3,11 +3,11 @@ pragma solidity =0.8.25; import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; -import {OrderConfigV4, OrderV4, IOV2, EvaluableV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderConfigV4, OrderV4, IOV2, EvaluableV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; -import {NotRainMetaV1, META_MAGIC_NUMBER_V1} from "rain.metadata/interface/unstable/IMetaV1_2.sol"; -import {LibMeta} from "rain.metadata/lib/LibMeta.sol"; -import {IExpressionDeployerV3} from "rain.interpreter.interface/interface/deprecated/v1/IExpressionDeployerV3.sol"; +import {NotRainMetaV1, META_MAGIC_NUMBER_V1} from "rain-metadata-0.1.0/src/interface/unstable/IMetaV1_2.sol"; +import {LibMeta} from "rain-metadata-0.1.0/src/lib/LibMeta.sol"; +import {IExpressionDeployerV3} from "rain-interpreter-interface-0.1.0/src/interface/deprecated/v1/IExpressionDeployerV3.sol"; /// @title RaindexV6AddOrderMockTest /// @notice Tests the addOrder function of the RaindexV6 contract. diff --git a/test/concrete/raindex/RaindexV6.addOrder.nonce.t.sol b/test/concrete/raindex/RaindexV6.addOrder.nonce.t.sol index f559896db3..54f4dfdb08 100644 --- a/test/concrete/raindex/RaindexV6.addOrder.nonce.t.sol +++ b/test/concrete/raindex/RaindexV6.addOrder.nonce.t.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; -import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; diff --git a/test/concrete/raindex/RaindexV6.addOrder.owner.t.sol b/test/concrete/raindex/RaindexV6.addOrder.owner.t.sol index cbd12f1d90..da0257f7aa 100644 --- a/test/concrete/raindex/RaindexV6.addOrder.owner.t.sol +++ b/test/concrete/raindex/RaindexV6.addOrder.owner.t.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; -import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; diff --git a/test/concrete/raindex/RaindexV6.addOrder.t.sol b/test/concrete/raindex/RaindexV6.addOrder.t.sol index 05f32c5b01..e4fa357866 100644 --- a/test/concrete/raindex/RaindexV6.addOrder.t.sol +++ b/test/concrete/raindex/RaindexV6.addOrder.t.sol @@ -4,8 +4,8 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; -import {OrderConfigV4, EvaluableV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IParserV2} from "rain.interpreter.interface/interface/IParserV2.sol"; +import {OrderConfigV4, EvaluableV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IParserV2} from "rain-interpreter-interface-0.1.0/src/interface/IParserV2.sol"; import {UnsupportedCalculateOutputs} from "../../../src/concrete/raindex/RaindexV6.sol"; /// @title RaindexV6AddOrderTest diff --git a/test/concrete/raindex/RaindexV6.clear.badStack.t.sol b/test/concrete/raindex/RaindexV6.clear.badStack.t.sol index 02fe1f2156..328949d627 100644 --- a/test/concrete/raindex/RaindexV6.clear.badStack.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.badStack.t.sol @@ -11,9 +11,9 @@ import { ClearConfigV2, SignedContextV1, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {UnsupportedCalculateOutputs} from "../../../src/concrete/raindex/RaindexV6.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; contract RaindexV6ClearOrderBadStackTest is RaindexV6ExternalRealTest { function checkBadStack( diff --git a/test/concrete/raindex/RaindexV6.clear.context.t.sol b/test/concrete/raindex/RaindexV6.clear.context.t.sol index 5b5f4eed74..0e36e3f790 100644 --- a/test/concrete/raindex/RaindexV6.clear.context.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.context.t.sol @@ -12,13 +12,13 @@ import { SignedContextV1, IOV2, EvaluableV4 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {REVERTING_MOCK_BYTECODE} from "test/util/lib/LibTestConstants.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; struct ClearContextVaultIds { bytes32 aliceInputVaultId; diff --git a/test/concrete/raindex/RaindexV6.clear.handleIO.revert.t.sol b/test/concrete/raindex/RaindexV6.clear.handleIO.revert.t.sol index 2e05b98edf..1e71861f90 100644 --- a/test/concrete/raindex/RaindexV6.clear.handleIO.revert.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.handleIO.revert.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Vm} from "forge-std/Vm.sol"; +import {Vm} from "forge-std-1.16.1/src/Vm.sol"; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import { ClearConfigV2, @@ -13,9 +13,9 @@ import { SignedContextV1, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {SourceIndexOutOfBounds} from "rain.interpreter.interface/error/ErrBytecode.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {SourceIndexOutOfBounds} from "rain-interpreter-interface-0.1.0/src/error/ErrBytecode.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; /// @title RaindexV6ClearHandleIORevertTest diff --git a/test/concrete/raindex/RaindexV6.clear.mock.t.sol b/test/concrete/raindex/RaindexV6.clear.mock.t.sol index 27830a9d40..6ecab7bfe8 100644 --- a/test/concrete/raindex/RaindexV6.clear.mock.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.mock.t.sol @@ -2,9 +2,9 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test, stdError} from "forge-std/Test.sol"; +import {Test, stdError} from "forge-std-1.16.1/src/Test.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; import { OrderConfigV4, @@ -16,19 +16,19 @@ import { IInterpreterV4, TaskV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {NotOrderOwner, StackItem, NegativeBounty, ClearZeroAmount} from "../../../src/concrete/raindex/RaindexV6.sol"; -import {LibNamespace} from "rain.interpreter.interface/lib/ns/LibNamespace.sol"; -import {StateNamespace, EvalV4, SourceIndexV2} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; +import {LibNamespace} from "rain-interpreter-interface-0.1.0/src/lib/ns/LibNamespace.sol"; +import {StateNamespace, EvalV4, SourceIndexV2} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; import { LibFixedPointDecimalArithmeticOpenZeppelin -} from "rain.math.fixedpoint/lib/LibFixedPointDecimalArithmeticOpenZeppelin.sol"; -import {Math} from "openzeppelin-contracts/contracts/utils/math/Math.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +} from "rain-math-fixedpoint-0.1.0/src/lib/LibFixedPointDecimalArithmeticOpenZeppelin.sol"; +import {Math} from "@openzeppelin-contracts-4.8.3/utils/math/Math.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; -import {LibFormatDecimalFloat} from "rain.math.float/lib/format/LibFormatDecimalFloat.sol"; -import {console2} from "forge-std/console2.sol"; +import {LibFormatDecimalFloat} from "rain-math-float-0.1.1/src/lib/format/LibFormatDecimalFloat.sol"; +import {console2} from "forge-std-1.16.1/src/console2.sol"; contract MockInterpreter { StackItem[] internal sStack; @@ -789,7 +789,7 @@ contract RaindexV6ClearTest is RaindexV6ExternalMockTest { ) external { // 0 tested separately. aliceIORatio18 = bound(aliceIORatio18, 1, 1e18); - bobIORatio18 = bound(bobIORatio18, 1e18, uint256(1e18).fixedPointDiv(aliceIORatio18, Math.Rounding.Floor)); + bobIORatio18 = bound(bobIORatio18, 1e18, uint256(1e18).fixedPointDiv(aliceIORatio18, Math.Rounding.Down)); Float aliceIORatio = LibDecimalFloat.fromFixedDecimalLosslessPacked(aliceIORatio18, 18); Float bobIORatio = LibDecimalFloat.fromFixedDecimalLosslessPacked(bobIORatio18, 18); diff --git a/test/concrete/raindex/RaindexV6.clear.sameOwner.t.sol b/test/concrete/raindex/RaindexV6.clear.sameOwner.t.sol index 90d14be257..1d15a95058 100644 --- a/test/concrete/raindex/RaindexV6.clear.sameOwner.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.sameOwner.t.sol @@ -5,8 +5,8 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; -import {OrderConfigV4, OrderV4, ClearConfigV2, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {SignedContextV1} from "rain.interpreter.interface/interface/deprecated/v1/IInterpreterCallerV2.sol"; +import {OrderConfigV4, OrderV4, ClearConfigV2, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {SignedContextV1} from "rain-interpreter-interface-0.1.0/src/interface/deprecated/v1/IInterpreterCallerV2.sol"; import {SameOwner} from "../../../src/concrete/raindex/RaindexV6.sol"; /// Clearing two orders with the same owner must revert with SameOwner. diff --git a/test/concrete/raindex/RaindexV6.clear.sameToken.t.sol b/test/concrete/raindex/RaindexV6.clear.sameToken.t.sol index 4521230c51..df59bdf890 100644 --- a/test/concrete/raindex/RaindexV6.clear.sameToken.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.sameToken.t.sol @@ -10,7 +10,7 @@ import { ClearConfigV2, SignedContextV1, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {TokenSelfTrade} from "../../../src/concrete/raindex/RaindexV6.sol"; diff --git a/test/concrete/raindex/RaindexV6.clear.zeroAmount.t.sol b/test/concrete/raindex/RaindexV6.clear.zeroAmount.t.sol index 629c484a51..4f1920979d 100644 --- a/test/concrete/raindex/RaindexV6.clear.zeroAmount.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.zeroAmount.t.sol @@ -9,7 +9,7 @@ import { TaskV2, SignedContextV1, ClearConfigV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {ClearZeroAmount} from "../../../src/concrete/raindex/RaindexV6.sol"; diff --git a/test/concrete/raindex/RaindexV6.deposit.entask.t.sol b/test/concrete/raindex/RaindexV6.deposit.entask.t.sol index ae7efa56ba..e076ee631a 100644 --- a/test/concrete/raindex/RaindexV6.deposit.entask.t.sol +++ b/test/concrete/raindex/RaindexV6.deposit.entask.t.sol @@ -3,12 +3,12 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest, LibDecimalFloat, Float} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; -import {OrderConfigV4, EvaluableV4, TaskV2, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; -import {LibFormatDecimalFloat} from "rain.math.float/lib/format/LibFormatDecimalFloat.sol"; +import {OrderConfigV4, EvaluableV4, TaskV2, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; +import {LibFormatDecimalFloat} from "rain-math-float-0.1.1/src/lib/format/LibFormatDecimalFloat.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; contract RaindexV6DepositEnactTest is RaindexV6ExternalRealTest { using Strings for address; diff --git a/test/concrete/raindex/RaindexV6.deposit.t.sol b/test/concrete/raindex/RaindexV6.deposit.t.sol index 9c3edaaf75..5c82c5710a 100644 --- a/test/concrete/raindex/RaindexV6.deposit.t.sol +++ b/test/concrete/raindex/RaindexV6.deposit.t.sol @@ -2,16 +2,16 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {stdError} from "forge-std/Test.sol"; +import {stdError} from "forge-std-1.16.1/src/Test.sol"; import {REVERTING_MOCK_BYTECODE, CONSOLE_ADDRESS} from "test/util/lib/LibTestConstants.sol"; import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; -import {TaskV2, EvaluableV4, IRaindexV6} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {TaskV2, EvaluableV4, IRaindexV6} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {Reenteroor} from "test/util/concrete/Reenteroor.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; -import {ReentrancyGuard} from "openzeppelin-contracts/contracts/utils/ReentrancyGuard.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; +import {ReentrancyGuard} from "@openzeppelin-contracts-5.6.1/utils/ReentrancyGuard.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; /// @title RaindexV6DepositTest /// Tests depositing to a raindex. diff --git a/test/concrete/raindex/RaindexV6.entask.t.sol b/test/concrete/raindex/RaindexV6.entask.t.sol index e8ef5bbff2..9401d2741b 100644 --- a/test/concrete/raindex/RaindexV6.entask.t.sol +++ b/test/concrete/raindex/RaindexV6.entask.t.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; -import {OrderConfigV4, EvaluableV4, TaskV2, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderConfigV4, EvaluableV4, TaskV2, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; contract RaindexV6EnactTest is RaindexV6ExternalRealTest { function checkReentrancyRW() internal view { diff --git a/test/concrete/raindex/RaindexV6.quote.sameToken.t.sol b/test/concrete/raindex/RaindexV6.quote.sameToken.t.sol index e0a1a0b975..b6dc3e684f 100644 --- a/test/concrete/raindex/RaindexV6.quote.sameToken.t.sol +++ b/test/concrete/raindex/RaindexV6.quote.sameToken.t.sol @@ -3,9 +3,9 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; -import {QuoteV2, OrderConfigV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {QuoteV2, OrderConfigV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {TokenSelfTrade} from "../../../src/concrete/raindex/RaindexV6.sol"; -import {Float} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; /// @title RaindexV6QuoteSameTokenTest contract RaindexV6QuoteSameTokenTest is RaindexV6ExternalRealTest { diff --git a/test/concrete/raindex/RaindexV6.quote.t.sol b/test/concrete/raindex/RaindexV6.quote.t.sol index 4de0841a30..b4f10b852e 100644 --- a/test/concrete/raindex/RaindexV6.quote.t.sol +++ b/test/concrete/raindex/RaindexV6.quote.t.sol @@ -11,15 +11,15 @@ import { TaskV2, OrderV4, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; import {TokenSelfTrade} from "../../../src/concrete/raindex/RaindexV6.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; -import {LibFormatDecimalFloat} from "rain.math.float/lib/format/LibFormatDecimalFloat.sol"; +import {LibFormatDecimalFloat} from "rain-math-float-0.1.1/src/lib/format/LibFormatDecimalFloat.sol"; /// @title RaindexV6QuoteTest contract RaindexV6QuoteTest is RaindexV6ExternalRealTest { diff --git a/test/concrete/raindex/RaindexV6.removeOrder.entask.t.sol b/test/concrete/raindex/RaindexV6.removeOrder.entask.t.sol index 48840b31a5..73f0d9699d 100644 --- a/test/concrete/raindex/RaindexV6.removeOrder.entask.t.sol +++ b/test/concrete/raindex/RaindexV6.removeOrder.entask.t.sol @@ -9,11 +9,11 @@ import { OrderV4, TaskV2, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; contract RaindexV6RemoveOrderEnactTest is RaindexV6ExternalRealTest { using LibOrder for OrderV4; diff --git a/test/concrete/raindex/RaindexV6.removeOrder.mock.t.sol b/test/concrete/raindex/RaindexV6.removeOrder.mock.t.sol index 62524a3a2e..74ab223a6d 100644 --- a/test/concrete/raindex/RaindexV6.removeOrder.mock.t.sol +++ b/test/concrete/raindex/RaindexV6.removeOrder.mock.t.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; -import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {NotOrderOwner} from "../../../src/concrete/raindex/RaindexV6.sol"; diff --git a/test/concrete/raindex/RaindexV6.removeOrder.owner.t.sol b/test/concrete/raindex/RaindexV6.removeOrder.owner.t.sol index a45243d060..ee801705ba 100644 --- a/test/concrete/raindex/RaindexV6.removeOrder.owner.t.sol +++ b/test/concrete/raindex/RaindexV6.removeOrder.owner.t.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; -import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderConfigV4, OrderV4, EvaluableV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; import {NotOrderOwner} from "../../../src/concrete/raindex/RaindexV6.sol"; diff --git a/test/concrete/raindex/RaindexV6.takeOrder.badStack.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.badStack.t.sol index fe8a067366..c009319168 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.badStack.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.badStack.t.sol @@ -5,7 +5,7 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; -import {OrderConfigV4, OrderV4, TaskV2, TakeOrdersConfigV5} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {OrderConfigV4, OrderV4, TaskV2, TakeOrdersConfigV5} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {UnsupportedCalculateOutputs} from "../../../src/concrete/raindex/RaindexV6.sol"; contract RaindexV6TakeOrderBadStackTest is RaindexV6ExternalRealTest { diff --git a/test/concrete/raindex/RaindexV6.takeOrder.exceedsMaxRatio.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.exceedsMaxRatio.t.sol index 2e3c6a9572..637e0eb6a6 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.exceedsMaxRatio.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.exceedsMaxRatio.t.sol @@ -2,11 +2,11 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; -import {OrderV4, TakeOrdersConfigV5, TaskV2, IRaindexV6} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {OrderV4, TakeOrdersConfigV5, TaskV2, IRaindexV6} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; /// When an order's IORatio exceeds the taker's maximumIORatio, the order diff --git a/test/concrete/raindex/RaindexV6.takeOrder.handleIO.revert.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.handleIO.revert.t.sol index aef659267f..4eb6bf15df 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.handleIO.revert.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.handleIO.revert.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Vm} from "forge-std/Vm.sol"; +import {Vm} from "forge-std-1.16.1/src/Vm.sol"; import {RaindexV6ExternalRealTest, IERC20} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import { OrderV4, @@ -12,10 +12,10 @@ import { TakeOrdersConfigV5, EvaluableV4, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {SourceIndexOutOfBounds} from "rain.interpreter.interface/error/ErrBytecode.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {SourceIndexOutOfBounds} from "rain-interpreter-interface-0.1.0/src/error/ErrBytecode.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; /// @title RaindexV6TakeOrderHandleIORevertTest diff --git a/test/concrete/raindex/RaindexV6.takeOrder.maximumInput.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.maximumInput.t.sol index 62a3031de5..e5193bf570 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.maximumInput.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.maximumInput.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RaindexV6ExternalRealTest, Vm} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import { OrderV4, @@ -13,12 +13,12 @@ import { OrderConfigV4, TaskV2, IRaindexV6 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {SignedContextV1} from "rain.interpreter.interface/interface/deprecated/v1/IInterpreterCallerV2.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {SignedContextV1} from "rain-interpreter-interface-0.1.0/src/interface/deprecated/v1/IInterpreterCallerV2.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibFormatDecimalFloat} from "rain.math.float/lib/format/LibFormatDecimalFloat.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibFormatDecimalFloat} from "rain-math-float-0.1.1/src/lib/format/LibFormatDecimalFloat.sol"; contract RaindexV6TakeOrderMaximumInputTest is RaindexV6ExternalRealTest { using LibDecimalFloat for Float; diff --git a/test/concrete/raindex/RaindexV6.takeOrder.maximumOutput.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.maximumOutput.t.sol index 849679c663..bce96c5124 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.maximumOutput.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.maximumOutput.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RaindexV6ExternalRealTest, Vm} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import { OrderV4, @@ -14,9 +14,9 @@ import { IOV2, EvaluableV4, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; contract RaindexV6TakeOrderMaximumOutputTest is RaindexV6ExternalRealTest { using LibDecimalFloat for Float; diff --git a/test/concrete/raindex/RaindexV6.takeOrder.minimumIO.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.minimumIO.t.sol index d1c1fbd9da..79d713fb79 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.minimumIO.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.minimumIO.t.sol @@ -2,11 +2,11 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; -import {OrderV4, TakeOrdersConfigV5, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {OrderV4, TakeOrdersConfigV5, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; import {MinimumIO} from "../../../src/concrete/raindex/RaindexV6.sol"; /// When the total taker IO is less than the configured minimumIO, diff --git a/test/concrete/raindex/RaindexV6.takeOrder.noop.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.noop.t.sol index 2d3a375364..6cae97d72f 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.noop.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.noop.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Vm} from "forge-std/Test.sol"; +import {Vm} from "forge-std-1.16.1/src/Test.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; @@ -12,9 +12,9 @@ import { TakeOrdersConfigV5, TakeOrderConfigV4, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; /// @title RaindexV6TakeOrderNoopTest /// @notice A test harness for testing the Raindex takeOrder function. Focuses diff --git a/test/concrete/raindex/RaindexV6.takeOrder.precision.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.precision.t.sol index d0bf1346bd..19b3f543b2 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.precision.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.precision.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Vm} from "forge-std/Test.sol"; +import {Vm} from "forge-std-1.16.1/src/Test.sol"; import {RaindexV6ExternalRealTest, IERC20} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; import { OrderV4, @@ -12,9 +12,9 @@ import { OrderConfigV4, EvaluableV4, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; import {LibTestTakeOrder} from "test/util/lib/LibTestTakeOrder.sol"; /// @title RaindexV6TakeOrderPrecisionTest diff --git a/test/concrete/raindex/RaindexV6.takeOrder.sameToken.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.sameToken.t.sol index 59d666a9cd..1a91ef9cea 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.sameToken.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.sameToken.t.sol @@ -10,10 +10,10 @@ import { TakeOrderConfigV4, SignedContextV1, TakeOrdersConfigV5 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {TokenSelfTrade} from "../../../src/concrete/raindex/RaindexV6.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; contract RaindexV6TakeOrderSameTokenTest is RaindexV6ExternalRealTest { /// forge-config: default.fuzz.runs = 10 diff --git a/test/concrete/raindex/RaindexV6.takeOrder.tokenMismatch.t.sol b/test/concrete/raindex/RaindexV6.takeOrder.tokenMismatch.t.sol index 9795eb73bf..0c144c626f 100644 --- a/test/concrete/raindex/RaindexV6.takeOrder.tokenMismatch.t.sol +++ b/test/concrete/raindex/RaindexV6.takeOrder.tokenMismatch.t.sol @@ -10,9 +10,9 @@ import { TakeOrdersConfigV5, EvaluableV4, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import {TokenMismatch} from "../../../src/concrete/raindex/RaindexV6.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; /// @title RaindexV6TakeOrderTokenMismatchTest /// @notice A test harness for testing the RaindexV6 takeOrder function. diff --git a/test/concrete/raindex/RaindexV6.vaultBalance.t.sol b/test/concrete/raindex/RaindexV6.vaultBalance.t.sol index fed27c63c1..9eda5a22f0 100644 --- a/test/concrete/raindex/RaindexV6.vaultBalance.t.sol +++ b/test/concrete/raindex/RaindexV6.vaultBalance.t.sol @@ -3,8 +3,8 @@ pragma solidity =0.8.25; import {RaindexV6ExternalMockTest} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {IRaindexV6} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {IRaindexV6} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; /// @title RaindexV6VaultBalanceTest /// Tests the basic functionality of reading from the vault balance. diff --git a/test/concrete/raindex/RaindexV6.withdraw.entask.t.sol b/test/concrete/raindex/RaindexV6.withdraw.entask.t.sol index e9ca0c4499..60c7148f84 100644 --- a/test/concrete/raindex/RaindexV6.withdraw.entask.t.sol +++ b/test/concrete/raindex/RaindexV6.withdraw.entask.t.sol @@ -3,16 +3,16 @@ pragma solidity =0.8.25; import {RaindexV6ExternalRealTest} from "test/util/abstract/RaindexV6ExternalRealTest.sol"; -import {OrderConfigV4, EvaluableV4, TaskV2, SignedContextV1} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +import {OrderConfigV4, EvaluableV4, TaskV2, SignedContextV1} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibFormatDecimalFloat} from "rain.math.float/lib/format/LibFormatDecimalFloat.sol"; -import {ReentrancyGuard} from "openzeppelin-contracts/contracts/utils/ReentrancyGuard.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibFormatDecimalFloat} from "rain-math-float-0.1.1/src/lib/format/LibFormatDecimalFloat.sol"; +import {ReentrancyGuard} from "@openzeppelin-contracts-5.6.1/utils/ReentrancyGuard.sol"; -import {console2} from "forge-std/Test.sol"; +import {console2} from "forge-std-1.16.1/src/Test.sol"; contract RaindexV6WithdrawEvalTest is RaindexV6ExternalRealTest { using Strings for address; diff --git a/test/concrete/raindex/RaindexV6.withdraw.t.sol b/test/concrete/raindex/RaindexV6.withdraw.t.sol index 5e62d7fdc3..e6a6898c02 100644 --- a/test/concrete/raindex/RaindexV6.withdraw.t.sol +++ b/test/concrete/raindex/RaindexV6.withdraw.t.sol @@ -2,18 +2,18 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; -import {Math} from "openzeppelin-contracts/contracts/utils/math/Math.sol"; +import {Math} from "@openzeppelin-contracts-5.6.1/utils/math/Math.sol"; import {RaindexV6ExternalMockTest, REVERTING_MOCK_BYTECODE} from "test/util/abstract/RaindexV6ExternalMockTest.sol"; import {Reenteroor, IERC20} from "test/util/concrete/Reenteroor.sol"; -import {TaskV2, IRaindexV6} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +import {TaskV2, IRaindexV6} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibDecimalFloatImplementation} from "rain.math.float/lib/implementation/LibDecimalFloatImplementation.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibDecimalFloatImplementation} from "rain-math-float-0.1.1/src/lib/implementation/LibDecimalFloatImplementation.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; /// @title RaindexV6WithdrawTest /// Tests withdrawing from the raindex. diff --git a/test/lib/LibOrder.t.sol b/test/lib/LibOrder.t.sol index 52cd33c199..47ed1fc265 100644 --- a/test/lib/LibOrder.t.sol +++ b/test/lib/LibOrder.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibOrder, OrderV4} from "../../src/lib/LibOrder.sol"; diff --git a/test/lib/LibRaindexArb.finalizeArbNativeGas.t.sol b/test/lib/LibRaindexArb.finalizeArbNativeGas.t.sol index 4164191a42..19109a6dc7 100644 --- a/test/lib/LibRaindexArb.finalizeArbNativeGas.t.sol +++ b/test/lib/LibRaindexArb.finalizeArbNativeGas.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestArb, ArbResult} from "test/util/lib/LibTestArb.sol"; contract LibRaindexArbFinalizeArbNativeGasTest is Test { diff --git a/test/lib/LibRaindexArb.finalizeArbOutputTokenProfit.t.sol b/test/lib/LibRaindexArb.finalizeArbOutputTokenProfit.t.sol index c647d065c6..55790f933f 100644 --- a/test/lib/LibRaindexArb.finalizeArbOutputTokenProfit.t.sol +++ b/test/lib/LibRaindexArb.finalizeArbOutputTokenProfit.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestArb, ArbResult} from "test/util/lib/LibTestArb.sol"; contract LibRaindexArbFinalizeArbOutputTokenProfitTest is Test { diff --git a/test/lib/LibRaindexArb.finalizeArbTaskContext.t.sol b/test/lib/LibRaindexArb.finalizeArbTaskContext.t.sol index 041c8c3ee7..94bcef8ac0 100644 --- a/test/lib/LibRaindexArb.finalizeArbTaskContext.t.sol +++ b/test/lib/LibRaindexArb.finalizeArbTaskContext.t.sol @@ -2,12 +2,12 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {EvaluableV4, SignedContextV1, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {IParserV2} from "rain.interpreter.interface/interface/IParserV2.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {EvaluableV4, SignedContextV1, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {IParserV2} from "rain-interpreter-interface-0.1.0/src/interface/IParserV2.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; import {LibTestArb, ArbResult} from "test/util/lib/LibTestArb.sol"; /// @title LibRaindexArbFinalizeArbTaskContextTest diff --git a/test/lib/LibRaindexArb.finalizeArbTokenTransfers.t.sol b/test/lib/LibRaindexArb.finalizeArbTokenTransfers.t.sol index b175424882..c09a9bddf3 100644 --- a/test/lib/LibRaindexArb.finalizeArbTokenTransfers.t.sol +++ b/test/lib/LibRaindexArb.finalizeArbTokenTransfers.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibTestArb, ArbResult} from "test/util/lib/LibTestArb.sol"; contract LibRaindexArbFinalizeArbTokenTransfersTest is Test { diff --git a/test/lib/deploy/LibRaindexDeploy.t.sol b/test/lib/deploy/LibRaindexDeploy.t.sol index 3e84ce7643..19a6e390fb 100644 --- a/test/lib/deploy/LibRaindexDeploy.t.sol +++ b/test/lib/deploy/LibRaindexDeploy.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; import {RaindexV6} from "../../../src/concrete/raindex/RaindexV6.sol"; diff --git a/test/lib/deploy/LibRaindexDeployIsStartBlockArbitrum.t.sol b/test/lib/deploy/LibRaindexDeployIsStartBlockArbitrum.t.sol index baec111528..96a55ee562 100644 --- a/test/lib/deploy/LibRaindexDeployIsStartBlockArbitrum.t.sol +++ b/test/lib/deploy/LibRaindexDeployIsStartBlockArbitrum.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployIsStartBlockArbitrumTest diff --git a/test/lib/deploy/LibRaindexDeployIsStartBlockBase.t.sol b/test/lib/deploy/LibRaindexDeployIsStartBlockBase.t.sol index 41eeaa2914..c5977eded1 100644 --- a/test/lib/deploy/LibRaindexDeployIsStartBlockBase.t.sol +++ b/test/lib/deploy/LibRaindexDeployIsStartBlockBase.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployIsStartBlockBaseTest diff --git a/test/lib/deploy/LibRaindexDeployIsStartBlockFlare.t.sol b/test/lib/deploy/LibRaindexDeployIsStartBlockFlare.t.sol index 1d9fc39844..92b3f0b19c 100644 --- a/test/lib/deploy/LibRaindexDeployIsStartBlockFlare.t.sol +++ b/test/lib/deploy/LibRaindexDeployIsStartBlockFlare.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployIsStartBlockFlareTest diff --git a/test/lib/deploy/LibRaindexDeployIsStartBlockPolygon.t.sol b/test/lib/deploy/LibRaindexDeployIsStartBlockPolygon.t.sol index 62dc2b5437..4ef3f9efd3 100644 --- a/test/lib/deploy/LibRaindexDeployIsStartBlockPolygon.t.sol +++ b/test/lib/deploy/LibRaindexDeployIsStartBlockPolygon.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployIsStartBlockPolygonTest diff --git a/test/lib/deploy/LibRaindexDeployNetworksJsonAddresses.t.sol b/test/lib/deploy/LibRaindexDeployNetworksJsonAddresses.t.sol index e46e29effe..0c98a134c6 100644 --- a/test/lib/deploy/LibRaindexDeployNetworksJsonAddresses.t.sol +++ b/test/lib/deploy/LibRaindexDeployNetworksJsonAddresses.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployNetworksJsonAddressesTest diff --git a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockArbitrum.t.sol b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockArbitrum.t.sol index 81fc963ae7..b664449402 100644 --- a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockArbitrum.t.sol +++ b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockArbitrum.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployNetworksJsonStartBlockArbitrumTest diff --git a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockBase.t.sol b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockBase.t.sol index 87993b7e93..0c03b8f961 100644 --- a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockBase.t.sol +++ b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockBase.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployNetworksJsonStartBlockBaseTest diff --git a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockFlare.t.sol b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockFlare.t.sol index a0041760fd..1ea94abc8c 100644 --- a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockFlare.t.sol +++ b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockFlare.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployNetworksJsonStartBlockFlareTest diff --git a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockPolygon.t.sol b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockPolygon.t.sol index b65cc15131..ab59198dad 100644 --- a/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockPolygon.t.sol +++ b/test/lib/deploy/LibRaindexDeployNetworksJsonStartBlockPolygon.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployNetworksJsonStartBlockPolygonTest diff --git a/test/lib/deploy/LibRaindexDeployProd.t.sol b/test/lib/deploy/LibRaindexDeployProd.t.sol index 9a549f6383..d343231b83 100644 --- a/test/lib/deploy/LibRaindexDeployProd.t.sol +++ b/test/lib/deploy/LibRaindexDeployProd.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployProdTest diff --git a/test/lib/deploy/LibRaindexDeployStartBlockArbitrum.t.sol b/test/lib/deploy/LibRaindexDeployStartBlockArbitrum.t.sol index fa26dc23fe..83c204f584 100644 --- a/test/lib/deploy/LibRaindexDeployStartBlockArbitrum.t.sol +++ b/test/lib/deploy/LibRaindexDeployStartBlockArbitrum.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployStartBlockArbitrumTest diff --git a/test/lib/deploy/LibRaindexDeployStartBlockBase.t.sol b/test/lib/deploy/LibRaindexDeployStartBlockBase.t.sol index f56ad4e7e1..1fccf7fb25 100644 --- a/test/lib/deploy/LibRaindexDeployStartBlockBase.t.sol +++ b/test/lib/deploy/LibRaindexDeployStartBlockBase.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployStartBlockBaseTest diff --git a/test/lib/deploy/LibRaindexDeployStartBlockFlare.t.sol b/test/lib/deploy/LibRaindexDeployStartBlockFlare.t.sol index 55673d3f7b..cbc40207e9 100644 --- a/test/lib/deploy/LibRaindexDeployStartBlockFlare.t.sol +++ b/test/lib/deploy/LibRaindexDeployStartBlockFlare.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployStartBlockFlareTest diff --git a/test/lib/deploy/LibRaindexDeployStartBlockPolygon.t.sol b/test/lib/deploy/LibRaindexDeployStartBlockPolygon.t.sol index 1ddbb0e80b..c23b905b17 100644 --- a/test/lib/deploy/LibRaindexDeployStartBlockPolygon.t.sol +++ b/test/lib/deploy/LibRaindexDeployStartBlockPolygon.t.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeployStartBlockPolygonTest diff --git a/test/lib/deploy/LibRaindexDeploySubgraphYamlAddress.t.sol b/test/lib/deploy/LibRaindexDeploySubgraphYamlAddress.t.sol index 123640064e..dc58b7a884 100644 --- a/test/lib/deploy/LibRaindexDeploySubgraphYamlAddress.t.sol +++ b/test/lib/deploy/LibRaindexDeploySubgraphYamlAddress.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {LibRaindexDeploy} from "src/lib/deploy/LibRaindexDeploy.sol"; /// @title LibRaindexDeploySubgraphYamlAddressTest diff --git a/test/lib/deploy/LibRouteProcessor4CreationCode.t.sol b/test/lib/deploy/LibRouteProcessor4CreationCode.t.sol index 1f0be4c191..223aab8dc2 100644 --- a/test/lib/deploy/LibRouteProcessor4CreationCode.t.sol +++ b/test/lib/deploy/LibRouteProcessor4CreationCode.t.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {ROUTE_PROCESSOR_4_CREATION_CODE} from "../../../src/lib/deploy/LibRouteProcessor4CreationCode.sol"; /// @dev Known codehash of the RouteProcessor4 runtime bytecode, verified diff --git a/test/util/abstract/ArbTest.sol b/test/util/abstract/ArbTest.sol index a5632532f6..0e54e3a24f 100644 --- a/test/util/abstract/ArbTest.sol +++ b/test/util/abstract/ArbTest.sol @@ -2,9 +2,9 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; -import {ERC20} from "openzeppelin-contracts/contracts/token/ERC20/ERC20.sol"; +import {ERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/ERC20.sol"; import {Refundoor} from "test/util/concrete/Refundoor.sol"; import { FlashLendingMockRaindex, @@ -14,8 +14,8 @@ import { SignedContextV1, EvaluableV4 } from "test/util/concrete/FlashLendingMockRaindex.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; contract Token is ERC20 { diff --git a/test/util/abstract/IRaindexV6Stub.sol b/test/util/abstract/IRaindexV6Stub.sol index 040cefa158..472353660a 100644 --- a/test/util/abstract/IRaindexV6Stub.sol +++ b/test/util/abstract/IRaindexV6Stub.sol @@ -13,9 +13,9 @@ import { TaskV2, QuoteV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC3156FlashLender} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashLender.sol"; -import {IERC3156FlashBorrower} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC3156FlashLender} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashLender.sol"; +import {IERC3156FlashBorrower} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; abstract contract IRaindexV6Stub is IRaindexV6 { /// @inheritdoc IRaindexV6 diff --git a/test/util/abstract/MockRaindexBase.sol b/test/util/abstract/MockRaindexBase.sol index d8e0a76328..46a4e85f2e 100644 --- a/test/util/abstract/MockRaindexBase.sol +++ b/test/util/abstract/MockRaindexBase.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; import { IRaindexV6, TakeOrdersConfigV5, @@ -14,8 +14,8 @@ import { TaskV2, QuoteV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC3156FlashBorrower} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC3156FlashBorrower} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; /// @dev Base for mock raindex contracts that stub all IRaindexV6 functions. /// Inheritors override flashLoan and/or takeOrders4 with real token transfers. diff --git a/test/util/abstract/RaindexV6ExternalMockTest.sol b/test/util/abstract/RaindexV6ExternalMockTest.sol index e7b4a54379..2abec798fc 100644 --- a/test/util/abstract/RaindexV6ExternalMockTest.sol +++ b/test/util/abstract/RaindexV6ExternalMockTest.sol @@ -2,24 +2,24 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; -import {IMetaV1_2} from "rain.metadata/lib/LibMeta.sol"; +import {IMetaV1_2} from "rain-metadata-0.1.0/src/lib/LibMeta.sol"; import {REVERTING_MOCK_BYTECODE} from "test/util/lib/LibTestConstants.sol"; import {IRaindexV6Stub} from "test/util/abstract/IRaindexV6Stub.sol"; import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {IRaindexV6, OrderConfigV4, OrderV4, TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {IRaindexV6, OrderConfigV4, OrderV4, TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; -import {EvaluableV4} from "rain.interpreter.interface/interface/IInterpreterCallerV4.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {EvaluableV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterCallerV4.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; /// @title RaindexV6ExternalTest /// Abstract contract that performs common setup needed for testing a raindex diff --git a/test/util/abstract/RaindexV6ExternalRealTest.sol b/test/util/abstract/RaindexV6ExternalRealTest.sol index 6cb81b5d27..72d57a2cb1 100644 --- a/test/util/abstract/RaindexV6ExternalRealTest.sol +++ b/test/util/abstract/RaindexV6ExternalRealTest.sol @@ -2,25 +2,25 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test, Vm, console2} from "forge-std/Test.sol"; +import {Test, Vm, console2} from "forge-std-1.16.1/src/Test.sol"; import {REVERTING_MOCK_BYTECODE} from "test/util/lib/LibTestConstants.sol"; import {IRaindexV6Stub} from "test/util/abstract/IRaindexV6Stub.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {IParserV2} from "rain.interpreter.interface/interface/IParserV2.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {IParserV2} from "rain-interpreter-interface-0.1.0/src/interface/IParserV2.sol"; import { IRaindexV6, IInterpreterV4, TaskV2, EvaluableV4, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import {RaindexV6SubParser} from "../../../src/concrete/parser/RaindexV6SubParser.sol"; -import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; -import {LibDecimalFloat, Float} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; +import {IERC20Metadata} from "@openzeppelin-contracts-5.6.1/token/ERC20/extensions/IERC20Metadata.sol"; +import {LibDecimalFloat, Float} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; diff --git a/test/util/abstract/RaindexV6SelfTest.sol b/test/util/abstract/RaindexV6SelfTest.sol index 12d4f096b4..c7b6525d69 100644 --- a/test/util/abstract/RaindexV6SelfTest.sol +++ b/test/util/abstract/RaindexV6SelfTest.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Test} from "forge-std/Test.sol"; +import {Test} from "forge-std-1.16.1/src/Test.sol"; import {REVERTING_MOCK_BYTECODE} from "test/util/lib/LibTestConstants.sol"; diff --git a/test/util/abstract/RaindexV6SubParserContextTest.sol b/test/util/abstract/RaindexV6SubParserContextTest.sol index 0cb7768997..bda2062939 100644 --- a/test/util/abstract/RaindexV6SubParserContextTest.sol +++ b/test/util/abstract/RaindexV6SubParserContextTest.sol @@ -2,9 +2,9 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {StackAllocationMismatch} from "rain.interpreter/error/ErrIntegrity.sol"; -import {OpTest, StackItem} from "rain.interpreter/../test/abstract/OpTest.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; +import {StackAllocationMismatch} from "rainlang-0.1.2/src/error/ErrIntegrity.sol"; +import {OpTest, StackItem} from "rainlang-0.1.2/src/../test/abstract/OpTest.sol"; +import {Strings} from "@openzeppelin-contracts-5.6.1/utils/Strings.sol"; import {LibRaindexSubParserContextFixture} from "test/util/fixture/LibRaindexSubParserContextFixture.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {LibEtchRaindex} from "test/util/lib/LibEtchRaindex.sol"; diff --git a/test/util/concrete/AllowanceCheckingExchange.sol b/test/util/concrete/AllowanceCheckingExchange.sol index 5d5a42e6f3..65d0fddf57 100644 --- a/test/util/concrete/AllowanceCheckingExchange.sol +++ b/test/util/concrete/AllowanceCheckingExchange.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; /// @dev Exchange that records the allowance it sees from its caller at call time. contract AllowanceCheckingExchange { diff --git a/test/util/concrete/ChildRaindexV6ArbTaskGated.sol b/test/util/concrete/ChildRaindexV6ArbTaskGated.sol index e4af8af415..0d5dd0679d 100644 --- a/test/util/concrete/ChildRaindexV6ArbTaskGated.sol +++ b/test/util/concrete/ChildRaindexV6ArbTaskGated.sol @@ -3,7 +3,7 @@ pragma solidity =0.8.25; import {RaindexV6ArbTaskGated, RaindexV6ArbConfig} from "../../../src/abstract/RaindexV6ArbTaskGated.sol"; -import {TaskV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {TaskV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; /// @dev We need a contract that is deployable in order to test the abstract /// base contract. Exposes `_checkTaskHash` as an external function. diff --git a/test/util/concrete/FlashLendingMockRaindex.sol b/test/util/concrete/FlashLendingMockRaindex.sol index 4697b3b2d8..b9c659dbd5 100644 --- a/test/util/concrete/FlashLendingMockRaindex.sol +++ b/test/util/concrete/FlashLendingMockRaindex.sol @@ -15,8 +15,8 @@ import { TaskV2, QuoteV2, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IERC3156FlashBorrower} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IERC3156FlashBorrower} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; contract FlashLendingMockRaindex is IRaindexV6 { function flashLoan(IERC3156FlashBorrower receiver, address token, uint256 amount, bytes calldata data) diff --git a/test/util/concrete/MaliciousLender.sol b/test/util/concrete/MaliciousLender.sol index 23531167db..c262c619e7 100644 --- a/test/util/concrete/MaliciousLender.sol +++ b/test/util/concrete/MaliciousLender.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; /// @dev Malicious lender that calls onFlashLoan directly, pretending to be a diff --git a/test/util/concrete/MaliciousRaindex.sol b/test/util/concrete/MaliciousRaindex.sol index f48ceffb55..d75d43942f 100644 --- a/test/util/concrete/MaliciousRaindex.sol +++ b/test/util/concrete/MaliciousRaindex.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {IERC3156FlashBorrower} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {IERC3156FlashBorrower} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; import {MockRaindexBase} from "test/util/abstract/MockRaindexBase.sol"; /// @dev Malicious raindex that records the token allowances it has from the diff --git a/test/util/concrete/MockExchange.sol b/test/util/concrete/MockExchange.sol index 97f5a8e5c6..fba45d667e 100644 --- a/test/util/concrete/MockExchange.sol +++ b/test/util/concrete/MockExchange.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; contract MockExchange { using SafeERC20 for IERC20; diff --git a/test/util/concrete/MockRouteProcessor.sol b/test/util/concrete/MockRouteProcessor.sol index 4b532aa1a5..625ed18cbf 100644 --- a/test/util/concrete/MockRouteProcessor.sol +++ b/test/util/concrete/MockRouteProcessor.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; import {IRouteProcessor} from "sushixswap-v2/src/interfaces/IRouteProcessor.sol"; /// @dev Mock route processor that pulls inputToken from sender and sends diff --git a/test/util/concrete/MockToken.sol b/test/util/concrete/MockToken.sol index 4ae3801a44..15b0aee4c0 100644 --- a/test/util/concrete/MockToken.sol +++ b/test/util/concrete/MockToken.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {ERC20} from "openzeppelin-contracts/contracts/token/ERC20/ERC20.sol"; +import {ERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/ERC20.sol"; contract MockToken is ERC20 { uint8 internal immutable iDecimals; diff --git a/test/util/concrete/RealisticFlashLendingMockRaindex.sol b/test/util/concrete/RealisticFlashLendingMockRaindex.sol index 60abc6d723..c04c8f716f 100644 --- a/test/util/concrete/RealisticFlashLendingMockRaindex.sol +++ b/test/util/concrete/RealisticFlashLendingMockRaindex.sol @@ -2,13 +2,13 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; -import {TakeOrdersConfigV5, Float} from "rain.raindex.interface/interface/IRaindexV6.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; +import {TakeOrdersConfigV5, Float} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; import { IERC3156FlashBorrower, ON_FLASH_LOAN_CALLBACK_SUCCESS -} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; +} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; import {MockRaindexBase} from "test/util/abstract/MockRaindexBase.sol"; /// @dev Mock raindex with real ERC3156 flash loan transfers and real diff --git a/test/util/concrete/RealisticOrderTakerMockRaindex.sol b/test/util/concrete/RealisticOrderTakerMockRaindex.sol index 94d28ccf4f..93259d2efd 100644 --- a/test/util/concrete/RealisticOrderTakerMockRaindex.sol +++ b/test/util/concrete/RealisticOrderTakerMockRaindex.sol @@ -2,10 +2,10 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; -import {TakeOrdersConfigV5, Float} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IRaindexV6OrderTaker} from "rain.raindex.interface/interface/IRaindexV6OrderTaker.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; +import {TakeOrdersConfigV5, Float} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IRaindexV6OrderTaker} from "raindex-interface-0.1.1/src/interface/IRaindexV6OrderTaker.sol"; import {MockRaindexBase} from "test/util/abstract/MockRaindexBase.sol"; /// @dev Mock raindex with real takeOrders4 transfers and onTakeOrders2 diff --git a/test/util/concrete/Reenteroor.sol b/test/util/concrete/Reenteroor.sol index d0f0324b99..3c05b4ea4d 100644 --- a/test/util/concrete/Reenteroor.sol +++ b/test/util/concrete/Reenteroor.sol @@ -2,12 +2,12 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Address} from "openzeppelin-contracts/contracts/utils/Address.sol"; +import {Address} from "@openzeppelin-contracts-5.6.1/utils/Address.sol"; import { IERC3156FlashBorrower, ON_FLASH_LOAN_CALLBACK_SUCCESS -} from "rain.raindex.interface/interface/ierc3156/IERC3156FlashBorrower.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +} from "raindex-interface-0.1.1/src/interface/ierc3156/IERC3156FlashBorrower.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; /// @title Reenteroor /// A contract that reenters the caller with a configurable call. diff --git a/test/util/concrete/ReentrantExchange.sol b/test/util/concrete/ReentrantExchange.sol index 2a5a5227f3..79685114f5 100644 --- a/test/util/concrete/ReentrantExchange.sol +++ b/test/util/concrete/ReentrantExchange.sol @@ -12,10 +12,10 @@ import { EvaluableV4, SignedContextV1, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; /// @dev Exchange that re-enters arb4 when called during _exchange. contract ReentrantExchange { diff --git a/test/util/concrete/ReentrantMockRaindex.sol b/test/util/concrete/ReentrantMockRaindex.sol index c50bb6b0c4..ab9d2e3754 100644 --- a/test/util/concrete/ReentrantMockRaindex.sol +++ b/test/util/concrete/ReentrantMockRaindex.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; -import {SafeERC20} from "openzeppelin-contracts/contracts/token/ERC20/utils/SafeERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; +import {SafeERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/utils/SafeERC20.sol"; import {GenericPoolRaindexV6ArbOrderTaker} from "../../../src/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sol"; import { IRaindexV6, @@ -12,9 +12,9 @@ import { EvaluableV4, SignedContextV1, Float -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; import {MockRaindexBase} from "test/util/abstract/MockRaindexBase.sol"; /// @dev Mock Raindex whose takeOrders4 callback re-enters arb5 on the taker. diff --git a/test/util/concrete/RevertingExchange.sol b/test/util/concrete/RevertingExchange.sol index 34cba0019d..c055752d68 100644 --- a/test/util/concrete/RevertingExchange.sol +++ b/test/util/concrete/RevertingExchange.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; /// @dev Exchange that always reverts. contract RevertingExchange { diff --git a/test/util/lib/LibEtchRaindex.sol b/test/util/lib/LibEtchRaindex.sol index a8f59f78cf..b075545b8e 100644 --- a/test/util/lib/LibEtchRaindex.sol +++ b/test/util/lib/LibEtchRaindex.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity =0.8.25; -import {Vm} from "forge-std/Vm.sol"; +import {Vm} from "forge-std-1.16.1/src/Vm.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {RUNTIME_CODE as RAINDEX_RUNTIME_CODE} from "../../../src/generated/RaindexV6.pointers.sol"; import {RUNTIME_CODE as SUB_PARSER_RUNTIME_CODE} from "../../../src/generated/RaindexV6SubParser.pointers.sol"; diff --git a/test/util/lib/LibTestAddOrder.sol b/test/util/lib/LibTestAddOrder.sol index e4c0edc569..80383f7386 100644 --- a/test/util/lib/LibTestAddOrder.sol +++ b/test/util/lib/LibTestAddOrder.sol @@ -2,14 +2,14 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {META_MAGIC_NUMBER_V1} from "rain.metadata/lib/LibMeta.sol"; +import {META_MAGIC_NUMBER_V1} from "rain-metadata-0.1.0/src/lib/LibMeta.sol"; import {LibOrder} from "../../../src/lib/LibOrder.sol"; -import {OrderConfigV4, OrderV4, IOV2} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4, SourceIndexV2} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {EvaluableV4} from "rain.interpreter.interface/interface/IInterpreterCallerV4.sol"; +import {OrderConfigV4, OrderV4, IOV2} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4, SourceIndexV2} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {EvaluableV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterCallerV4.sol"; import {HANDLE_IO_ENTRYPOINT} from "../../../src/concrete/raindex/RaindexV6.sol"; -import {LibBytecode} from "rain.interpreter.interface/lib/bytecode/LibBytecode.sol"; +import {LibBytecode} from "rain-interpreter-interface-0.1.0/src/lib/bytecode/LibBytecode.sol"; library LibTestAddOrder { /// A little boilerplate to make it easier to build the order that we expect diff --git a/test/util/lib/LibTestArb.sol b/test/util/lib/LibTestArb.sol index 769abfa41d..0d9de592cc 100644 --- a/test/util/lib/LibTestArb.sol +++ b/test/util/lib/LibTestArb.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {Vm} from "forge-std/Vm.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Vm} from "forge-std-1.16.1/src/Vm.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import { IRaindexV6, TakeOrdersConfigV5, @@ -13,13 +13,13 @@ import { EvaluableV4, SignedContextV1, TaskV2 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; import {GenericPoolRaindexV6ArbOrderTaker} from "../../../src/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; import {MockExchange} from "test/util/concrete/MockExchange.sol"; diff --git a/test/util/lib/LibTestFlashBorrowerArb.sol b/test/util/lib/LibTestFlashBorrowerArb.sol index 210a5a987d..46fbaf1c7e 100644 --- a/test/util/lib/LibTestFlashBorrowerArb.sol +++ b/test/util/lib/LibTestFlashBorrowerArb.sol @@ -2,8 +2,8 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {Vm} from "forge-std/Vm.sol"; -import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {Vm} from "forge-std-1.16.1/src/Vm.sol"; +import {IERC20} from "@openzeppelin-contracts-5.6.1/token/ERC20/IERC20.sol"; import { IRaindexV6, TakeOrdersConfigV5, @@ -12,13 +12,13 @@ import { IOV2, EvaluableV4, SignedContextV1 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibRainDeploy} from "rain.deploy/lib/LibRainDeploy.sol"; -import {LibTOFUTokenDecimals} from "rain.tofu.erc20-decimals/lib/LibTOFUTokenDecimals.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibRainDeploy} from "rain-deploy-0.1.2/src/lib/LibRainDeploy.sol"; +import {LibTOFUTokenDecimals} from "rain-tofu-erc20-decimals-0.1.1/src/lib/LibTOFUTokenDecimals.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; import {GenericPoolRaindexV6FlashBorrower} from "../../../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol"; import {MockToken} from "test/util/concrete/MockToken.sol"; diff --git a/test/util/lib/LibTestTakeOrder.sol b/test/util/lib/LibTestTakeOrder.sol index 3a0f8751d5..23320d0ca2 100644 --- a/test/util/lib/LibTestTakeOrder.sol +++ b/test/util/lib/LibTestTakeOrder.sol @@ -2,7 +2,7 @@ // SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd pragma solidity ^0.8.19; -import {Vm} from "forge-std/Vm.sol"; +import {Vm} from "forge-std-1.16.1/src/Vm.sol"; import { OrderV4, TakeOrderConfigV4, @@ -12,13 +12,13 @@ import { OrderConfigV4, TaskV2, IRaindexV6 -} from "rain.raindex.interface/interface/IRaindexV6.sol"; -import {IInterpreterV4} from "rain.interpreter.interface/interface/IInterpreterV4.sol"; -import {IInterpreterStoreV3} from "rain.interpreter.interface/interface/IInterpreterStoreV3.sol"; -import {IParserV2} from "rain.interpreter.interface/interface/IParserV2.sol"; -import {SignedContextV1} from "rain.interpreter.interface/interface/deprecated/v1/IInterpreterCallerV2.sol"; -import {Float, LibDecimalFloat} from "rain.math.float/lib/LibDecimalFloat.sol"; -import {LibInterpreterDeploy} from "rain.interpreter/lib/deploy/LibInterpreterDeploy.sol"; +} from "raindex-interface-0.1.1/src/interface/IRaindexV6.sol"; +import {IInterpreterV4} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; +import {IInterpreterStoreV3} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterStoreV3.sol"; +import {IParserV2} from "rain-interpreter-interface-0.1.0/src/interface/IParserV2.sol"; +import {SignedContextV1} from "rain-interpreter-interface-0.1.0/src/interface/deprecated/v1/IInterpreterCallerV2.sol"; +import {Float, LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; +import {LibInterpreterDeploy} from "rainlang-0.1.2/src/lib/deploy/LibInterpreterDeploy.sol"; import {LibRaindexDeploy} from "../../../src/lib/deploy/LibRaindexDeploy.sol"; library LibTestTakeOrder { From bf51b1ff66e42965e86ef2adecb2b20d9f0b2f8a Mon Sep 17 00:00:00 2001 From: David Meister Date: Fri, 22 May 2026 10:35:40 +0000 Subject: [PATCH 2/7] chore: align prep-base.sh + fs_permissions with soldeer MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Replace `forge install` with `git submodule update --init --recursive` plus an explicit `forge soldeer install`. - Drop the `rainix-sol-prelude` runs inside each lib/rain.* submodule; Solidity resolves via published soldeer artifacts. Keep `rainix-rs-prelude` / `rainlang-prelude` since the Cargo workspace still consumes the submodules' Rust crates as path-deps. - Remove fs_permissions entries pointing at the rain.interpreter submodule's meta / deployments dirs — no raindex source references these paths after the soldeer migration. Co-Authored-By: Claude Opus 4.7 --- foundry.toml | 5 ----- prep-base.sh | 54 +++++++++++++--------------------------------------- 2 files changed, 13 insertions(+), 46 deletions(-) diff --git a/foundry.toml b/foundry.toml index 5f34ef9a79..383f0a0b5d 100644 --- a/foundry.toml +++ b/foundry.toml @@ -31,11 +31,6 @@ cbor_metadata = false # than expose ffi to forge. fs_permissions = [ { access = "read", path = "./meta" }, - { access = "read", path = "./lib/rain.interpreter/meta/RainterpreterExpressionDeployerNPE2.rain.meta" }, - { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterParserNPE2" }, - { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterStoreNPE2" }, - { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterNPE2" }, - { access = "read", path = "./lib/rain.interpreter/deployments/latest/RainterpreterExpressionDeployerNPE2" }, { access = "read-write", path = "./meta/RaindexV6SubParserAuthoringMeta.rain.meta" }, { access = "read-write", path = "src/generated" }, { access = "read", path = "./subgraph" }, diff --git a/prep-base.sh b/prep-base.sh index e6c5469530..126fbf7628 100755 --- a/prep-base.sh +++ b/prep-base.sh @@ -1,20 +1,9 @@ #!/bin/bash -# Set strict error handling set -euxo pipefail echo "Starting project setup..." -# Environment variables that need to be set (commented out as reference) -# export CI_DEPLOY_SEPOLIA_RPC_URL="" -# export CI_FORK_SEPOLIA_DEPLOYER_ADDRESS="" -# export CI_FORK_SEPOLIA_BLOCK_NUMBER="" -# export CI_DEPLOY_POLYGON_RPC_URL="" -# export CI_SEPOLIA_METABOARD_URL="" -# export RPC_URL_ETHEREUM_FORK="" -# export COMMIT_SHA="" - -# Keep environment variables when using nix-develop keep=( -k CI_DEPLOY_SEPOLIA_RPC_URL -k CI_FORK_SEPOLIA_DEPLOYER_ADDRESS @@ -31,50 +20,33 @@ keep=( -k PUBLIC_WALLETCONNECT_PROJECT_ID ) -echo "Installing Forge dependencies..." -nix develop -c forge install +git submodule update --init --recursive -echo "Setting up rain.math.float..." -nix develop -i ${keep[@]} -c bash \ - -c '(cd lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.math.float && rainix-sol-prelude)' -nix develop -i ${keep[@]} -c bash \ - -c '(cd lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.math.float && rainix-rs-prelude)' +nix develop -c forge soldeer install -echo "Setting up rain.tofu.erc20-decimals..." -(cd lib/rain.interpreter/lib/rain.tofu.erc20-decimals && nix develop -c forge build) +nix develop -i "${keep[@]}" -c bash \ + -c '(cd lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.math.float && rainix-rs-prelude)' -echo "Setting up rain.interpreter..." -nix develop -i ${keep[@]} -c bash -c '(cd lib/rain.interpreter && rainix-sol-prelude)' -nix develop -i ${keep[@]} -c bash -c '(cd lib/rain.interpreter && rainix-rs-prelude)' -(cd lib/rain.interpreter && nix develop -i ${keep[@]} -c bash -c rainlang-prelude) +nix develop -i "${keep[@]}" -c bash -c '(cd lib/rain.interpreter && rainix-rs-prelude)' +(cd lib/rain.interpreter && nix develop -i "${keep[@]}" -c bash -c rainlang-prelude) -echo "Setting up rain.metadata..." -nix develop -i ${keep[@]} -c bash -c '(cd lib/rain.interpreter/lib/rain.metadata && rainix-sol-prelude)' -nix develop -i ${keep[@]} -c bash -c '(cd lib/rain.interpreter/lib/rain.metadata && rainix-rs-prelude)' +nix develop -i "${keep[@]}" -c bash -c '(cd lib/rain.interpreter/lib/rain.metadata && rainix-rs-prelude)' -echo "Setting up main project dependencies..." -nix develop -i ${keep[@]} -c rainix-sol-prelude -nix develop -i ${keep[@]} -c rainix-rs-prelude -nix develop -i ${keep[@]} -c raindex-prelude +nix develop -i "${keep[@]}" -c rainix-sol-prelude +nix develop -i "${keep[@]}" -c rainix-rs-prelude +nix develop -i "${keep[@]}" -c raindex-prelude -echo "Building Solidity contracts..." -nix develop -i ${keep[@]} -c forge build +nix develop -i "${keep[@]}" -c forge build -# Temporarily disable command echoing set +x export LANG=en_US.UTF-8 export LC_ALL=en_US.UTF-8 -GREEN='\033[0;32m' -NC='\033[0m' # No Color - -# Print the completion message -printf "\033[0;32m" # Set text to green +printf "\033[0;32m" printf "╔════════════════════════════════════════════════════════════════════════╗\n" printf "║ Base Setup Complete! ║\n" printf "╚════════════════════════════════════════════════════════════════════════╝\n" -printf "\033[0m" # Reset text color +printf "\033[0m" -# Re-enable command echoing set -x From b7639ef6db47f90c94dbc30429dcb27924eeffeb Mon Sep 17 00:00:00 2001 From: David Meister Date: Fri, 22 May 2026 10:51:37 +0000 Subject: [PATCH 3/7] fix(soldeer): drop rain-math-fixedpoint + OZ 4.8.3 transitive The single test usage of `fixedPointDiv` was a one-liner that resolves to `Math.mulDiv(a, 1e18, b, Math.Rounding.Floor)`. Inlining it lets us drop both `rain-math-fixedpoint-0.1.0` and the `@openzeppelin-contracts-4.8.3` side-by-side install it pulled in. This unblocks `forge soldeer install` in CI, which was failing because the lockfile only retained one OZ version while foundry.toml referenced both. Co-Authored-By: Claude Opus 4.7 --- foundry.toml | 1 - remappings.txt | 2 -- soldeer.lock | 15 ++++----------- test/concrete/raindex/RaindexV6.clear.mock.t.sol | 8 ++------ 4 files changed, 6 insertions(+), 20 deletions(-) diff --git a/foundry.toml b/foundry.toml index 383f0a0b5d..7c99dc4aa5 100644 --- a/foundry.toml +++ b/foundry.toml @@ -65,7 +65,6 @@ rain-lib-hash = "0.1.0" rain-math-binary = "0.1.1" rain-string = "0.2.0" rain-lib-memkv = "0.1.0" -rain-math-fixedpoint = "0.1.0" [soldeer] recursive_deps = false diff --git a/remappings.txt b/remappings.txt index 4afac64043..766d6e8e21 100644 --- a/remappings.txt +++ b/remappings.txt @@ -1,4 +1,3 @@ -@openzeppelin-contracts-4.8.3/=dependencies/@openzeppelin-contracts-4.8.3/ @openzeppelin-contracts-5.6.1/=dependencies/@openzeppelin-contracts-5.6.1/ forge-std-1.16.1/=dependencies/forge-std-1.16.1/ rain-deploy-0.1.2/=dependencies/rain-deploy-0.1.2/ @@ -8,7 +7,6 @@ rain-lib-hash-0.1.0/=dependencies/rain-lib-hash-0.1.0/ rain-lib-memkv-0.1.0/=dependencies/rain-lib-memkv-0.1.0/ rain-lib-typecast-0.1.0/=dependencies/rain-lib-typecast-0.1.0/ rain-math-binary-0.1.1/=dependencies/rain-math-binary-0.1.1/ -rain-math-fixedpoint-0.1.0/=dependencies/rain-math-fixedpoint-0.1.0/ rain-math-float-0.1.1/=dependencies/rain-math-float-0.1.1/ rain-metadata-0.1.0/=dependencies/rain-metadata-0.1.0/ rain-sol-codegen-0.1.0/=dependencies/rain-sol-codegen-0.1.0/ diff --git a/soldeer.lock b/soldeer.lock index b80a2d19ff..e89a75e5db 100644 --- a/soldeer.lock +++ b/soldeer.lock @@ -1,9 +1,9 @@ [[dependencies]] name = "@openzeppelin-contracts" -version = "4.8.3" -url = "https://soldeer-revisions.s3.amazonaws.com/@openzeppelin-contracts/4_8_3_22-01-2024_13:13:46_contracts.zip" -checksum = "c6c0f1d430120cf45a3531a2fe740a4dffa1434ebccac753a59c54bc1ce65db9" -integrity = "3ecc700e5d25af23c53959baf3cfd3cbadbc0013e80dfca40cee9e7ea34e141d" +version = "5.6.1" +url = "https://soldeer-revisions.s3.amazonaws.com/@openzeppelin-contracts/5_6_1_15-03-2026_09:19:50_contracts.zip" +checksum = "a3b6bc661be858c7c27f60a1708cbebe8c71034b4cc1e9fe270d0a05b069352f" +integrity = "bce03af7ada1eee21a7fff393f238bcd7cd75a022a4db55ffb6b0dbb32433d35" [[dependencies]] name = "forge-std" @@ -61,13 +61,6 @@ url = "https://soldeer-revisions.s3.amazonaws.com/rain-math-binary/0_1_1_09-05-2 checksum = "6f966e4f5f59103b62de2004005db508824622495b893a646d0e2a35511f0093" integrity = "4cfaa11c0e48ac46824a10fec2184863d114f09c171544b721d782386708dca7" -[[dependencies]] -name = "rain-math-fixedpoint" -version = "0.1.0" -url = "https://soldeer-revisions.s3.amazonaws.com/rain-math-fixedpoint/0_1_0_09-05-2026_20:41:06_rain.math.zip" -checksum = "3b19166f9f12ed84047f6570992d1bc445eed7705d5ba7e5a94de9f8cc51d572" -integrity = "8578d71cf511ea2ab2044821c733f06ad5d2a08afc4eb3ff7c14b1af809ab39c" - [[dependencies]] name = "rain-math-float" version = "0.1.1" diff --git a/test/concrete/raindex/RaindexV6.clear.mock.t.sol b/test/concrete/raindex/RaindexV6.clear.mock.t.sol index 6ecab7bfe8..a99180b6df 100644 --- a/test/concrete/raindex/RaindexV6.clear.mock.t.sol +++ b/test/concrete/raindex/RaindexV6.clear.mock.t.sol @@ -21,10 +21,7 @@ import {LibTestAddOrder} from "test/util/lib/LibTestAddOrder.sol"; import {NotOrderOwner, StackItem, NegativeBounty, ClearZeroAmount} from "../../../src/concrete/raindex/RaindexV6.sol"; import {LibNamespace} from "rain-interpreter-interface-0.1.0/src/lib/ns/LibNamespace.sol"; import {StateNamespace, EvalV4, SourceIndexV2} from "rain-interpreter-interface-0.1.0/src/interface/IInterpreterV4.sol"; -import { - LibFixedPointDecimalArithmeticOpenZeppelin -} from "rain-math-fixedpoint-0.1.0/src/lib/LibFixedPointDecimalArithmeticOpenZeppelin.sol"; -import {Math} from "@openzeppelin-contracts-4.8.3/utils/math/Math.sol"; +import {Math} from "@openzeppelin-contracts-5.6.1/utils/math/Math.sol"; import {LibDecimalFloat} from "rain-math-float-0.1.1/src/lib/LibDecimalFloat.sol"; import {LibFormatDecimalFloat} from "rain-math-float-0.1.1/src/lib/format/LibFormatDecimalFloat.sol"; @@ -45,7 +42,6 @@ contract MockInterpreter { /// @title RaindexV6ClearTest /// Tests clearing an order. contract RaindexV6ClearTest is RaindexV6ExternalMockTest { - using LibFixedPointDecimalArithmeticOpenZeppelin for uint256; using Math for uint256; using LibDecimalFloat for Float; @@ -789,7 +785,7 @@ contract RaindexV6ClearTest is RaindexV6ExternalMockTest { ) external { // 0 tested separately. aliceIORatio18 = bound(aliceIORatio18, 1, 1e18); - bobIORatio18 = bound(bobIORatio18, 1e18, uint256(1e18).fixedPointDiv(aliceIORatio18, Math.Rounding.Down)); + bobIORatio18 = bound(bobIORatio18, 1e18, Math.mulDiv(1e18, 1e18, aliceIORatio18, Math.Rounding.Floor)); Float aliceIORatio = LibDecimalFloat.fromFixedDecimalLosslessPacked(aliceIORatio18, 18); Float bobIORatio = LibDecimalFloat.fromFixedDecimalLosslessPacked(bobIORatio18, 18); From 06cc55a41e9696ca831c82758c335a3256912ca0 Mon Sep 17 00:00:00 2001 From: David Meister Date: Fri, 22 May 2026 12:17:27 +0000 Subject: [PATCH 4/7] fix(soldeer): strip submodule preludes from pointers.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The pointers.sh script ran rainix-sol-prelude inside each rain.* submodule, which invokes forge install — which now tries to git submodule update a dependencies/ pathspec that does not exist in raindex. The submodule preludes were generating pointer constants embedded in the libs Solidity, but those constants now ship inside the published soldeer artifacts. raindex only needs to soldeer-install + run its own preludes + execute BuildPointers.sol. Co-Authored-By: Claude Opus 4.7 --- pointers.sh | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/pointers.sh b/pointers.sh index 17325c5d0a..ba0f5e2ed9 100755 --- a/pointers.sh +++ b/pointers.sh @@ -2,14 +2,7 @@ set -euxo pipefail -(cd lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.math.float && nix develop -c rainix-sol-prelude) -(cd lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.math.float && nix develop -c rainix-rs-prelude) -(cd lib/rain.interpreter && nix develop -c rainix-sol-prelude) -(cd lib/rain.interpreter && nix develop -c rainix-rs-prelude) -(cd lib/rain.interpreter && nix develop -c rainlang-prelude) -(cd lib/rain.interpreter/lib/rain.metadata && nix develop -c rainix-sol-prelude) -(cd lib/rain.interpreter/lib/rain.metadata && nix develop -c rainix-rs-prelude) -(cd lib/rain.interpreter/lib/rain.tofu.erc20-decimals && nix develop -c forge build) +nix develop -c forge soldeer install nix develop -c rainix-sol-prelude nix develop -c rainix-rs-prelude From 45cabb5136fe98f45f46d4513bbc4bcdf978799e Mon Sep 17 00:00:00 2001 From: David Meister Date: Sat, 23 May 2026 05:59:29 +0000 Subject: [PATCH 5/7] fix: bump rainix pin + drop obsolete prelude calls The old rainix rev pinned in flake.lock predated soldeer support and its `rainix-sol-prelude` task ran `forge install`, which modern foundry treats as soldeer-aware and chokes on raindex's `dependencies/` directory pathspec. Bumps the rainix input to current HEAD (only exposes `rainix-sol-artifacts` and `rainix-rs-static`), and replaces the legacy `rainix-sol-prelude` / `rainix-rs-prelude` invocations in pointers.sh and prep-base.sh with explicit `forge soldeer install + forge build`. Co-Authored-By: Claude Opus 4.7 --- flake.lock | 65 +++++++++++++++++++--------------------------------- pointers.sh | 3 +-- prep-base.sh | 11 +-------- 3 files changed, 26 insertions(+), 53 deletions(-) diff --git a/flake.lock b/flake.lock index 2f38fe0b93..632f0b9982 100644 --- a/flake.lock +++ b/flake.lock @@ -198,11 +198,11 @@ "nixpkgs": "nixpkgs_5" }, "locked": { - "lastModified": 1773213477, - "narHash": "sha256-Pv1Z3QqGkSGEUV+9pM5vYIiI7VJo7Tfm6ZmR+JSp1zo=", + "lastModified": 1778486972, + "narHash": "sha256-iuy/TbK9AbghEld2VSFuxyAF30LkOGUUdtrvixLfE7M=", "owner": "shazow", "repo": "foundry.nix", - "rev": "3c73daa86c823d706824fd9bbcb85aa23fd0f668", + "rev": "db117ae95a77b9ead24137c3ccb28896ae4fa4ec", "type": "github" }, "original": { @@ -218,11 +218,11 @@ "nixpkgs": "nixpkgs_6" }, "locked": { - "lastModified": 1774104215, - "narHash": "sha256-EAtviqz0sEAxdHS4crqu7JGR5oI3BwaqG0mw7CmXkO8=", + "lastModified": 1778507602, + "narHash": "sha256-kTwur1wV+01SdqskVMSo6JMEpg71ps3HpbFY2GsflKs=", "owner": "cachix", "repo": "git-hooks.nix", - "rev": "f799ae951fde0627157f40aec28dec27b22076d0", + "rev": "61ab0e80d9c7ab14c256b5b453d8b3fb0189ba0a", "type": "github" }, "original": { @@ -267,22 +267,6 @@ "type": "indirect" } }, - "nixpkgs-old": { - "locked": { - "lastModified": 1749104371, - "narHash": "sha256-m2NmOPd6XgBiskmUq/BS9Xxuf3z0ebnGVfSKNAO5NEM=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "48975d7f9b9960ed33c4e8561bcce20cc0c2de5b", - "type": "github" - }, - "original": { - "owner": "nixos", - "repo": "nixpkgs", - "rev": "48975d7f9b9960ed33c4e8561bcce20cc0c2de5b", - "type": "github" - } - }, "nixpkgs_2": { "locked": { "lastModified": 1714764285, @@ -362,11 +346,11 @@ }, "nixpkgs_7": { "locked": { - "lastModified": 1776017067, - "narHash": "sha256-oEp8fqJweZd5doqvH/aBAtc6NzZh+fh0tOhR09gQXck=", + "lastModified": 1778656924, + "narHash": "sha256-lKVrom9wOmpC3i7m+uBoGaBdW0PfH3QbLRG1XmuC6YA=", "owner": "nixos", "repo": "nixpkgs", - "rev": "a5a7cf16648d79134eb4da0e3354b08913917b2f", + "rev": "4ba039de0909446943c07e2b42bd2f0f4507072e", "type": "github" }, "original": { @@ -393,11 +377,11 @@ }, "nixpkgs_9": { "locked": { - "lastModified": 1771923393, - "narHash": "sha256-Fy0+UXELv9hOE8WjYhJt8fMDLYTU2Dqn3cX4BwoGBos=", + "lastModified": 1777641297, + "narHash": "sha256-WNGcmeOZ8Tr9dq6ztCspYbzWFswr2mPebM9LpsfGxPk=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "ea7f1f06811ce7fcc81d6c6fd4213150c23edcf2", + "rev": "c6d65881c5624c9cae5ea6cedef24699b0c0a4c0", "type": "github" }, "original": { @@ -454,16 +438,15 @@ "foundry": "foundry_2", "git-hooks-nix": "git-hooks-nix", "nixpkgs": "nixpkgs_7", - "nixpkgs-old": "nixpkgs-old", "rust-overlay": "rust-overlay_2", "solc": "solc_2" }, "locked": { - "lastModified": 1777887852, - "narHash": "sha256-1AXVZpY1okCogZKt0CslqP06FG5HldcY+RmjEfct1rc=", + "lastModified": 1779209879, + "narHash": "sha256-9x9V41PmF1RQlM5R6SV6xbgVnP+qgW9mUyRC50RQ9G8=", "owner": "rainlanguage", "repo": "rainix", - "rev": "620c4d3604ba7967004afce6ffacd2ae9ef2c1a1", + "rev": "d444279bc7346a6f4f7bd4a0b7f9900523b8f00e", "type": "github" }, "original": { @@ -503,11 +486,11 @@ "nixpkgs": "nixpkgs_8" }, "locked": { - "lastModified": 1773216618, - "narHash": "sha256-iZlowevS+xKLGOXtZwpIrz3SWe7PtoGUfEeVZNib+WE=", + "lastModified": 1778642276, + "narHash": "sha256-bhk4lawR4ZnFhPtamB5WkCyvfgyZmsEUbWfT/3FRxFY=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "07d7dc6fcc5eae76b4fb0e19d4afd939437bec97", + "rev": "77265d2dc1e61b2abfd3b1d6609dbb66fe75e0a5", "type": "github" }, "original": { @@ -538,13 +521,13 @@ "solc-macos-amd64-list-json": { "flake": false, "locked": { - "narHash": "sha256-oEiXc95EghuYCudzkPA9XBFOnMdgWFfTO2/4XUfSTpc=", + "narHash": "sha256-zzwwHA2qPotv7yp8mK7+y9BZhm7ytuFeCJVvKBBdBn4=", "type": "file", - "url": "https://github.com/argotorg/solc-bin/raw/83cb756/macosx-amd64/list.json" + "url": "https://github.com/argotorg/solc-bin/raw/902dfaf/macosx-amd64/list.json" }, "original": { "type": "file", - "url": "https://github.com/argotorg/solc-bin/raw/83cb756/macosx-amd64/list.json" + "url": "https://github.com/argotorg/solc-bin/raw/902dfaf/macosx-amd64/list.json" } }, "solc_2": { @@ -554,11 +537,11 @@ "solc-macos-amd64-list-json": "solc-macos-amd64-list-json" }, "locked": { - "lastModified": 1772085240, - "narHash": "sha256-+NEcuhT2A0QQumVx9Ze6g2iuNicyuW028Jq/HUJHGh4=", + "lastModified": 1777817996, + "narHash": "sha256-iI71iUhD7THLibl3w1JcQEhHmTwZMxChi70RTe33BAo=", "owner": "hellwolf", "repo": "solc.nix", - "rev": "d3cc119973e484ea366f4b997b404bb00d7829ca", + "rev": "e3cf898cb804d5c0e5474b378a300fe8942e67d6", "type": "github" }, "original": { diff --git a/pointers.sh b/pointers.sh index ba0f5e2ed9..df02b48358 100755 --- a/pointers.sh +++ b/pointers.sh @@ -3,9 +3,8 @@ set -euxo pipefail nix develop -c forge soldeer install +nix develop -c forge build -nix develop -c rainix-sol-prelude -nix develop -c rainix-rs-prelude nix develop -c raindex-prelude nix develop -c forge script script/BuildPointers.sol diff --git a/prep-base.sh b/prep-base.sh index 126fbf7628..fd0bd89847 100755 --- a/prep-base.sh +++ b/prep-base.sh @@ -23,17 +23,8 @@ keep=( git submodule update --init --recursive nix develop -c forge soldeer install +nix develop -c forge build -nix develop -i "${keep[@]}" -c bash \ - -c '(cd lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.math.float && rainix-rs-prelude)' - -nix develop -i "${keep[@]}" -c bash -c '(cd lib/rain.interpreter && rainix-rs-prelude)' -(cd lib/rain.interpreter && nix develop -i "${keep[@]}" -c bash -c rainlang-prelude) - -nix develop -i "${keep[@]}" -c bash -c '(cd lib/rain.interpreter/lib/rain.metadata && rainix-rs-prelude)' - -nix develop -i "${keep[@]}" -c rainix-sol-prelude -nix develop -i "${keep[@]}" -c rainix-rs-prelude nix develop -i "${keep[@]}" -c raindex-prelude nix develop -i "${keep[@]}" -c forge build From 6ffa7e7d11b99955b4abc641f4b02ba6434f180d Mon Sep 17 00:00:00 2001 From: David Meister Date: Sat, 23 May 2026 06:26:44 +0000 Subject: [PATCH 6/7] wip: drop alloy-ethers-typecast (foundation + bump rain.interpreter) Co-Authored-By: Claude Opus 4.7 --- Cargo.toml | 1 - crates/cli/Cargo.toml | 11 +- crates/common/Cargo.toml | 11 +- crates/common/src/deposit.rs | 182 +++-------------------- crates/common/src/lib.rs | 2 + crates/common/src/remove_order.rs | 114 +-------------- crates/common/src/transaction.rs | 236 +++++++----------------------- crates/common/src/withdraw.rs | 91 +----------- crates/common/src/write_tx.rs | 59 ++++++++ crates/js_api/Cargo.toml | 11 +- crates/quote/Cargo.toml | 1 - lib/rain.interpreter | 2 +- 12 files changed, 168 insertions(+), 553 deletions(-) create mode 100644 crates/common/src/write_tx.rs diff --git a/Cargo.toml b/Cargo.toml index 1016cf15af..e687a87858 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,7 +12,6 @@ homepage = "https://github.com/rainlanguage/raindex" [workspace.dependencies] foundry-block-explorers = "0.2.6" alloy = { version = "1.0.9", features = ["sol-types", "json", "json-abi"] } -alloy-ethers-typecast = { git = "https://github.com/rainlanguage/alloy-ethers-typecast", rev = "bcc3a04394aefe191fef4ae8e6e94381a419c99a" } anyhow = "1.0.70" async-trait = "0.1.77" clap = { version = "4.2.5", features = ["cargo", "derive"] } diff --git a/crates/cli/Cargo.toml b/crates/cli/Cargo.toml index 75ce54d437..c4b6c30d3d 100644 --- a/crates/cli/Cargo.toml +++ b/crates/cli/Cargo.toml @@ -9,7 +9,6 @@ homepage.workspace = true # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -alloy-ethers-typecast = { workspace = true } alloy = { workspace = true } raindex_subgraph_client = { workspace = true } raindex_bindings = { workspace = true } @@ -40,11 +39,11 @@ tokio = { workspace = true, features = ["full"] } [target.'cfg(target_family = "wasm")'.dependencies] tokio = { workspace = true, features = [ - "sync", - "macros", - "io-util", - "rt", - "time", + "sync", + "macros", + "io-util", + "rt", + "time", ] } [dev-dependencies] diff --git a/crates/common/Cargo.toml b/crates/common/Cargo.toml index c547e6a6e4..f2d88b161f 100644 --- a/crates/common/Cargo.toml +++ b/crates/common/Cargo.toml @@ -21,7 +21,6 @@ raindex_subgraph_client = { workspace = true } raindex_app_settings = { workspace = true } raindex_quote = { workspace = true } alloy = { workspace = true, features = ["dyn-abi", "rand"] } -alloy-ethers-typecast = { workspace = true } url = { workspace = true } serde = { workspace = true } serde_json = { workspace = true } @@ -67,11 +66,11 @@ rusqlite = { version = "0.32", features = ["functions"] } [target.'cfg(target_family = "wasm")'.dependencies] tokio = { workspace = true, features = [ - "sync", - "macros", - "io-util", - "rt", - "time", + "sync", + "macros", + "io-util", + "rt", + "time", ] } serde-wasm-bindgen = "0.4" getrandom = { workspace = true } diff --git a/crates/common/src/deposit.rs b/crates/common/src/deposit.rs index c4ab486e91..1c620490e4 100644 --- a/crates/common/src/deposit.rs +++ b/crates/common/src/deposit.rs @@ -1,11 +1,7 @@ -use crate::transaction::{TransactionArgs, TransactionArgsError, WritableTransactionExecuteError}; -use alloy::primitives::{Address, B256, U256}; -use alloy_ethers_typecast::{ - ReadContractParametersBuilder, ReadContractParametersBuilderError, ReadableClient, - ReadableClientError, WritableClientError, +use crate::transaction::{ + read_call, TransactionArgs, TransactionArgsError, WritableTransactionExecuteError, }; -#[cfg(not(target_family = "wasm"))] -use alloy_ethers_typecast::{WriteTransaction, WriteTransactionStatus}; +use alloy::primitives::{Address, B256, U256}; use rain_math_float::{Float, FloatError}; #[cfg(not(target_family = "wasm"))] use raindex_bindings::IERC20::approveCall; @@ -13,17 +9,11 @@ use raindex_bindings::{IRaindexV6::deposit4Call, IERC20::allowanceCall}; use serde::{Deserialize, Serialize}; use thiserror::Error; +#[cfg(not(target_family = "wasm"))] +use crate::write_tx::{execute_write_tx, WriteTransactionStatus}; + #[derive(Error, Debug)] pub enum DepositError { - #[error(transparent)] - ReadableClientError(#[from] ReadableClientError), - - #[error(transparent)] - ReadContractParametersBuilderError(#[from] ReadContractParametersBuilderError), - - #[error(transparent)] - WritableClientError(#[from] WritableClientError), - #[error(transparent)] WritableTransactionExecuteError(#[from] WritableTransactionExecuteError), @@ -46,72 +36,62 @@ impl TryFrom for deposit4Call { type Error = FloatError; fn try_from(val: DepositArgs) -> Result { - let call = deposit4Call { + Ok(deposit4Call { token: val.token, vaultId: val.vault_id, depositAmount: val.amount.get_inner(), tasks: vec![], - }; - - Ok(call) + }) } } impl DepositArgs { - /// Execute read IERC20 allowance call pub async fn read_allowance( &self, owner: Address, transaction_args: TransactionArgs, ) -> Result { - let readable_client = ReadableClient::new_from_http_urls(transaction_args.rpcs.clone())?; - let parameters = ReadContractParametersBuilder::::default() - .address(self.token) - .call(allowanceCall { + let res = read_call( + &transaction_args.rpcs, + self.token, + allowanceCall { owner, spender: transaction_args.raindex_address, - }) - .build()?; - let res = readable_client.read(parameters).await?; - + }, + ) + .await?; Ok(res) } - /// Execute IERC20 approve call #[cfg(not(target_family = "wasm"))] - pub async fn execute_approve)>( + pub async fn execute_approve( &self, transaction_args: TransactionArgs, transaction_status_changed: S, ) -> Result<(), DepositError> { let (ledger_client, address) = transaction_args.clone().try_into_ledger_client().await?; - // Check allowance already granted for this token and contract let current_allowance = self .read_allowance(address, transaction_args.clone()) .await?; let current_allowance_float = Float::from_fixed_decimal(current_allowance, self.decimals)?; - // If allowance differs from desired amount, overwrite it with the target value if !current_allowance_float.eq(self.amount)? { let approve_call = approveCall { spender: transaction_args.raindex_address, amount: self.amount.to_fixed_decimal(self.decimals)?, }; - let params = - transaction_args.try_into_write_contract_parameters(approve_call, self.token)?; + let tx_request = + transaction_args.try_into_transaction_request(approve_call, self.token)?; - WriteTransaction::new(ledger_client, params, 4, transaction_status_changed) - .execute() - .await?; + execute_write_tx(ledger_client, tx_request, 4, transaction_status_changed).await?; } Ok(()) } - /// Execute Raindex deposit call #[cfg(not(target_family = "wasm"))] - pub async fn execute_deposit)>( + pub async fn execute_deposit( &self, transaction_args: TransactionArgs, transaction_status_changed: S, @@ -119,127 +99,11 @@ impl DepositArgs { let (ledger_client, _) = transaction_args.clone().try_into_ledger_client().await?; let deposit_call: deposit4Call = self.clone().try_into()?; - let params = transaction_args - .try_into_write_contract_parameters(deposit_call, transaction_args.raindex_address)?; + let tx_request = transaction_args + .try_into_transaction_request(deposit_call, transaction_args.raindex_address)?; - WriteTransaction::new(ledger_client, params, 4, transaction_status_changed) - .execute() - .await?; + execute_write_tx(ledger_client, tx_request, 4, transaction_status_changed).await?; Ok(()) } } - -#[cfg(all(test, not(target_family = "wasm")))] -mod tests { - use super::*; - use alloy::primitives::{address, Address, B256}; - use httpmock::MockServer; - use serde_json::json; - use std::str::FromStr; - - #[test] - fn test_deposit_args_into() { - let args = DepositArgs { - token: address!("1234567890abcdef1234567890abcdef12345678"), - vault_id: B256::from(U256::from(42)), - amount: Float::from_fixed_decimal(U256::from(123), 6).unwrap(), - decimals: 6, - }; - - let deposit_call: deposit4Call = args.try_into().unwrap(); - - assert_eq!( - deposit_call.token, - address!("1234567890abcdef1234567890abcdef12345678") - ); - assert_eq!(deposit_call.vaultId, B256::from(U256::from(42))); - let amount = Float::parse("0.000123".to_string()).unwrap().get_inner(); - assert_eq!(deposit_call.depositAmount, amount); - } - - #[tokio::test] - async fn test_read_allowance() { - let rpc_server = MockServer::start_async().await; - - rpc_server.mock(|when, then| { - when.path("/rpc").body_contains("0xdd62ed3e"); - let value = B256::left_padding_from(&[200u8]).to_string(); - then.json_body(json!({ - "jsonrpc": "2.0", - "id": 1, - "result": value, - })); - }); - - let args = DepositArgs { - token: Address::from_str("0x1234567890abcdef1234567890abcdef12345678").unwrap(), - vault_id: B256::from(U256::from(42)), - amount: Float::from_fixed_decimal(U256::from(100), 18).unwrap(), - decimals: 18, - }; - - let res = args - .read_allowance( - Address::ZERO, - TransactionArgs { - rpcs: vec![rpc_server.url("/rpc")], - raindex_address: Address::ZERO, - ..Default::default() - }, - ) - .await - .unwrap(); - assert_eq!(res, U256::from(200)); - } - - #[test] - fn test_deposit_call_try_into_write_contract_parameters() { - let args = TransactionArgs { - rpcs: vec!["http://test.com".to_string()], - raindex_address: Address::ZERO, - derivation_index: Some(0_usize), - chain_id: Some(1), - max_priority_fee_per_gas: Some(200), - max_fee_per_gas: Some(100), - }; - - let amount = Float::parse("100".to_string()).unwrap().get_inner(); - let deposit_call = deposit4Call { - token: Address::ZERO, - vaultId: B256::from(U256::from(42)), - depositAmount: amount, - tasks: vec![], - }; - let params = args - .try_into_write_contract_parameters(deposit_call.clone(), Address::ZERO) - .unwrap(); - assert_eq!(params.address, Address::ZERO); - assert_eq!(params.call, deposit_call); - assert_eq!(params.max_priority_fee_per_gas, Some(200)); - assert_eq!(params.max_fee_per_gas, Some(100)); - } - - #[test] - fn test_approve_call_try_into_write_contract_parameters() { - let args = TransactionArgs { - rpcs: vec!["http://test.com".to_string()], - raindex_address: Address::ZERO, - derivation_index: Some(0_usize), - chain_id: Some(1), - max_priority_fee_per_gas: Some(200), - max_fee_per_gas: Some(100), - }; - let approve_call = approveCall { - spender: Address::ZERO, - amount: U256::from(100), - }; - let params = args - .try_into_write_contract_parameters(approve_call.clone(), Address::ZERO) - .unwrap(); - assert_eq!(params.address, Address::ZERO); - assert_eq!(params.call, approve_call); - assert_eq!(params.max_priority_fee_per_gas, Some(200)); - assert_eq!(params.max_fee_per_gas, Some(100)); - } -} diff --git a/crates/common/src/lib.rs b/crates/common/src/lib.rs index a2c3c1036f..672a8acab7 100644 --- a/crates/common/src/lib.rs +++ b/crates/common/src/lib.rs @@ -25,6 +25,8 @@ pub mod types; pub mod unit_tests; pub mod utils; pub mod withdraw; +#[cfg(not(target_family = "wasm"))] +pub mod write_tx; pub use dotrain; pub use dotrain_lsp; #[cfg(test)] diff --git a/crates/common/src/remove_order.rs b/crates/common/src/remove_order.rs index 12e334f318..fdb678a4d8 100644 --- a/crates/common/src/remove_order.rs +++ b/crates/common/src/remove_order.rs @@ -1,11 +1,10 @@ #[cfg(not(target_family = "wasm"))] use crate::transaction::TransactionArgs; use crate::transaction::TransactionArgsError; +#[cfg(not(target_family = "wasm"))] +use crate::write_tx::{execute_write_tx, WriteTransactionError, WriteTransactionStatus}; use alloy::primitives::hex::FromHexError; use alloy::sol_types::SolCall; -use alloy_ethers_typecast::WritableClientError; -#[cfg(not(target_family = "wasm"))] -use alloy_ethers_typecast::{WriteTransaction, WriteTransactionStatus}; use raindex_bindings::IRaindexV6::removeOrder3Call; use raindex_subgraph_client::types::{common::SgOrder, order_detail_traits::OrderDetailError}; use serde::{Deserialize, Serialize}; @@ -13,8 +12,9 @@ use thiserror::Error; #[derive(Error, Debug)] pub enum RemoveOrderArgsError { + #[cfg(not(target_family = "wasm"))] #[error(transparent)] - WritableClientError(#[from] WritableClientError), + WriteTransaction(#[from] WriteTransactionError), #[error(transparent)] TransactionArgs(#[from] TransactionArgsError), #[error(transparent)] @@ -47,7 +47,7 @@ impl TryInto for RemoveOrderArgs { impl RemoveOrderArgs { #[cfg(not(target_family = "wasm"))] - pub async fn execute)>( + pub async fn execute( self, transaction_args: TransactionArgs, transaction_status_changed: S, @@ -55,14 +55,10 @@ impl RemoveOrderArgs { let (ledger_client, _) = transaction_args.clone().try_into_ledger_client().await?; let remove_order_call: removeOrder3Call = self.try_into()?; - let params = transaction_args.try_into_write_contract_parameters( - remove_order_call, - transaction_args.raindex_address, - )?; + let tx_request = transaction_args + .try_into_transaction_request(remove_order_call, transaction_args.raindex_address)?; - WriteTransaction::new(ledger_client, params, 4, transaction_status_changed) - .execute() - .await?; + execute_write_tx(ledger_client, tx_request, 4, transaction_status_changed).await?; Ok(()) } @@ -72,97 +68,3 @@ impl RemoveOrderArgs { Ok(remove_order_call.abi_encode()) } } - -#[cfg(all(test, not(target_family = "wasm")))] -mod tests { - use super::*; - use alloy::primitives::Address; - use raindex_bindings::IRaindexV6::removeOrder3Call; - use raindex_subgraph_client::types::common::{SgBigInt, SgBytes, SgErc20, SgRaindex, SgVault}; - use raindex_subgraph_client::utils::float::*; - - fn get_order() -> SgOrder { - SgOrder { - id: SgBytes( - "0x99db88d9726c5dbcea240be8eba022d2fd6dd40f6d947dc28cda692a9ba8e6ae".to_string(), - ), - order_bytes: SgBytes( - "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000018a62a3ac2ca9f775a4a12380eda03245270b73e00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001e000000000000000000000000000000000000000000000000000000000000002602d79fbdfab4699235b5e9d2144f3bab5e2d887c3f4df9d1a1a1bef1d9d5b81b20000000000000000000000005fb33d710f8b58de4c9fdec703b5c2487a5219d600000000000000000000000084c6e7f5a1e5dd89594cc25bef4722a1b8871ae6000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000ad00000000000000000000000000000000000000000000000000000000000000020000000000000000000000001d80c49bbbcd1c0911346656b529df9e5c2f783d0000000000000000000000000000000000000000000000000214e8348c4f0000000000000000000000000000000000000000000000000000000000000000002d0200000024080500021810000001100001361100000110000101100000031000041e12000022130000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000b38e83b86d491735feaa0a791f65c2b995353960000000000000000000000000000000000000000000000000000000000000006d23be6b1eb755ac469bba083cade61d48f156fc531662469291dc04a0782964500000000000000000000000000000000000000000000000000000000000000010000000000000000000000001d80c49bbbcd1c0911346656b529df9e5c2f783d0000000000000000000000000000000000000000000000000000000000000012d23be6b1eb755ac469bba083cade61d48f156fc531662469291dc04a07829645".to_string(), - ), - order_hash: SgBytes( - "0x99db88d9726c5dbcea240be8eba022d2fd6dd40f6d947dc28cda692a9ba8e6ae".to_string(), - ), - owner: SgBytes("0x18a62a3ac2ca9f775a4a12380eda03245270b73e".to_string()), - outputs: vec![ - SgVault { - id: SgBytes("0xfd661f641ed6f13210fa83be991d7afc8e290202473f1fa9548a8e5654984575".to_string()), - owner: SgBytes("0x18a62a3ac2ca9f775a4a12380eda03245270b73e".to_string()), - vault_id: SgBytes("95091534377674853556918913044061641909871616138258204934350492514947914962501".to_string()), - balance: SgBytes(F50.as_hex()), - token: SgErc20 { - id: SgBytes("0x1d80c49bbbcd1c0911346656b529df9e5c2f783d".to_string()), - address: SgBytes("0x1d80c49bbbcd1c0911346656b529df9e5c2f783d".to_string()), - name: Some("Wrapped Flare".to_string()), - symbol: Some("WFLR".to_string()), - decimals: Some(SgBigInt("18".to_string())), - }, - raindex: SgRaindex { - id: SgBytes("0xcee8cd002f151a536394e564b84076c41bbbcd4d".to_string()), - }, - orders_as_output: vec![], - orders_as_input: vec![], - balance_changes: vec![], - }, - ], - inputs: vec![], - raindex: SgRaindex { - id: SgBytes("0xcee8cd002f151a536394e564b84076c41bbbcd4d".to_string()), - }, - active: true, - timestamp_added: SgBigInt("1745524403".to_string()), - meta: None, - add_events: vec![], - remove_events: vec![], - trades: vec![], - } - } - - #[tokio::test] - async fn test_remove_order_calldata() { - let remove_order_args = RemoveOrderArgs { order: get_order() }; - let calldata = remove_order_args.get_rm_order_calldata().await.unwrap(); - - let remove_order_call = removeOrder3Call { - order: get_order().try_into().unwrap(), - tasks: vec![], - }; - let expected_calldata = remove_order_call.abi_encode(); - - assert_eq!(calldata, expected_calldata); - } - - #[test] - fn test_try_into_remove_order_call() { - let remove_order_call = removeOrder3Call { - order: get_order().try_into().unwrap(), - tasks: vec![], - }; - - let args = TransactionArgs { - rpcs: vec!["http://test.com".to_string()], - raindex_address: Address::ZERO, - derivation_index: Some(0_usize), - chain_id: Some(1), - max_priority_fee_per_gas: Some(200), - max_fee_per_gas: Some(100), - }; - - let params = args - .try_into_write_contract_parameters(remove_order_call.clone(), args.raindex_address) - .unwrap(); - assert_eq!(params.address, args.raindex_address); - assert_eq!(params.call, remove_order_call); - assert_eq!(params.max_priority_fee_per_gas, Some(200)); - assert_eq!(params.max_fee_per_gas, Some(100)); - } -} diff --git a/crates/common/src/transaction.rs b/crates/common/src/transaction.rs index b28b95933a..db72f85494 100644 --- a/crates/common/src/transaction.rs +++ b/crates/common/src/transaction.rs @@ -1,24 +1,29 @@ use alloy::primitives::{ruint::FromUintError, Address}; +use alloy::providers::Provider; +use alloy::rpc::types::TransactionRequest; use alloy::sol_types::SolCall; +use alloy::transports::TransportError; use rain_math_float::FloatError; +use raindex_bindings::provider::{mk_read_provider, ReadProviderError}; use serde::{Deserialize, Serialize}; use thiserror::Error; +use url::Url; #[cfg(not(target_family = "wasm"))] use alloy::{ network::AnyNetwork, - providers::{Provider, ProviderBuilder, WalletProvider}, + providers::{ProviderBuilder, WalletProvider}, signers::ledger::{HDPath, LedgerError, LedgerSigner}, }; -use alloy_ethers_typecast::{ - ReadableClient, ReadableClientError, WritableClientError, WriteContractParameters, - WriteContractParametersBuilder, WriteContractParametersBuilderError, -}; + +#[cfg(not(target_family = "wasm"))] +use crate::write_tx::WriteTransactionError; #[derive(Error, Debug)] pub enum WritableTransactionExecuteError { + #[cfg(not(target_family = "wasm"))] #[error(transparent)] - WritableClient(#[from] WritableClientError), + WriteTransaction(#[from] WriteTransactionError), #[error(transparent)] TransactionArgs(#[from] TransactionArgsError), #[cfg(not(target_family = "wasm"))] @@ -32,22 +37,23 @@ pub enum WritableTransactionExecuteError { #[derive(Error, Debug)] pub enum TransactionArgsError { - #[error(transparent)] - BuildParameters(#[from] WriteContractParametersBuilderError), #[error(transparent)] ChainIdParse(#[from] FromUintError), #[error("Chain ID is required, but set to None")] ChainIdNone, #[error(transparent)] - ReadableClient(#[from] ReadableClientError), - #[cfg(not(target_family = "wasm"))] + Transport(#[from] TransportError), #[error(transparent)] - Ledger(#[from] LedgerError), - #[cfg(not(target_family = "wasm"))] + ReadProvider(#[from] ReadProviderError), #[error(transparent)] Url(#[from] url::ParseError), + #[cfg(not(target_family = "wasm"))] + #[error(transparent)] + Ledger(#[from] LedgerError), #[error("Invalid input args: {0}")] InvalidArgs(String), + #[error("ABI decode error: {0}")] + AbiDecode(String), } #[derive(Clone, Serialize, Deserialize, Default)] @@ -61,30 +67,27 @@ pub struct TransactionArgs { } impl TransactionArgs { - pub fn try_into_write_contract_parameters( + pub fn try_into_transaction_request( &self, call: T, contract: Address, - ) -> Result, TransactionArgsError> { - let params = WriteContractParametersBuilder::default() - .address(contract) - .call(call) - .max_priority_fee_per_gas(self.max_priority_fee_per_gas) - .max_fee_per_gas(self.max_fee_per_gas) - .build()?; - - Ok(params) + ) -> Result { + let mut tx = TransactionRequest::default() + .to(contract) + .input(call.abi_encode().into()); + if let Some(max_priority) = self.max_priority_fee_per_gas { + tx = tx.max_priority_fee_per_gas(max_priority); + } + if let Some(max_fee) = self.max_fee_per_gas { + tx = tx.max_fee_per_gas(max_fee); + } + Ok(tx) } pub async fn try_fill_chain_id(&mut self) -> Result<(), TransactionArgsError> { if self.chain_id.is_none() { - let chain_id = ReadableClient::new_from_http_urls(self.rpcs.clone())? - .get_chainid() - .await?; - - self.chain_id = Some(chain_id); + self.chain_id = Some(read_chain_id(&self.rpcs).await?); } - Ok(()) } @@ -128,163 +131,32 @@ impl TransactionArgs { } } - // if we are here, we have tried all rpcs and failed Err(err.unwrap()) } } -#[cfg(all(test, not(target_family = "wasm")))] -mod tests { - use alloy::primitives::{address, B256, U256}; - use httpmock::MockServer; - - use super::*; - use raindex_bindings::IRaindexV6::vaultBalance2Call; - - #[test] - fn test_try_into_write_contract_parameters_ok() { - let args = TransactionArgs { - raindex_address: Address::ZERO, - derivation_index: None, - chain_id: None, - rpcs: vec!["https://mainnet.infura.io/v3/your-api-key".to_string()], - max_priority_fee_per_gas: None, - max_fee_per_gas: None, - }; - - let call = vaultBalance2Call { - owner: Address::ZERO, - token: Address::ZERO, - vaultId: B256::ZERO, - }; - - let params = args - .try_into_write_contract_parameters(call.clone(), Address::ZERO) - .unwrap(); - - assert_eq!(params.address, Address::ZERO); - assert_eq!(params.call, call); - assert_eq!(params.max_priority_fee_per_gas, None); - assert_eq!(params.max_fee_per_gas, None); - - let args = TransactionArgs { - raindex_address: address!("123abcdef24Ca5003905aA834De7156C68b2E1d0"), - derivation_index: Some(0), - chain_id: Some(1), - rpcs: vec!["https://mainnet.infura.io/v3/your-api-key".to_string()], - max_priority_fee_per_gas: Some(100), - max_fee_per_gas: Some(200), - }; - - let call = vaultBalance2Call { - owner: address!("b20a608c624Ca5003905aA834De7156C68b2E1d0"), - token: address!("00000000219ab540356cBB839Cbe05303d7705Fa"), - vaultId: B256::from(U256::from(123456)), - }; - - let params = args - .try_into_write_contract_parameters( - call.clone(), - address!("0000000000000000000000000123456789abcdef"), - ) - .unwrap(); - - assert_eq!( - params.address, - address!("0000000000000000000000000123456789abcdef") - ); - assert_eq!(params.call, call); - assert_eq!(params.max_priority_fee_per_gas, Some(100)); - assert_eq!(params.max_fee_per_gas, Some(200)); - } - - #[tokio::test] - async fn test_try_fill_chain_id_ok() { - let server = MockServer::start(); - - server.mock(|when, then| { - when.path("/rpc").body_contains("eth_chainId"); - - then.status(200) - .header("content-type", "application/json") - .body(r#"{ "jsonrpc": "2.0", "id": 1, "result": "0x1" }"#); - }); - - let mut args = TransactionArgs { - raindex_address: Address::ZERO, - derivation_index: None, - chain_id: None, - rpcs: vec![server.url("/rpc")], - max_priority_fee_per_gas: None, - max_fee_per_gas: None, - }; - - args.try_fill_chain_id().await.unwrap(); - assert_eq!(args.chain_id, Some(1)); - - // the URL is invalid but it shouldn't be used now that chain ID is set - args.rpcs = vec!["".to_string()]; - args.try_fill_chain_id().await.unwrap(); - assert_eq!(args.chain_id, Some(1)); - } - - #[tokio::test] - async fn test_try_fill_chain_id_err() { - let server = MockServer::start(); - - server.mock(|when, then| { - when.path("/rpc").body_contains("eth_chainId"); - then.status(500); - }); - - let mut args = TransactionArgs { - raindex_address: Address::ZERO, - derivation_index: None, - chain_id: None, - rpcs: vec![server.url("/rpc")], - max_priority_fee_per_gas: None, - max_fee_per_gas: None, - }; - - let err = args.try_fill_chain_id().await.unwrap_err(); - assert!( - matches!( - &err, - TransactionArgsError::ReadableClient(ReadableClientError::AllProvidersFailed(ref msg)) - if msg.get(&args.rpcs[0]).is_some() - && matches!( - msg.get(&args.rpcs[0]).unwrap(), - ReadableClientError::ReadChainIdError(_) - ) - ), - "unexpected error variant: {err:?}" - ); - } - - #[tokio::test] - async fn test_try_into_ledger_client_err() { - let server = MockServer::start(); - - server.mock(|when, then| { - when.path("/rpc").body_contains("eth_chainId"); - then.status(200) - .body(r#"{ "jsonrpc": "2.0", "id": 1, "result": "0x1" }"#); - }); - - let args = TransactionArgs { - raindex_address: Address::ZERO, - derivation_index: None, - chain_id: None, - rpcs: vec![server.url("/rpc")], - max_priority_fee_per_gas: None, - max_fee_per_gas: None, - }; - - let result = args.clone().try_into_ledger_client().await; - assert!(result.is_err()); - } +pub async fn read_chain_id(rpcs: &[String]) -> Result { + let urls = rpcs + .iter() + .map(|s| s.parse::()) + .collect::, _>>()?; + let provider = mk_read_provider(&urls)?; + Ok(provider.get_chain_id().await?) +} - // NOTE: `alloy` ignores all ledger tests so it seems like there is no way - // to mock a device. hence there is only a test case for a scenario that - // should fail regardless of whether a ledger is connected or not +pub async fn read_call( + rpcs: &[String], + contract: Address, + call: C, +) -> Result { + let urls = rpcs + .iter() + .map(|s| s.parse::()) + .collect::, _>>()?; + let provider = mk_read_provider(&urls)?; + let tx = TransactionRequest::default() + .to(contract) + .input(call.abi_encode().into()); + let bytes = provider.call(tx).await?; + C::abi_decode_returns(&bytes).map_err(|e| TransactionArgsError::AbiDecode(e.to_string())) } diff --git a/crates/common/src/withdraw.rs b/crates/common/src/withdraw.rs index 8fe61c9c0f..822bdb94f1 100644 --- a/crates/common/src/withdraw.rs +++ b/crates/common/src/withdraw.rs @@ -1,10 +1,10 @@ #[cfg(not(target_family = "wasm"))] use crate::transaction::TransactionArgs; use crate::transaction::WritableTransactionExecuteError; +#[cfg(not(target_family = "wasm"))] +use crate::write_tx::{execute_write_tx, WriteTransactionStatus}; use alloy::primitives::{Address, B256}; use alloy::sol_types::SolCall; -#[cfg(not(target_family = "wasm"))] -use alloy_ethers_typecast::{WriteTransaction, WriteTransactionStatus}; use serde::{Deserialize, Serialize}; use rain_math_float::Float; @@ -29,9 +29,8 @@ impl From for withdraw4Call { } impl WithdrawArgs { - /// Execute Raindex withdraw call #[cfg(not(target_family = "wasm"))] - pub async fn execute)>( + pub async fn execute( &self, transaction_args: TransactionArgs, transaction_status_changed: S, @@ -39,12 +38,10 @@ impl WithdrawArgs { let (ledger_client, _) = transaction_args.clone().try_into_ledger_client().await?; let withdraw_call: withdraw4Call = self.clone().into(); - let params = transaction_args - .try_into_write_contract_parameters(withdraw_call, transaction_args.raindex_address)?; + let tx_request = transaction_args + .try_into_transaction_request(withdraw_call, transaction_args.raindex_address)?; - WriteTransaction::new(ledger_client, params, 4, transaction_status_changed) - .execute() - .await?; + execute_write_tx(ledger_client, tx_request, 4, transaction_status_changed).await?; Ok(()) } @@ -54,79 +51,3 @@ impl WithdrawArgs { Ok(withdraw_call.abi_encode()) } } - -#[cfg(all(test, not(target_family = "wasm")))] -mod tests { - use super::*; - use alloy::primitives::{address, U256}; - use std::str::FromStr; - - #[test] - fn test_withdraw_args_into() { - let amount = Float::parse("100".to_string()).unwrap(); - let args = WithdrawArgs { - token: "0x1234567890abcdef1234567890abcdef12345678" - .parse::
() - .unwrap(), - vault_id: B256::from(U256::from(42)), - target_amount: amount, - }; - - let withdraw_call: withdraw4Call = args.into(); - assert_eq!( - withdraw_call.token, - address!("1234567890abcdef1234567890abcdef12345678") - ); - assert_eq!(withdraw_call.vaultId, B256::from(U256::from(42))); - assert_eq!(withdraw_call.targetAmount, amount.get_inner()); - } - - #[tokio::test] - async fn test_get_withdraw_calldata() { - let amount = Float::parse("100".to_string()).unwrap(); - let args = WithdrawArgs { - token: Address::from_str("0x1234567890abcdef1234567890abcdef12345678").unwrap(), - vault_id: B256::from(U256::from(42)), - target_amount: amount, - }; - let calldata = args.get_withdraw_calldata().await.unwrap(); - - let expected_calldata = withdraw4Call { - token: Address::from_str("0x1234567890abcdef1234567890abcdef12345678").unwrap(), - vaultId: B256::from(U256::from(42)), - targetAmount: amount.get_inner(), - tasks: vec![], - } - .abi_encode(); - - assert_eq!(calldata, expected_calldata); - assert_eq!(calldata.len(), 164); - } - - #[test] - fn test_withdraw_call_try_into_write_contract_parameters() { - let args = TransactionArgs { - rpcs: vec!["http://test.com".to_string()], - raindex_address: Address::ZERO, - derivation_index: Some(0_usize), - chain_id: Some(1), - max_priority_fee_per_gas: Some(200), - max_fee_per_gas: Some(100), - }; - - let amount = Float::parse("456".to_string()).unwrap().get_inner(); - let withdraw_call = withdraw4Call { - token: Address::from_str("0x1234567890abcdef1234567890abcdef12345678").unwrap(), - vaultId: B256::from(U256::from(123)), - targetAmount: amount, - tasks: vec![], - }; - let params = args - .try_into_write_contract_parameters(withdraw_call.clone(), Address::ZERO) - .unwrap(); - assert_eq!(params.address, Address::ZERO); - assert_eq!(params.call, withdraw_call); - assert_eq!(params.max_priority_fee_per_gas, Some(200)); - assert_eq!(params.max_fee_per_gas, Some(100)); - } -} diff --git a/crates/common/src/write_tx.rs b/crates/common/src/write_tx.rs new file mode 100644 index 0000000000..07abad6092 --- /dev/null +++ b/crates/common/src/write_tx.rs @@ -0,0 +1,59 @@ +use alloy::network::{AnyNetwork, AnyReceiptEnvelope}; +use alloy::providers::{Provider, WalletProvider}; +use alloy::rpc::types::{Log, TransactionReceipt, TransactionRequest}; +use thiserror::Error; + +#[derive(Clone, Debug)] +pub enum WriteTransactionStatus { + PendingPrepare(Box), + PendingSign(Box), + Sending, + Confirmed(Box>>), +} + +#[derive(Debug, Error)] +pub enum WriteTransactionError { + #[error("Failed to send transaction: {0}")] + Send(String), + #[error("Failed to confirm transaction: {0}")] + Confirmation(String), + #[error("Transaction reverted")] + Reverted, +} + +pub async fn execute_write_tx< + P: Provider + WalletProvider + Clone, + F: Fn(WriteTransactionStatus), +>( + provider: P, + tx_request: TransactionRequest, + confirmations: u8, + status_changed: F, +) -> Result<(), WriteTransactionError> { + status_changed(WriteTransactionStatus::PendingPrepare(Box::new( + tx_request.clone(), + ))); + status_changed(WriteTransactionStatus::PendingSign(Box::new( + tx_request.clone(), + ))); + + let pending_tx = provider + .send_transaction(tx_request) + .await + .map_err(|e| WriteTransactionError::Send(e.to_string()))? + .with_required_confirmations(u64::from(confirmations)); + + status_changed(WriteTransactionStatus::Sending); + + let receipt = pending_tx + .get_receipt() + .await + .map_err(|e| WriteTransactionError::Confirmation(e.to_string()))?; + + if !receipt.inner.inner.status() { + return Err(WriteTransactionError::Reverted); + } + + status_changed(WriteTransactionStatus::Confirmed(Box::new(receipt.inner))); + Ok(()) +} diff --git a/crates/js_api/Cargo.toml b/crates/js_api/Cargo.toml index eee4356a65..275223c4dd 100644 --- a/crates/js_api/Cargo.toml +++ b/crates/js_api/Cargo.toml @@ -21,14 +21,13 @@ raindex_app_settings = { workspace = true } raindex_subgraph_client = { workspace = true } raindex_bindings = { workspace = true } raindex_quote = { workspace = true } -alloy-ethers-typecast = { workspace = true } wasm-bindgen-utils = { workspace = true } tokio = { workspace = true, features = [ - "sync", - "macros", - "io-util", - "rt", - "time", + "sync", + "macros", + "io-util", + "rt", + "time", ] } alloy = { workspace = true, features = ["dyn-abi"] } flate2 = "1.0.34" diff --git a/crates/quote/Cargo.toml b/crates/quote/Cargo.toml index 540f99f65f..418c74ef5c 100644 --- a/crates/quote/Cargo.toml +++ b/crates/quote/Cargo.toml @@ -19,7 +19,6 @@ raindex_subgraph_client = { workspace = true } futures = { workspace = true } rain-error-decoding = { workspace = true } alloy = { workspace = true, features = ["sol-types"] } -alloy-ethers-typecast = { workspace = true } serde = { workspace = true } serde_json = { workspace = true } thiserror = { workspace = true } diff --git a/lib/rain.interpreter b/lib/rain.interpreter index 2c041df702..bbd39eaefb 160000 --- a/lib/rain.interpreter +++ b/lib/rain.interpreter @@ -1 +1 @@ -Subproject commit 2c041df70284be63edfdbec209ff17a318eee279 +Subproject commit bbd39eaefb0087f6c877d92cb53cdfd95f34452d From 86ec6e07260b6e4d71d2ca8fe23ae4de7f3a9c1d Mon Sep 17 00:00:00 2001 From: David Meister Date: Sat, 23 May 2026 06:40:35 +0000 Subject: [PATCH 7/7] ci: stop recursing submodules during checkout Co-Authored-By: Claude Opus 4.7 --- .github/workflows/copilot-setup-steps.yml | 8 +------- .github/workflows/deploy-subgraph.yaml | 7 +------ .github/workflows/git-clean.yaml | 10 +--------- .github/workflows/manual-rs-release.yml | 6 +----- .github/workflows/manual-sol-artifacts.yaml | 9 +-------- .github/workflows/rainix.yaml | 11 ++--------- .github/workflows/test-subgraph.yml | 11 +---------- .github/workflows/test-ui-components.yaml | 14 +------------- .github/workflows/test-webapp.yaml | 17 ++--------------- .github/workflows/vercel-docs-preview.yaml | 12 ++---------- .github/workflows/vercel-docs-prod.yaml | 8 +------- .github/workflows/vercel-preview.yaml | 2 +- .github/workflows/vercel-prod.yaml | 11 +---------- 13 files changed, 16 insertions(+), 110 deletions(-) diff --git a/.github/workflows/copilot-setup-steps.yml b/.github/workflows/copilot-setup-steps.yml index f37dd2d13c..fbe1899776 100644 --- a/.github/workflows/copilot-setup-steps.yml +++ b/.github/workflows/copilot-setup-steps.yml @@ -1,5 +1,4 @@ name: Copilot Agent Setup - on: workflow_dispatch: push: @@ -17,35 +16,30 @@ jobs: steps: - uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | keep-env-derivations = true keep-outputs = true - - name: Restore and save Nix store uses: nix-community/cache-nix-action@v6 with: primary-key: nix-${{ runner.os }}-${{ hashFiles('**/*.nix', '**/flake.lock') }} restore-prefixes-first-match: nix-${{ runner.os }}- gc-max-store-size-linux: 1G - - name: Prepare environment files run: | set -euxo pipefail cp -f .env.example .env cp -f packages/webapp/.env.example packages/webapp/.env cp -f .env.example crates/common/.env - - name: Prepare repository dependencies run: ./prep-all.sh env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID || 'test' }} COMMIT_SHA: ${{ github.sha }} - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() diff --git a/.github/workflows/deploy-subgraph.yaml b/.github/workflows/deploy-subgraph.yaml index c0e9e51f40..762d7ee18d 100644 --- a/.github/workflows/deploy-subgraph.yaml +++ b/.github/workflows/deploy-subgraph.yaml @@ -1,7 +1,6 @@ name: Deploy subgraph on: workflow_dispatch: - jobs: deploy: permissions: @@ -14,12 +13,10 @@ jobs: steps: - uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -31,9 +28,7 @@ jobs: primary-key: nix-${{ runner.os }}-${{ hashFiles('**/*.nix', '**/flake.lock') }} restore-prefixes-first-match: nix-${{ runner.os }}- gc-max-store-size-linux: 1G - - run: nix develop -c subgraph-deploy - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() diff --git a/.github/workflows/git-clean.yaml b/.github/workflows/git-clean.yaml index dde5610f0e..554700e9bf 100644 --- a/.github/workflows/git-clean.yaml +++ b/.github/workflows/git-clean.yaml @@ -4,11 +4,9 @@ on: branches: - main pull_request: - concurrency: group: ${{ github.ref }}-git-clean cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} - jobs: git-clean: permissions: @@ -18,12 +16,10 @@ jobs: steps: - uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -40,17 +36,13 @@ jobs: # before trying to save a new cache # 1G = 1073741824 gc-max-store-size-linux: 1G - # Build metas etc. required to do a correct pointer build. - run: ./pointers.sh - # Format the repo after generating pointers so that the pointer files are # formatted too. - run: nix develop -c forge fmt - # Check if the repo is clean after generating pointers and formatting. - run: git diff --exit-code - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() # This ensures it runs regardless of previous step outcomes diff --git a/.github/workflows/manual-rs-release.yml b/.github/workflows/manual-rs-release.yml index 52b6a94fed..3a8274883e 100644 --- a/.github/workflows/manual-rs-release.yml +++ b/.github/workflows/manual-rs-release.yml @@ -1,6 +1,5 @@ name: Manual rs release on: [workflow_dispatch] - jobs: release: runs-on: ubuntu-latest @@ -11,8 +10,7 @@ jobs: - uses: actions/checkout@v4 with: fetch-depth: 0 - submodules: recursive - + submodules: true - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -29,9 +27,7 @@ jobs: # before trying to save a new cache # 1G = 1073741824 gc-max-store-size-linux: 1G - - run: nix develop --command cargo release --workspace - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() diff --git a/.github/workflows/manual-sol-artifacts.yaml b/.github/workflows/manual-sol-artifacts.yaml index f50e495e56..c621345397 100644 --- a/.github/workflows/manual-sol-artifacts.yaml +++ b/.github/workflows/manual-sol-artifacts.yaml @@ -13,7 +13,6 @@ on: - arb-generic-pool-order-taker - arb-route-processor-order-taker - arb-generic-pool-flash-borrower - jobs: deploy: runs-on: ubuntu-latest @@ -23,9 +22,8 @@ jobs: steps: - uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -42,11 +40,9 @@ jobs: # before trying to save a new cache # 1G = 1073741824 gc-max-store-size-linux: 1G - - run: nix develop -c rainix-sol-prelude - run: nix develop -c rainix-rs-prelude - run: nix develop -c raindex-prelude - - name: deploy to all supported networks run: nix develop -c rainix-sol-artifacts env: @@ -54,19 +50,16 @@ jobs: DEPLOY_BROADCAST: "1" DEPLOYMENT_KEY: ${{ secrets.PRIVATE_KEY }} ETH_RPC_URL: ${{ secrets.CI_DEPLOY_BASE_RPC_URL || vars.CI_DEPLOY_BASE_RPC_URL || '' }} - CI_DEPLOY_ARBITRUM_RPC_URL: ${{ secrets.CI_DEPLOY_ARBITRUM_RPC_URL || vars.CI_DEPLOY_ARBITRUM_RPC_URL || '' }} CI_DEPLOY_BASE_RPC_URL: ${{ secrets.CI_DEPLOY_BASE_RPC_URL || vars.CI_DEPLOY_BASE_RPC_URL || '' }} CI_DEPLOY_BASE_SEPOLIA_RPC_URL: ${{ secrets.CI_DEPLOY_BASE_SEPOLIA_RPC_URL || vars.CI_DEPLOY_BASE_SEPOLIA_RPC_URL || '' }} CI_DEPLOY_FLARE_RPC_URL: ${{ secrets.CI_DEPLOY_FLARE_RPC_URL || vars.CI_DEPLOY_FLARE_RPC_URL || '' }} CI_DEPLOY_POLYGON_RPC_URL: ${{ secrets.CI_DEPLOY_POLYGON_RPC_URL || vars.CI_DEPLOY_POLYGON_RPC_URL || '' }} - CI_DEPLOY_ARBITRUM_ETHERSCAN_API_KEY: ${{ secrets.CI_DEPLOY_ARBITRUM_ETHERSCAN_API_KEY || vars.CI_DEPLOY_ARBITRUM_ETHERSCAN_API_KEY || '' }} CI_DEPLOY_BASE_ETHERSCAN_API_KEY: ${{ secrets.CI_DEPLOY_BASE_ETHERSCAN_API_KEY || vars.CI_DEPLOY_BASE_ETHERSCAN_API_KEY || '' }} CI_DEPLOY_BASE_SEPOLIA_ETHERSCAN_API_KEY: ${{ secrets.CI_DEPLOY_BASE_SEPOLIA_ETHERSCAN_API_KEY || vars.CI_DEPLOY_BASE_SEPOLIA_ETHERSCAN_API_KEY || '' }} CI_DEPLOY_FLARE_ETHERSCAN_API_KEY: ${{ secrets.CI_DEPLOY_FLARE_ETHERSCAN_API_KEY || vars.CI_DEPLOY_FLARE_ETHERSCAN_API_KEY || '' }} CI_DEPLOY_POLYGON_ETHERSCAN_API_KEY: ${{ secrets.CI_DEPLOY_POLYGON_ETHERSCAN_API_KEY || vars.CI_DEPLOY_POLYGON_ETHERSCAN_API_KEY || '' }} - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() diff --git a/.github/workflows/rainix.yaml b/.github/workflows/rainix.yaml index 782ffc87e9..cca0c41962 100644 --- a/.github/workflows/rainix.yaml +++ b/.github/workflows/rainix.yaml @@ -4,11 +4,9 @@ on: branches: - main pull_request: - concurrency: group: ${{ github.ref }}-rainix cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} - jobs: standard-tests: permissions: @@ -52,15 +50,13 @@ jobs: steps: - uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - - name: Free disk space if: matrix.os == 'ubuntu-latest' uses: jlumbroso/free-disk-space@v1.3.1 with: large-packages: ${{ matrix.task != 'rainix-wasm-browser-test' }} - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -76,9 +72,7 @@ jobs: # collect garbage until the Nix store size is at most this number # before trying to save a new cache gc-max-store-size-linux: 10G - - run: ./pointers.sh - - name: Run ${{ matrix.task }} env: ETH_RPC_URL: ${{ secrets.CI_DEPLOY_BASE_RPC_URL || vars.CI_DEPLOY_BASE_RPC_URL || '' }} @@ -88,10 +82,9 @@ jobs: CI_DEPLOY_FLARE_RPC_URL: ${{ secrets.CI_DEPLOY_FLARE_RPC_URL || vars.CI_DEPLOY_FLARE_RPC_URL || '' }} CI_DEPLOY_POLYGON_RPC_URL: ${{ secrets.CI_DEPLOY_POLYGON_RPC_URL || vars.CI_DEPLOY_POLYGON_RPC_URL || '' }} run: nix develop -c ${{ matrix.task }} - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status - if: always() + if: always() uses: rainlanguage/github-chore/.github/actions/telegram-status-report@main with: status: ${{ job.status }} diff --git a/.github/workflows/test-subgraph.yml b/.github/workflows/test-subgraph.yml index 3fd9f45595..127feab56e 100644 --- a/.github/workflows/test-subgraph.yml +++ b/.github/workflows/test-subgraph.yml @@ -4,28 +4,23 @@ on: branches: - main pull_request: - concurrency: group: ${{ github.ref }}-subgraph cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} - jobs: test: permissions: id-token: write contents: read runs-on: ubuntu-latest - steps: - name: Checkout repository uses: actions/checkout@v4 with: fetch-depth: 0 - submodules: recursive - + submodules: true - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -42,16 +37,12 @@ jobs: # before trying to save a new cache # 1G = 1073741824 gc-max-store-size-linux: 1G - - run: | (cd lib/rain.interpreter/lib/rain.interpreter.interface/lib/rain.math.float && nix develop -c rainix-sol-prelude) - - name: Build subgraph run: nix develop -c subgraph-build - - name: Matchstick tests run: nix develop -c subgraph-test - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() diff --git a/.github/workflows/test-ui-components.yaml b/.github/workflows/test-ui-components.yaml index be5049c380..b59c8eda42 100644 --- a/.github/workflows/test-ui-components.yaml +++ b/.github/workflows/test-ui-components.yaml @@ -4,11 +4,9 @@ on: branches: - main pull_request: - concurrency: group: ${{ github.ref }}-ui-components cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} - jobs: test: permissions: @@ -20,12 +18,10 @@ jobs: steps: - uses: actions/checkout@v2 with: - submodules: recursive + submodules: true fetch-depth: 0 - - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -42,32 +38,24 @@ jobs: # before trying to save a new cache # 1G = 1073741824 gc-max-store-size-linux: 10G - - run: ./prep-webapp.sh env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID || 'test' }} COMMIT_SHA: ${{ github.sha }} CARGO_HOME: ${{ github.workspace }}/.cargo CARGO_TARGET_DIR: ${{ github.workspace }}/.cargo/target - - name: Cleanup Rust artifacts after prep run: rm -rf target || true - - run: nix develop -c npm run svelte-lint-format-check -w @rainlanguage/ui-components - - run: nix develop -c npm run test -w @rainlanguage/ui-components - # check for npm package blacklists pkgs across all packages - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main - - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main with: working-directory: packages/raindex - - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main with: working-directory: packages/ui-components - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() diff --git a/.github/workflows/test-webapp.yaml b/.github/workflows/test-webapp.yaml index c1ba4971ad..7607c68446 100644 --- a/.github/workflows/test-webapp.yaml +++ b/.github/workflows/test-webapp.yaml @@ -4,11 +4,9 @@ on: branches: - main pull_request: - concurrency: group: ${{ github.ref }}-webapp cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} - jobs: test: permissions: @@ -20,12 +18,10 @@ jobs: steps: - uses: actions/checkout@v2 with: - submodules: recursive + submodules: true fetch-depth: 0 - - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -42,40 +38,31 @@ jobs: # before trying to save a new cache # 1G = 1073741824 gc-max-store-size-linux: 10G - - run: ./prep-webapp.sh env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID || 'test' }} COMMIT_SHA: ${{ github.sha }} CARGO_HOME: ${{ github.workspace }}/.cargo CARGO_TARGET_DIR: ${{ github.workspace }}/.cargo/target - - name: Cleanup Rust artifacts after prep run: rm -rf target || true - - run: nix develop -c npm run svelte-lint-format-check -w @rainlanguage/webapp env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID || 'test' }} - - run: nix develop -c npm run test -w @rainlanguage/webapp env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID || 'test' }} - # check for npm package blacklists pkgs across all packages - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main - - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main with: working-directory: packages/raindex - - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main with: working-directory: packages/ui-components - - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main with: working-directory: packages/webapp - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() @@ -83,4 +70,4 @@ jobs: with: status: ${{ job.status }} telegram-bot-token: ${{ secrets.TELEGRAM_BOT_TOKEN }} - telegram-chat-id: ${{ secrets.TELEGRAM_CHAT_ID }} \ No newline at end of file + telegram-chat-id: ${{ secrets.TELEGRAM_CHAT_ID }} diff --git a/.github/workflows/vercel-docs-preview.yaml b/.github/workflows/vercel-docs-preview.yaml index 6ff5c97bfc..6dc49d3bb0 100644 --- a/.github/workflows/vercel-docs-preview.yaml +++ b/.github/workflows/vercel-docs-preview.yaml @@ -9,7 +9,6 @@ on: concurrency: group: ${{ github.ref }}-vercel-docs-preview cancel-in-progress: true - jobs: Deploy-Docs-Preview: runs-on: ubuntu-latest @@ -21,38 +20,31 @@ jobs: steps: - uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 - - uses: DeterminateSystems/nix-installer-action@main with: determinate: true - uses: DeterminateSystems/flakehub-cache-action@main - - run: ./prep-all.sh env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID }} - - run: nix develop .#webapp-shell -c npm run docs working-directory: packages/raindex - - name: Prepare Vercel build output run: | OUTPUT_DIR="packages/raindex/.vercel/output" mkdir -p "${OUTPUT_DIR}/static" cp -r packages/raindex/docs/* "${OUTPUT_DIR}/static/" echo '{ "version": 3 }' > "${OUTPUT_DIR}/config.json" - - name: Install Vercel CLI run: npm install --global vercel@canary - name: Pull Vercel Environment Information run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }} - name: Deploy Project Artifacts to Vercel run: vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }} packages/raindex - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() @@ -60,4 +52,4 @@ jobs: with: status: ${{ job.status }} telegram-bot-token: ${{ secrets.TELEGRAM_BOT_TOKEN }} - telegram-chat-id: ${{ secrets.TELEGRAM_CHAT_ID }} \ No newline at end of file + telegram-chat-id: ${{ secrets.TELEGRAM_CHAT_ID }} diff --git a/.github/workflows/vercel-docs-prod.yaml b/.github/workflows/vercel-docs-prod.yaml index ff1ea4add5..5536e0460f 100644 --- a/.github/workflows/vercel-docs-prod.yaml +++ b/.github/workflows/vercel-docs-prod.yaml @@ -17,35 +17,29 @@ jobs: steps: - uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - - uses: DeterminateSystems/nix-installer-action@main with: determinate: true - uses: DeterminateSystems/flakehub-cache-action@main - - run: ./prep-all.sh env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID }} - - run: nix develop .#webapp-shell -c npm run docs working-directory: packages/raindex - - name: Prepare Vercel build output run: | OUTPUT_DIR="packages/raindex/.vercel/output" mkdir -p "${OUTPUT_DIR}/static" cp -r packages/raindex/docs/* "${OUTPUT_DIR}/static/" echo '{ "version": 3 }' > "${OUTPUT_DIR}/config.json" - - name: Install Vercel CLI run: npm install --global vercel@canary - name: Pull Vercel Environment Information run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }} - name: Deploy Project Artifacts to Vercel run: vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_TOKEN }} packages/raindex - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always() diff --git a/.github/workflows/vercel-preview.yaml b/.github/workflows/vercel-preview.yaml index c1330ae441..9b6deedb66 100644 --- a/.github/workflows/vercel-preview.yaml +++ b/.github/workflows/vercel-preview.yaml @@ -34,7 +34,7 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 with: - submodules: recursive + submodules: true fetch-depth: 0 - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 diff --git a/.github/workflows/vercel-prod.yaml b/.github/workflows/vercel-prod.yaml index b278b11e75..9652752e3b 100644 --- a/.github/workflows/vercel-prod.yaml +++ b/.github/workflows/vercel-prod.yaml @@ -17,12 +17,10 @@ jobs: steps: - uses: actions/checkout@v2 with: - submodules: recursive + submodules: true fetch-depth: 0 - - name: Free disk space uses: jlumbroso/free-disk-space@v1.3.1 - - uses: nixbuild/nix-quick-install-action@v30 with: nix_conf: | @@ -39,34 +37,27 @@ jobs: # before trying to save a new cache # 1G = 1073741824 gc-max-store-size-linux: 1G - - run: ./prep-webapp.sh env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID }} - - run: nix develop .#webapp-shell -c npm run build working-directory: packages/webapp env: PUBLIC_WALLETCONNECT_PROJECT_ID: ${{ secrets.WALLETCONNECT_PROJECT_ID }} - # check for npm package blacklists pkgs across all packages - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main - - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main with: working-directory: packages/raindex - - uses: rainlanguage/github-chore/.github/actions/npm-blacklist@main with: working-directory: packages/ui-components - - name: Install Vercel CLI run: npm install --global vercel@canary - name: Pull Vercel Environment Information run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }} - name: Deploy Project Artifacts to Vercel run: vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_TOKEN }} packages/webapp - # forwards status to telegram chat if this ci fails or gets canceled, only runs for default branch - name: Forward CI Status if: always()