[BUG] Unable to tip

Hi!
Tried to tip superhero.com
image
and it failed:
image
The console shows that the Glorious Sophia Compiler failed:

CC: @bruteforce.chain @radrow.chain

Actually I see the reason for this crash - Either the SDK or the Superhero UI forgets to escape the newline character in the string. Currently encoding call data works by injecting the arguments straight to the contract source and running the lexer, parser 3 times and the typechecker 2 times(soon the situation will improve a lot :slight_smile: ) - injecting /n will fail :stuck_out_tongue:

1 Like

I have just checked and this is not an issue of the compiler – it handles escape chars correctly. It looks like a bug in the SDK.

image

Yup, the sdk forgets to escape special characters

2 Likes

Yes, its a known issue.

3 Likes

Just ran into this problem one more time:

Http request for https://latest.compiler.aepps.com/encode-calldata failed with status code 400. Status: . 
Error data: [{"message":"Lexical error on input: \"Watch out! The #aeternity #hyperchains #whitepaper has been just updated with a new security paragraph. This time we covered parent chain overload attack.\n","pos":{"col":111,"line":26},"type":"parse_error"}]
    at d (http.js:40)
    at async Object._ [as contractCall] (contract.js:232)
    at async Object.call
1 Like

Now I have something more suspicious:

GET https://raendom-backend.z52da5wt.xyz/linkpreview/image/undefined 404
GET https://raendom-backend.z52da5wt.xyz/profile/image/ak_xdMvnwfmbJ3AN16ZatP1VsiXoaaD3uaAGKKD7KJ8etafGEwrC? 404
GET https://raendom-backend.z52da5wt.xyz/profile/image/ak_zXeqmbwsXemNKdup2WRTRXZ4WqoHpGPiPtkt3QquDVYbGhXCc? 404
GET https://raendom-backend.z52da5wt.xyz/profile/image/ak_2oBEG11B2GZSWVdVUQy1CYEvgWCfeizEGzjDaQB1YFv4owMcbd? 404
GET https://raendom-backend.z52da5wt.xyz/profile/image/ak_JiKroPAi6xEUy7KZmFgKjeefPkJ6swqz8F7CxwLdQsMpx8idL? 404
GET https://mainnet.aeternity.io/v2/contracts/ct_2Cvbf3NYZ5DLoaNYAU71t67DdXLHeSXhodkSNifhgd7Xsw28Xd 404
SendTip.vue:131 Error: Contract with address ct_2Cvbf3NYZ5DLoaNYAU71t67DdXLHeSXhodkSNifhgd7Xsw28Xd not found on-chain or not active
    at Object.x [as getContractInstance]
GET https://mainnet.aeternity.io/v2/contracts/ct_2Cvbf3NYZ5DLoaNYAU71t67DdXLHeSXhodkSNifhgd7Xsw28Xd 404
Error: Contract with address ct_2Cvbf3NYZ5DLoaNYAU71t67DdXLHeSXhodkSNifhgd7Xsw28Xd not found on-chain or not active
    at Object.x [as getContractInstance]

Prevents me from tipping

1 Like