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

Fix/UI noble hashes #23

Open
wants to merge 4 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
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
e2e: build build
yarn workspace dapp-agoric-orca-contract test; yarn workspace dapp-agoric-orca-contract build; yarn workspace dapp-agoric-orca-contract e2e
e2e: test-orca build build
yarn workspace dapp-agoric-orca-contract e2e
build:
yarn workspace dapp-agoric-orca-contract test; yarn workspace dapp-agoric-orca-contract build;
yarn workspace dapp-agoric-orca-contract build:deployer;
redeploy:
yarn workspace dapp-agoric-orca-contract deployc
test-orca:
Expand Down
4 changes: 2 additions & 2 deletions contract/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ ATOM_DENOM=ibc/BA313C4A19DFBF943586C0387E6B11286F9E416B4DD27574E6909CABE0E342FA
ATOM=000000$(ATOM_DENOM)

# your deployer address made from make add-address
ADDR=agoric1mqvg26gpv6xzch2v0wpv569md3c2z4cdxq9clz
ADDR=agoric1jwuskhnxkjw50vnx3ak8qwmvy8f43sfdxnd438
Copy link
Member

Choose a reason for hiding this comment

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

is this change relevant?

PROVISION_POOL_ADDR=agoric1megzytg65cyrgzs6fvzxgrcqvwwl7ugpt62346

PROPOSAL=1
Expand Down Expand Up @@ -262,7 +262,7 @@ e2e:
kubectl exec -i agoriclocal-genesis-0 -c validator -- bash -c "yarn add @agoric/[email protected]"
kubectl exec -i agoriclocal-genesis-0 -c validator -- bash -c "yarn add @agoric/[email protected]"
kubectl exec -i agoriclocal-genesis-0 -c validator -- bash -c "yarn add @agoric/[email protected]"
make copy-bn-js
# make copy-bn-js
Copy link
Member

Choose a reason for hiding this comment

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

why keep the commented-out code?

kubectl exec -i agoriclocal-genesis-0 -c validator -- bash -c "yarn build:deployer"
kubectl exec -i agoriclocal-genesis-0 -c validator -- bash -c "yarn node scripts/deploy-contract.js --install src/orca.contract.js --eval src/orca.proposal.js"
kubectl exec -i agoriclocal-genesis-0 -c validator -- bash -c "yarn node scripts/deploy-contract.js --install src/orca.contract.js --eval src/orca.proposal.js"
Expand Down
3 changes: 2 additions & 1 deletion contract/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"deploy": "make dev-working",
"test": "ava",
"lint": "tsc && eslint '**/*.js'",
"lint:fix": "eslint --fix '**/*.js'"
"lint:fix": "eslint --fix '**/*.js'",
"e2e": "make e2e"
Copy link
Member

Choose a reason for hiding this comment

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

this looks like a build commit, not a fix

},
"devDependencies": {
"@agoric/deploy-script-support": "dev",
Expand Down
14 changes: 12 additions & 2 deletions ui/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';

// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
resolve: {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this is so the uI can resolve the noble hashes deps that the workspace defines

Copy link
Member

Choose a reason for hiding this comment

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

I don't understand. I can't find any occurrences of @noble/hashes in the ui directory.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

its a sub-dependency from @cosmjs/proto-signing 🫠

✘ [ERROR] Could not resolve "@noble/hashes/sha3"

    ../node_modules/@cosmjs/proto-signing/node_modules/@cosmjs/crypto/build/keccak.js:4:23:
      4 │ const sha3_1 = require("@noble/hashes/sha3");
        ╵                        ~~~~~~~~~~~~~~~~~~~~

  The module "./sha3.js" was not found on the file system:

    ../node_modules/@noble/hashes/package.json:116:17:
      116 │       "require": "./sha3.js"
          ╵                  ~~~~~~~~~~~

First encountered here

alias: {
'@noble/hashes/sha256': '../node_modules/@noble/hashes/src/sha256.ts',
'@noble/hashes/sha3': '../node_modules/@noble/hashes/src/sha3.ts',
'@noble/hashes/ripemd160':
'../node_modules/@noble/hashes/src/ripemd160.ts',
'@noble/hashes/sha512': '../node_modules/@noble/hashes/src/sha512.ts',
'@noble/hashes/pbkdf2': '../node_modules/@noble/hashes/src/pbkdf2.ts',
'@noble/hashes/utils': '../node_modules/@noble/hashes/src/utils.ts',
'@noble/hashes/crypto': '../node_modules/@noble/hashes/src/crypto.ts',
},
},
});
Loading