@@ -11,10 +11,10 @@ use witnet_crypto::hash::calculate_sha256;
1111use crate :: {
1212 chain:: {
1313 tapi:: ActiveWips , DataRequestInfo , DataRequestOutput , DataRequestStage , DataRequestState ,
14- Epoch , Hash , Hashable , PublicKeyHash , ValueTransferOutput ,
14+ Environment , Epoch , Hash , Hashable , PublicKeyHash , ValueTransferOutput ,
1515 } ,
1616 error:: { DataRequestError , TransactionError } ,
17- get_protocol_version_activation_epoch,
17+ get_environment , get_protocol_version_activation_epoch,
1818 proto:: versioning:: { ProtocolVersion , VersionedHashable } ,
1919 radon_report:: { RadonReport , Stage , TypeLike } ,
2020 transaction:: { CommitTransaction , DRTransaction , RevealTransaction , TallyTransaction } ,
@@ -579,7 +579,10 @@ pub fn data_request_has_too_many_witnesses(
579579 if ProtocolVersion :: from_epoch_opt ( epoch) < ProtocolVersion :: V2_0 {
580580 false
581581 } else {
582- usize:: from ( dr_output. witnesses ) > validator_count / 4
582+ match get_environment ( ) {
583+ Environment :: Mainnet => usize:: from ( dr_output. witnesses ) > validator_count / 4 ,
584+ _ => usize:: from ( dr_output. witnesses ) > validator_count,
585+ }
583586 }
584587}
585588
0 commit comments