2

Following the quickstart guidance using Ropsten testnet, I have done the following on a synced geth console:

> loadScript('/my/path/to/ensutils-testnet.js');
> new Date(testRegistrar.expiryTimes(web3.sha3('blipblop.test')).toNumber() * 1000)

<Date Thu, 01 Jan 1970 01:00:00 BST>

> ens.setResolver(namehash('blipblop.test'), publicResolver.address, {from: eth.accounts[0]});

"0x28f01d23b98a7b4fe1bc4324cb70e406714e1c14e64e632708f8ec44cebbde78"

When I look up the transaction on etherscan, it reports a bad jump destination and the name does no resolve:

> getAddr('blipblop.test')

"0x0000000000000000000000000000000000000000"

Am I doing something obviously wrong?

Should there be a delay between setting the resolver and being able to resolve the name?

Related (on main net): ENS setResolver bad jump destination

Lee
  • 8,548
  • 6
  • 46
  • 80
  • 1
    You have not provided full code so it is not clear what you are doing. From what I can see there are errors e.g web3.sha3('blipblop.test') instead of web3.sha3('blipblop') – Thomas Clowes Aug 16 '17 at 12:24
  • @ThomasClowes thanks - I've edited to includ loadscript command. I don't have any further code to add - is there something obvious missing? I've followed the linked guide --> http://docs.ens.domains/en/latest/quickstart.html – Lee Aug 16 '17 at 12:28
  • @ThomasClowes Thanks I've managed to get it working now - I think I had missed the testRegistrar step – Lee Aug 16 '17 at 13:14
  • @atomh33ls this can be tied off neatly, if you write and accept your own answer – carver Aug 16 '17 at 17:07
  • @carver I was a bit hasty above - whilst the contract bad jump error no longer occurs, the getAddr('blipblop.test') still gives "0x0000000000000000000000000000000000000000" – Lee Aug 16 '17 at 20:02
  • After setting the resolver to the public resolver, did you also call resolver.setAddr()? – carver Aug 16 '17 at 20:21
  • @carver thanks, no, have done it now. I still get 0x00... after getAddr however – Lee Aug 16 '17 at 20:40
  • How did you generate the namehash value 0x27d224a842cd4d6f0e5161a3dbe482a65e8848ad4bbc8645faacaf989157b97b? I get namehash: > namehash('blipblop.test') "0x370f76c0ca0ed4644977abd7995b060f3f13dca45a330b2cd9ef9275b009da0b" – carver Aug 16 '17 at 20:50
  • @carver Ah yes I repeated with blipblop2.test ! – Lee Aug 16 '17 at 20:51

1 Answers1

2

Here are the series of steps that worked (after jumping in chat with @atomh33ls).

> loadScript('/my/path/to/ensutils-testnet.js');

> testRegistrar.register(web3.sha3('blipblop'), eth.accounts[0],
                             {from: eth.accounts[0]});
// wait for block inclusion...

> ens.setResolver(namehash('blipblop.test'), publicResolver.address,
                             {from: eth.accounts[0]});

> publicResolver.setAddr(namehash('blipblop.test'), publicResolver.address,
                             {from: eth.accounts[0]});
// wait for block inclusion...

> getAddr('blipblop.test')
0x8058596db747ca76e2e769be88fb07cea5a47f89
carver
  • 6,381
  • 21
  • 51