prysmaticlabs / prysm

Functions prefixed with Get should return a value RVV-A0006
Anti-pattern
Major
6 occurrences in this check
function 'GetLiveness' seems to be a getter but it does not return any result
 994// It is important to note that the values returned by the beacon node are not canonical;
 995// they are best-effort and based upon a subjective view of the network.
 996// A beacon node that was recently started or suffered a network partition may indicate that a validator is not live when it actually is.
 997func (s *Server) GetLiveness(w http.ResponseWriter, r *http.Request) { 998	ctx, span := trace.StartSpan(r.Context(), "validator.GetLiveness")
 999	defer span.End()
1000
function 'GetSyncCommitteeDuties' seems to be a getter but it does not return any result
 861//     or an epoch from the next sync committee period, then get the current state.
 862//   - Get the state's current sync committee. If it's an epoch from the next sync committee period, then get the next sync committee.
 863//   - Get duties.
 864func (s *Server) GetSyncCommitteeDuties(w http.ResponseWriter, r *http.Request) { 865	ctx, span := trace.StartSpan(r.Context(), "validator.GetSyncCommitteeDuties")
 866	defer span.End()
 867
function 'GetProposerDuties' seems to be a getter but it does not return any result
 734}
 735
 736// GetProposerDuties requests beacon node to provide all validators that are scheduled to propose a block in the given epoch.
 737func (s *Server) GetProposerDuties(w http.ResponseWriter, r *http.Request) { 738	ctx, span := trace.StartSpan(r.Context(), "validator.GetProposerDuties")
 739	defer span.End()
 740
function 'GetAttesterDuties' seems to be a getter but it does not return any result
 605
 606// GetAttesterDuties requests the beacon node to provide a set of attestation duties,
 607// which should be performed by validators, for a particular epoch.
 608func (s *Server) GetAttesterDuties(w http.ResponseWriter, r *http.Request) { 609	ctx, span := trace.StartSpan(r.Context(), "validator.GetAttesterDuties")
 610	defer span.End()
 611
function 'GetAttestationData' seems to be a getter but it does not return any result
 401
 402// GetAttestationData requests that the beacon node produces attestation data for
 403// the requested committee index and slot based on the nodes current head.
 404func (s *Server) GetAttestationData(w http.ResponseWriter, r *http.Request) { 405	ctx, span := trace.StartSpan(r.Context(), "validator.GetAttestationData")
 406	defer span.End()
 407
function 'GetAggregateAttestation' seems to be a getter but it does not return any result
  38)
  39
  40// GetAggregateAttestation aggregates all attestations matching the given attestation data root and slot, returning the aggregated result.
  41func (s *Server) GetAggregateAttestation(w http.ResponseWriter, r *http.Request) {  42	_, span := trace.StartSpan(r.Context(), "validator.GetAggregateAttestation")
  43	defer span.End()
  44