Skip to content

Conversation

@DashCoreAutoGuix
Copy link
Owner

Backports bitcoin#26302

Original commit: 50cc8ef

Changes

  • Uses NodeClock::now() instead of GetTime() for type safety
  • Changes m_next_resend from std::atomic<int64_t> to std::atomic<NodeClock::time_point>
  • Uses FastRandomContext{}.rand_uniform_delay() for type-safe random delay
  • Adds #include <util/time.h> to wallet.h

Dash-specific adaptations

  • Preserved std::atomic wrapper around m_next_resend (Dash uses atomic for thread safety)
  • Added .load() calls for atomic access in comparisons

Original PR description

GetTime is not type-safe, thus deprecated.

ACKs for top commit:
shaavan: Code Review ACK fa51cc9
aureleoules: ACK fa51cc9

Backport of bitcoin#26302

Co-authored-by: MacroFake <falke.marco@gmail.com>
@coderabbitai
Copy link

coderabbitai bot commented Dec 6, 2025

Warning

Rate limit exceeded

@DashCoreAutoGuix has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 9 minutes and 2 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between 9cf919c and 2987a68.

📒 Files selected for processing (2)
  • src/wallet/wallet.cpp (1 hunks)
  • src/wallet/wallet.h (2 hunks)
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch backport-0.25-batch-480-pr-26302

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants