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

Use SDK on dapp-kit #317

Open
wants to merge 18 commits into
base: main
Choose a base branch
from
Open

Use SDK on dapp-kit #317

wants to merge 18 commits into from

Conversation

fabiorigam
Copy link
Member

No description provided.

rodolfopietro97 and others added 3 commits August 19, 2024 11:43
* feat: add core

* feat: new dependencies

* feat: address utils

* feat: certificate

* feat: version 12 of beta

* feat: implement sdk core in certificate-wallet.ts and wallet-manager.ts

* feat: version 12 of sdk core

* 266 use sdk instead of thor devkit (#267)

* feat: working tests

* feat: remove thor-devkit

* fix: e2e tests

* fix: tests

* Refactor inputs (#268)

* fix: refactor inputs

* fix: improve inputs

* Sonar integration (#254)

* Create sonar-scan.yml

* Create sonar-project.properties

* remove test branch from workflow

---------

Co-authored-by: Fabio Rigamonti <73019897+fabiorigam@users.noreply.github.com>

* fix: packages

---------

Co-authored-by: Davide Carpini <carpini.davide@gmail.com>
Co-authored-by: Fabio Rigamonti <73019897+fabiorigam@users.noreply.github.com>
Co-authored-by: WaqarAhmedVC <122815219+WaqarAhmedVC@users.noreply.github.com>
* feat: add core

* feat: new dependencies

* feat: address utils

* feat: certificate

* feat: version 12 of beta

* feat: implement sdk core in certificate-wallet.ts and wallet-manager.ts

* feat: version 12 of sdk core

* 266 use sdk instead of thor devkit (#267)

* feat: working tests

* feat: remove thor-devkit

* fix: e2e tests

* fix: tests

* Refactor inputs (#268)

* fix: refactor inputs

* fix: improve inputs

* Sonar integration (#254)

* Create sonar-scan.yml

* Create sonar-project.properties

* remove test branch from workflow

---------

Co-authored-by: Fabio Rigamonti <73019897+fabiorigam@users.noreply.github.com>

* fix: adapt to main v2

* feat: add sdk network

* fix: remove temporary comment

* fix: node version

---------

Co-authored-by: Davide Carpini <carpini.davide@gmail.com>
Co-authored-by: Fabio Rigamonti <73019897+fabiorigam@users.noreply.github.com>
Co-authored-by: WaqarAhmedVC <122815219+WaqarAhmedVC@users.noreply.github.com>
* feat: initial new SDK implementation

* feat: renaming ConnexWallet

* feat: update core library

* feat: reduce required coverage

* feat: add SDK signer

* feat: add SDK signer for every source

* test: new SDK signer

* feat: update package name in sample-react-app/package.json

* feat: upgrade typescript versions

* feat: update .nvmrc

* Darren/implement new vechain sdk (#310)

* refactor: remove connex and init signer within dappkit

* chore(deps): remove connex

* fix: gha syntax error

* chore(deps): remove connex

* fix: tests

* fix: build errors

* revert: add sync2 back int

* fix: tests

* refactor: yarn, e2e and eslint (#311)

* refactor: yarn, e2e and eslint

* fix(GHA): install before install:all

* fix(GHA): install before install:all

* fix(extension): bug in extension

* fix(extension): bug in extension

* fix: update cucumber

* fix: run stop preview after e2e

* fix: lint errors

* fix: sync errors

* fix: sync2 not connecting

* fix: sync2 txs broken

* fix: tests

* fix: tests

* fix: yarn

* fix: yarn workspaces

* fix: missing declarations in test

* fix: missing declarations in test

* fix: missing declarations in test

* fix: missing declarations in test

* fix: dapp-kit-react tsx

* fix: add exports to package.json

* fix: ignore cucumber in examples

* fix: set type to module

* fix: package.jsons

* fix: add type module

* fix: package.jsons

* fix: package.jsons

* fix: fix angular

* chore: documenation

---------

Co-authored-by: Darren Kelly <107671032+darrenvechain@users.noreply.github.com>
fabiorigam and others added 5 commits December 12, 2024 17:16
* fix: fix conflicts

* fix: solve issues

* fix: solve issues

* fix: solve issues

* fix: fix lint issues

* fix: refactor tests

* fix: refactor tests

* fix: fix failing tests

* fix: fix linter issue

* fix: fix build issue

* fix: fix security issue

* fix: remove duplicate code

* fix: fix failing tests

* fix: fix failing tests

* fix: change sonar properties

* fix: change sonar properties

* fix: change sonar properties
* 266 use sdk instead of thor devkit (#267)

* feat: working tests

* feat: remove thor-devkit

* fix: e2e tests

* fix: tests

* Refactor inputs (#268)

* fix: refactor inputs

* fix: improve inputs

* Sonar integration (#254)

* Create sonar-scan.yml

* Create sonar-project.properties

* remove test branch from workflow

---------

Co-authored-by: Fabio Rigamonti <73019897+fabiorigam@users.noreply.github.com>

* Bump 1.0.13 (#269)

* chore: v1.0.13

* fix: versions

* Update README.md (#273)

* fix: update README.md

* fix: update LICENSE

* Adding signed typed data (#286)

* feat: adding signer typed data with connex

* feat: expose signedTypedData

* feat: revert changes to dappKit Driver

* test: sign typed data

* fix: linting

* refactor: simplify signTypedData method in certificate-wallet and wc-wallet

* build: v1.0.14 (#287)

* fix: strict mode issue (#288)

* chore(deps): bump vite from 5.3.5 to 5.3.6 (#279)

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.3.5 to 5.3.6.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.3.6/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.3.6/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Davide Carpini <carpini.davide@gmail.com>

* chore(deps): bump next in /examples/sample-next-app (#280)

Bumps [next](https://github.com/vercel/next.js) from 14.1.4 to 14.2.10.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](vercel/next.js@v14.1.4...v14.2.10)

---
updated-dependencies:
- dependency-name: next
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Davide Carpini <carpini.davide@gmail.com>

* chore(deps): bump express from 4.19.2 to 4.21.0 (#281)

Bumps [express](https://github.com/expressjs/express) from 4.19.2 to 4.21.0.
- [Release notes](https://github.com/expressjs/express/releases)
- [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md)
- [Commits](expressjs/express@4.19.2...4.21.0)

---
updated-dependencies:
- dependency-name: express
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Davide Carpini <carpini.davide@gmail.com>

* chore(deps-dev): bump vite from 4.5.3 to 4.5.5 (#289)

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 4.5.3 to 4.5.5.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v4.5.5/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v4.5.5/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* chore: version bump 1.0.15 (#290)

* Add vechain domains (#293)

* feat: add vns domains on react

* fix: configs

* fix: vanilla button and modal

* fix: react stuff

* fix: improved tests

* fix: eslint

* fix: package json

* fix: yarn lock

* fix: build

* fix: eslint

* chore(deps): bump http-proxy-middleware from 2.0.6 to 2.0.7 (#294)

Bumps [http-proxy-middleware](https://github.com/chimurai/http-proxy-middleware) from 2.0.6 to 2.0.7.
- [Release notes](https://github.com/chimurai/http-proxy-middleware/releases)
- [Changelog](https://github.com/chimurai/http-proxy-middleware/blob/v2.0.7/CHANGELOG.md)
- [Commits](chimurai/http-proxy-middleware@v2.0.6...v2.0.7)

---
updated-dependencies:
- dependency-name: http-proxy-middleware
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Davide Carpini <carpini.davide@gmail.com>

* feat: allow custom net injection (#257)

Co-authored-by: Fabio Rigamonti <fabio.rigamonti@icloud.com>
Co-authored-by: Davide Carpini <carpini.davide@gmail.com>

* feat: ping wallet connect on focus (#224)

* feat: ping wallet connect on focus

* fix: if statement for ssr

* fix: update yarn.lock

---------

Co-authored-by: Fabio Rigamonti <fabio.rigamonti@icloud.com>
Co-authored-by: Davide Carpini <carpini.davide@gmail.com>

* Chore/v1.0.16 (#295)

* chore: v1.0.16

* chore: v1.0.16

* chore: sdk to beta 32

* fix: angular typescript version

* fix: typescript

* fix: add wallets filter

* chore: review build process

* fix: publish packages script

* fix: publish packages script

* fix: publish packages script

* V1.1.0 (#299)

* chore: review build process

* fix: publish packages script

* fix: publish packages script

* chore(release): v1.1.0

* fix: publish script

* fix: useVechainDomain

* fix: decouple fetch vechain domain

* chore(release): v1.1.1

* fix: prepare packages script (#306)

* chore(deps-dev): bump happy-dom from 14.12.3 to 15.10.2 (#309)

Bumps [happy-dom](https://github.com/capricorn86/happy-dom) from 14.12.3 to 15.10.2.
- [Release notes](https://github.com/capricorn86/happy-dom/releases)
- [Commits](capricorn86/happy-dom@v14.12.3...v15.10.2)

---
updated-dependencies:
- dependency-name: happy-dom
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Fabio Rigamonti <73019897+fabiorigam@users.noreply.github.com>

* chore(deps): bump @eslint/plugin-kit from 0.2.1 to 0.2.3 (#312)

Bumps [@eslint/plugin-kit](https://github.com/eslint/rewrite) from 0.2.1 to 0.2.3.
- [Release notes](https://github.com/eslint/rewrite/releases)
- [Changelog](https://github.com/eslint/rewrite/blob/main/release-please-config.json)
- [Commits](eslint/rewrite@plugin-kit-v0.2.1...plugin-kit-v0.2.3)

---
updated-dependencies:
- dependency-name: "@eslint/plugin-kit"
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Fabio Rigamonti <73019897+fabiorigam@users.noreply.github.com>

* fix: merge conflicts

* fix: fix failing tests

* fix: remove duplicated constants

* fix: remove unused files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Davide Carpini <carpini.davide@gmail.com>
Co-authored-by: WaqarAhmedVC <122815219+WaqarAhmedVC@users.noreply.github.com>
Co-authored-by: Valazan <al-fede@hotmail.it>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Darren Kelly <107671032+darrenvechain@users.noreply.github.com>
Copy link

socket-security bot commented Dec 17, 2024

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@angular-devkit/build-angular@18.2.12 environment, filesystem, network, shell, unsafe Transitive: eval +577 679 MB google-wombot
npm/@angular/animations@18.2.13 None 0 1.73 MB google-wombot
npm/@angular/cli@18.2.12 environment, filesystem, network, shell, unsafe Transitive: eval +145 25.4 MB google-wombot
npm/@angular/common@18.2.13 None 0 11.5 MB google-wombot
npm/@angular/compiler-cli@18.2.13 Transitive: environment, filesystem, network, unsafe +41 46.7 MB google-wombot
npm/@angular/compiler@18.2.13 None 0 9.24 MB google-wombot
npm/@angular/core@18.2.13 None +1 23.2 MB google-wombot
npm/@angular/forms@18.2.13 None 0 1.98 MB google-wombot
npm/@angular/localize@18.2.13 Transitive: environment, filesystem, network, unsafe +41 12 MB google-wombot
npm/@angular/platform-browser-dynamic@18.2.13 None 0 81 kB google-wombot
npm/@angular/platform-browser@18.2.13 None 0 766 kB google-wombot
npm/@angular/router@18.2.13 None 0 2.44 MB google-wombot
npm/@tsconfig/node10@1.0.11 None 0 2.31 kB typescript-deploys
npm/@vechain/sdk-core@2.0.0-beta.1 Transitive: network +8 57.2 MB
npm/@vechain/sdk-network@2.0.0-beta.1 Transitive: network +11 78.5 MB
npm/acorn-walk@8.3.3 None 0 52.6 kB marijn
npm/turbo-darwin-64@2.3.3 None 0 30 MB turbobot
npm/turbo-darwin-arm64@2.3.3 None 0 26.2 MB turbobot
npm/turbo-linux-64@2.3.3 None 0 32.6 MB turbobot
npm/turbo-linux-arm64@2.3.3 None 0 27.6 MB turbobot
npm/turbo-windows-64@2.3.3 None 0 40.2 MB turbobot
npm/turbo-windows-arm64@2.3.3 None 0 40.2 MB turbobot
npm/turbo@2.3.3 None 0 14.9 kB turbobot

🚮 Removed packages: npm/@angular-devkit/build-angular@16.2.16, npm/@angular/animations@16.2.12, npm/@angular/cli@16.2.16, npm/@angular/platform-browser-dynamic@16.2.12, npm/@angular/router@16.2.12, npm/@chakra-ui/react@2.10.4, npm/@chakra-ui/react@2.8.2, npm/@emotion/react@11.14.0, npm/@emotion/styled@11.14.0, npm/@privy-io/react-auth@1.98.4, npm/@vechain/dapp-kit-react-privy@1.3.0, npm/turbo-darwin-64@2.0.9, npm/turbo-darwin-arm64@2.0.9, npm/turbo-linux-64@2.0.9, npm/turbo-linux-arm64@2.0.9, npm/turbo-windows-64@2.0.9, npm/turbo-windows-arm64@2.0.9, npm/turbo@2.0.9, npm/typescript@4.9.5

View full report↗︎

@fabiorigam fabiorigam marked this pull request as ready for review December 17, 2024 09:30

Choose a reason for hiding this comment

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

do we need to commit .yarn ? or it is created when you actually install yarn

Copy link
Contributor

Choose a reason for hiding this comment

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

install-state.gz shoudl be ignored based on yarn docs

this.wallet
.signTx(msg, options)
.then((res) => {
// TODO: we should probably remove these assignment, because the user should be already logged in, and the address should be already defined, test it after e2e with transactions

Choose a reason for hiding this comment

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

maybe worth adding ticket for that ?

this.thor = framework.thor;
this.vendor = framework.vendor;
this.wallet = walletManager;
this.thor = ThorClient.fromUrl(nodeUrl);

Choose a reason for hiding this comment

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

has not in change to client.at ?

options: TransactionOptions = {},
): Promise<TransactionResponse> => {
const s1 = v1.sign('tx');
/*options.signer && s1.signer(options.signer);

Choose a reason for hiding this comment

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

do we need that comment ?

onDisconnected: () => {},
thor: ThorClient.fromUrl('https://testnet.vechain.org'),

Choose a reason for hiding this comment

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

same question as before :)

@@ -43,7 +41,9 @@ describe('createWcSigner', () => {

const res = await signer.connect();

expect(res).toBe(address);
expect(res.account.toLowerCase()).toBe(

Choose a reason for hiding this comment

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

do we always cast them to lowercase ?

);
};

window.vechain = {
newConnexSigner: () => mockedConnexSigner,
newConnexSigner: () => mockedConnexSigner as any,

Choose a reason for hiding this comment

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

is any not to broad ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rebase dappkit main-v2 to the new main
5 participants