-
Notifications
You must be signed in to change notification settings - Fork 266
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove
defender.proposeUpgrade
and dependencies for Defender legacy (…
- Loading branch information
Showing
15 changed files
with
32 additions
and
1,241 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -544,55 +544,6 @@ Similar to `prepareUpgrade`. This method validates and deploys the new implement | |
|
||
* `@openzeppelin/[email protected]` | ||
|
||
[[defender-propose-upgrade]] | ||
== defender.proposeUpgrade | ||
|
||
[source,ts] | ||
---- | ||
async function proposeUpgrade( | ||
proxyAddress: string, | ||
ImplFactory: ContractFactory, | ||
opts?: { | ||
unsafeAllow?: ValidationError[], | ||
unsafeAllowRenames?: boolean, | ||
unsafeSkipStorageCheck?: boolean, | ||
constructorArgs?: unknown[], | ||
timeout?: number, | ||
pollingInterval?: number, | ||
redeployImplementation?: 'always' | 'never' | 'onchange', | ||
kind?: 'uups' | 'transparent' | 'beacon', | ||
title?: string, | ||
description?: string, | ||
multisig?: string, | ||
proxyAdmin?: string, | ||
}, | ||
): Promise<{ | ||
url: string, | ||
txResponse?: ethers.providers.TransactionResponse, | ||
}> | ||
---- | ||
|
||
NOTE: This method requires configuring a Defender Team API Key. | ||
|
||
Proposes an upgrade using https://docs.openzeppelin.com/defender/admin[Defender Admin]. | ||
|
||
Similar to `prepareUpgrade`. This method validates and deploys the new implementation contract, but also creates an upgrade proposal in Defender Admin, for review and approval by the upgrade administrators. Supported for UUPS or Transparent proxies. Not currently supported for beacon proxies or beacons. For beacons, use `prepareUpgrade` along with a custom action in Defender Admin to upgrade the beacon to the deployed implementation. | ||
|
||
*Parameters:* | ||
|
||
* `proxyAddress` - the proxy address. | ||
* `ImplFactory` - the new implementation contract. | ||
* `opts` - an object with options: | ||
** `title`: title of the upgrade proposal as seen in Defender Admin, defaults to `Upgrade to 0x12345678` (using the first 8 digits of the new implementation address) | ||
** `description`: description of the upgrade proposal as seen in Defender Admin, defaults to the full implementation address. | ||
** `multisig`: address of the multisignature wallet contract with the rights to execute the upgrade. This is autodetected in https://docs.openzeppelin.com/contracts/api/proxy#TransparentUpgradeableProxy[Transparent proxies], but required for https://docs.openzeppelin.com/contracts/api/proxy#UUPSUpgradeable[UUPS proxies] (read more https://docs.openzeppelin.com/contracts/api/proxy#transparent-vs-uups[here]). Both Gnosis Safe and Gnosis MultisigWallet multisigs are supported. | ||
** `proxyAdmin`: address of the https://docs.openzeppelin.com/contracts/api/proxy#ProxyAdmin[`ProxyAdmin`] contract that manages the proxy, if exists. This is autodetected in https://docs.openzeppelin.com/contracts/api/proxy#TransparentUpgradeableProxy[Transparent proxies], but required for https://docs.openzeppelin.com/contracts/api/proxy#UUPSUpgradeable[UUPS proxies] (read more https://docs.openzeppelin.com/contracts/api/proxy#transparent-vs-uups[here]), though UUPS proxies typically do not require the usage of a ProxyAdmin. | ||
** additional options as described in <<common-options>>. | ||
|
||
*Returns:* | ||
|
||
* an object with the URL of the Defender proposal, and the ethers transaction response corresponding to the deployment of the new implementation contract. Note that if the new implementation contract was originally imported as a result of `forceImport`, the ethers transaction response will be undefined. | ||
|
||
[[admin-change-proxy-admin]] | ||
== admin.changeProxyAdmin | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
99 changes: 0 additions & 99 deletions
99
packages/plugin-hardhat/src/defender-v1/propose-upgrade.ts
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
101 changes: 0 additions & 101 deletions
101
packages/plugin-hardhat/src/defender-v1/verify-deployment.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.