Warning! Error Encounter during Contract Execution [Reverted]


#1

When trying to purchase our tokens via smart contract the error message below is posted on Etherscan and the transaction fails. I checked the past technical reports and see that this can be caused by a white list function issue but we do not have a white list enabled. Please advise. Thank you.
Warning! Error Encounter during Contract Execution [Reverted]


#2

Hello,

Are all of these statements false, when you are trying to purchase https://github.com/poanetwork/token-wizard/wiki/Token-Wizard-Possible-Tx-Failures#possible-transaction-failures-while-participating-in-crowdsale?


#3

Yes, All are false. I just tried the transaction again about 10 hours later and it failed again - same error message. It processed for about 30 minutes before failing.


#4

Yes, All are false. I just tried the transaction again about 10 hours later and it failed again - same error message. It processed for about 30 minutes before failing.

What is your crowdsale address? And which method are you trying to execute for purchase?


#5

Crowdsale contract: 0x94F892F0E5957B59c668150578A1c1C39314ad91
Method ID: 0xa6f2ae3a
Used MetaMask to send to the contract, included the Method ID in the Hex Data field.
This same processed worked fine in the past with some small amount transfers.


#6

No, this is not a crowdsale contract address. This is a first tier contract address. Your last tier contract is 0x69dfa7e6e282da072b4dd3ca9465d7da14f7f0df. And you should make purchase transaction to it.

Btw, you have not to take care about it, when you purchase in Token Wizard. DApp makes this magic for you, chooses a correct tier contract endpoint for the current time of crowdsale.


#7

I’m not clear. Here is our live crowdsale page showing the crowdsale address as 0x94F892F0E5957B59c668150578A1c1C39314ad91


#8

I’m not clear. Here is our live crowdsale page showing the crowdsale address as 0x94F892F0E5957B59c668150578A1c1C39314ad91

The value from the query string’s addr parameter of the page’s address is displayed in this field. It should be a valid tier’s address. Usually, the address of a first tier is in query string. And addresses of all tiers are in your archive with crowdsale’s metadata, that you’ve got from the publish step of Token Wizard.


#9

My understanding is/was that Token Wizard handles the tier address in background as you mentioned above and the crowdsale contract stays the same for all tiers. Below is the current live Token Wizard Invest screen shot. It has shown the same crowdsale address for all tiers.

This address is listed as our crowdsale address in multiple places, verified etc.
What do we need to do to correct?


#10

What do you want to do? :slight_smile:

If you want to purchase in your crowdsale directly from smart-contracts beyond Token Wizard, call buy method on the address of the current tier. You know the method ID of buy method. The current tier is the last tier, as you can see from the timer. I gave you the address of your last tier. Also, you can check by yourself the address of the last tier with calling getLastTier property. You can call this method on any tier’ contract.


#11

So an example of sending ETH to our crowdsale with MetaMask would be:

  1. Send ETH to 0x69dfa7e6e282da072b4dd3ca9465d7da14f7f0df
  2. MethodID = 0xa6f2ae3a (placed in Hex Data field)
  3. After sending ETH the sender will receive tokens with address 0xD6513C922d9bE2E26992D1FCd544E9BdD9d7b8E6
  4. Optionally, using the token wizard Invest page rather than MetaMask or other wallet for sending ETH, the same final result (item 3 above) will be achieved.
  5. For future reference, the crowdsale address changes with every every tier.
    is this correct?

#12

… Sorry, I forgot to mentioned that our objective is how to instruct token buyers how to purchase our tokens with MetaMask. Is the instruction above correct for doing so?


#13

not to 0x69dfa7e6e282da072b4dd3ca9465d7da14f7f0df

to 0x94F892F0E5957B59c668150578A1c1C39314ad91. This is your current tier.

You should provide the correct current tier address for your users, if you want to support purchasing directly from smart-contracts.


#14

Okay. This is what we are doing. But, the Tx fails.


#15

Oh, sorry… 0x69dfa7e6e282da072b4dd3ca9465d7da14f7f0df - this is your last tier, as I wrote originally. Yes, your guide is correct.


#16

Okay. I understand but I’m concerned this may worry token buyers, since they are sending to a different address than the listed crowdsale contract. How can they verify? Most will not be technically oriented. (We have a big promotion coming up).


#17

You should tell them the correct address for every tier in your promotion. Check the addresses of the ties in your archive with metadata. Also, the list of crowdsale addresses is listed in the property joinedCrowdsales in every tier smart-contract. Otherwise, they can use Token Wizard and contribute with one button.


#18

Okay. I got it. One last question, will the total number of tokens purchased (on all tiers) still show on Etherscan under the crowdsale contract address?


#19

Total amount of tokens, purchased in all tiers will be displayed on token contract address.


#20

Okay. All is working now. We had new token purchases following the info you provided.
Many thanks again for your help.