Justin Starry
da7e88fc41
fix: add compute units to jsonrpc parser ( #27554 )
2022-09-01 18:18:43 +00:00
Justin Starry
31087b8aba
Revert "fix: add compute units to jsonrpc parser" ( #27553 )
...
Revert "fix: add compute units to jsonrpc parser (#27466 )"
This reverts commit b34cab46d6
.
2022-09-01 13:30:22 -04:00
Maximilian Schneider
b34cab46d6
fix: add compute units to jsonrpc parser ( #27466 )
...
add compute units to jsonrpc parser
2022-09-01 09:34:10 -07:00
Justin Starry
292b2a1bfe
feat: update `Connection` to support versioned transactions ( #27068 )
...
feat: update Connection to support versioned transactions
2022-08-31 08:46:24 -04:00
Justin Starry
ada493f607
feat: add VersionedMessage.deserializeMessageVersion utility function ( #27415 )
2022-08-29 21:20:16 +01:00
Steven Luscher
60f3dc5f72
fix: replace tweetnacl impl
...
* Install `@noble/ed25519` and create a shim
* Replace `tweetnacl` with `@noble/ed25519` in `Account` class
* Replace `tweetnacl` with `@noble/ed25519` in `Keypair` class
* Replace `tweetnacl` with `@noble/ed25519` in `PublicKey` class
* Replace `tweetnacl` with `@noble/ed25519` in `Ed25519Program` class
* Replace `tweetnacl` with `@noble/ed25519` in `Transaction` class
* Replace `tweetnacl` with `@noble/ed25519` in versioned `Transaction` class
* Remove `tweetnacl` from project
* Damnit, typedoc.
2022-08-28 12:11:34 -07:00
Steven Luscher
713e86e877
Update rollup script to exclude new secp256k1 and hmac/sha256 dependencies ( #27428 )
...
* fix: repair build script, not to bundle @noble libraries but to keep them as external deps
* chore: remove secp256k1 Typescript types
2022-08-26 12:33:29 -07:00
Steven Luscher
1a836ab4af
[web3.js] Replace sha256 and secp256k1 impls ( #27390 )
...
* fix: replace `@ethersproject/sha2` with `@noble/hashes/sha256`
* fix: replace `secp256k1` with `@noble/secp256k1`
2022-08-25 13:34:11 -07:00
Justin Starry
1ccfc65a52
feat: add support for creating version 0 transactions ( #27142 )
...
* feat: add support for version 0 transactions
* chore: feedback
* chore: update VersionedMessage type
* chore: use literals for version getter
* chore: fix lint error
* chore: switch to VersionedMessage.deserialize
2022-08-25 15:42:54 +02:00
Steven Luscher
5975176af7
[web3.js] Eliminate dependency on `URL` class ( #27349 )
...
* fix: `makeWebsocketUrl` no longer depends on the `URL` class
* fix: `Connection` no longer relies on the `URL` class
* fix: remove dependency on `react-native-url-polyfill`
2022-08-24 11:02:40 -07:00
dependabot[bot]
9b157499ef
chore: bump eslint-plugin-mocha from 10.0.4 to 10.1.0 in /web3.js ( #27332 )
...
Bumps [eslint-plugin-mocha](https://github.com/lo1tuma/eslint-plugin-mocha ) from 10.0.4 to 10.1.0.
- [Release notes](https://github.com/lo1tuma/eslint-plugin-mocha/releases )
- [Changelog](https://github.com/lo1tuma/eslint-plugin-mocha/blob/master/CHANGELOG.md )
- [Commits](https://github.com/lo1tuma/eslint-plugin-mocha/compare/10.0.4...10.1.0 )
---
updated-dependencies:
- dependency-name: eslint-plugin-mocha
dependency-type: direct:development
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <[email protected] >
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-23 08:49:27 +00:00
dependabot[bot]
cb847a61ad
chore: bump @commitlint/travis-cli from 17.0.0 to 17.0.3 in /web3.js ( #27331 )
...
Bumps [@commitlint/travis-cli](https://github.com/conventional-changelog/commitlint/tree/HEAD/@commitlint/travis-cli ) from 17.0.0 to 17.0.3.
- [Release notes](https://github.com/conventional-changelog/commitlint/releases )
- [Changelog](https://github.com/conventional-changelog/commitlint/blob/master/@commitlint/travis-cli/CHANGELOG.md )
- [Commits](https://github.com/conventional-changelog/commitlint/commits/v17.0.3/@commitlint/travis-cli )
---
updated-dependencies:
- dependency-name: "@commitlint/travis-cli"
dependency-type: direct:development
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <[email protected] >
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-23 08:42:38 +00:00
dependabot[bot]
3a0fc00827
chore: bump @babel/register from 7.17.7 to 7.18.9 in /web3.js ( #27330 )
...
Bumps [@babel/register](https://github.com/babel/babel/tree/HEAD/packages/babel-register ) from 7.17.7 to 7.18.9.
- [Release notes](https://github.com/babel/babel/releases )
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md )
- [Commits](https://github.com/babel/babel/commits/v7.18.9/packages/babel-register )
---
updated-dependencies:
- dependency-name: "@babel/register"
dependency-type: direct:development
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <[email protected] >
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-23 08:35:00 +00:00
dependabot[bot]
12693e83df
chore: bump @babel/core from 7.18.0 to 7.18.13 in /web3.js ( #27329 )
...
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core ) from 7.18.0 to 7.18.13.
- [Release notes](https://github.com/babel/babel/releases )
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md )
- [Commits](https://github.com/babel/babel/commits/v7.18.13/packages/babel-core )
---
updated-dependencies:
- dependency-name: "@babel/core"
dependency-type: direct:development
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <[email protected] >
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-23 08:24:00 +00:00
Andrew Schonfeld
4b8ab4e65d
VoteProgram.safeWithdraw function to safeguard against accidental vote account closures ( #26586 )
...
feat: safe withdraw function
Co-authored-by: aschonfeld <[email protected] >
2022-08-17 00:22:38 +02:00
dependabot[bot]
e779032e4e
chore: bump @babel/preset-env from 7.18.0 to 7.18.10 in /web3.js ( #27138 )
...
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env ) from 7.18.0 to 7.18.10.
- [Release notes](https://github.com/babel/babel/releases )
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md )
- [Commits](https://github.com/babel/babel/commits/v7.18.10/packages/babel-preset-env )
---
updated-dependencies:
- dependency-name: "@babel/preset-env"
dependency-type: direct:development
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <[email protected] >
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-15 08:14:19 +00:00
Justin Starry
a97346aec7
chore: add constant for pubkey byte length ( #27134 )
2022-08-14 16:19:06 +00:00
Justin Starry
dcef8ec100
feat: add getAddressLookupTable method to Connection ( #27127 )
2022-08-14 10:11:49 +00:00
Justin Starry
8e30dbbbf2
chore: restructure utils code
2022-08-12 17:11:51 +01:00
Justin Starry
52dc24abfb
chore: restructure program files
2022-08-12 17:11:51 +01:00
Justin Starry
1a1a7ce1cf
chore: restucture message files
2022-08-12 17:11:51 +01:00
Justin Starry
7ffcde7330
chore: restructure transaction files
2022-08-12 17:11:51 +01:00
Justin Starry
7e7785fc19
feat: support minContextSlot in getParsedAccountInfo method ( #27084 )
2022-08-11 14:28:54 +00:00
Justin Starry
9ab52e4260
chore: annotate more types as deprecated ( #27067 )
2022-08-10 20:35:30 +00:00
Justin Starry
369b6b1828
feat: handle `loadedAddresses` field in tx meta responses ( #27065 )
...
feat: handle loadedAddresses field in tx meta responses
2022-08-10 20:08:24 +00:00
Steven Luscher
526001557d
chore: update `tweetnacl` dependency to 1.0.3 explicitly ( #26907 )
2022-08-03 10:52:03 -07:00
Steven Luscher
00ce805788
chore: Update web3.js README to ask that contributions and issues regarding web3.js be filed against the monorepo and not the mirror
2022-07-31 21:12:59 -07:00
Steven Luscher
f4100f621f
fix: (web3.js) clear the idle timer whenever the websocket closes ( #26734 )
...
fix: clear the idle timer whenever the websocket closes
2022-07-24 21:56:03 -07:00
Athar Mohammad
ce337e009d
feat(web3.js): add support for get stake minimum delegation ( #26682 )
2022-07-22 01:02:49 -07:00
steveluscher
b9001a947a
fix: add `maxSupportedTransactionVersion` config to remaining `getTransaction` calls
2022-07-22 08:02:28 +00:00
Steven Luscher
c971c61dfb
feat: add `maxSupportedTransactionVersion` option to `getBlock` and `getTransaction` ( #26726 )
2022-07-21 21:02:05 -07:00
dependabot[bot]
91c12d9104
chore: bump terser from 5.12.1 to 5.14.2 in /web3.js ( #26702 )
...
Bumps [terser](https://github.com/terser/terser ) from 5.12.1 to 5.14.2.
- [Release notes](https://github.com/terser/terser/releases )
- [Changelog](https://github.com/terser/terser/blob/master/CHANGELOG.md )
- [Commits](https://github.com/terser/terser/commits )
---
updated-dependencies:
- dependency-name: terser
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-20 17:51:17 +00:00
Antematter
e3c9c58032
feat: added web3 bindings for Address Lookup Table Program instructions ( #26469 )
...
* feat: added web3 bindings for Address Lookup Table Program
* fix: refactoring + addresses PR comments
* fix: typos fixed and minor refactoring
* add lookup table instruction decoding support + fixes recent slot serialization bug
* export lookup table program
* linting
* fix: type annotations
* add tests cases for address lookup table program
* fix: alloc encoding buffer properly for seq layouts
* fix: typedoc issue
Co-authored-by: Antematter <[email protected] >
Co-authored-by: Muhammad Saad <[email protected] >
Co-authored-by: Justin Starry <[email protected] >
2022-07-13 20:19:51 +01:00
Steven Luscher
817402123f
fix: fork `URL` and `fetch` for React Native in web3.js ( #26604 )
2022-07-12 21:41:33 -07:00
Athar Mohammad
d0d3ad7166
Support for returnData in simulate transaction ( #26499 )
...
feat(web3.js): add Support for returnData in simulate transaction
2022-07-12 14:07:17 +02:00
Justin Starry
0de0d4625e
chore: remove web3 examples ( #26515 )
2022-07-08 23:14:38 +01:00
Mike MacCana
6d7a569087
chore: make documentation and examples more prominent in README ( #26498 )
...
* Make documentation and examples more prominent in README
There's a lot more documentation to this library than many users would see looking at the current README
- Make a dedicated 'Documentation and examples' heading
- Bring the Solana Cookbook (which has more examples than all the other documentation listed in the README) to the top
- Mention the examples higher up in the README
* Update web3.js/README.md
* Update web3.js/README.md
2022-07-08 22:00:33 +01:00
steveluscher
627d91fb20
chore: move `checkBlockHeight` into block where it's used
2022-07-02 13:15:50 -07:00
steveluscher
6f6e5172d3
fix: ingest only the relevant properties when constructing `Transactions`
2022-07-02 13:15:50 -07:00
steveluscher
6b82235fab
fix: a much simpler way to prevent getRecentPerformanceSamples from sending a commitment
2022-07-01 22:34:30 -07:00
steveluscher
b1f8baf6ad
test: maybe don't disable all the web3.js tests
2022-07-01 22:31:02 -07:00
steveluscher
e24b64dd71
fix: `getPerformanceSamples` no longer breaks when the connection has a default commitment
2022-07-02 05:29:41 +00:00
Mark Daniel
3fcdc45092
fix: web3.js; maxRetries no longer stripped when zero ( #26345 )
...
Co-authored-by: Mark D <[email protected] >
2022-06-30 23:20:22 -07:00
Steven Luscher
e17ed6b2b9
feat: web3.js RPC errors now hold the error `code` and `data` on the error object ( #26318 )
...
feat: web3.js RPC errors now hold the error code on the error object
2022-06-30 13:08:10 -07:00
Steven Luscher
f57f228126
feat: add `minContextSlot` configuration to (almost) all web3.js methods ( #26296 )
...
* feat: add `minContextSlot` config to `getAccountInfo`
* feat: add `minContextSlot` config to `getBalance`
* feat: add `minContextSlot` config to `getBlockHeight``
* feat: add `minContextSlot` config to `getEpochInfo`
* feat: add `minContextSlot` config to `getInflationReward`
* feat: add `minContextSlot` config to `getLatestBlockhash`
* feat: add `minContextSlot` config to `getMultipleAccounts`
* feat: add `minContextSlot` config to `getProgramAccounts`
* feat: add `minContextSlot` config to `getSignaturesForAddress`
* feat: add `minContextSlot` config to `getSlot`
* feat: add `minContextSlot` config to `getSlotLeader`
* feat: add `minContextSlot` config to `getStakeActivation`
* feat: add `minContextSlot` config to `getTokenAccountsByOwner`
* feat: add `minContextSlot` config to `getTransactionCount`
* feat: add `minContextSlot` config to `sendTransaction`
2022-06-29 09:22:34 -07:00
steveluscher
eb12983785
feat: add custom version HTTP header string to RPC requests
2022-06-29 06:59:44 +00:00
steveluscher
028c3eba8f
test: compile web3.js tests in such a way that you can use es2020+ syntax without crashing Mocha
2022-06-28 11:22:43 -07:00
steveluscher
de5b6a2989
chore: upgrade `rpc-websockets` to eliminate bad `circular-json` dependency
2022-06-28 06:23:26 +00:00
Steven Luscher
a741eddf7d
fix: always use the nonce as the recent blockhash; never overwrite it ( #25829 )
2022-06-26 19:01:54 -07:00
Steven Luscher
19eea3a741
chore: fix types of `RpcRequest` and `RpcBatchRequest` ( #26102 )
2022-06-21 14:48:44 -07:00