nimiq / network Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
See nimiq/hub#368
If the user's system clock is wrongly set, blocks can be rejected and the consensus fails to be established.
The miner ui detects this error and shows a warning.
Similarly, the network iframe should fire an event that then get's handled by the Network client or Safe + Hub to display a warning.
The code used in the miner to detect a misconfigured system clock on consensus-established
and peers-changed
events is as follows:
_checkComputerClock() {
// if computer clock deviates too much from network time show a warning. To recover from this state, user has to
// reload as the netword time offset does not get recalculated.
if (this.$.network.peerCount < 3 // ask at least 3 peers for their time
|| Math.abs(this.$.network.time.now() - Date.now()) < Nimiq.Block.TIMESTAMP_DRIFT_MAX * 1000) return;
this.ui.clockMisconfigured();
this.stopMining();
}
I consider this quite an important issue (and therefore labeled it as bug) as it prevents the user from doing anything meaningful in the Safe / Hub without giving him any clue.
Add some communication layer between network iFrames that enables us to use the same NanoApi instance for all open tabs.
It would be nice if one deployment of this service would suffice to allow multiple CDNs, networks... in short: config as needed by the user of networkClient
.
Suggestions:
Problems to consider: core API might change for different versions.
I think the sendTransaction
method can also be invoked with a serialized transaction, right?
This is currenlty not reflected in the function signature / type of sendTransaction
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.