diff --git a/Tools/TestNetRewarder/EventsFormatter.cs b/Tools/TestNetRewarder/EventsFormatter.cs index 7e363432..e37943bb 100644 --- a/Tools/TestNetRewarder/EventsFormatter.cs +++ b/Tools/TestNetRewarder/EventsFormatter.cs @@ -1,8 +1,7 @@ using BlockchainUtils; -using CodexContractsPlugin; using CodexContractsPlugin.ChainMonitor; +using CodexContractsPlugin.Marketplace; using DiscordRewards; -using GethPlugin; using System.Globalization; using System.Numerics; using Utils; @@ -16,10 +15,12 @@ namespace TestNetRewarder private readonly List errors = new List(); private readonly EmojiMaps emojiMaps = new EmojiMaps(); private readonly Configuration config; + private readonly string periodDuration; - public EventsFormatter(Configuration config) + public EventsFormatter(Configuration config, MarketplaceConfig marketplaceConfig) { this.config = config; + periodDuration = Time.FormatDuration(marketplaceConfig.PeriodDuration); } public ChainEventMessage[] GetInitializationEvents(Configuration config) @@ -58,7 +59,8 @@ namespace TestNetRewarder $"PricePerBytePerSecond: {BitIntToTestTokens(request.Request.Ask.PricePerBytePerSecond)}", $"Number of Slots: {request.Request.Ask.Slots}", $"Slot Tolerance: {request.Request.Ask.MaxSlotLoss}", - $"Slot Size: {BigIntToByteSize(request.Request.Ask.SlotSize)}" + $"Slot Size: {BigIntToByteSize(request.Request.Ask.SlotSize)}", + $"Proof Probability: 1 / {request.Request.Ask.ProofProbability} every {periodDuration}" ); } diff --git a/Tools/TestNetRewarder/Processor.cs b/Tools/TestNetRewarder/Processor.cs index 649ebf47..036f8795 100644 --- a/Tools/TestNetRewarder/Processor.cs +++ b/Tools/TestNetRewarder/Processor.cs @@ -25,7 +25,7 @@ namespace TestNetRewarder if (config.ProofReportHours < 1) throw new Exception("ProofReportHours must be one or greater"); builder = new RequestBuilder(); - eventsFormatter = new EventsFormatter(config); + eventsFormatter = new EventsFormatter(config, contracts.Deployment.Config); chainState = new ChainState(log, contracts, eventsFormatter, config.HistoryStartUtc, doProofPeriodMonitoring: config.ShowProofPeriodReports > 0);