Skip to content

Conversation

@GabrielMartinezRodriguez
Copy link
Contributor

@GabrielMartinezRodriguez GabrielMartinezRodriguez commented Dec 20, 2024

Linked Issues

Description

This PR adds the code to submit DRAND numbers to the blockchain every 3 seconds.

In addition, it adapts the code to ensure commitments continue to work, considering the commitment contract now operates based on blocks instead of timestamps.

  • Include all relevant context (but no need to repeat the issue's content).
  • Draw attention to new, noteworthy & unintuitive elements.
Toggle Checklist

Checklist

Basics

  • B1. I have applied the proper label & proper branch name (e.g. norswap/build-system-caching).
  • B2. This PR is not so big that it should be split & addresses only one concern.
  • B3. The PR targets the lowest branch it can (ideally master).

Reminder: PR review guidelines

Correctness

  • C1. Builds and passes tests.
  • C2. The code is properly parameterized & compatible with different environments (e.g. local,
    testnet, mainnet, standalone wallet, ...).
  • C3. I have manually tested my changes & connected features.

< INDICATE BROWSER, DEMO APP & OTHER ENV DETAILS USED FOR TESTING HERE >

< INDICATE TESTED SCENARIOS (USER INTERFACE INTERACTION, CODE FLOWS) HERE >

Tested in local with anvil

  • C4. I have performed a thorough self-review of my code after submitting the PR,
    and have updated the code & comments accordingly.

Architecture & Documentation

  • D1. I made it easy to reason locally about the code, by (1) using proper abstraction boundaries,
    (2) commenting these boundaries correctly, (3) adding inline comments for context when needed.
  • D2. All public-facing APIs & meaningful (non-local) internal APIs are properly documented in code
    comments.
  • D3. If appropriate, the general architecture of the code is documented in a code comment or
    in a Markdown document.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Dec 20, 2024

Deploying happychain with  Cloudflare Pages  Cloudflare Pages

Latest commit: c0de6bf
Status: ✅  Deploy successful!
Preview URL: https://599daeca.happychain.pages.dev
Branch Preview URL: https://gabriel-drand-service.happychain.pages.dev

View logs

@linear
Copy link

linear bot commented Dec 20, 2024

HAPPY-244 Submit Drand to the `DranOracle` smartcontract

Create a service that submits the random numbers generated by https://drand.love/ to the DranOracle smart contract

@GabrielMartinezRodriguez GabrielMartinezRodriguez marked this pull request as ready for review December 20, 2024 11:33
@GabrielMartinezRodriguez GabrielMartinezRodriguez changed the title feat(randomness-service): drand service Submmit drand numbers Dec 23, 2024
@GabrielMartinezRodriguez GabrielMartinezRodriguez added the reviewing-1 Ready for, or undergoing first-line review label Dec 23, 2024
@GabrielMartinezRodriguez GabrielMartinezRodriguez changed the title Submmit drand numbers Submit drand numbers Dec 23, 2024
@AryanGodara AryanGodara self-requested a review December 24, 2024 15:06
Copy link
Collaborator

@norswap norswap left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably worth to do a thorough randomness spec + code review at some point & documenting the design, but that's for later.

@norswap norswap added updating Updating after review and removed reviewing-2 Ready for, or undergoing final review labels Feb 9, 2025
@GabrielMartinezRodriguez GabrielMartinezRodriguez added reviewing-2 Ready for, or undergoing final review and removed updating Updating after review labels Feb 10, 2025
@GabrielMartinezRodriguez GabrielMartinezRodriguez force-pushed the gabriel/drand-service branch 2 times, most recently from 2411eba to 68d402a Compare February 10, 2025 15:31
@norswap norswap force-pushed the gabriel/drand-service branch from 68d402a to 50f1ed4 Compare February 10, 2025 17:16
@norswap norswap merged commit 00c05ac into master Feb 10, 2025
3 checks passed
@norswap norswap deleted the gabriel/drand-service branch February 10, 2025 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

reviewing-2 Ready for, or undergoing final review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants