When the returned data is
(
record {
certificate = opt blob "\d9\d9\f7\a2\64\74\72\65\65\83\01\83\01\83\01\82\04\58\20\a6\5a\fa\38\e2\24\22\88\63\a8\9e\bb\73\cf\e5\5c\f9\c0\b5\e6\c8\f8\75\6c\39\88\cd\78\39\76\5e\8b\83\02\48\63\61\6e\69\73\74\65\72\83\01\83\01\83\01\82\04\58\20\58\04\42\44\36\89\eb\3d\eb\bb\43\c3\e6\89\9a\9f\42\0f\51\59\2e\28\83\1a\8c\38\43\3f\a0\8e\be\f3\83\01\83\02\4a\00\00\00\00\00\00\00\02\01\01\83\01\83\01\83\02\4e\63\65\72\74\69\66\69\65\64\5f\64\61\74\61\82\03\58\20\0f\6e\14\41\6f\45\a2\4f\24\98\43\de\68\f6\c8\13\0c\f9\af\ae\be\d3\e5\37\dc\7b\14\2a\84\da\29\a1\82\04\58\20\d8\f6\4f\7a\fc\a6\a5\5d\4e\e6\de\d9\b0\20\0b\ac\66\51\ca\f4\c7\a1\92\02\12\b5\a0\3c\9b\f1\df\36\82\04\58\20\04\65\01\70\d9\75\f9\ec\43\58\de\ca\c4\01\b1\3f\0e\3b\1c\02\57\de\28\c8\f2\88\44\66\5c\72\a1\c1\82\04\58\20\a4\38\ef\5d\37\ff\d3\40\33\ec\79\ec\c6\cd\b1\25\85\ff\38\14\4c\2c\e4\ba\15\38\47\7d\28\86\43\9d\82\04\58\20\47\27\79\af\59\13\ad\7f\12\be\3a\47\42\9a\80\6d\c5\3a\df\13\de\1e\36\cc\25\8b\8b\a2\59\37\96\be\82\04\58\20\65\cc\8f\3f\1f\e7\6a\55\dd\e2\26\86\4b\0e\c6\7e\a7\19\39\e5\f5\42\d2\b4\03\fb\7f\90\7f\83\57\45\82\04\58\20\8f\6c\89\34\76\3f\b9\35\44\5b\b0\c5\81\f6\47\d1\dd\4f\d7\21\ef\c9\f8\51\62\e3\2e\ec\3d\41\87\4a\83\01\82\04\58\20\72\26\e7\fc\71\7e\7b\ba\9b\83\d8\fd\64\3f\3a\aa\71\2c\d0\2e\01\d8\46\fe\c7\3b\04\b8\30\43\d6\3f\83\02\44\74\69\6d\65\82\03\49\f4\89\a1\ac\fe\e3\a0\80\18\69\73\69\67\6e\61\74\75\72\65\58\30\a5\11\d2\56\76\17\47\5d\7f\9d\8c\40\27\b9\64\40\4c\f3\d9\e6\4f\7b\a3\74\71\d6\c0\56\69\56\a1\36\55\4f\ce\c0\03\30\19\87\45\fd\87\9f\19\91\df\b5";
blocks = vec {};
chain_length = 15_183_723 : nat64;
first_block_index = 15_182_000 : nat64;
archived_blocks = vec {
record {
callback = func "q4eej - kyaaa - aaaaa - aaaha - cai".get_blocks;
start = 15_181_994 : nat64;
length = 1 : nat64;
};
};
},
)
when blocks is an empty array, an error will be reported:
Candid failed with decoding at byte index 879 with message: Expected byte with value 0 or 1, got: 10.
If blocks is not empty, it can be decoded normally.
Here is the test case
https://github.com/Deland-Labs/ICP.NET/blob/189d458e26e625297a060fde2b4fecde6d5a9116/test/Candid.Tests/QueryResponseTests.cs#L10
When the returned data is
when blocks is an empty array, an error will be reported:
Candid failed with decoding at byte index 879 with message: Expected byte with value 0 or 1, got: 10.
If blocks is not empty, it can be decoded normally.
Here is the test case
https://github.com/Deland-Labs/ICP.NET/blob/189d458e26e625297a060fde2b4fecde6d5a9116/test/Candid.Tests/QueryResponseTests.cs#L10