Skip to content
This repository was archived by the owner on Mar 5, 2025. It is now read-only.

Commit 6d0bd23

Browse files
Merge branch '4.x' into 6371-uncaught-typeerror-class-extends-value-undefined-is-not-a-constructor-or-null
2 parents 8913307 + 80adabe commit 6d0bd23

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+2019
-681
lines changed

CHANGELOG.md

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2007,7 +2007,6 @@ If there are any bugs, improvements, optimizations or any new feature proposal f
20072007

20082008
#### web3-eth-contract
20092009

2010-
20112010
#### web3-utils
20122011

20132012
- `soliditySha3()` with BigInt support
@@ -2021,6 +2020,7 @@ If there are any bugs, improvements, optimizations or any new feature proposal f
20212020
#### web3-eth
20222021

20232022
- Added to `Web3Config` property `contractDataInputFill` allowing users to have the choice using property `data`, `input` or `both` for contract methods to be sent to the RPC provider when creating contracts. (#6377) (#6400)
2023+
- Added `ALL_EVENTS` and `ALL_EVENTS_ABI` constants, `SendTransactionEventsBase` type, `decodeEventABI` method (#6410)
20242024

20252025
#### web3-eth-contract
20262026

@@ -2081,5 +2081,26 @@ If there are any bugs, improvements, optimizations or any new feature proposal f
20812081

20822082
- Dependencies updated
20832083

2084-
20852084
## [Unreleased]
2085+
2086+
### Added
2087+
2088+
#### web3-eth
2089+
2090+
- Added `ALL_EVENTS` and `ALL_EVENTS_ABI` constants, `SendTransactionEventsBase` type, `decodeEventABI` method (#6410)
2091+
2092+
#### web3-types
2093+
2094+
- Interface `EventLog` was added. (#6410)
2095+
2096+
### Fixed
2097+
2098+
#### web3-eth
2099+
2100+
- Ensure provider.supportsSubscriptions exists before watching by subscription (#6440)
2101+
2102+
### Changed
2103+
2104+
#### web3-eth-contract
2105+
2106+
- The `events` property was added to the `receipt` object (#6410)

docs/docs/guides/web3_plugin_guide/plugin_authors.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ To provide type safety and IntelliSense for your plugin users, please refer to t
1919
At the minimum, your plugin should depend on `web3` package version `4.0.2`. This will allow your plugin class to extend the provided `Web3PluginBase` abstract class. However, `web3` shouldn't be listed as a regular dependency, instead it should be listed in your plugin's `package.json` as a [peer dependency](https://nodejs.org/en/blog/npm/peer-dependencies/).
2020

2121
:::important
22-
If the version `[email protected]`, was not available yet. You can use the version `[email protected]`.
22+
It is important to note that the plugin name should be structured as `@<organization>/web3-plugin-<name>` or `web3-plugin-<name>`.
2323
:::
2424

2525
```json

packages/web3-core/CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,4 +179,8 @@ Documentation:
179179

180180
- Added to `Web3Config` property `contractDataInputFill` allowing users to have the choice using property `data`, `input` or `both` for contract methods to be sent to the RPC provider when creating contracts. (#6377) (#6400)
181181

182-
## [Unreleased]
182+
## [Unreleased]
183+
184+
### Changed
185+
186+
- defaultTransactionType is now type 0x2 instead of 0x0 (#6282)

packages/web3-core/src/types.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ along with web3.js. If not, see <http://www.gnu.org/licenses/>.
1717

1818
import { HexString, Transaction } from 'web3-types';
1919

20-
export type TransactionTypeParser = (transaction: Transaction) => HexString | undefined;
20+
export type TransactionTypeParser = (
21+
transaction: Transaction,
22+
) => HexString | undefined;
2123

2224
export interface Method {
2325
name: string;

packages/web3-core/src/web3_config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ export abstract class Web3Config
8585
defaultHardfork: 'london',
8686
// TODO - Check if there is a default Common
8787
defaultCommon: undefined,
88-
defaultTransactionType: '0x0',
88+
defaultTransactionType: '0x2',
8989
defaultMaxPriorityFeePerGas: toHex(2500000000),
9090
enableExperimentalFeatures: {
9191
useSubscriptionWhenCheckingBlockTimeout: false,

packages/web3-core/test/unit/__snapshots__/web3_context.test.ts.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Object {
1313
"defaultHardfork": "london",
1414
"defaultMaxPriorityFeePerGas": "0x9502f900",
1515
"defaultNetworkId": undefined,
16-
"defaultTransactionType": "0x0",
16+
"defaultTransactionType": "0x2",
1717
"enableExperimentalFeatures": Object {
1818
"useRpcCallSpecification": false,
1919
"useSubscriptionWhenCheckingBlockTimeout": false,

packages/web3-core/test/unit/web3_config.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ const defaultConfig = {
4242
transactionReceiptPollingInterval: undefined,
4343
transactionSendTimeout: 750 * 1000,
4444
transactionConfirmationPollingInterval: undefined,
45-
defaultTransactionType: '0x0',
45+
defaultTransactionType: '0x2',
4646
defaultMaxPriorityFeePerGas: toHex(2500000000),
4747
};
4848
const setValue = {

packages/web3-eth-abi/test/unit/get_encoded_eip712_data.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ describe('getEncodedEip712Data', () => {
2424
});
2525

2626
it.each(erroneousTestData)('%s', (_, typedData, hashEncodedData, expectedError) => {
27-
expect(() => getEncodedEip712Data(typedData, hashEncodedData)).toThrowError(expectedError);
27+
expect(() => getEncodedEip712Data(typedData, hashEncodedData)).toThrow(expectedError);
2828
});
2929
});

packages/web3-eth-contract/CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,4 +308,8 @@ Documentation:
308308
- Added to `Web3Config` property `contractDataInputFill` allowing users to have the choice using property `data`, `input` or `both` for contract methods to be sent to the RPC provider when creating contracts. (#6377)
309309

310310

311-
## [Unreleased]
311+
## [Unreleased]
312+
313+
### Changed
314+
315+
- The `events` property was added to the `receipt` object (#6410)
Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*
1+
/*
22
This file is part of web3.js.
33
44
web3.js is free software: you can redistribute it and/or modify
@@ -14,13 +14,4 @@ GNU Lesser General Public License for more details.
1414
You should have received a copy of the GNU Lesser General Public License
1515
along with web3.js. If not, see <http://www.gnu.org/licenses/>.
1616
*/
17-
18-
import { AbiEventFragment } from 'web3-types';
19-
20-
export const ALL_EVENTS = 'ALLEVENTS';
21-
export const ALL_EVENTS_ABI = {
22-
name: ALL_EVENTS,
23-
signature: '',
24-
type: 'event',
25-
inputs: [],
26-
} as AbiEventFragment & { signature: string };
17+
export { ALL_EVENTS, ALL_EVENTS_ABI } from 'web3-eth';

0 commit comments

Comments
 (0)