Sarath
1
Hi,
i try to deploy the bellow contract, but i am getting error
transaction() {
prepare(admin: AuthAccount) {
let code: [UInt8] = βf845b8404d171ee5ee7303d91db44363d39230cef2ed8f6f48e15a10756458ffda0b6bddb232d05eb1b6a5598be6818e53a4709daf4ca22722882bf6fb3a228a6ef49d7b030364β.decodeHex()
let signer = AuthAccount(payer: admin)
signer.contracts.add(
name: βTestβ,
code: code
)
}
}
bastian
2
You get this error because the code you provide is invalid, it looks like random data and not Cadence source code.
How did you generate the hex-encoded form of the code you provide?
f845b8404d171ee5ee7303d91db44363d39230cef2ed8f6f48e15a10756458ffda0b6bddb232d05eb1b6a5598be6818e53a4709daf4ca22722882bf6fb3a228a6ef49d7b030364
If I decode this, it looks like random data.