Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timestamp ser and der failed on borsh feature #687

Closed
DaviRain-Su opened this issue May 20, 2023 · 0 comments · Fixed by #688 or #693
Closed

Timestamp ser and der failed on borsh feature #687

DaviRain-Su opened this issue May 20, 2023 · 0 comments · Fixed by #688 or #693
Milestone

Comments

@DaviRain-Su
Copy link
Contributor

DaviRain-Su commented May 20, 2023

Bug Summary

Current Timestamp ser and der have failed,

use borsh::{BorshDeserialize, BorshSerialize};
let timestamp = Timestamp::now();
let encode_timestamp = timestamp.try_to_vec().unwrap();
let _ = Timestamp::try_from_slice(&encode_timestamp).unwrap();

report this error:

Custom { kind: InvalidData, error: "Not all bytes read" }'

Details

Version

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
2 participants