invalid bytes32 value #2256
Description
Expected behavior
contract.deploy({
... data: bytecode,
... arguments: [stringArray.map(name => web3.utils.asciiToHex(name))]
... }).send({args ...})
should deploy the contract where argument to contract is an array of bytes32.
There is no issue with web3 1.0.0-beta.37, it happens with beta.41
Actual behavior
The deploy fails with Error: invalid bytes32 value (arg="candidateName", coderType="bytes32", value="0x52616d61", version=4.0.23)
Error Logs
(node:46067) UnhandledPromiseRejectionWarning: Error: invalid bytes32 value (arg="candidateNames", coderType="bytes32", value="0x52616d61", version=4.0.23)
at Object.throwError (node_modules/ethers/errors.js:76:17)
at CoderFixedBytes.encode (/node_modules/ethers/utils/abi-coder.js:473:20)
at /node_modules/ethers/utils/abi-coder.js:645:59
at Array.forEach ()
at pack (/node_modules/ethers/utils/abi-coder.js:644:12)
at CoderArray.encode (/node_modules/ethers/utils/abi-coder.js:744:40)
at /node_modules/ethers/utils/abi-coder.js:645:59
Versions
NodeJS 11.5.0
Web3js 1.0.0-beta.41