I am running some tests with aens and when i try to update the claim with a contract address the system
throws the exeption :
(node:73253) UnhandledPromiseRejectionWarning: Error: Unknown class ct
at p (/Users/sss/projects/aeternity/isaqb-ui/node_modules/@Albert/aepp-sdk/dist/aepp-sdk.js:1:130220)
at Object. (/Users/ulfangermann/projects/aeternity/isaqb-ui/node_modules/@Albert/aepp-sdk/dist/aepp-sdk.js:1:130618)
at x (/Users/sss/projects/aeternity/isaqb-ui/node_modules/@Albert/aepp-sdk/dist/aepp-sdk.js:1:317336)
at Generator._invoke (/Users/sss/projects/aeternity/isaqb-ui/node_modules/@Albert/aepp-sdk/dist/aepp-sdk.js:1:317124)
at Generator.e.(anonymous function) [as next] (/Users/sss/projects/aeternity/isaqb-ui/node_modules/@Albert/aepp-sdk/dist/aepp-sdk.js:1:317515)
at r (/Users/sss/projects/aeternity/isaqb-ui/node_modules/@Albert/aepp-sdk/dist/aepp-sdk.js:1:1637)
at s (/Users/sss/projects/aeternity/isaqb-ui/node_modules/@Albert/aepp-sdk/dist/aepp-sdk.js:1:1847)
at processTicksAndRejections (internal/process/next_tick.js:81:5)
Note: If a update with my public Key as the target, it works well.
Here is the code, which i run:
async function add_name(name, contract_address) {
console.log(“map : " + name + " to :” + contract_address);
//await handleApiError(async () => {
client = await getClient();
const preclaim = await client.aensPreclaim(name);
console.log(“preclaim:” , preclaim);
const claim = await client.aensClaim(name, preclaim.salt, preclaim.height);
console.log("claim : ", claim);
const update = await client.aensUpdate(claim.id, contract_address);
console.log(update);
// })
}
This is the result of the preclaim and claim
preclaim: { blockHash: ‘mh_mv5Etda6AshH456awT1Ne84a1awxF18gnnno3Xc69zkVHoi7h’,
blockHeight: 727,
hash: ‘th_2iJAxpkNMxbFQn9Efum3dzfiicKCFthWbA6GiDpYDNXGoxRr5S’,
signatures:
[ ‘sg_TeSaAvpM4xvDbqWEdqswH81cqHwH3twrpTBQoHFnDMfVfjDqizFMWm6abczJEaPG4JFY2pD8F2Bcc8WpY1HVEbFJjtykn’ ],
tx:
{ accountId: ‘ak_2mwRmUeYmfuW93ti9HMSUJzCk1EYcQEfikVSzgo6k2VghsWhgU’,
commitmentId: ‘cm_2Lywkui3K5WyzeSu6F9VKk9RjbpNtomvkfNd5ZXWBRKkBKQnD6’,
fee: 16640000000000,
nonce: 40,
type: ‘NamePreclaimTx’,
version: 1 },
rawTx:
‘tx_+JkLAfhCuEDLqu3CzkF439jnSJuxvedoN+WMT88CUVR49W4PhwRkAzgAb3OPAsXmLahY4FNdzdsU3R3jfGBVzizYPwLwB/MEuFH4TyEBoQHpu/YE5hG1Rgo7OZnpdxtvYEF9c858VRnhL34SehIlyiihA7ERNE6zuSaoOkwwiInCv96Ni+yxwcaEwiKb2JWui3Nohg8iTUoAAAB2Iy5y’,
height: 727,
claim: [Function: claim],
salt: 2412960464931419,
commitmentId: ‘cm_2Lywkui3K5WyzeSu6F9VKk9RjbpNtomvkfNd5ZXWBRKkBKQnD6’ }
claim : { blockHash: ‘mh_day2eFmnVBU5ZtuFQ1yjbJT7KTAeAR7Q3MdAS7qp2r94SAK46’,
blockHeight: 728,
hash: ‘th_mBGtqZDsqJGidCppDY49jHGseTCTQYdk8ho27XSBCykJwhwJk’,
signatures:
[ ‘sg_U3RzRREDHJ6C95ke1vBgJRYkUDmmkG6pA5ZgzQU8iHGMsvDqNjk7kwRfJa91MyY3cRZM91DZphSXbHhgYDwrYYP62c1Kj’ ],
tx:
{ accountId: ‘ak_2mwRmUeYmfuW93ti9HMSUJzCk1EYcQEfikVSzgo6k2VghsWhgU’,
fee: 16540000000000,
name: ‘kkkkkkkkkkkkkkk.test’,
nameSalt: ‘2412960464931419’,
nonce: 41,
type: ‘NameClaimTx’,
version: 1 },
rawTx:
‘tx_+JQLAfhCuEDOsowMwibzwm8ojQm7qx4sx3D3UEpbMScomKmlbk7U3Mae93wnM8tPj/1viLnCBKw4Q/9bQaizvl9+cSWg22sAuEz4SiABoQHpu/YE5hG1Rgo7OZnpdxtvYEF9c858VRnhL34SehIlyimUa2tra2tra2tra2tra2trLnRlc3SHCJKTI16KW4YPCwTTGAAAufZyBg==’,
id: ‘nm_i7QWYRyXZbnnScVu5T841hoWMXJZJL1uVDffzbMq5gVuGCkzw’,
pointers: ,
ttl: 50728,
update: [Function],
transfer: [Function],
revoke: [Function] }
Best Regards,
Ulf