Coder Social home page Coder Social logo

wormhole-token-list's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

wormhole-token-list's Issues

tokenMarkets is overly verbose

tokenMarkets[x][y][TOK]['markets'] = ['uniswap'] says: token TOK starting from chain id x, sent to chain id y, will be tradeable on uniswap.

this requires a lot of duplicate information because, for example, the below 4 tokens are UST on Solana, Ethereum, Terra, and BSC, and the below states the fact that UST:

  • when brought to Sol is tradeable on "saber", "mercurial", "jupiter","aldrin", "sunny", "apricot"
  • when brought to Eth is tradeable on curve and uniswap
  • when brought to Terra is tradeable on Anchor
  • when brought to BSC is tradeable on pancakeswap
    and in the current schema we need 12 entries (4*(4-1)) instead of 4:
"tokenMarkets": { // <-- this key is already in the file
    "1": { // source = Sol
      "2": {  // dest = Eth
        "9vMJfxuKxXBoEa7rM12mYLMwTacLMLDJqHozw96WQL8i": {
          "markets":["curve","uniswap"]
        },
      },
      "3": {  // dest = Terra
        "9vMJfxuKxXBoEa7rM12mYLMwTacLMLDJqHozw96WQL8i": {
          "markets": ["anchor"]
        },
      "4": {  // dest = BSC
        "9vMJfxuKxXBoEa7rM12mYLMwTacLMLDJqHozw96WQL8i": {
          "markets": ["pancakeswap"]
        }
      }
    },
    "2": { // source = Eth
      "1": {  // dest = Sol
        "0xa693B19d2931d498c5B318dF961919BB4aee87a5": {
          "markets": ["saber", "mercurial", "jupiter","aldrin", "sunny", "apricot"]
        },
      },
      "3": {
        "0xa693B19d2931d498c5B318dF961919BB4aee87a5": {
          "markets": ["anchor"]
        },
      },
      "4": {  // dest = BSC
        "0xa693B19d2931d498c5B318dF961919BB4aee87a5": {
          "markets": ["pancakeswap"]
        }
      }
    },
    "3": { // source = Terra
      "1": {  // dest = Sol
        "uusd": {
          "markets": ["saber", "mercurial", "jupiter","aldrin", "sunny", "apricot"]
        }
      },
      "2": {  // dest = Eth
        "uusd": {
          "markets": ["curve", "uniswap"]
        }
      },
      "4": {  // dest = BSC
        "uusd": {
          "markets": ["pancakeswap"]
        }
      }
    },
    "4": { // source = BSC
      "1": {  // dest = Sol
        "0x3d4350cD54aeF9f9b2C29435e0fa809957B3F30a": {
          "markets": ["saber", "mercurial", "jupiter","aldrin", "sunny", "apricot"]
        },
      },
      "2": {  // dest = Eth
        "0x3d4350cD54aeF9f9b2C29435e0fa809957B3F30a": {
          "markets": ["curve", "uniswap"]
        },
      },
      "3": {  // dest = Terra
        "0x3d4350cD54aeF9f9b2C29435e0fa809957B3F30a": {
          "markets": ["anchor"]
        },
      "4": {  // dest = BSC
        "0x3d4350cD54aeF9f9b2C29435e0fa809957B3F30a": {
          "markets": ["pancakeswap"]
        }
      }
    }
}

it would be a lot less verbose to just have:

  1. tokens list the native tokens for each chain, and then for each native token, the addresses on all other chains (this part can be autogenerated)
  2. tokenMarkets lists the markets (on every chain) for each native token

for example the above information would be encoded with

"tokens":  {
    "3": {
      "uusd": {
        "symbol": "UST",
        "logo": "https://assets.terra.money/icon/60/UST.png",
        "addresses": {
          "1": "9vMJfxuKxXBoEa7rM12mYLMwTacLMLDJqHozw96WQL8i",
          "2": "0xa693B19d2931d498c5B318dF961919BB4aee87a5",
          "4": "0x3d4350cD54aeF9f9b2C29435e0fa809957B3F30a"
        },
      }
},
"tokenMarkets" {
    "3": {
      "uusd": {
        "1": { 
          "markets": ["saber", "mercurial", "jupiter","aldrin", "sunny", "apricot"]
        },
        "2": { 
          "markets": ["curve", "uniswap"]
        },
        "3": { 
          "markets": ["anchor"]
        },
        "4": { 
          "markets": ["pancakeswap"]
        }
    }
}

Enough is Enough

It would have been so nice if this info was provided to me 2 yrs ago. But now it's to late. Everyone wants me to add crypto and then it disappears. That's it from, I've already lost my house, cars and wife. You guys have screwed up everything because of secrecy, well as far as I'm concerned it just as bad as CZ. I have a half of mind to just post all my private keys on the web. Hell you guys are basically in control of my accounts God knows I'm not. I'm just gonna shut down. This can clog up all it wants. You are nothing but a bunch of Cyber Bullies. I don't know much about how coding works and you guys sures hell don't help worth a shit. All I wanted to do was finally give my family the life they deserved and you guys fucked that up for me and now we get to spend the holidays on the streets. That's if I make it thru this weekend. Keep an eye out because if I decide this is the end, I'll make sure all of you get a very clear live feed. I hope you're happy.

RAY, AURY, ATLAS addresses should be SOL versions

the current schema is a bit confused
for example RAY -> 0x13b6A55662f6591f8B8408Af1C73B017E32eEdB8 (a BSC address) appears in tokens["1"]
https://github.com/certusone/wormhole-token-list/blob/main/src/markets.json#L158

but weUSDC -> A9mUU4qviSctJVPJdBJWkb28deg915LYJKrzQ19ji3FM (a SOL address) also appears in tokens["1"]
https://github.com/certusone/wormhole-token-list/blob/main/src/markets.json#L90

it seems like tokens["1"] should only contain destination Solana addresses, for example RAY's address should be replaced with 4k3Dyjzvzp8eMZWUXbBCjEvwSkkk59S5iCNLY3QrkX6R

it seems like the reason this kinda worked is because the website checks for EITHER the source address OR the dest address in our dict (but this is imprecise and generally leads to confusion).

you can see this here (screenshot from a SOL -> BSC transfer, the addresses below begin with 0x even though they are SOL tokens):
image

Add CI Process to run the generate scripts

A PR submission should not require the submitter install npm or python deps. We can do this for them as part of CI/CD process.

On submission or merge of a PR we should run the scripts to update whatever needs updating.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.