# Gas estimation failed - PaymentSplitter Contract

**URL:** <https://forum.openzeppelin.com/t/gas-estimation-failed-paymentsplitter-contract/3664>\
**Category:** Contracts\
**Created:** [August 29, 2020, 4:50pm UTC](https://forum.openzeppelin.com/t/gas-estimation-failed-paymentsplitter-contract/3664 "2020-08-29T16:50:35Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Edgar\_Papa\_Maduna](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/edgar_papa_maduna/32/2925_2.png) [@Edgar\_Papa\_Maduna](https://forum.openzeppelin.com/u/Edgar_Papa_Maduna)\
**Post date:** [August 29, 2020, 4:50pm UTC](https://forum.openzeppelin.com/t/gas-estimation-failed-paymentsplitter-contract/3664/1 "2020-08-29T16:50:35Z")

</div>

I am having problems PaymentSplitter.sol. All is compiling well and deployed as expected. But everytime I release(\_address) on remix (button), is giving me the following error:

```auto
Gas estimation errored with the following message (see below). The transaction execution will likely fail. Do you want to force sending?
Internal JSON-RPC error. { "message": "VM Exception while processing transaction: revert PaymentSplitter: account is not due payment", "code": -32000, "data": { "stack": "c: VM Exception while processing transaction: revert PaymentSplitter: account is not due payment\n at Function.c.fromResults ....

```

I really don’t know what I am doing wrong… the only code I have included in my file is:

```auto
pragma solidity ^0.6.0;

import "https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/payment/PaymentSplitter.sol";

contract MySplit is PaymentSplitter {
    constructor (address[] memory payees, uint256[] memory shares) 
	PaymentSplitter(payees, shares)
	 public payable{}
}

```

I keep on getting gas warnings and function loop warnings on remix everytime I import PaymentSplitter.sol and have no idea what they trying to say.

Your help would be highly appreciated… Thank you

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [August 31, 2020, 8:12am UTC](https://forum.openzeppelin.com/t/gas-estimation-failed-paymentsplitter-contract/3664/2 "2020-08-31T08:12:04Z")

</div>

Hi @Edgar_Papa_Maduna,

Welcome to the community 👋

I wrote a guide that you can use: [Using PaymentSplitter with Remix](https://forum.openzeppelin.com/t/using-paymentsplitter-with-remix/3007)

⚠ For OpenZeppelin Contracts you should only use code published in an official release, when you import from GitHub you should specify a release tag (see the example in the guide).

Let me know if you run into any issues.

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [September 7, 2020, 12:27am UTC](https://forum.openzeppelin.com/t/gas-estimation-failed-paymentsplitter-contract/3664/3 "2020-09-07T00:27:17Z")

</div>

Hi @Edgar_Papa_Maduna,

I wanted to check if you were able to use PaymentSplitter?

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [February 26, 2021, 2:09am UTC](https://forum.openzeppelin.com/t/gas-estimation-failed-paymentsplitter-contract/3664/4 "2021-02-26T02:09:53Z")

</div>

Split this topic on February 26, 2021, 2:09am UTC

A post was split to a new topic: [How much gas is required to deploy token or crowdsale?](https://forum.openzeppelin.com/t/how-much-gas-is-required-to-deploy-token-or-crowdsale/5984)
