• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tari-project / tari / 21171015234

20 Jan 2026 12:11PM UTC coverage: 60.527% (-0.2%) from 60.73%
21171015234

push

github

web-flow
chore(deps): bump azure/trusted-signing-action from 0.5.11 to 1.0.0 (#7661)

Bumps
[azure/trusted-signing-action](https://github.com/azure/trusted-signing-action)
from 0.5.11 to 1.0.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/azure/trusted-signing-action/releases">azure/trusted-signing-action's
releases</a>.</em></p>
<blockquote>
<h2>Artifact Signing v1.0.0</h2>
<p>Rebranding action from Trusted Signing into Artifact Signing. This
will be our initial version for GA.</p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/Azure/artifact-signing-action/commit/db7a3a6bd"><code>db7a3a6</code></a>
Rebrand trusted signing into artifact signing (<a
href="https://redirect.github.com/azure/trusted-signing-action/issues/108">#108</a>)</li>
<li>See full diff in <a
href="https://github.com/azure/trusted-signing-action/compare/v0.5.11...v1.0.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=azure/trusted-signing-action&package-manager=github_actions&previous-version=0.5.11&new-version=1.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merg... (continued)

70258 of 116078 relevant lines covered (60.53%)

225689.28 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

41.67
/base_layer/core/src/base_node/sync/hooks.rs
1
//  Copyright 2020, The Tari Project
2
//
3
//  Redistribution and use in source and binary forms, with or without modification, are permitted provided that the
4
//  following conditions are met:
5
//
6
//  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following
7
//  disclaimer.
8
//
9
//  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the
10
//  following disclaimer in the documentation and/or other materials provided with the distribution.
11
//
12
//  3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote
13
//  products derived from this software without specific prior written permission.
14
//
15
//  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
16
//  INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
17
//  DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
18
//  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
19
//  SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
20
//  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
21
//  USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
22

23
#![allow(clippy::type_complexity)]
24

25
use std::sync::Arc;
26

27
use tari_node_components::blocks::ChainBlock;
28

29
use crate::base_node::sync::{horizon_state_sync::HorizonSyncInfo, SyncPeer};
30

31
#[derive(Default)]
32
pub(super) struct Hooks {
33
    on_starting: Vec<Box<dyn FnOnce(&SyncPeer) + Send + Sync>>,
34
    on_progress_header: Vec<Box<dyn Fn(u64, u64, &SyncPeer) + Send + Sync>>,
35
    on_progress_block: Vec<Box<dyn Fn(Arc<ChainBlock>, u64, &SyncPeer) + Send + Sync>>,
36
    on_progress_horizon_sync: Vec<Box<dyn Fn(HorizonSyncInfo) + Send + Sync>>,
37
    on_complete: Vec<Box<dyn Fn(Arc<ChainBlock>, u64) + Send + Sync>>,
38
    on_rewind: Vec<Box<dyn Fn(Vec<Arc<ChainBlock>>) + Send + Sync>>,
39
}
40

41
impl Hooks {
42
    pub fn add_on_starting_hook<H>(&mut self, hook: H)
12✔
43
    where H: FnOnce(&SyncPeer) + Send + Sync + 'static {
12✔
44
        self.on_starting.push(Box::new(hook));
12✔
45
    }
12✔
46

47
    pub fn call_on_starting_hook(&mut self, sync_peer: &SyncPeer) {
12✔
48
        self.on_starting.drain(..).for_each(|f| (f)(sync_peer));
12✔
49
    }
12✔
50

51
    pub fn add_on_progress_header_hook<H>(&mut self, hook: H)
12✔
52
    where H: Fn(u64, u64, &SyncPeer) + Send + Sync + 'static {
12✔
53
        self.on_progress_header.push(Box::new(hook));
12✔
54
    }
12✔
55

56
    pub fn call_on_progress_header_hooks(&self, local_height: u64, remote_height: u64, sync_peer: &SyncPeer) {
2✔
57
        self.on_progress_header
2✔
58
            .iter()
2✔
59
            .for_each(|f| (*f)(local_height, remote_height, sync_peer));
2✔
60
    }
2✔
61

62
    pub fn add_on_progress_block_hook<H>(&mut self, hook: H)
×
63
    where H: Fn(Arc<ChainBlock>, u64, &SyncPeer) + Send + Sync + 'static {
×
64
        self.on_progress_block.push(Box::new(hook));
×
65
    }
×
66

67
    pub fn call_on_progress_block_hooks(&self, block: Arc<ChainBlock>, remote_tip_height: u64, sync_peer: &SyncPeer) {
×
68
        self.on_progress_block
×
69
            .iter()
×
70
            .for_each(|f| (*f)(block.clone(), remote_tip_height, sync_peer));
×
71
    }
×
72

73
    pub fn add_on_progress_horizon_hook<H>(&mut self, hook: H)
×
74
    where H: Fn(HorizonSyncInfo) + Send + Sync + 'static {
×
75
        self.on_progress_horizon_sync.push(Box::new(hook));
×
76
    }
×
77

78
    pub fn call_on_progress_horizon_hooks(&self, info: HorizonSyncInfo) {
×
79
        self.on_progress_horizon_sync.iter().for_each(|f| (*f)(info.clone()));
×
80
    }
×
81

82
    pub fn add_on_complete_hook<H>(&mut self, hook: H)
×
83
    where H: Fn(Arc<ChainBlock>, u64) + Send + Sync + 'static {
×
84
        self.on_complete.push(Box::new(hook));
×
85
    }
×
86

87
    pub fn call_on_complete_hooks(&self, final_block: Arc<ChainBlock>, starting_height: u64) {
×
88
        self.on_complete
×
89
            .iter()
×
90
            .for_each(|f| (*f)(final_block.clone(), starting_height));
×
91
    }
×
92

93
    pub fn add_on_rewind_hook<H>(&mut self, hook: H)
12✔
94
    where H: Fn(Vec<Arc<ChainBlock>>) + Send + Sync + 'static {
12✔
95
        self.on_rewind.push(Box::new(hook));
12✔
96
    }
12✔
97

98
    pub fn call_on_rewind_hooks(&mut self, blocks: Vec<Arc<ChainBlock>>) {
×
99
        self.on_rewind.iter().for_each(|f| (*f)(blocks.clone()));
×
100
    }
×
101
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc