Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

eth_estimateGas under-estimating for token xfer #3930

Closed
sammy007 opened this issue Dec 21, 2016 · 11 comments
Closed

eth_estimateGas under-estimating for token xfer #3930

sammy007 opened this issue Dec 21, 2016 · 11 comments
Labels
M4-core ⛓ Core client code / Rust. Z0-unconfirmed 🤔 Issue might be valid, but it’s not yet known.
Milestone

Comments

@sammy007
Copy link

From chat on gitter.

@jacogr
Copy link
Contributor

jacogr commented Dec 21, 2016

UI does use eth_estimateGas. Process is -

  1. Call eth_estimateGas
  2. Adjust by factor of 1.2 (giving slightly better chance of success)
  3. Call using those calculated values

@sammy007
Copy link
Author

I tried to transfer token which requires 100K gas. UI estimated less than 30K. I had --gas-floor-target 500000 setting on a node. So I guess it uses something different. cc @gavofyork

@gavofyork
Copy link
Contributor

@sammy007 could you detail what steps you went through to transfer the token?

@sammy007
Copy link
Author

  1. Set --gas-floor-target 500000
  2. Transfer token
  3. out of gas exception

@tomusdrw tomusdrw added M4-core ⛓ Core client code / Rust. Z0-unconfirmed 🤔 Issue might be valid, but it’s not yet known. labels Jan 3, 2017
@tomusdrw
Copy link
Collaborator

tomusdrw commented Jan 3, 2017

Possibly related to #3749?

@gavofyork gavofyork changed the title Use eth_estimateGas in UI if no explicit gas supplied eth_estimateGas under-estimating for token xfer Jan 6, 2017
@gavofyork
Copy link
Contributor

@tomusdrw / @jacogr any luck in reproducing this?

@gavofyork gavofyork added this to the 1.5 Tenuity milestone Jan 6, 2017
@tomusdrw
Copy link
Collaborator

tomusdrw commented Jan 9, 2017

I wasn't trying to reproduce this exact issue, but could easily reproduce #3749

@gavofyork
Copy link
Contributor

will probably push this to a patch release.

@gavofyork
Copy link
Contributor

this may be fixed by #4100. to help me reproduce, @sammy007 could you be more specific as to the type of token you were transferring and how exactly you transferred it?

@sammy007
Copy link
Author

sammy007 commented Jan 11, 2017

It was ICN token.

@sammy007
Copy link
Author

sammy007 commented Jan 11, 2017

Tried again with 1.4.9.

Scenario 1

  1. Transfer (full balance + advanced sending options)
  2. Don't adjust advanced sending options
  3. Send

result: out of gas failure

Scenario 2

  1. Transfer (full account balance)
  2. Send

result: OK.

It was a first time I used not advanced sending, so perhaps Scenario 1 is by design in parity and I wasted a lot of your time.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
M4-core ⛓ Core client code / Rust. Z0-unconfirmed 🤔 Issue might be valid, but it’s not yet known.
Projects
None yet
Development

No branches or pull requests

4 participants