Skip to content

v0.3.0-rc.1 - Slashing

Pre-release
Pre-release
Compare
Choose a tag to compare
@MegaRedHand MegaRedHand released this 19 Feb 22:41
69e7d28

What's Changed

Added 🎉

  • feat: new BLS aggregation service interface by @maximopalopoli in #578

    • The new interface implies starting the service before using it, interact with it using a handler and receiving the aggregated responses in a separate channel.

    • An example using the interface is:

      // initialize service
      blsAgg := NewBlsAggregatorBuilder(fakeAvsRegistryService, hashFunction, logger)
      handler, aggResponsesC := blsAgg.Start()
      
      // Initialize task
      metadata := NewTaskMetadata(taskIndex, blockNum, quorumNumbers, quorumThresholdPercentages, tasksTimeToExpiry)
      err := handler.InitializeNewTask(metadata)
      
      // Process signature
      taskSignature := NewTaskSignature(taskIndex, taskResponse, blsSig, testOperator1.OperatorId)
      err = handler.ProcessNewSignature(
        context.Background(),
        taskSignature,
      )
      
      // Receive responses
      aggregationServiceResponse := <-aggResponsesC
  • added setMinimumStakeForQuorum by @Sidu28 in #554

  • feat: added StakeRegistryStorage functions by @Sidu28 in #555

  • BLS APK Registry Storage functions by @Sidu28 in #556

  • feat: add missing contract addresses on BuildAllConfig by @MegaRedHand in #558

  • feat: implement updateAVSMetadataURI wrapper by @MegaRedHand in #553

  • feat: add ServiceManagerBase.createAVSRewardsSubmission wrapper by @MegaRedHand in #557

  • AllocationManagerStorage functions by @Sidu28 in #563

  • Added delegationmanagerstorage functions by @Sidu28 in #564

  • feat: implement ServiceManagerBase.getRestakeableStrategies wrapper by @MegaRedHand in #559

  • feat: implement ServiceManagerBase.createOperatorDirectedAVSRewardsSubmission wrapper by @MegaRedHand in #561

  • feat: implement new method registerOperatorWithChurn by @damiramirez in #566

  • feat: implement method ModifyStrategyParams by @damiramirez in #570

  • feat: implement new method AddStrategies by @damiramirez in #568

  • feat: implement ServiceManagerBase.getOperatorRestakedStrategies wrapper by @MegaRedHand in #560

  • feate: implement method RemoveStrategies by @damiramirez in #569

  • feat: Add RewardsCoordinatorStorage functions by @Sidu28 in #565

Fixes

Breaking Changes 🛠

  • refactor: encapsulate parameters into TaskSignature in #487

    • Introduced TaskSignature struct to encapsulate parameters related to task signatures:

    • Updated ProcessNewSignature to accept a TaskSignature struct instead of multiple parameters.

      // BEFORE
      blsAggServ.ProcessNewSignature(
          context.Background(),
          taskIndex,
          taskResponse,
          blsSigOp1,
          testOperator1.OperatorId,
      )
      
      // AFTER
      taskSignature := NewTaskSignature(taskIndex, taskResponse, blsSig, testOperator1.OperatorId)
      
      blsAggServ.ProcessNewSignature(
          context.Background(),
          taskSignature,
      )
  • refactor: update interface on bls aggregation in #485.

    • Introduces a new struct TaskMetadata with a constructor NewTaskMetadata to initialize a new task and a method WithWindowDuration to set the window duration.

    • Refactors InitializeNewTask and singleTaskAggregatorGoroutineFunc to accept a TaskMetadata struct instead of multiple parameters.

      // BEFORE
      blsAggServ := NewBlsAggregatorService(fakeAvsRegistryService, hashFunction, logger)
      
      blsAggServ.InitializeNewTask(
          taskIndex,
          blockNum,
          quorumNumbers,
          quorumThresholdPercentages,
          tasksTimeToExpiry,
      )
      
      // AFTER
      blsAggServ := NewBlsAggregatorService(fakeAvsRegistryService, hashFunction, logger)
      
      metadata := NewTaskMetadata(taskIndex, blockNum, quorumNumbers, quorumThresholdPercentages, tasksTimeToExpiry)
      blsAggServ.InitializeNewTask(metadata)
    • Removes InitializeNewTaskWithWindow since windowDuration can now be set in TaskMetadata.

      // BEFORE
      blsAggServ := NewBlsAggregatorService(fakeAvsRegistryService, hashFunction, logger)
      err = blsAggServ.InitializeNewTaskWithWindow(
          taskIndex,
          blockNum,
          quorumNumbers,
          quorumThresholdPercentages,
          timeToExpiry,
          windowDuration,
      )
      
      // AFTER
      blsAggServ := NewBlsAggregatorService(fakeAvsRegistryService, hashFunction, logger)
      
      metadata := NewTaskMetadata(
          taskIndex,
          blockNum,
          quorumNumbers,
          quorumThresholdPercentages,
          tasksTimeToExpiry,
      ).WithWindowDuration(windowDuration)
      blsAggServ.InitializeNewTask(metadata)

Removed

Other Changes

  • chore(deps): bump github.com/ethereum/go-ethereum from 1.14.0 to 1.15.0 by @dependabot in #543
  • chore(deps): bump github.com/ethereum/go-ethereum from 1.14.0 to 1.14.13 in /signer by @dependabot in #490
  • feat: make SDK compatible with mainnet contracts by @MegaRedHand in #464
  • fix: respect context in new signature call by @MegaRedHand in #502
  • chore(deps): bump github.com/urfave/cli/v2 from 2.27.1 to 2.27.5 by @dependabot in #431
  • ci: add job to enforce updates to the changelog by @ricomateo in #483
  • chore(deps): bump github.com/prometheus/client_golang from 1.19.0 to 1.20.5 by @dependabot in #432
  • chore(deps): bump github.com/consensys/gnark-crypto from 0.14.0 to 0.16.0 by @dependabot in #573
  • test: avsregistry add new tests cases for reader methods by @damiramirez in #458
  • fix: change PR url in Changelog workflow by @maximopalopoli in #575

Full Changelog: v0.2.0...v0.3.0-rc.1