Skip to content

Commit

Permalink
Merge f41ccee into 3684fc3
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanio committed Apr 13, 2020
2 parents 3684fc3 + f41ccee commit 97c7e2e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,10 @@ Released with 1.0.0-beta.37 code base.
- Removed old bower and meteor artifacts
- Moved logo assets to own folder
- Moved github assets to own folder
- *Please note*: Geth [v1.9.12](https://github.com/ethereum/go-ethereum/releases/tag/v1.9.12) contains a breaking change for `eth_call` that will not default to your first account anymore if `from` is not set. If a sender is not explicitly defined, the `eth_call` will be executed from `address(0)`. (#3467)
- This was done to avoid the same input behaving differently in different environments. You should never do `eth_call` without explicitly setting a sender.
- This means that if you're calling `view` methods that refer to a `msg.sender` without explicitly setting a `from` address in your request options, you may see unexpected behavior.
- In `web3.js`, the `from` address can be specified on a per-call basis or by setting the `defaultAccount` property.

### Fixed

Expand Down
4 changes: 2 additions & 2 deletions docs/web3-eth-contract.rst
Original file line number Diff line number Diff line change
Expand Up @@ -745,14 +745,14 @@ methods.myMethod.call
myContract.methods.myMethod([param1[, param2[, ...]]]).call(options[, callback])
Will call a "constant" method and execute its smart contract method in the EVM without sending any transaction. Note calling can not alter the smart contract state.
Will call a "constant" method and execute its smart contract method in the EVM without sending any transaction. Note calling cannot alter the smart contract state.

----------
Parameters
----------

1. ``options`` - ``Object`` (optional): The options used for calling.
* ``from`` - ``String`` (optional): The address the call "transaction" should be made from.
* ``from`` - ``String`` (optional): The address the call "transaction" should be made from. For calls the ``from`` property is optional however it is highly recommended to explicitly set it or it may default to `address(0)` depending on your node or provider.
* ``gasPrice`` - ``String`` (optional): The gas price in wei to use for this call "transaction".
* ``gas`` - ``Number`` (optional): The maximum gas provided for this call "transaction" (gas limit).
2. ``callback`` - ``Function`` (optional): This callback will be fired with the result of the smart contract method execution as the second argument, or with an error object as the first argument.
Expand Down
2 changes: 1 addition & 1 deletion docs/web3-eth.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1600,7 +1600,7 @@ Executes a message call transaction, which is directly executed in the VM of the
Parameters
----------

1. ``Object`` - A transaction object see :ref:`web3.eth.sendTransaction <eth-sendtransaction-return>`, with the difference that for calls the ``from`` property is optional as well.
1. ``Object`` - A transaction object, see :ref:`web3.eth.sendTransaction <eth-sendtransaction-return>`. For calls the ``from`` property is optional however it is highly recommended to explicitly set it or it may default to `address(0)` depending on your node or provider.
2. ``Number|String|BN|BigNumber`` - (optional) If you pass this parameter it will not use the default block set with :ref:`web3.eth.defaultBlock <eth-defaultblock>`. Pre-defined block numbers as ``"latest"``, ``"earliest"``, ``"pending"``, and ``"genesis"`` can also be used.
3. ``Function`` - (optional) Optional callback, returns an error object as first parameter and the result as second.

Expand Down

0 comments on commit 97c7e2e

Please sign in to comment.