Skip to content

Commit fdf4f19

Browse files
Merge pull request #2831 from rainlanguage/bump-rain-math-binary-0.1.3
chore: bump all soldeer deps to registry latest (rain-deploy 0.1.18, rain-math-float 0.3.10, rainlang 0.2.14)
2 parents f408ed1 + e69df8b commit fdf4f19

258 files changed

Lines changed: 1349 additions & 1309 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.env.example‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,12 @@
11
COMMIT_SHA=test
2+
# rain-deploy:generated:env:begin
3+
ARBITRUM_RPC_URL=https://arb1.arbitrum.io/rpc
4+
BASE_RPC_URL=https://mainnet.base.org
5+
BASE_SEPOLIA_RPC_URL=https://sepolia.base.org
6+
BSC_RPC_URL=https://bsc-dataseed.binance.org
7+
ETHEREUM_RPC_URL=https://eth-pokt.nodies.app
8+
FLARE_RPC_URL=https://flare-api.flare.network/ext/C/rpc
9+
HYPEREVM_RPC_URL=https://rpc.hyperliquid.xyz/evm
10+
POLYGON_RPC_URL=https://polygon-bor-rpc.publicnode.com
11+
ROBINHOOD_RPC_URL=https://rpc.mainnet.chain.robinhood.com
12+
# rain-deploy:generated:env:end

‎.gitignore‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,5 @@ dependencies/
2929

3030
# Local pre-commit hook config
3131
.pre-commit-config.yaml
32+
33+
.staged-config

‎crates/bindings/abis/RaindexV6.json‎

Lines changed: 26 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2065,22 +2065,6 @@
20652065
}
20662066
]
20672067
},
2068-
{
2069-
"type": "error",
2070-
"name": "MaximizeOverflow",
2071-
"inputs": [
2072-
{
2073-
"name": "signedCoefficient",
2074-
"type": "int256",
2075-
"internalType": "int256"
2076-
},
2077-
{
2078-
"name": "exponent",
2079-
"type": "int256",
2080-
"internalType": "int256"
2081-
}
2082-
]
2083-
},
20842068
{
20852069
"type": "error",
20862070
"name": "MinimumIO",
@@ -2276,6 +2260,32 @@
22762260
"name": "TokenSelfTrade",
22772261
"inputs": []
22782262
},
2263+
{
2264+
"type": "error",
2265+
"name": "UnabsExponentOverflow",
2266+
"inputs": [
2267+
{
2268+
"name": "a",
2269+
"type": "int256",
2270+
"internalType": "int256"
2271+
},
2272+
{
2273+
"name": "b",
2274+
"type": "int256",
2275+
"internalType": "int256"
2276+
},
2277+
{
2278+
"name": "signedCoefficientAbs",
2279+
"type": "uint256",
2280+
"internalType": "uint256"
2281+
},
2282+
{
2283+
"name": "exponent",
2284+
"type": "int256",
2285+
"internalType": "int256"
2286+
}
2287+
]
2288+
},
22792289
{
22802290
"type": "error",
22812291
"name": "UnsupportedCalculateOutputs",

‎crates/test_fixtures/abis/RaindexV6.json‎

Lines changed: 27 additions & 17 deletions
Large diffs are not rendered by default.

‎crates/test_fixtures/abis/RaindexV6SubParser.json‎

Lines changed: 1 addition & 17 deletions
Large diffs are not rendered by default.

‎foundry.toml‎

Lines changed: 35 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -54,42 +54,46 @@ fs_permissions = [
5454
# script/Build.sol reads `[external.package].version` to name the frozen
5555
# per-release snapshot dir.
5656
{ access = "read", path = "foundry.toml" },
57+
{ access = "read", path = "./.env.example" },
58+
{ access = "read-write", path = "./.staged-config" },
59+
{ access = "read", path = "./script/build.sh" },
5760
]
5861

5962
remappings = [
6063
# Custom remap so @openzeppelin packages' own internal imports resolve.
61-
"@openzeppelin/contracts/=dependencies/@openzeppelin-contracts-5.6.1/",
64+
"@openzeppelin/contracts/=dependencies/@openzeppelin-contracts-5.7.0/",
6265
]
6366

6467
[dependencies]
65-
forge-std = "1.16.2"
66-
"@openzeppelin-contracts" = "5.6.1"
68+
forge-std = "1.17.0"
69+
"@openzeppelin-contracts" = "5.7.0"
6770
# rainlanguage/rain.interpreter was renamed to rainlanguage/rainlang;
6871
# its Soldeer registry name follows.
69-
rainlang = "0.2.6"
72+
rainlang = "0.2.14"
7073
# rainlanguage/rain.interpreter.interface was renamed to
7174
# rainlanguage/rainlang.interface; its Soldeer registry name moved from
7275
# `rain-interpreter-interface` (0.1.x) to `rainlang-interface` (0.2.x).
73-
rainlang-interface = "0.2.9"
76+
rainlang-interface = "0.2.13"
7477
# rainlanguage/rain.raindex.interface was renamed to
7578
# rainlanguage/raindex.interface; Soldeer registry name follows.
76-
raindex-interface = "0.1.7"
77-
rain-metadata = "0.1.7"
79+
raindex-interface = "0.1.8"
80+
rain-metadata = "0.1.43"
7881
# The MetaBoard split out of `rain.metadata` into its own deploy repo. The
7982
# deploy pin lives there now; `rain-metadata` keeps the interfaces and libs.
8083
rain-metadata-deploy = "0.1.1"
81-
rain-intorastring = "0.1.0"
82-
rain-sol-codegen = "0.1.37"
84+
rain-intorastring = "0.1.4"
85+
rain-sol-codegen = "0.1.39"
8386
rain-solmem = "0.1.28"
84-
rain-math-float = "0.2.1"
85-
rain-math-float-deploy = "0.1.2"
86-
rain-tofu-erc20-decimals = "0.1.1"
87-
rain-deploy = "0.1.10"
87+
rain-math-float = "0.3.10"
88+
rain-math-float-deploy = "0.1.5"
89+
rain-tofu-erc20-decimals = "0.1.4"
90+
rain-tofu-erc20-decimals-deploy = "0.1.0"
91+
rain-deploy = "0.1.18"
8892
rain-lib-typecast = "0.1.4"
89-
rain-lib-hash = "0.1.0"
93+
rain-lib-hash = "0.1.27"
9094
rain-math-binary = "0.1.4"
91-
rain-string = "0.2.0"
92-
rain-lib-memkv = "0.1.0"
95+
rain-string = "0.3.9"
96+
rain-lib-memkv = "0.2.0"
9397
rain-extrospection = "0.1.14"
9498

9599
[soldeer]
@@ -98,29 +102,33 @@ recursive_deps = false
98102
[fuzz]
99103
runs = 5096
100104

105+
# rain-deploy:generated:rpc_endpoints:begin
101106
[rpc_endpoints]
102107
arbitrum = "${ARBITRUM_RPC_URL}"
103108
base = "${BASE_RPC_URL}"
104109
base_sepolia = "${BASE_SEPOLIA_RPC_URL}"
110+
bsc = "${BSC_RPC_URL}"
105111
ethereum = "${ETHEREUM_RPC_URL}"
106112
flare = "${FLARE_RPC_URL}"
107113
hyperevm = "${HYPEREVM_RPC_URL}"
108-
robinhood = "${ROBINHOOD_RPC_URL}"
109-
bsc = "${BSC_RPC_URL}"
110114
polygon = "${POLYGON_RPC_URL}"
115+
robinhood = "${ROBINHOOD_RPC_URL}"
116+
# rain-deploy:generated:rpc_endpoints:end
111117

112-
[etherscan]
113-
arbitrum = { key = "${CI_DEPLOY_ARBITRUM_ETHERSCAN_API_KEY}" }
114-
base = { key = "${CI_DEPLOY_BASE_ETHERSCAN_API_KEY}" }
115-
base_sepolia = { key = "${CI_DEPLOY_BASE_SEPOLIA_ETHERSCAN_API_KEY}" }
116-
ethereum = { key = "${CI_DEPLOY_ETHEREUM_ETHERSCAN_API_KEY}", chain = 1 }
117-
flare = { key = "${CI_DEPLOY_FLARE_ETHERSCAN_API_KEY}" }
118-
hyperevm = { key = "${CI_DEPLOY_HYPEREVM_ETHERSCAN_API_KEY}", chain = 999 }
119118
# Robinhood Chain (4663) is not indexed by Etherscan V2. Its Blockscout speaks
120119
# the Etherscan API, so the entry points there (the key is ignored). That
121120
# explorer has rejected non-browser clients, so if `--verify` fails there,
122121
# verify afterwards through Sourcify: `forge verify-contract --verifier
123122
# sourcify --chain 4663 ...`.
124-
robinhood = { key = "${CI_DEPLOY_ROBINHOOD_ETHERSCAN_API_KEY}", chain = 4663, url = "https://robinhoodchain.blockscout.com/api" }
123+
# rain-deploy:generated:etherscan:begin
124+
[etherscan]
125+
arbitrum = { key = "${CI_DEPLOY_ARBITRUM_ETHERSCAN_API_KEY}", chain = 42161 }
126+
base = { key = "${CI_DEPLOY_BASE_ETHERSCAN_API_KEY}", chain = 8453 }
127+
base_sepolia = { key = "${CI_DEPLOY_BASE_SEPOLIA_ETHERSCAN_API_KEY}", chain = 84532 }
125128
bsc = { key = "${CI_DEPLOY_BSC_ETHERSCAN_API_KEY}", chain = 56 }
126-
polygon = { key = "${CI_DEPLOY_POLYGON_ETHERSCAN_API_KEY}" }
129+
ethereum = { key = "${CI_DEPLOY_ETHEREUM_ETHERSCAN_API_KEY}", chain = 1 }
130+
flare = { key = "${CI_DEPLOY_FLARE_ETHERSCAN_API_KEY}", chain = 14 }
131+
hyperevm = { key = "${CI_DEPLOY_HYPEREVM_ETHERSCAN_API_KEY}", chain = 999 }
132+
polygon = { key = "${CI_DEPLOY_POLYGON_ETHERSCAN_API_KEY}", chain = 137 }
133+
robinhood = { key = "${CI_DEPLOY_ROBINHOOD_ETHERSCAN_API_KEY}", chain = 4663, url = "https://robinhoodchain.blockscout.com/api" }
134+
# rain-deploy:generated:etherscan:end

‎remappings.txt‎

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
1-
@openzeppelin-contracts-5.6.1/=dependencies/@openzeppelin-contracts-5.6.1/
2-
forge-std-1.16.2/=dependencies/forge-std-1.16.2/
3-
rain-deploy-0.1.10/=dependencies/rain-deploy-0.1.10/
1+
@openzeppelin-contracts-5.7.0/=dependencies/@openzeppelin-contracts-5.7.0/
2+
forge-std-1.17.0/=dependencies/forge-std-1.17.0/
3+
rain-deploy-0.1.18/=dependencies/rain-deploy-0.1.18/
44
rain-extrospection-0.1.14/=dependencies/rain-extrospection-0.1.14/
5-
rain-intorastring-0.1.0/=dependencies/rain-intorastring-0.1.0/
6-
rain-lib-hash-0.1.0/=dependencies/rain-lib-hash-0.1.0/
7-
rain-lib-memkv-0.1.0/=dependencies/rain-lib-memkv-0.1.0/
5+
rain-intorastring-0.1.4/=dependencies/rain-intorastring-0.1.4/
6+
rain-lib-hash-0.1.27/=dependencies/rain-lib-hash-0.1.27/
7+
rain-lib-memkv-0.2.0/=dependencies/rain-lib-memkv-0.2.0/
88
rain-lib-typecast-0.1.4/=dependencies/rain-lib-typecast-0.1.4/
99
rain-math-binary-0.1.4/=dependencies/rain-math-binary-0.1.4/
10-
rain-math-float-0.2.1/=dependencies/rain-math-float-0.2.1/
11-
rain-math-float-deploy-0.1.2/=dependencies/rain-math-float-deploy-0.1.2/
12-
rain-metadata-0.1.7/=dependencies/rain-metadata-0.1.7/
10+
rain-math-float-0.3.10/=dependencies/rain-math-float-0.3.10/
11+
rain-math-float-deploy-0.1.5/=dependencies/rain-math-float-deploy-0.1.5/
12+
rain-metadata-0.1.43/=dependencies/rain-metadata-0.1.43/
1313
rain-metadata-deploy-0.1.1/=dependencies/rain-metadata-deploy-0.1.1/
14-
rain-sol-codegen-0.1.37/=dependencies/rain-sol-codegen-0.1.37/
14+
rain-sol-codegen-0.1.39/=dependencies/rain-sol-codegen-0.1.39/
1515
rain-solmem-0.1.28/=dependencies/rain-solmem-0.1.28/
16-
rain-string-0.2.0/=dependencies/rain-string-0.2.0/
17-
rain-tofu-erc20-decimals-0.1.1/=dependencies/rain-tofu-erc20-decimals-0.1.1/
18-
raindex-interface-0.1.7/=dependencies/raindex-interface-0.1.7/
19-
rainlang-0.2.6/=dependencies/rainlang-0.2.6/
20-
rainlang-interface-0.2.9/=dependencies/rainlang-interface-0.2.9/
16+
rain-string-0.3.9/=dependencies/rain-string-0.3.9/
17+
rain-tofu-erc20-decimals-0.1.4/=dependencies/rain-tofu-erc20-decimals-0.1.4/
18+
rain-tofu-erc20-decimals-deploy-0.1.0/=dependencies/rain-tofu-erc20-decimals-deploy-0.1.0/
19+
raindex-interface-0.1.8/=dependencies/raindex-interface-0.1.8/
20+
rainlang-0.2.14/=dependencies/rainlang-0.2.14/
21+
rainlang-interface-0.2.13/=dependencies/rainlang-interface-0.2.13/

‎script/Build.sol‎

Lines changed: 40 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,20 @@
22
// SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd
33
pragma solidity =0.8.25;
44

5-
import {BuildScript} from "rain-deploy-0.1.10/src/abstract/BuildScript.sol";
6-
import {LibRainDeploySnapshot} from "rain-deploy-0.1.10/src/lib/LibRainDeploySnapshot.sol";
7-
import {LibRainDeploy} from "rain-deploy-0.1.10/src/lib/LibRainDeploy.sol";
8-
import {LibCodeGen} from "rain-sol-codegen-0.1.37/src/lib/LibCodeGen.sol";
9-
import {LibFs} from "rain-sol-codegen-0.1.37/src/lib/LibFs.sol";
10-
import {LibGenParseMeta} from "rainlang-interface-0.2.9/src/lib/codegen/LibGenParseMeta.sol";
5+
import {BuildScript} from "rain-deploy-0.1.18/src/abstract/BuildScript.sol";
6+
import {LibRainDeploySnapshot} from "rain-deploy-0.1.18/src/lib/LibRainDeploySnapshot.sol";
7+
import {LibRainDeploy} from "rain-deploy-0.1.18/src/lib/LibRainDeploy.sol";
8+
import {LibCodeGen} from "rain-sol-codegen-0.1.39/src/lib/LibCodeGen.sol";
9+
import {LibFs} from "rain-sol-codegen-0.1.39/src/lib/LibFs.sol";
10+
import {LibGenParseMeta} from "rainlang-interface-0.2.13/src/lib/codegen/LibGenParseMeta.sol";
1111
import {DeployCandidate} from "../src/abstract/RainDeploySuitesBase.sol";
1212
import {RaindexDeploySuites} from "../src/abstract/RaindexDeploySuites.sol";
13+
import {RaindexV6} from "../src/concrete/raindex/RaindexV6.sol";
1314
import {RaindexV6SubParser} from "../src/concrete/parser/RaindexV6SubParser.sol";
15+
import {GenericPoolRaindexV6ArbOrderTaker} from "../src/concrete/arb/GenericPoolRaindexV6ArbOrderTaker.sol";
16+
import {RouteProcessorRaindexV6ArbOrderTaker} from "../src/concrete/arb/RouteProcessorRaindexV6ArbOrderTaker.sol";
17+
import {GenericPoolRaindexV6FlashBorrower} from "../src/concrete/arb/GenericPoolRaindexV6FlashBorrower.sol";
18+
import {ROUTE_PROCESSOR_4_CREATION_CODE} from "../src/lib/deploy/LibRouteProcessor4CreationCode.sol";
1419
import {LibRaindexSubParser, EXTERN_PARSE_META_BUILD_DEPTH} from "../src/lib/LibRaindexSubParser.sol";
1520

1621
/// One contract's generated snapshot and the released-suites lib emitted from
@@ -19,10 +24,12 @@ struct GeneratedContract {
1924
/// Places the snapshot inside `src/generated/<dir>/` and names the
2025
/// generated released-suites lib.
2126
string contractName;
22-
/// Snapshots are written from its `sourceCreationCode` and
23-
/// `snapshot.dependencies`; the released lib takes its suite key and
24-
/// artifact path from its `snapshot`.
27+
/// The released lib takes its suite key and artifact path from its
28+
/// `snapshot`.
2529
DeployCandidate candidate;
30+
/// The creation code its snapshot is written from, with
31+
/// `candidate.snapshot.dependencies`.
32+
bytes sourceCreationCode;
2633
}
2734

2835
/// @title Build
@@ -44,17 +51,33 @@ contract Build is BuildScript, RaindexDeploySuites {
4451
/// @return The generated contracts.
4552
function generatedContracts() internal pure returns (GeneratedContract[] memory) {
4653
GeneratedContract[] memory contracts = new GeneratedContract[](6);
47-
contracts[0] = GeneratedContract({contractName: "RaindexV6", candidate: raindexCandidate()});
48-
contracts[1] = GeneratedContract({contractName: "RaindexV6SubParser", candidate: subParserCandidate()});
49-
contracts[2] = GeneratedContract({contractName: "RouteProcessor4", candidate: routeProcessorCandidate()});
54+
contracts[0] = GeneratedContract({
55+
contractName: "RaindexV6", candidate: raindexCandidate(), sourceCreationCode: type(RaindexV6).creationCode
56+
});
57+
contracts[1] = GeneratedContract({
58+
contractName: "RaindexV6SubParser",
59+
candidate: subParserCandidate(),
60+
sourceCreationCode: type(RaindexV6SubParser).creationCode
61+
});
62+
contracts[2] = GeneratedContract({
63+
contractName: "RouteProcessor4",
64+
candidate: routeProcessorCandidate(),
65+
sourceCreationCode: ROUTE_PROCESSOR_4_CREATION_CODE
66+
});
5067
contracts[3] = GeneratedContract({
51-
contractName: "GenericPoolRaindexV6ArbOrderTaker", candidate: genericPoolArbOrderTakerCandidate()
68+
contractName: "GenericPoolRaindexV6ArbOrderTaker",
69+
candidate: genericPoolArbOrderTakerCandidate(),
70+
sourceCreationCode: type(GenericPoolRaindexV6ArbOrderTaker).creationCode
5271
});
5372
contracts[4] = GeneratedContract({
54-
contractName: "RouteProcessorRaindexV6ArbOrderTaker", candidate: routeProcessorArbOrderTakerCandidate()
73+
contractName: "RouteProcessorRaindexV6ArbOrderTaker",
74+
candidate: routeProcessorArbOrderTakerCandidate(),
75+
sourceCreationCode: type(RouteProcessorRaindexV6ArbOrderTaker).creationCode
5576
});
5677
contracts[5] = GeneratedContract({
57-
contractName: "GenericPoolRaindexV6FlashBorrower", candidate: genericPoolFlashBorrowerCandidate()
78+
contractName: "GenericPoolRaindexV6FlashBorrower",
79+
candidate: genericPoolFlashBorrowerCandidate(),
80+
sourceCreationCode: type(GenericPoolRaindexV6FlashBorrower).creationCode
5881
});
5982
return contracts;
6083
}
@@ -94,9 +117,10 @@ contract Build is BuildScript, RaindexDeploySuites {
94117
for (uint256 i = 0; i < contracts.length; i++) {
95118
LibRainDeploySnapshot.writeSnapshot(
96119
vm,
120+
recordRoot(),
97121
LibRainDeploySnapshot.CANDIDATE,
98122
contracts[i].contractName,
99-
contracts[i].candidate.sourceCreationCode,
123+
contracts[i].sourceCreationCode,
100124
contracts[i].candidate.snapshot.dependencies
101125
);
102126
}

‎script/BuildAuthoringMeta.sol‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd
33
pragma solidity =0.8.25;
44

5-
import {Script} from "forge-std-1.16.2/src/Script.sol";
5+
import {Script} from "forge-std-1.17.0/src/Script.sol";
66
import {LibRaindexSubParser} from "../src/lib/LibRaindexSubParser.sol";
77

88
/// @title Raindex subparser Authoring Meta

‎script/Deploy.sol‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// SPDX-FileCopyrightText: Copyright (c) 2020 Rain Open Source Software Ltd
33
pragma solidity =0.8.25;
44

5-
import {RainDeployBroadcast} from "rain-deploy-0.1.10/src/abstract/RainDeployBroadcast.sol";
5+
import {RainDeployBroadcast} from "rain-deploy-0.1.18/src/abstract/RainDeployBroadcast.sol";
66
import {RaindexDeploySuites} from "../src/abstract/RaindexDeploySuites.sol";
77

88
/// @title Deploy

0 commit comments

Comments
 (0)