Closed zachyking closed 1 year ago
I think this actually breaks the miner by setting the timer every run.
Also feel free to blow away my commit. Git commands didn't go well.
I think this actually breaks the miner by setting the timer every run.
I added this because the previous one was breaking it little too, as timer wasn't being increased unless it found some hash and tried to do tx.
It would make sense to just do number of iterations before updating the state, instead of getting time on every iteration, to keep it simple.
However ideally it could use some worker threads and have main thread post messages with a new state for the worker threads (then separate thread for making txs maybe), I can probably make PR with this if you want it here?
I added this because the previous one was breaking it little too, as timer wasn't being increased unless it found some hash and tried to do tx.
oh I am dumb yeah timer gets reset every X secs inside the condition and that's enough, it was late and I blame @Riley-Kilgore for not telling me I am wrong 😄
It would make sense to just do number of iterations before updating the state, instead of getting time on every iteration, to keep it simple.
then this could still make sense but it doesn't really matter
No other changes needed, I apologize for my confusion 😄
However ideally it could use some worker threads and have main thread post messages with a new state for the worker threads (then separate thread for making txs maybe), I can probably make PR with this if you want it here?
Though this still makes sense I think
missed this in last pr, timer wasn't being updated