Xahau / xahaud

Codebase for Xahaud - The consensus, RPC & blockchain app for the Xahau network.
https://xahau.network
ISC License
22 stars 11 forks source link

Date object should not be used or should use ripple-epoch time in jshook #329

Closed tequdev closed 4 days ago

tequdev commented 1 month ago
var Hook = (arg) => {
  trace("", new Date(), false);
  return accept("", 1);
};
HookInfo[rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn-rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn]: creating quickjs instance
HookTrace[rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn-rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn]: : "2024-05-30T06:54:44.902Z"
HookInfo[rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn-rG1QQv2nh2gr7RCZ1P8YYcBUKCCN633jCn]: ApiVersion: 1 ACCEPT RS: '' RC: 1
preclaim result: tesSUCCESS
RichardAH commented 1 month ago

Correct, non-deterministic things like clocks need to be stripped out

RichardAH commented 4 days ago

https://github.com/Xahau/xahaud/commit/f2becaf140a2457d8b1c36badf2ce50153b14c70