Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies to threshold-network and keep-network projects #212

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 57 additions & 1 deletion .github/workflows/contracts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,15 @@ jobs:
node-version: "14.x"
cache: "yarn"

# We need this step because the `@keep-network/tbtc` which we install in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Install dependencies
run: yarn install

Expand All @@ -57,6 +66,15 @@ jobs:
node-version: "14.x"
cache: "yarn"

# We need this step because the `@keep-network/tbtc` which we install in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Install dependencies
run: yarn install

Expand All @@ -76,6 +94,15 @@ jobs:
cache: "yarn"
registry-url: "https://registry.npmjs.org"

# We need this step because the `@keep-network/tbtc` which we install in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Install dependencies
run: yarn install --frozen-lockfile

Expand All @@ -87,12 +114,14 @@ jobs:
query: |
keep-core-contracts-version = github.com/keep-network/keep-core/solidity-v1#version
tbtc-contracts-version = github.com/keep-network/tbtc/solidity#version
solidity-contracts-version = github.com/threshold-network/solidity-contracts#version
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
solidity-contracts-version = github.com/threshold-network/solidity-contracts#version
threshold-contracts-version = github.com/threshold-network/solidity-contracts#version


- name: Resolve latest contracts
run: |
yarn upgrade \
@keep-network/keep-core@${{ steps.upstream-builds-query.outputs.keep-core-contracts-version }} \
@keep-network/tbtc@${{ steps.upstream-builds-query.outputs.tbtc-contracts-version }}
@keep-network/tbtc@${{ steps.upstream-builds-query.outputs.tbtc-contracts-version }} \
@threshold-network/solidity-contracts@${{ steps.upstream-builds-query.outputs.solidity-contracts-version }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
@threshold-network/solidity-contracts@${{ steps.upstream-builds-query.outputs.solidity-contracts-version }}
@threshold-network/solidity-contracts@${{ steps.upstream-builds-query.outputs.threshold-contracts-version }}


- name: Configure tenderly
if: github.event.inputs.environment == 'ropsten'
Expand Down Expand Up @@ -156,6 +185,15 @@ jobs:
node-version: "14.x"
cache: "yarn"

# We need this step because the `@keep-network/tbtc` which we install in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Install needed dependencies
run: yarn install --frozen-lockfile

Expand Down Expand Up @@ -186,6 +224,15 @@ jobs:
node-version: "14.x"
cache: "yarn"

# We need this step because the `@keep-network/tbtc` which we install in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Install dependencies
run: yarn install

Expand Down Expand Up @@ -222,6 +269,15 @@ jobs:
SLITHER_VERSION: 0.8.3
run: pip3 install slither-analyzer==$SLITHER_VERSION

# We need this step because the `@keep-network/tbtc` which we install in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Install dependencies
run: yarn install

Expand Down
9 changes: 9 additions & 0 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@ jobs:
node-version: "14"
cache: "yarn"

# We need this step because the `@keep-network/tbtc` which we install in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Install dependencies
run: yarn install

Expand Down
12 changes: 11 additions & 1 deletion .github/workflows/npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,21 @@ jobs:
registry-url: "https://registry.npmjs.org"
cache: "yarn"

# We need this step because the `@keep-network/tbtc` which we update in
# next step has a dependency to `@summa-tx/[email protected]` package, which
# downloads one of its sub-dependencies via unathenticated `git://`
# protocol. That protocol is no longer supported. Thanks to this step
# `https://` is used instead of `git://`.
- name: Configure git to don't use unauthenticated protocol
shell: bash
run: git config --global url."https://".insteadOf git://

- name: Resolve latest contracts
run: |
yarn upgrade \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's pin to exact dependencies versions. (see keep-network/keep-core#3083 for explaination)

Suggested change
yarn upgrade \
yarn upgrade --exact \

@keep-network/keep-core \
@keep-network/tbtc
@keep-network/tbtc \
@threshold-network/solidity-contracts

# Deploy contracts to a local network to generate deployment artifacts that
# are required by dashboard compilation.
Expand Down
13 changes: 13 additions & 0 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,19 @@ yarn build
```
Compiled contracts will land in the `build/` directory.

*NOTE:* The `coverage-pools` package contains an indirect dependency to
`@summa-tx/[email protected]` package, which downloads one of its sub-dependencies
via unathenticated `git://` protocol. That protocol is no longer supported by
GitHub. This means that in certain situations installation of the package or
update of its dependencies using Yarn may result in `The unauthenticated git
protocol on port 9418 is no longer supported` or `fatal: unable to connect to
github.com:` error. +
As a workaround, we advise changing Git configuration to use `https://` protocol
instead of `git://` by executing:
```
git config --global url."https://".insteadOf git://
```

=== Test contracts

There are multiple test scenarios living in the `test` directory.
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@
"prepublishOnly": "./scripts/prepare-artifacts.sh --network $npm_config_network"
},
"dependencies": {
"@keep-network/keep-core": ">1.8.0-dev <1.8.0-pre",
"@keep-network/tbtc": ">1.1.2-dev <1.1.2-pre",
"@keep-network/keep-core": ">1.8.0-dev <1.8.0-goerli",
"@keep-network/tbtc": ">1.1.2-dev <1.1.2-goerli",
Comment on lines +38 to +39
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we use the development tag here as well?

Suggested change
"@keep-network/keep-core": ">1.8.0-dev <1.8.0-goerli",
"@keep-network/tbtc": ">1.1.2-dev <1.1.2-goerli",
"@keep-network/keep-core": "development",
"@keep-network/tbtc": "development",

"@thesis/solidity-contracts": "github:thesis/solidity-contracts#4985bcf",
"@threshold-network/solidity-contracts": ">1.1.0-dev <1.1.0-ropsten",
"@threshold-network/solidity-contracts": "development",
"@openzeppelin/contracts": "^4.3",
"@tenderly/hardhat-tenderly": "^1.0.12"
},
Expand Down
62 changes: 38 additions & 24 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1151,10 +1151,18 @@
"@openzeppelin/upgrades" "^2.7.2"
openzeppelin-solidity "2.4.0"

"@keep-network/keep-core@>1.8.0-dev <1.8.0-pre":
version "1.8.0-dev.1"
resolved "https://registry.yarnpkg.com/@keep-network/keep-core/-/keep-core-1.8.0-dev.1.tgz#1a85bfaef785cf4c8ca34ae961556062c7414d39"
integrity sha512-OOvVxxUYXeBS7qH8zncCHTWqMnByg1/CX5BZ6006v1lWOnBeBS2Wf+n6HnTer5sSkDt6FI0Q2jhJTjh37I570g==
"@keep-network/keep-core@>1.8.0-dev <1.8.0-goerli":
version "1.8.0-dev.11"
resolved "https://registry.yarnpkg.com/@keep-network/keep-core/-/keep-core-1.8.0-dev.11.tgz#cf607c6b9f86b545d8110ea4857b2eef5f3de737"
integrity sha512-NWsG0RqsJm+ZTbSUTWXgmJe6tSyNmHVhx7tQO/7d3/A31hEpbeJeC2H8ro7Pj88M6JDHSvor7svn8bL0KlIy1A==
dependencies:
"@openzeppelin/upgrades" "^2.7.2"
openzeppelin-solidity "2.4.0"

"@keep-network/keep-core@>1.8.1-dev <1.8.1-goerli":
version "1.8.1-dev.0"
resolved "https://registry.yarnpkg.com/@keep-network/keep-core/-/keep-core-1.8.1-dev.0.tgz#d95864b25800214de43d8840376a68336cb12055"
integrity sha512-gFXkgN4PYOYCZ14AskL7fZHEFW5mu3BDd+TJKBuKZc1q9CgRMOK+dxpJnSctxmSH1tV+Ln9v9yqlSkfPCoiBHw==
dependencies:
"@openzeppelin/upgrades" "^2.7.2"
openzeppelin-solidity "2.4.0"
Expand All @@ -1169,6 +1177,10 @@
"@openzeppelin/upgrades" "^2.7.2"
openzeppelin-solidity "2.3.0"

"@keep-network/prettier-config-keep@github:keep-network/prettier-config-keep":
version "0.0.1"
resolved "https://codeload.github.com/keep-network/prettier-config-keep/tar.gz/a1a333e7ac49928a0f6ed39421906dd1e46ab0f3"

"@keep-network/prettier-config-keep@github:keep-network/prettier-config-keep#d6ec02e":
version "0.0.1"
resolved "https://codeload.github.com/keep-network/prettier-config-keep/tar.gz/d6ec02e80dd76edfba073ca58ef99aee39002c2c"
Expand All @@ -1180,10 +1192,10 @@
dependencies:
"@openzeppelin/contracts" "^2.4.0"

"@keep-network/tbtc@>1.1.2-dev <1.1.2-pre":
version "1.1.2-dev.0"
resolved "https://registry.yarnpkg.com/@keep-network/tbtc/-/tbtc-1.1.2-dev.0.tgz#52f61f6455406c2d3650d9f14cc3d734fe2addab"
integrity sha512-G/JbDht/IgdX8Ety0i0iUl+kB2J2ofiAmNw+HmN/YUN9BYFhhzQqltPtYjS/krBkWzBYmNJmZBFeX/h+q4EJvA==
"@keep-network/tbtc@>1.1.2-dev <1.1.2-goerli":
version "1.1.2-dev.1"
resolved "https://registry.yarnpkg.com/@keep-network/tbtc/-/tbtc-1.1.2-dev.1.tgz#dd1e734c0fed50474c74d7170c8749127231d1f9"
integrity sha512-IRa0j1D7JBG8UpduaFxkaq2Ii6F61HhNMUBmxr7kAIZwj/yx8sYXWi921mn0L2Z+hAYNcwEUVhCM91VKQH29pQ==
dependencies:
"@celo/contractkit" "^1.0.2"
"@keep-network/keep-ecdsa" ">1.9.0-dev <1.9.0-ropsten"
Expand Down Expand Up @@ -1286,10 +1298,10 @@
"@types/sinon-chai" "^3.2.3"
"@types/web3" "1.0.19"

"@openzeppelin/contracts-upgradeable@^4.4":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@openzeppelin/contracts-upgradeable/-/contracts-upgradeable-4.4.2.tgz#748a5986a02548ef541cabc2ce8c67a890044c40"
integrity sha512-bavxs18L47EmcdnL9I6DzsVSUJO+0/zD6zH7/6qG7QRBugvR3VNVZR+nMvuZlCNwuTTnCa3apR00PYzYr/efAw==
"@openzeppelin/contracts-upgradeable@~4.5.2":
version "4.5.2"
resolved "https://registry.yarnpkg.com/@openzeppelin/contracts-upgradeable/-/contracts-upgradeable-4.5.2.tgz#90d9e47bacfd8693bfad0ac8a394645575528d05"
integrity sha512-xgWZYaPlrEOQo3cBj97Ufiuv79SPd8Brh4GcFYhPgb6WvAq4ppz8dWKL6h+jLAK01rUqMRp/TS9AdXgAeNvCLA==

"@openzeppelin/contracts@^2.4.0":
version "2.5.1"
Expand All @@ -1306,10 +1318,10 @@
resolved "https://registry.yarnpkg.com/@openzeppelin/contracts/-/contracts-4.3.2.tgz#ff80affd6d352dbe1bbc5b4e1833c41afd6283b6"
integrity sha512-AybF1cesONZStg5kWf6ao9OlqTZuPqddvprc0ky7lrUVOjXeKpmQ2Y9FK+6ygxasb+4aic4O5pneFBfwVsRRRg==

"@openzeppelin/contracts@^4.4":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@openzeppelin/contracts/-/contracts-4.4.2.tgz#4e889c9c66e736f7de189a53f8ba5b8d789425c2"
integrity sha512-NyJV7sJgoGYqbtNUWgzzOGW4T6rR19FmX1IJgXGdapGPWsuMelGJn9h03nos0iqfforCbCB0iYIR0MtIuIFLLw==
"@openzeppelin/contracts@~4.5.0":
version "4.5.0"
resolved "https://registry.yarnpkg.com/@openzeppelin/contracts/-/contracts-4.5.0.tgz#3fd75d57de172b3743cdfc1206883f56430409cc"
integrity sha512-fdkzKPYMjrRiPK6K4y64e6GzULR7R7RwxSigHS8DDp7aWDeoReqsQI+cxHV1UuhAqX69L1lAaWDxenfP+xiqzA==

"@openzeppelin/upgrades@^2.7.2":
version "2.8.0"
Expand Down Expand Up @@ -1589,13 +1601,14 @@
dependencies:
"@openzeppelin/contracts" "^4.1.0"

"@threshold-network/solidity-contracts@>1.1.0-dev <1.1.0-ropsten":
version "1.1.0-dev.1"
resolved "https://registry.yarnpkg.com/@threshold-network/solidity-contracts/-/solidity-contracts-1.1.0-dev.1.tgz#c6c662aa5479592b8899a7b703745da7563a925e"
integrity sha512-2Qxho8mExTihE1UCXSIs5He4WBD0UumUa66ze6/in9l/UZW9ZTXcGI5hQssa3WkHps+74DUykFcRFYrKC4w1DA==
"@threshold-network/solidity-contracts@development":
version "1.2.0-dev.18"
resolved "https://registry.yarnpkg.com/@threshold-network/solidity-contracts/-/solidity-contracts-1.2.0-dev.18.tgz#814721dea03e47c3fe2f21644802e99d49dd9260"
integrity sha512-ao6Kngc8Q9rPg42/DlSlsOi2k/GH0DfdAOB4fmzcQSBl4H4D+dP0k0ymqvK6zfeMgxYmjRYP2KI5kDLPpaF2jg==
dependencies:
"@keep-network/keep-core" ">1.8.0-dev <1.8.0-pre"
"@openzeppelin/contracts" "^4.4"
"@keep-network/keep-core" ">1.8.1-dev <1.8.1-goerli"
"@openzeppelin/contracts" "~4.5.0"
"@openzeppelin/contracts-upgradeable" "~4.5.2"
"@thesis/solidity-contracts" "github:thesis/solidity-contracts#4985bcf"

"@truffle/error@^0.0.14":
Expand Down Expand Up @@ -4494,12 +4507,13 @@ eslint-config-google@^0.13.0:
version "0.3.0"
resolved "https://codeload.github.com/keep-network/eslint-config-keep/tar.gz/0c27ade54e725f980e971c3d91ea88bab76b2330"
dependencies:
"@keep-network/prettier-config-keep" "github:keep-network/prettier-config-keep"
eslint-config-google "^0.13.0"
eslint-config-prettier "^6.10.0"
eslint-config-prettier "^6.15.0"
eslint-plugin-no-only-tests "^2.3.1"
eslint-plugin-prettier "^3.1.2"

eslint-config-prettier@^6.10.0:
eslint-config-prettier@^6.15.0:
version "6.15.0"
resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-6.15.0.tgz#7f93f6cb7d45a92f1537a70ecc06366e1ac6fed9"
integrity sha512-a1+kOYLR8wMGustcgAjdydMsQ2A/2ipRPwRKUmfYaSxc9ZPcrku080Ctl6zrZzZNs/U82MjSv+qKREkoq3bJaw==
Expand Down