mirror of
https://github.com/aljazceru/crawler_v2.git
synced 2025-12-16 23:14:19 +01:00
error walks.ErrInvalidRemoval contains
the correct value by reading it at compile time
This commit is contained in:
@@ -3,7 +3,6 @@ package walks
|
||||
|
||||
import (
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"log"
|
||||
"math/rand/v2"
|
||||
@@ -17,7 +16,7 @@ var (
|
||||
Alpha = 0.85 // the dampening factor
|
||||
N = 100 // the walks per node
|
||||
|
||||
ErrInvalidRemoval = errors.New("the walks to be removed are different than the expected number (100)")
|
||||
ErrInvalidRemoval = fmt.Errorf("the walks to be removed are different than the expected number (%d)", N)
|
||||
)
|
||||
|
||||
// ID represent how walks are identified in the storage layer
|
||||
@@ -29,7 +28,6 @@ func (id ID) MarshalBinary() ([]byte, error) { return []byte(id), nil }
|
||||
type Walk struct {
|
||||
ID ID
|
||||
Path []graph.ID
|
||||
// Stop int
|
||||
}
|
||||
|
||||
// Len returns the lenght of the walk
|
||||
|
||||
Reference in New Issue
Block a user