@superfluid-finance/ethereum-contracts 1.7.2-dev.09f3be3.0 → 1.7.2-dev.1ef77a5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (188) hide show
  1. package/README.md +2 -2
  2. package/artifacts/contracts/apps/SuperAppBaseFlow.sol/SuperAppBaseFlow.json +13 -13
  3. package/artifacts/contracts/apps/SuperfluidLoaderLibrary.sol/SuperfluidLoaderLibrary.json +2 -2
  4. package/artifacts/contracts/mocks/SuperAppBaseFlowTester.sol/SuperAppBaseFlowTester.json +15 -15
  5. package/build/contracts/AccessControl.json +1 -1
  6. package/build/contracts/AccessControlEnumerable.json +1 -1
  7. package/build/contracts/Address.json +1 -1
  8. package/build/contracts/AgreementBase.json +18 -18
  9. package/build/contracts/AgreementLibrary.json +165 -165
  10. package/build/contracts/BaseRelayRecipient.json +57 -57
  11. package/build/contracts/BatchLiquidator.json +382 -382
  12. package/build/contracts/BatchOperation.json +614 -614
  13. package/build/contracts/CFAv1Forwarder.json +1250 -1250
  14. package/build/contracts/CFAv1ForwarderDeployerLibrary.json +2384 -2384
  15. package/build/contracts/CFAv1Library.json +389 -389
  16. package/build/contracts/CallUtils.json +198 -198
  17. package/build/contracts/ClosingOnUpdateFlowTestApp.json +1525 -1525
  18. package/build/contracts/ConstantFlowAgreementV1.json +1087 -1087
  19. package/build/contracts/ConstantInflowNFT.json +402 -402
  20. package/build/contracts/ConstantOutflowNFT.json +661 -661
  21. package/build/contracts/Context.json +1 -1
  22. package/build/contracts/ContextDefinitions.json +614 -614
  23. package/build/contracts/CustomSuperTokenBase.json +19 -19
  24. package/build/contracts/ERC165.json +1 -1
  25. package/build/contracts/ERC1820Implementer.json +1 -1
  26. package/build/contracts/ERC1820RegistryCompiled.json +22 -22
  27. package/build/contracts/ERC20.json +1 -1
  28. package/build/contracts/ERC20WithTokenInfo.json +23 -23
  29. package/build/contracts/ERC777Helper.json +384 -384
  30. package/build/contracts/ERC777RecipientDrainingGas.json +863 -863
  31. package/build/contracts/ERC777RecipientReverting.json +863 -863
  32. package/build/contracts/EnumerableSet.json +1 -1
  33. package/build/contracts/EventsEmitter.json +43 -43
  34. package/build/contracts/ExclusiveInflowTestApp.json +1525 -1525
  35. package/build/contracts/FixedSizeData.json +200 -200
  36. package/build/contracts/FlowExchangeTestApp.json +1526 -1526
  37. package/build/contracts/FlowNFTBase.json +1280 -1280
  38. package/build/contracts/FlowOperatorDefinitions.json +614 -614
  39. package/build/contracts/ForwarderBase.json +190 -190
  40. package/build/contracts/FullUpgradableSuperTokenProxy.json +116 -116
  41. package/build/contracts/IAccessControl.json +1 -1
  42. package/build/contracts/IAccessControlEnumerable.json +1 -1
  43. package/build/contracts/IConstantFlowAgreementV1.json +677 -677
  44. package/build/contracts/IConstantInflowNFT.json +54 -54
  45. package/build/contracts/IConstantOutflowNFT.json +107 -107
  46. package/build/contracts/IDAv1Forwarder.json +912 -912
  47. package/build/contracts/IDAv1ForwarderDeployerLibrary.json +2384 -2384
  48. package/build/contracts/IDAv1Library.json +430 -430
  49. package/build/contracts/IERC165.json +1 -1
  50. package/build/contracts/IERC1820Implementer.json +1 -1
  51. package/build/contracts/IERC1820Registry.json +1 -1
  52. package/build/contracts/IERC20.json +1 -1
  53. package/build/contracts/IERC20Metadata.json +1 -1
  54. package/build/contracts/IERC20Permit.json +1 -1
  55. package/build/contracts/IERC721.json +1 -1
  56. package/build/contracts/IERC721Metadata.json +1 -1
  57. package/build/contracts/IERC777.json +1 -1
  58. package/build/contracts/IERC777Recipient.json +1 -1
  59. package/build/contracts/IERC777Sender.json +1 -1
  60. package/build/contracts/IFlowNFTBase.json +115 -115
  61. package/build/contracts/IInstantDistributionAgreementV1.json +667 -667
  62. package/build/contracts/IMultiSigWallet.json +31 -31
  63. package/build/contracts/IPoolAdminNFT.json +7 -7
  64. package/build/contracts/IPoolMemberNFT.json +7 -7
  65. package/build/contracts/IPureSuperToken.json +62 -62
  66. package/build/contracts/IPureSuperTokenCustom.json +62 -62
  67. package/build/contracts/IRelayRecipient.json +27 -27
  68. package/build/contracts/IResolver.json +38 -38
  69. package/build/contracts/ISETH.json +67 -67
  70. package/build/contracts/ISETHCustom.json +67 -67
  71. package/build/contracts/ISuperAgreement.json +50 -50
  72. package/build/contracts/ISuperApp.json +191 -191
  73. package/build/contracts/ISuperToken.json +695 -695
  74. package/build/contracts/ISuperTokenFactory.json +225 -225
  75. package/build/contracts/ISuperfluid.json +904 -904
  76. package/build/contracts/ISuperfluidGovernance.json +251 -251
  77. package/build/contracts/ISuperfluidToken.json +407 -407
  78. package/build/contracts/ITOGAv1.json +1346 -1346
  79. package/build/contracts/ITOGAv2.json +1346 -1346
  80. package/build/contracts/ITOGAv3.json +1346 -1346
  81. package/build/contracts/Initializable.json +1 -1
  82. package/build/contracts/InstantDistributionAgreementV1.json +594 -594
  83. package/build/contracts/Math.json +1 -1
  84. package/build/contracts/NonClosableOutflowTestApp.json +1526 -1526
  85. package/build/contracts/Ownable.json +1 -1
  86. package/build/contracts/Proxy.json +1 -1
  87. package/build/contracts/ProxyDeployerLibrary.json +2382 -2382
  88. package/build/contracts/PureSuperToken.json +106 -106
  89. package/build/contracts/Resolver.json +98 -98
  90. package/build/contracts/SETHProxy.json +224 -224
  91. package/build/contracts/SafeCast.json +1 -1
  92. package/build/contracts/SafeERC20.json +1 -1
  93. package/build/contracts/SafeGasLibrary.json +51 -51
  94. package/build/contracts/SafeMath.json +1 -1
  95. package/build/contracts/SelfDeletingFlowTestApp.json +1525 -1525
  96. package/build/contracts/SlotsBitmapLibrary.json +457 -457
  97. package/build/contracts/StreamRedirector.json +704 -704
  98. package/build/contracts/Strings.json +1 -1
  99. package/build/contracts/SuperAppBase.json +42 -42
  100. package/build/contracts/SuperAppBaseFlow.json +800 -800
  101. package/build/contracts/SuperAppDefinitions.json +614 -614
  102. package/build/contracts/SuperToken.json +2714 -2714
  103. package/build/contracts/SuperTokenDeployerLibrary.json +2383 -2383
  104. package/build/contracts/SuperTokenFactory.json +1347 -1347
  105. package/build/contracts/SuperTokenFactoryBase.json +1329 -1329
  106. package/build/contracts/SuperTokenV1Library.json +1483 -1483
  107. package/build/contracts/SuperUpgrader.json +439 -439
  108. package/build/contracts/Superfluid.json +5196 -5196
  109. package/build/contracts/SuperfluidCFAv1DeployerLibrary.json +2383 -2383
  110. package/build/contracts/SuperfluidFrameworkDeployer.json +1260 -1260
  111. package/build/contracts/SuperfluidFrameworkDeploymentSteps.json +2382 -2382
  112. package/build/contracts/SuperfluidGovDeployerLibrary.json +2383 -2383
  113. package/build/contracts/SuperfluidGovernanceBase.json +2449 -2449
  114. package/build/contracts/SuperfluidGovernanceConfigs.json +614 -614
  115. package/build/contracts/SuperfluidGovernanceII.json +155 -155
  116. package/build/contracts/SuperfluidGovernanceIIProxy.json +135 -135
  117. package/build/contracts/SuperfluidHostDeployerLibrary.json +2382 -2382
  118. package/build/contracts/SuperfluidIDAv1DeployerLibrary.json +2383 -2383
  119. package/build/contracts/SuperfluidLoader.json +207 -207
  120. package/build/contracts/SuperfluidLoaderDeployerLibrary.json +2384 -2384
  121. package/build/contracts/SuperfluidLoaderLibrary.json +552 -417
  122. package/build/contracts/SuperfluidNFTLogicDeployerLibrary.json +2387 -2387
  123. package/build/contracts/SuperfluidPeripheryDeployerLibrary.json +2385 -2385
  124. package/build/contracts/SuperfluidToken.json +1423 -1423
  125. package/build/contracts/TOGA.json +1360 -1360
  126. package/build/contracts/TestGovernance.json +250 -250
  127. package/build/contracts/TestResolver.json +47 -47
  128. package/build/contracts/TestToken.json +102 -102
  129. package/build/contracts/TokenDeployerLibrary.json +2384 -2384
  130. package/build/contracts/TokenInfo.json +32 -32
  131. package/build/contracts/UUPSProxiable.json +139 -139
  132. package/build/contracts/UUPSProxy.json +81 -81
  133. package/build/contracts/UUPSUtils.json +37 -37
  134. package/build/contracts-sizes.txt +15 -15
  135. package/build/typechain/contracts/apps/SuperAppBaseFlow.d.ts +9 -9
  136. package/build/typechain/contracts/apps/SuperAppBaseFlow.d.ts.map +1 -1
  137. package/build/typechain/contracts/mocks/SuperAppBaseFlowTester.d.ts +9 -9
  138. package/build/typechain/contracts/mocks/SuperAppBaseFlowTester.d.ts.map +1 -1
  139. package/build/typechain/factories/contracts/apps/SuperAppBaseFlow__factory.d.ts +10 -10
  140. package/build/typechain/factories/contracts/apps/SuperAppBaseFlow__factory.js +13 -13
  141. package/build/typechain/factories/contracts/apps/SuperAppBaseFlow__factory.js.map +1 -1
  142. package/build/typechain/factories/contracts/apps/SuperfluidLoaderLibrary__factory.d.ts +1 -1
  143. package/build/typechain/factories/contracts/apps/SuperfluidLoaderLibrary__factory.d.ts.map +1 -1
  144. package/build/typechain/factories/contracts/apps/SuperfluidLoaderLibrary__factory.js +1 -1
  145. package/build/typechain/factories/contracts/apps/SuperfluidLoaderLibrary__factory.js.map +1 -1
  146. package/build/typechain/factories/contracts/mocks/SuperAppBaseFlowTester__factory.d.ts +11 -11
  147. package/build/typechain/factories/contracts/mocks/SuperAppBaseFlowTester__factory.d.ts.map +1 -1
  148. package/build/typechain/factories/contracts/mocks/SuperAppBaseFlowTester__factory.js +14 -14
  149. package/build/typechain/factories/contracts/mocks/SuperAppBaseFlowTester__factory.js.map +1 -1
  150. package/contracts/apps/SuperAppBaseFlow.sol +8 -8
  151. package/contracts/apps/SuperfluidLoaderLibrary.sol +5 -2
  152. package/package.json +5 -5
  153. package/ops-scripts/.eslintrc.js +0 -15
  154. package/ops-scripts/artifacts/ERC1820Registry.json +0 -5
  155. package/ops-scripts/deploy-aux-contracts.js +0 -99
  156. package/ops-scripts/deploy-deterministically.js +0 -169
  157. package/ops-scripts/deploy-erc1820.js +0 -83
  158. package/ops-scripts/deploy-framework.js +0 -895
  159. package/ops-scripts/deploy-mfa.ts +0 -27
  160. package/ops-scripts/deploy-super-token.js +0 -206
  161. package/ops-scripts/deploy-test-environment.js +0 -98
  162. package/ops-scripts/deploy-test-token.js +0 -86
  163. package/ops-scripts/deploy-unlisted-pure-super-token.js +0 -69
  164. package/ops-scripts/deploy-unlisted-super-token.js +0 -68
  165. package/ops-scripts/gov-create-new-app-registration-key.js +0 -75
  166. package/ops-scripts/gov-create-new-factory-registration.js +0 -49
  167. package/ops-scripts/gov-set-3Ps-config.js +0 -67
  168. package/ops-scripts/gov-set-reward-address.js +0 -60
  169. package/ops-scripts/gov-set-token-min-deposit.js +0 -53
  170. package/ops-scripts/gov-set-trusted-forwarder.js +0 -80
  171. package/ops-scripts/gov-transfer-framework-ownership.js +0 -90
  172. package/ops-scripts/gov-upgrade-governance.js +0 -87
  173. package/ops-scripts/gov-upgrade-super-token-logic.js +0 -193
  174. package/ops-scripts/info-inspect-account.js +0 -118
  175. package/ops-scripts/info-list-apps.js +0 -55
  176. package/ops-scripts/info-print-contract-addresses.js +0 -136
  177. package/ops-scripts/info-scan-deployments.js +0 -63
  178. package/ops-scripts/info-show-protocol.js +0 -400
  179. package/ops-scripts/libs/common.js +0 -436
  180. package/ops-scripts/libs/getConfig.js +0 -289
  181. package/ops-scripts/libs/truffleScriptRunnerFactory.js +0 -97
  182. package/ops-scripts/resolver-list-super-token.js +0 -73
  183. package/ops-scripts/resolver-register-token.js +0 -72
  184. package/ops-scripts/resolver-reset-deployment.js +0 -54
  185. package/ops-scripts/resolver-set-key-value.js +0 -69
  186. package/ops-scripts/resolver-unlist-super-token.js +0 -61
  187. package/ops-scripts/tmp-trigger-token-transfer.js +0 -33
  188. package/ops-scripts/validate-nft-addresses.ts +0 -49
@@ -1,61 +0,0 @@
1
- const SuperfluidSDK = require("@superfluid-finance/js-sdk");
2
- const {
3
- getScriptRunnerFactory: S,
4
- ZERO_ADDRESS,
5
- extractWeb3Options,
6
- builtTruffleContractLoader,
7
- setResolver,
8
- } = require("./libs/common");
9
-
10
- /**
11
- * @dev Unlist a previously listed super token in resolver.
12
- * @param {Array} argv Overriding command line arguments
13
- * @param {boolean} options.isTruffle Whether the script is used within native truffle framework
14
- * @param {Web3} options.web3 Injected web3 instance
15
- * @param {Address} options.from Address to deploy contracts from
16
- * @param {string} options.protocolReleaseVersion Specify the protocol release version to be used
17
- *
18
- * Usage: npx truffle exec ops-scripts/resolver-unlist-super-token.js : {SYMBOL}
19
- */
20
- module.exports = eval(`(${S.toString()})()`)(async function (
21
- args,
22
- options = {}
23
- ) {
24
- console.log("======== Unlist a super token ========");
25
- let {protocolReleaseVersion} = options;
26
-
27
- if (args.length !== 1) {
28
- throw new Error("Wrong number of arguments");
29
- }
30
- const superTokenSymbol = args.pop();
31
- console.log("Super Token Symbol", superTokenSymbol);
32
-
33
- console.log("protocol release version:", protocolReleaseVersion);
34
-
35
- const sf = new SuperfluidSDK.Framework({
36
- ...extractWeb3Options(options),
37
- version: protocolReleaseVersion,
38
- additionalContracts: [
39
- "Ownable",
40
- "IMultiSigWallet",
41
- "SuperfluidGovernanceBase",
42
- "SuperToken",
43
- "Resolver",
44
- "IAccessControlEnumerable",
45
- ],
46
- contractLoader: builtTruffleContractLoader,
47
- });
48
- await sf.initialize();
49
-
50
- const superTokenKey = `supertokens.${protocolReleaseVersion}.${superTokenSymbol}`;
51
- console.log("Super token key", superTokenKey);
52
-
53
- const resolver = await sf.contracts.Resolver.at(sf.resolver.address);
54
- const superTokenAddress = await resolver.get.call(superTokenKey);
55
-
56
- if (superTokenAddress === ZERO_ADDRESS) {
57
- throw new Error("Super token is not listed");
58
- }
59
-
60
- await setResolver(sf, superTokenKey, ZERO_ADDRESS);
61
- });
@@ -1,33 +0,0 @@
1
- const {getScriptRunnerFactory: S} = require("./libs/common");
2
-
3
- const SuperToken = artifacts.require("SuperToken");
4
-
5
- /**
6
- * @dev Trigger a token Transfer event in order to have the subgraph index it.
7
- * Also needed for a change of the resolver listing state to take effect.
8
- * TODO: remove once not needed anymore
9
- *
10
- * Usage: npx truffle exec ops-scripts/tmp-trigger-token-transfer.js : {TOKEN_ADDRESS}
11
- */
12
- module.exports = eval(`(${S.toString()})()`)(async function (args) {
13
- console.log("======== Trigger token Transfer ========");
14
-
15
- if (args.length !== 1) {
16
- throw new Error("Wrong number of arguments");
17
- }
18
- const tokenAddr = args.pop();
19
- console.log("Super Token Address", tokenAddr);
20
-
21
- const token = await SuperToken.at(tokenAddr);
22
- const tokenSymbol = await token.symbol();
23
-
24
- console.log("Token Symbol:", tokenSymbol);
25
-
26
- // transfer 0 tokens to some address
27
- const r = await token.transfer(
28
- "0x1111111111111111111111111111111111111111",
29
- 0
30
- );
31
-
32
- console.log("done in", r.tx);
33
- });
@@ -1,49 +0,0 @@
1
- import { ethers } from "hardhat";
2
- import metadata from "@superfluid-finance/metadata";
3
-
4
- async function main() {
5
- const networkId = (await ethers.provider.getNetwork()).chainId;
6
- const RESOLVER_ADDRESS = metadata.getNetworkByChainId(networkId)?.contractsV1.resolver;
7
- const resolver = await ethers.getContractAt("Resolver", RESOLVER_ADDRESS || "");
8
- const hostAddress = await resolver.get("Superfluid.v1");
9
- const hostContract = await ethers.getContractAt("Superfluid", hostAddress);
10
- const superTokenFactoryAddress = await hostContract.getSuperTokenFactory();
11
- const superTokenFactoryContract = await ethers.getContractAt("SuperTokenFactory", superTokenFactoryAddress);
12
- console.log("superTokenFactoryAddress", superTokenFactoryAddress);
13
-
14
- const constantOutflowNFTCanonicalLogic = await superTokenFactoryContract.CONSTANT_OUTFLOW_NFT_LOGIC();
15
- console.log("constantOutflowNFTCanonicalLogic", constantOutflowNFTCanonicalLogic);
16
- const constantInflowNFTCanonicalLogic = await superTokenFactoryContract.CONSTANT_INFLOW_NFT_LOGIC();
17
- console.log("constantInflowNFTCanonicalLogic", constantInflowNFTCanonicalLogic);
18
-
19
- const superTokenFactoryLogicAddress = await hostContract.getSuperTokenFactoryLogic();
20
- console.log("superTokenFactoryLogicAddress", superTokenFactoryLogicAddress);
21
- const superTokenLogicAddress = await superTokenFactoryContract.getSuperTokenLogic();
22
- const superTokenLogicContract = await ethers.getContractAt("SuperToken", superTokenLogicAddress);
23
-
24
- const constantOutflowNFProxy = await superTokenLogicContract.CONSTANT_OUTFLOW_NFT();
25
- const cofNFTContract = await ethers.getContractAt("ConstantOutflowNFT", constantOutflowNFProxy);
26
- console.log("constantOutflowNFProxy", constantOutflowNFProxy);
27
- const outflowProxyLogic = await cofNFTContract.getCodeAddress();
28
- console.log("outflowProxyLogic", outflowProxyLogic);
29
- console.log("cof baseURI", await cofNFTContract.baseURI());
30
-
31
- const constantInflowNFProxy = await superTokenLogicContract.CONSTANT_INFLOW_NFT();
32
- console.log("constantInflowNFProxy", constantInflowNFProxy);
33
- const cifNFTContract = await ethers.getContractAt("ConstantInflowNFT", constantInflowNFProxy);
34
- const inflowProxyLogic = await cifNFTContract.getCodeAddress();
35
- console.log("inflowProxyLogic", inflowProxyLogic);
36
- const differentImplementations = await cofNFTContract.proxiableUUID() !== await cifNFTContract.proxiableUUID();
37
- console.log("nft's have different implementations:", differentImplementations);
38
- console.log("cif baseURI", await cofNFTContract.baseURI());
39
-
40
- if (!differentImplementations) throw new Error("nft's have the same implementation");
41
-
42
- console.log("outflow proxy logic equal canonical logic", outflowProxyLogic === constantOutflowNFTCanonicalLogic);
43
- console.log("inflow proxy logic equal canonical logic", inflowProxyLogic === constantInflowNFTCanonicalLogic);
44
-
45
- if (outflowProxyLogic !== constantOutflowNFTCanonicalLogic) throw new Error("outflow proxy logic not equal canonical logic");
46
- if (inflowProxyLogic !== constantInflowNFTCanonicalLogic) throw new Error("inflow proxy logic not equal canonical logic");
47
- }
48
-
49
- main();