Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Altair VC client #2520

Merged
merged 14 commits into from
May 14, 2021
Merged

Add Altair VC client #2520

merged 14 commits into from
May 14, 2021

Conversation

dapplion
Copy link
Contributor

Motivation

Completes the work started with #2514. Part of #2388

Description

  • Adds a new service pair: SyncCommitteeService + SyncCommitteeDutiesService which work very similar to the attester services.
  • Abstract getting indices in a different service IndicesService used by sync and att services

@codeclimate
Copy link

codeclimate bot commented May 13, 2021

Code Climate has analyzed commit e041e3c and detected 22 issues on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 6
Duplication 16

View more on Code Climate.

@lgtm-com
Copy link

lgtm-com bot commented May 13, 2021

This pull request introduces 5 alerts when merging 117f77b into 7650671 - view on LGTM.com

new alerts:

  • 4 for Useless assignment to property
  • 1 for Unused variable, import, function or class

@lgtm-com
Copy link

lgtm-com bot commented May 14, 2021

This pull request introduces 5 alerts when merging 2607886 into 7650671 - view on LGTM.com

new alerts:

  • 4 for Useless assignment to property
  • 1 for Unused variable, import, function or class

@lgtm-com
Copy link

lgtm-com bot commented May 14, 2021

This pull request introduces 5 alerts when merging cd11799 into 7579f7f - view on LGTM.com

new alerts:

  • 4 for Useless assignment to property
  • 1 for Unused variable, import, function or class

@lgtm-com
Copy link

lgtm-com bot commented May 14, 2021

This pull request introduces 4 alerts when merging e796e12 into 7579f7f - view on LGTM.com

new alerts:

  • 4 for Useless assignment to property

// Produce one attestation data per slot and subcommitteeIndex
// Spec: the validator should prepare a SyncCommitteeSignature for the previous slot (slot - 1)
// as soon as they have determined the head block of slot - 1
const beaconBlockRoot = await this.apiClient.beacon.blocks.getBlockRoot(slot - 1).catch((e) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

my understanding is we want to get block root at the current slot since we wait for 1/3 slot already, so getBlockRoot(slot)

correct me if I'm wrong

Copy link
Contributor

Choose a reason for hiding this comment

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

will address in future PRs

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah that's right, we want to sign the head at that slot since the signatures will be included in the next. Even we can / should do getBlockRoot("head")

Copy link
Contributor Author

Choose a reason for hiding this comment

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

See #2522 as conclusion

@twoeths twoeths merged commit ffc81e4 into master May 14, 2021
@twoeths twoeths deleted the dapplion/altair-vc-client branch May 14, 2021 02:51
@dapplion dapplion mentioned this pull request May 14, 2021
25 tasks
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