demergent-labs / azle

A WebAssembly runtime for TypeScript and JavaScript on ICP
MIT License
208 stars 36 forks source link

Stablize tests #1998

Open bdemann opened 3 months ago

bdemann commented 3 months ago

The following tests occasionally fail and we need to figure out why

Also

Also

bdemann commented 3 months ago

property_tests/tests/service

This was already fixed. The problem was that the canister was too big, making the candid too big, making it eat up too much space in the binary. The temp fix was to make the canister smaller which was done in this commit https://github.com/demergent-labs/azle/commit/a642ad46d4db82ddecaad2eaadbed85cf2fc6e3b.

Here is a forum post discussing the matter https://forum.dfinity.org/t/total-size-exceeds-the-maximum-allowed/33331

bdemann commented 3 months ago

property_tests/tests/stable_b_tree_map

If my memory serves I think Jordan said this was something to do with QuickJs and floats. Ultimately something needs to be updated but in the meantime we might be able to disable that type of value for the stable b tree map tests

Jordan says we should just disable this one for day to day testing until we can get that quick js fix in

bdemann commented 3 months ago

tests/end_to_end/http_server/ethers_base

bdemann commented 3 months ago

tests/end_to_end/http_server/http_outcall_fetch

This one fails because the api that it is hitting with fetch is very frequently down. I think fixing this is as simple as testing it against a more reliable API

bdemann commented 3 months ago

tests/end_to_end/http_server/ic_evm_rpc

This, basic_bitcoin, and bitcoin_psbt all fail with a similar error. Sometime the transactions don't go through and if the transactions don't go through then the subsequent tests that depend on the related balances also fail. I am guessing they are all the same problem

They actually seem to be different problem, I found this error:

Received: "{\"success\":false,\"error\":{\"code\":\"UNKNOWN_ERROR\",\"message\":\"cannot read property 'length' of undefined\",\"details\":null}}"
bdemann commented 3 months ago

examples/basic_bitcoin

~See https://github.com/demergent-labs/azle/issues/1998#issuecomment-2272218406~ (Turns out it's not the same issue)

I am guessing it's the same issue as bitcoin_psbt

bdemann commented 3 months ago

examples/bitcoin_psbt

~See https://github.com/demergent-labs/azle/issues/1998#issuecomment-2272218406~ (Turns out it's not the same issue)

This example is currently flat out failing and I don't know why. Something changed such that anything that I import from basic bitcoin breaks

I found that problem and fixed it... I don't remember what it was, but it is fixed

The current issue looks like this:

 Received string: "{\"success\":false,\"error\":{\"code\":\"UNKNOWN_ERROR\",\"message\":\"Rejection code 5, IC0503: Error from Canister g4xu7-jiaaa-aaaan-aaaaq-cai: Canister called ic0.trap with message: Panicked at 'Canister state is not fully synced.', canister/src/lib.rs:252:13\",\"details\":null}}"
bdemann commented 3 months ago

examples/ckbtc