Lighthouse: Update shuffle() as per latest spec update

Created on 16 Oct 2018  路  7Comments  路  Source: sigp/lighthouse

Description

The shuffle() function in the Eth 2.0 spec has changed. We need to update our function.

Resources:

Present Behaviour

RAND_MAX is presently set to 2**24.

Expected Behaviour

RAND_MAX should be 2**24 - 1.

Steps to resolve

  1. Change RAND_MAX
  2. Use sigp/shuffling_sandbox to generate some test vectors. There's only 1 test vector in there now, we should throw in multiple (make sure you use different list sizes).

Hint: shuffling_sandbox cmd: $ python sandbox.py print --list-size LIST_SIZE

good first issue good for bounty spec_change

Most helpful comment

I wasn't sure if this is just a approval-only bounty by accident or not because of the PR @6ug opened.
However, couldn't withstand to play with Rust this weekend, so I thought I play with Rust and solving this issue along the way 馃憤

All 7 comments

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


__This issue now has a funding of 380.0 DAI (380.0 USD @ $1.0/DAI) attached to it as part of the Ethereum Community Fund via ECF Web 3.0 Infrastructure Fund fund.__

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


__Work has been started__.

These users each claimed they can complete the work by 7聽months, 1聽week from now.
Please review their action plans below:

1) pinkiebell has been approved to start work.

I can resolve the issue this weekend.
It will also be nice to digging with rust again :)

Learn more on the Gitcoin Issue Details page.

2) pvgupta24 has applied to start work _(Funders only: approve worker | reject worker)_.

Hello everyone, I believe I can resolve this issue and start my contribution to this project :)

Here's my action plan for the same :

  • Update the RAND_MAX value to be used
  • Generate test vectors of different sizes to cover corner cases and check.

Learn more on the Gitcoin Issue Details page.

3) shamardy has applied to start work _(Funders only: approve worker | reject worker)_.

I would like to work on this issue. I worked on multiple rust and Ethereum issues before in parity-ethereum client and parity substrate.

Learn more on the Gitcoin Issue Details page.

4) toya999 has applied to start work _(Funders only: approve worker | reject worker)_.

Ugds5hbbxzrjllhsweuhvhtde5ttyjhdsdfjo7fcgkb7

Learn more on the Gitcoin Issue Details page.

I wasn't sure if this is just a approval-only bounty by accident or not because of the PR @6ug opened.
However, couldn't withstand to play with Rust this weekend, so I thought I play with Rust and solving this issue along the way 馃憤

I'm new to this bounty thing, so please bear with me whilst I figure it out.

I can see that @pinkiebell was the first to apply and has already submitted some great work at #57, so it seems fair to me that they receive the grant.

I will ask the person who funded the issue (not me) to approve the funding. Thanks to all who applied!

I can see that @pinkiebell was the first to apply and has already submitted some great work at #57, so it seems fair to me that they receive the grant.

I was little late while applying and work, I agree with decision and @pinkiebell should get grant, closing my PR, good job buddy! :100:

@paulhauner @6ug
No problem, I normally wait for a comment but because it was already weekend and assuming 'first dibs', I just dived into the codebase 馃槃 .

@pinkiebell you have been approved to start work (now that you have finished it 馃槀). Please submit your work here and I will pay out ASAP.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

q9f picture q9f  路  4Comments

paulhauner picture paulhauner  路  5Comments

q9f picture q9f  路  3Comments

JustinDrake picture JustinDrake  路  3Comments

paulhauner picture paulhauner  路  4Comments