From 44a6fe73109f2187b1a1eaaf125712ed7c28ec43 Mon Sep 17 00:00:00 2001 From: Xianny <8582774+xianny@users.noreply.github.com> Date: Wed, 5 Jun 2019 16:59:15 -0700 Subject: [PATCH] Note on updating contract artifacts (#1853) --- contracts/README.md | 4 ++++ packages/migrations/README.md | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/contracts/README.md b/contracts/README.md index da9db02432..53194f3368 100644 --- a/contracts/README.md +++ b/contracts/README.md @@ -10,3 +10,7 @@ | Forwarder | [`@0x/contracts-exchange-forwarder`](/contracts/exchange-forwarder) | [v1.0.1](https://www.npmjs.com/package/@0x/contracts-exchange-forwarder/v/1.0.1) | [@0x/contracts-exchange-forwarder@1.0.1](https://github.com/0xProject/0x-monorepo/releases/tag/@0x/contracts-exchange-forwarder@1.0.1) | | MultiAssetProxy | [`@0x/contracts-asset-proxy`](/contracts/asset-proxy) | [v1.0.1](https://www.npmjs.com/package/@0x/contracts-asset-proxy/v/1.0.1) | [@0x/contracts-asset-proxy@1.0.1](https://github.com/0xProject/0x-monorepo/releases/tag/@0x/contracts-asset-proxy@1.0.1) | | ZRXToken | [`@0x/contracts-erc20`](/contracts/erc20) | [v1.0.1](https://www.npmjs.com/package/@0x/contracts-erc20/v/1.0.1) | [@0x/contracts-erc20@1.0.1](https://github.com/0xProject/0x-monorepo/releases/tag/@0x/contracts-erc20@1.0.1) | + +#### Development + +Building solidity files will update the contract artifact in `{package-name}/generated-artifacts/{contract}.json`, but does not automatically update the `abi-gen-wrappers` package, which are generated from the artifact JSON. To ensure consistency, clean and rebuild `abi-gen-wrappers` after any changes to the artifact JSON. diff --git a/packages/migrations/README.md b/packages/migrations/README.md index 1e8b92bf8d..c2f4f5e35b 100644 --- a/packages/migrations/README.md +++ b/packages/migrations/README.md @@ -98,3 +98,7 @@ In the event you need a specific version of the published Ganache snapshot run t ```bash docker run -e VERSION=2.2.2 -p 8545:8545 -ti 0xorg/ganache-cli:latest ``` + +#### Production + +If deploying contract changes to mainnet, `@0x/contract-artifacts` should also be updated and published. The artifacts must be copied from each `contracts/{package-name}/generated-artifacts/{contract}.json`.