MCPcopy Create free account
hub / github.com/JamieMason/syncpack / mark_suspect_with_expected

Method mark_suspect_with_expected

src/instance.rs:238–240  ·  view source on GitHub ↗

Like `mark_suspect` but records an expected specifier so a user can opt into routing the instance through the fix path via `severity: { ...: "fix" }`. Used by `RefuseToPinLocal` and `RefuseToSnapLocal` — both rewrite a local package's `/version` to a target specifier.

(&self, state: SuspectInstance, expected_specifier: &Rc<Specifier>)

Source from the content-addressed store, hash-verified

236 /// Used by `RefuseToPinLocal` and `RefuseToSnapLocal` — both rewrite a local
237 /// package's `/version` to a target specifier.
238 pub fn mark_suspect_with_expected(&self, state: SuspectInstance, expected_specifier: &Rc<Specifier>) -> &Self {
239 self.set_state(InstanceState::Suspect(state), expected_specifier)
240 }
241
242 /// Mark this instance as having a mismatch which can be auto-fixed
243 pub fn mark_fixable(&self, state: FixableInstance, expected_specifier: &Rc<Specifier>) -> &Self {

Callers 2

visitMethod · 0.80
visitMethod · 0.80

Calls 1

set_stateMethod · 0.80

Tested by

no test coverage detected