Skip to content

Commit e24847a

Browse files
committed
logs cleanup
1 parent 9b5e5d8 commit e24847a

File tree

1 file changed

+16
-34
lines changed

1 file changed

+16
-34
lines changed

test-integration/test-tools/src/scheduled_commits.rs

Lines changed: 16 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ impl IntegrationTestContext {
193193
{
194194
// 1. Find scheduled commit sent signature via
195195
// ScheduledCommitSent signature: <signature>
196-
let (ephem_logs, scheduled_commmit_sent_sig) = {
196+
let (ephem_logs_l1, scheduled_commmit_sent_sig) = {
197197
let logs = self.fetch_ephemeral_logs(sig).with_context(|| {
198198
format!(
199199
"Scheduled commit sent logs not found for sig {:?}",
@@ -206,47 +206,25 @@ impl IntegrationTestContext {
206206
format!("ScheduledCommitSent signature not found in logs, {:#?}", logs)
207207
})?;
208208

209-
println!("LOGS: {:#?}", logs);
210-
211209
(logs, sig)
212210
};
213211

214-
println!("Find chain commit signatures");
212+
println!("Ephem Logs level-1: {:#?}", ephem_logs_l1);
215213

216214
// 2. Find chain commit signatures
217-
// let chain_logs = self
218-
// .fetch_ephemeral_logs(scheduled_commmit_sent_sig)
219-
// .with_context(|| {
220-
// format!(
221-
// "Logs {:#?}\nScheduled commit sent sig {:?}",
222-
// ephem_logs, scheduled_commmit_sent_sig
223-
// )
224-
// })?;
225-
let (chain_logs, base_sig) = {
226-
let logs = self
227-
.fetch_ephemeral_logs(scheduled_commmit_sent_sig)
228-
.with_context(|| {
229-
format!(
230-
"Logs {:#?}\nScheduled commit sent sig {:?}",
231-
ephem_logs, scheduled_commmit_sent_sig
232-
)
233-
})?;
234-
let sig =
235-
extract_base_chain_commit_signature_from_logs(&logs)
236-
.with_context(|| {
237-
format!("ScheduledCommitSent signature not found in logs, {:#?}", logs)
238-
})?;
239-
240-
(logs, sig)
241-
};
242-
243-
println!("EPEHM_LOGS: {:#?}", chain_logs);
244-
println!("Found chain commit signatures: |{scheduled_commmit_sent_sig}| / |{base_sig}|");
215+
let ephem_logs_l2 = self
216+
.fetch_ephemeral_logs(scheduled_commmit_sent_sig)
217+
.with_context(|| {
218+
format!(
219+
"Logs {:#?}\nScheduled commit sent sig {:?}",
220+
ephem_logs_l1, scheduled_commmit_sent_sig
221+
)
222+
})?;
245223

246-
self.dump_chain_logs(base_sig);
224+
println!("Ephem Logs level-1: {:#?}", ephem_logs_l2);
247225

248226
let (included, excluded, feepayers, sigs) =
249-
extract_sent_commit_info_from_logs(&chain_logs);
227+
extract_sent_commit_info_from_logs(&ephem_logs_l2);
250228

251229
let mut committed_accounts = HashMap::new();
252230
for pubkey in included {
@@ -266,6 +244,10 @@ impl IntegrationTestContext {
266244
};
267245
}
268246

247+
for sig in sigs.iter() {
248+
self.dump_chain_logs(sig.clone());
249+
}
250+
269251
Ok(ScheduledCommitResult {
270252
included: committed_accounts,
271253
excluded,

0 commit comments

Comments
 (0)