Request for Comment : Updating Rewards Contract

This is correct. It is possible to get a multi-reward setup going with the current implementation, but it is very operationally burdensome. @Pasha seems to have arrived at this point in his comment as well. I will explain why:

  1. Even though multiple CometRewards can be set up with different multipliers, they all depend on the one speed defined in Comet. This means when there are multiple reward tokens, there is no way to change the speed for only one reward and not the other. You can imagine this makes turning off one reward token while keeping another on very difficult.

  2. If you want to start distributing a new reward token to a Comet that has already been distributing rewards, the new CometReward will read from the non-zero baseTrackingAccrued values of existing users. Remember, the reward contracts are sharing the same speed, and therefore, the same baseTrackingAccrued values as well. This means you will need to seed the rewardsClaimed value for each user in CometRewards using setRewardsClaimed to ensure that each user starts with 0 accrued rewards for the new reward token.

As you can imagine, this is a lot of off-chain processing and on-chain data posting that needs to be done right.

The alternative longer-term approach is to go with one of the smart contract changes discussed here.

3 Likes