Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    John Grant
    @johngrantuk
    Hi, quick question - if I used ColonyNetworkClient.getColony.call({ id:i }); how would I then use the address to find the colony token name/symbol?
    Griffin Ichiba Hotchkiss
    @gichiba
    Hey, there is also a getToken.call() which might be helpful there
    it will, however just return the address of the token
    getToken is a colonyClient method, not a colonyNetworkClient method
    @johngrantuk
    Christian Maniewski
    @chmanie
    @sidthekidder 1 domain -> x tasks
    John Grant
    @johngrantuk
    thanks @gichiba. so it seems like we'd need to store the token name/symbol somewhere centrally and reference it to the address
    Griffin Ichiba Hotchkiss
    @gichiba
    @johngrantuk yeah, you could do that, but many tokens also choose to have that available on chain, as in here: https://github.com/OpenZeppelin/openzeppelin-solidity/blob/master/contracts/token/ERC20/DetailedERC20.sol
    But yeah, there's no colonyJS caller to grab a colony's token symbol at the moment
    John Grant
    @johngrantuk
    ok, thanks
    Kevin Lu
    @KevinLiLu
    Are the special reward pot (pot[0]) and working capital pot (pot[1]) restricted to the colony token type? I remember reading that colonies can pay out in ether, CLNY, the colony token, or any whitelisted erc20 token.
    If they can be any of the above, then how can I get the ether pot balance for example? There is a getPotBalance.call({ potId, token }) but what address would I use to get the ether balance?
    Christian Maniewski
    @chmanie
    @KevinLiLu naturally I’d think that you could get the ether balance by using 0x0 for the token address.
    But I’ll double check
    Christian Maniewski
    @chmanie
    Confirmed. We will add it to the docs!
    @gichiba ☝️
    Griffin Ichiba Hotchkiss
    @gichiba
    :thumbsup:
    Christian Maniewski
    @chmanie
    Thanks!
    Dan Coman
    @dancomanlive
    How to link MetaMask to colony starter, and how to add a task?
    Christian Maniewski
    @chmanie
    The hackathonStarter?
    It’s a node.js project, so MetaMask will be tough to integrate (not impossible, though). To use it in a browser you need to transpile the files with something like babel (using webpack for example)
    Christian Maniewski
    @chmanie
    @dancomanlive the task creation is exemplified here: https://github.com/JoinColony/hackathonStarter/blob/master/src/create_task.js
    Kevin Lu
    @KevinLiLu
    I'm a little confused by Domain vs Skill based on the ColonyClient API. I get that domains are specific to a colony while skills are global. Calling ColonyClient.addDomain(parentSkillId) requires a parentSkillId to be given as a parameter, and returns both a skillId and parentSkillId. It seems like a domain is tightly coupled with a skill ? When you create a domain, it also automatically creates a new skill (that is assigned to the domain) that is a child of the parentSkillId you passed in?
    Elena Gesheva
    @elenadimitrova
    @KevinLiLu Behind every domain there is a "local" skill (different to the global skills maintained by the Meta Colony). This local skill is created at the same time as the Domain and is tightly coupled with it, task users ultimately earn reputation in that local skill/domain
    The parentSkillId required in addDomain is the id of the parent local skill for the root domain. Since for now we only allow one level of subdomains (and equally one level of local skills) below the root, that parentSkillId will in fact always be the root local skill for domainId 1
    Joseph Schiarizzi
    @jschiarizzi
    @gichiba I've got a thing going locally and having a hard time touching your Rinkeby deployment with it. I'm pretty confused with your loaders API. As far as I see there isn't any Rinkeby connection in the hackathon starter unless I'm missing it? The blog post said there would be, could I have some help?
    Griffin Ichiba Hotchkiss
    @gichiba
    Hey @jschiarizzi yeah, so it was my mistake to include that component in the post; the hackathonStarter unfortunately wasn't updated. Would it be helpful to schedule a time here in this channel that you can get some solid support and get all your questions answered in one go (rather than the asynchronous help that's been happening the last few days)?
    Kevin Lu
    @KevinLiLu
    Is there a way to get a colony's token name and symbol? I know the current JS API does not support this yet, but would I be able to load the token's address as a Token.sol contract to call the functions (assuming the contract deployed at the token's address is Token.sol?
    Christian Maniewski
    @chmanie
    @KevinLiLu I am adding these functions at this very moment. In the meantime, depending on your environment you can try to load the contract like this:
     const Token = await colonyClient.adapter.getContract({ contractName: ‘Token’ });
    const symbol = await Token.callConstant(‘symbol’, []);
    Christian Maniewski
    @chmanie
    @KevinLiLu we just released version 1.5 of ColonyJS which supports getTokenInfo: https://docs.colony.io/colonyjs/api-tokenclient/#gettokeninfocall
    Kevin Lu
    @KevinLiLu
    @chmanie how do I get a TokenClient object? ColonyClient has getToken which gives the address.
    Christian Maniewski
    @chmanie
    First make sure that you use at least v1.4.1 of ColonyJS
    Then in colonyClient you have a token and an authority property
    which are the respective tokenClients and authorityClients
    @KevinLiLu also to get back to your skillId question, the way you’re doing it is exactly what needs to be done
    Christian Maniewski
    @chmanie
    I will add the instance properties to the docs
    Kevin Lu
    @KevinLiLu
    :thumbsup:

    I tried migrating to @colony/colony-js-contract-loader-network, but now i'm getting this error:

    [0] Error: Cannot find module '../contracts/static/Authority.json'
    [0]     at Function.Module._resolveFilename (module.js:542:15)
    [0]     at Function.Module._load (module.js:472:25)
    [0]     at Module.require (module.js:585:17)
    [0]     at require (internal/module.js:11:18)
    [0]     at /Users/kelu/Colony/ColonyExplorer/metropolis/node_modules/@colony/colony-js-contract-loader-network/src/NetworkLoader.js:24:25
    [0]     at Array.forEach (<anonymous>)
    [0]     at Object.<anonymous> (/Users/kelu/Colony/ColonyExplorer/metropolis/node_modules/@colony/colony-js-contract-loader-network/src/NetworkLoader.js:23:18)
    [0]     at Module._compile (module.js:641:30)
    [0]     at Module._extensions..js (module.js:652:10)
    [0]     at Object.require.extensions.(anonymous function) [as .js] (/Users/kelu/Colony/ColonyExplorer/metropolis/node_modules/babel-register/lib/node.js:152:7)

    I'm using these dependencies:

        "@colony/colony-js-adapter-ethers": "^1.5.0",
        "@colony/colony-js-client": "^1.5.0",
        "@colony/colony-js-contract-loader-network": "^1.0.1",

    Any thoughts?

    Christian Maniewski
    @chmanie
    Oohh
    Yep, just another case of forgetting to build before pushing to npm ;)
    Sorry about that
    Christian Maniewski
    @chmanie
    @KevinLiLu v1.0.2 published. It should work with that
    "@colony/colony-js-contract-loader-network": "^1.0.2”
    Kevin Lu
    @KevinLiLu

    :thumbsup: Let me test it out! One more thing, I looped through each colony and called getToken() on each colony's token property, and most of them are giving me a call exception:

    [0] 0x0795Ef57326355ca6418575FB56C03368F5b8Ac8
    [0] { name: 'Colony Network Token', symbol: 'CLNY', decimals: 18 }
    [0] 0xB73EEbf7204894D7304d1De980bdd04C7ECb3AB3
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x3cCD37D11A7D057733bAd6AaD44597822D51B1B9
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x1217650382EE6a970b7a8B3AAc9295FDb4C75BdC
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x0858759903c0b41969eD45768356De53Ec3F32aa
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x60CA06Bfe36A2DEd283Bd9B57311825022b860a7
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x083d6883213F76D06165C6b2FD5ca2d41DA08a52
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x77BCB961B87e6A0Dc7D0f1D2a265b32dA79827a1
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x239e0ec7FB2A41de5A9a4d4a2BcB28FFAba977Df
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x44DfF5E3E01d9875F2Aa7bD60069A4Ab296e1624
    [0] call exception (address="0x06012c8cf97BEaD5deAe237070F9587f8E7A266d", method="name()", value=[])
    [0] 0x19300A7fdfb2dD949fE7a357Bb6bf6Df8097bE30
    [0] { name: ' ', symbol: ' ', decimals: 18 }

    Is this intended? Do people need to mint their token first or something?

    Christian Maniewski
    @chmanie
    You mean getTokenInfo()?
    Kevin Lu
    @KevinLiLu
    Sorry, yep getTokenInfo()
    Christian Maniewski
    @chmanie
    This is definitely not intentional
    Are these colonies deployed on your local test net?
    Kevin Lu
    @KevinLiLu
    Connected to rinkeby