We have an issue with the library with contract methods that are overriden, when there are multiple methods with the same name and different types, _createContractMethod will map the abi methods so that it will only use the first method type
issue is around here: https://github.com/web3/web3.js/blob/4.x/packages/web3-eth-contract/src/contract.ts#L1065
for example:
[
...,
{
inputs: [{ internalType: 'uint256', name: '_startTime', type: 'uint256' }],
name: 'getPenaltyBP',
outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
stateMutability: 'view',
type: 'function',
},
{
inputs: [{ internalType: 'address', name: '_user', type: 'address' }],
name: 'getPenaltyBP',
outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
stateMutability: 'view',
type: 'function',
},
]
contract.methods.getPenaltyBP("0xaceaEcB820Be3f147FF40d1C221B25F10ee8dd92").call().then(console.log) method should be encoded as an address