GithubHelp home page GithubHelp logo

Comments (5)

johnnynanjiang avatar johnnynanjiang commented on August 21, 2024 1

There was another compilation error, it got fixed as per the advice from @aaryan_ars in Telegram at https://t.me/c/2038294753/6/264

attribute nonce is required in type AuthCallbackParams. Replace line no 39 with this line:
const authsig = await authBrowser.checkAndSignAuthMessage({ chain: "ethereum", nonce: client.getLatestBlockhash() });
Please refer our docs - https://developer.litprotocol.com/v3/sdk/authentication/auth-sig#obtaining-an-authsig-in-the-browser

from js-sdk.

Ansonhkg avatar Ansonhkg commented on August 21, 2024 1

Hey @johnnynanjiang can you try the latest commit we just published 3.2.0

You might need to change the code here but we will patch this for the next release, here's how you can change it
https://github.com/LIT-Protocol/js-sdk/pull/379/files
image

from js-sdk.

Ansonhkg avatar Ansonhkg commented on August 21, 2024 1

❌ Empty directories found! Do you want to remove then?

packages/lit-third-party-libs

Hey @johnnynanjiang it says it on here:

❌ Empty directories found! Do you want to remove then?

    packages/lit-third-party-libs

This directory no longer exists in 3.2.0 so you will need to manually delete it (assuming you are checking out from 3.1.x version)

from js-sdk.

Aaryan-R-S avatar Aaryan-R-S commented on August 21, 2024

Hey @johnnynanjiang! We are looking into it and will get back to you shortly!

from js-sdk.

johnnynanjiang avatar johnnynanjiang commented on August 21, 2024

Hi @Ansonhkg , I'm getting errors with yarn build and yarn nx run react:serve on branch feature/lit-2546-js-sdk-fix-react-app-requires-latest-blockhash

Nans-MacBook-Pro-14:js-sdk nanjiang$ yarn build
yarn run v1.22.19
$ yarn build:packages
$ yarn gen:internal-dev && yarn update:contracts && yarn tools check --no-empty-directories=true && yarn tools fixTsConfig && yarn reset && yarn tools --build --packages && yarn tools --postBuild && yarn tools --setup-local-dev && yarn postBuild:mapDepsToDist && yarn prettier && yarn gen:readme && yarn build:verify
$ node ./tools/scripts/gen-internal-dev.mjs
✅ networks [
  'https://167.114.17.205:443',
  'https://64.131.85.108:443',
  'https://199.115.117.113:443',
  'https://199.115.117.115:443',
  'https://108.62.0.105:443',
  'https://64.131.85.106:443',
  'https://167.114.17.201:443',
  'https://167.114.17.204:443'
]
$ yarn gen:contracts --update --outdir ./packages/contracts-sdk/src/abis
$ node node_modules/@getlit/contracts --update --outdir ./packages/contracts-sdk/src/abis
✅ We have the latest version of the contract StakingBalances (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract Staking         (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract Multisender     (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract LITToken        (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract PubkeyRouter    (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract PKPNFT          (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract RateLimitNFT    (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract PKPHelper       (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract PKPPermissions  (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract PKPNFTMetadata  (11/15/2023 2:45:41 AM)
✅ We have the latest version of the contract Allowlist       (11/15/2023 2:45:41 AM)
------------------
✅ Done!
$ yarn node ./tools/scripts/tools.mjs check --no-empty-directories=true

❌ Empty directories found! Do you want to remove then?

    packages/lit-third-party-libs

error Command failed.
Exit code: 1
Command: /Users/nanjiang/.nvm/versions/node/v18.19.0/bin/node
Arguments: ./tools/scripts/tools.mjs check --no-empty-directories=true
Directory: Lit Protocol/js-sdk
Output:

info Visit https://yarnpkg.com/en/docs/cli/node for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Nans-MacBook-Pro-14:js-sdk nanjiang$ 
Nans-MacBook-Pro-14:js-sdk nanjiang$ 
Nans-MacBook-Pro-14:js-sdk nanjiang$ yarn nx run react:serve
yarn run v1.22.19
$ 'Lit Protocol/js-sdk/node_modules/.bin/nx' run react:serve

> nx run react:serve

<i> [webpack-dev-server] Project is running at:
<i> [webpack-dev-server] Loopback: http://localhost:4003/, http://[::1]:4003/
<i> [webpack-dev-server] 404s will fallback to '/index.html'

>  NX  Web Development Server is listening at http://localhost:4003/

Entrypoint main = runtime.js vendor.js main.js 3 auxiliary assets
Entrypoint polyfills = runtime.js polyfills.js 2 auxiliary assets
Entrypoint styles = runtime.js styles.css styles.js 2 auxiliary assets
chunk (runtime: runtime) main.js (main) 1.33 MiB [initial] [rendered]
chunk (runtime: runtime) node_modules_lit-protocol_accs-schemas_esm_schemas_LPACC_ATOM_json.js 693 bytes [rendered]
chunk (runtime: runtime) node_modules_lit-protocol_accs-schemas_esm_schemas_LPACC_EVM_BASIC_json.js 1.41 KiB [rendered]
chunk (runtime: runtime) node_modules_lit-protocol_accs-schemas_esm_schemas_LPACC_EVM_CONTRACT_json.js 1.91 KiB [rendered]
chunk (runtime: runtime) node_modules_lit-protocol_accs-schemas_esm_schemas_LPACC_SOL_json.js 924 bytes [rendered]
chunk (runtime: runtime) polyfills.js (polyfills) 508 KiB [initial] [rendered]
chunk (runtime: runtime) runtime.js (runtime) 35.8 KiB [entry] [rendered]
chunk (runtime: runtime) styles.css, styles.js (styles) 188 KiB (javascript) 3.17 KiB (css/mini-extract) [initial] [rendered]
chunk (runtime: runtime) vendor.js (vendor) (id hint: vendor) 7.4 MiB [initial] [rendered] split chunk (cache group: vendor) (name: vendor)
chunk (runtime: runtime) vendors-node_modules_walletconnect_modal-ui_dist_index_js.js (id hint: vendors) 345 KiB [rendered] reused as split chunk (cache group: defaultVendors)
chunk (runtime: runtime) vendors-node_modules_walletconnect_modal_dist_index_js.js (id hint: vendors) 21.4 KiB [rendered] reused as split chunk (cache group: defaultVendors)

WARNING in ../../packages/contracts-sdk/src/lib/contracts-sdk.ts 43:8-35
Module not found: Error: Package path ./cid is not exported from package Lit Protocol/js-sdk/node_modules/multiformats (see exports field in Lit Protocol/js-sdk/node_modules/multiformats/package.json)

ERROR in ./src/app/app.tsx 4:0-92
Module not found: Error: Can't resolve 'dist/packages/access-control-conditions' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 5:0-67
Module not found: Error: Can't resolve 'dist/packages/auth-browser' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 6:0-67
Module not found: Error: Can't resolve 'dist/packages/auth-helpers' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 7:0-62
Module not found: Error: Can't resolve 'dist/packages/constants' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 8:0-69
Module not found: Error: Can't resolve 'dist/packages/contracts-sdk' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 9:0-52
Module not found: Error: Can't resolve 'dist/packages/core' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 10:0-56
Module not found: Error: Can't resolve 'dist/packages/crypto' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 11:0-61
Module not found: Error: Can't resolve 'dist/packages/ecdsa-sdk' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 12:0-64
Module not found: Error: Can't resolve 'dist/packages/encryption' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 13:0-72
Module not found: Error: Can't resolve 'dist/packages/lit-auth-client' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 14:0-72
Module not found: Error: Can't resolve 'dist/packages/lit-node-client' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 15:0-85
Module not found: Error: Can't resolve 'dist/packages/lit-node-client-nodejs' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 16:0-56
Module not found: Error: Can't resolve 'dist/packages/logger' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 17:0-52
Module not found: Error: Can't resolve 'dist/packages/misc' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 18:0-67
Module not found: Error: Can't resolve 'dist/packages/misc-browser' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 19:0-52
Module not found: Error: Can't resolve 'dist/packages/nacl' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 20:0-59
Module not found: Error: Can't resolve 'dist/packages/pkp-base' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 21:0-63
Module not found: Error: Can't resolve 'dist/packages/pkp-client' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 22:0-63
Module not found: Error: Can't resolve 'dist/packages/pkp-cosmos' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 23:0-63
Module not found: Error: Can't resolve 'dist/packages/pkp-ethers' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 24:0-57
Module not found: Error: Can't resolve 'dist/packages/pkp-sui' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 25:0-77
Module not found: Error: Can't resolve 'dist/packages/pkp-walletconnect' in 'Lit Protocol/js-sdk/apps/react/src/app'

ERROR in ./src/app/app.tsx 26:0-66
Module not found: Error: Can't resolve 'dist/packages/uint8arrays' in 'Lit Protocol/js-sdk/apps/react/src/app'

webpack compiled with 23 errors and 1 warning (aebae069476a4d64)
No errors found.

from js-sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.