holochain / hdk-assemblyscript

The Holochain Developer Kit for Assemblyscript
41 stars 2 forks source link

Wrappers for commit_entry and get_entry #3

Closed willemolding closed 6 years ago

willemolding commented 6 years ago

Quite a lot going on in this PR. I'll make future ones more focused

What it doesn't do yet... consumer of this library, like /examples/appSpec still need to manually serialize/deserialize inputs and outputs`

Connoropolous commented 6 years ago

@willemolding seems there is only one tiny issue, we can create a "follow-up" issue for it, in which the string being returned has an extra 'null' unicode char on the end. See \u{0} where the \u indicates unicode, and the {0} indicates the null char, according to wikipedia (and @ddd-mtl )

See the last characters of these results

screen shot 2018-09-24 at 4 24 06 pm

This means having to do

let raw_commit_result = raw_commit_result.trim_right_matches(char::from(0));

to cut those characters off.

I think it's fine for now, because the parts we want working are working.