Skip to content

Commit

Permalink
looging target
Browse files Browse the repository at this point in the history
Signed-off-by: Adam Reif <[email protected]>
  • Loading branch information
Adam Reif authored and Adam Reif committed May 30, 2023
1 parent c71b65d commit 0ce414f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pallets/parachain-staking/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ pub use traits::*;
pub use types::*;
pub use RoundIndex;

#[cfg(not(feature = "on-chain-release-build"))]
const LOG_TARGET: &str = "parachain-staking";

#[pallet]
pub mod pallet {
use crate::{
Expand Down Expand Up @@ -1711,7 +1714,10 @@ pub mod pallet {
// choose the top TotalSelected qualified candidates, ordered by stake
let collators = Self::compute_top_candidates();
if collators.is_empty() {
log::error!("FAILED TO SELECT >=1 COLLATOR => using collators from previous round");
log::error!(
target: crate::LOG_TARGET,
"FAILED TO SELECT >=1 COLLATOR => using collators from previous round"
);
let last_round = now.saturating_sub(1u32);
let mut total_per_candidate: BTreeMap<T::AccountId, BalanceOf<T>> = BTreeMap::new();
// set this round AtStake to last round AtStake
Expand Down

0 comments on commit 0ce414f

Please sign in to comment.