Skip to content
This repository has been archived by the owner on Jan 15, 2021. It is now read-only.

xDAI Config changes #1429

Merged
merged 14 commits into from
Sep 22, 2020
Merged

xDAI Config changes #1429

merged 14 commits into from
Sep 22, 2020

Conversation

anxolin
Copy link
Contributor

@anxolin anxolin commented Sep 21, 2020

Part of #1398

First of several xDAI PRs. The xDAI integration is not finished, see #1398 for more pending tasks

This one includes:

  • test tokens
  • Placeholder for price estimate in mainnet/dev
  • the graph API
  • inception block in xDAI for contract
  • remove unneded utils (duplicated from dex-js)
  • Add WETH for xDAI contract

Depend on gnosis/dex-js#184

@anxolin anxolin mentioned this pull request Sep 21, 2020
29 tasks
@ghost
Copy link

ghost commented Sep 21, 2020

Travis automatic deployment:

Copy link
Contributor

@alfetopito alfetopito left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Copy link
Contributor

@Velenir Velenir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are still some places where Network xDai isn't detected. I'm assuming the problem will sort itself out with a new dex-js version?

pr1429--dexreact review gnosisdev com_storybook__path=_story_orderbook-real-data--usdc-dai

config-default.yaml Show resolved Hide resolved
Comment on lines +8 to +9
// TODO: Pending review what makes sense here. How do gas prices are stablished in xDAI network
100: undefined,
Copy link
Contributor

@Velenir Velenir Sep 22, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does web3.eth.getGasPrice() return? Is it a variable number over time?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll find out soon enough, I'm making a PR only for the gas, see #1398

@@ -1,7 +1,7 @@
import BN from 'bn.js'
import { assert } from '@gnosis.pm/dex-js'
import { assert, toBN } from '@gnosis.pm/dex-js'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Importing toBN from dex-js is ok here because it ultimately comes from web3 which is a peer dep for dex-js and therefore local web3 is used. But I would be wary of just importing any utility function because of potential version conflictsor duplicating deps.

For example if we ever need a function that makes use of bignumber.js and import it by the way of dex-js, it would be good to move bignumber.js to peer deps too.

@anxolin anxolin merged commit f11b75c into xdai Sep 22, 2020
@anxolin anxolin mentioned this pull request Sep 22, 2020
This was referenced Oct 5, 2020
@W3stside W3stside mentioned this pull request Oct 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants