File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -157,6 +157,7 @@ pub(crate) fn fetch_deps(
157
157
source_dir : & Path ,
158
158
fetch_build_std_targets : & [ & str ] ,
159
159
) -> anyhow:: Result < ( ) > {
160
+ let mut yanked_deps = false ;
160
161
let mut missing_deps = false ;
161
162
let mut broken_deps = false ;
162
163
let mut cmd = Command :: new ( workspace, toolchain. cargo ( ) )
@@ -174,10 +175,11 @@ pub(crate) fn fetch_deps(
174
175
175
176
match cmd
176
177
. process_lines ( & mut |line, _| {
177
- if line. contains ( "failed to load source for dependency" ) {
178
+ if line. contains ( "failed to select a version for the requirement" ) {
179
+ yanked_deps = true ;
180
+ } else if line. contains ( "failed to load source for dependency" ) {
178
181
missing_deps = true ;
179
- }
180
- if line. contains ( "failed to parse manifest at" )
182
+ } else if line. contains ( "failed to parse manifest at" )
181
183
|| line. contains ( "error: invalid table header" )
182
184
{
183
185
broken_deps = true ;
@@ -186,6 +188,9 @@ pub(crate) fn fetch_deps(
186
188
. run_capture ( )
187
189
{
188
190
Ok ( _) => Ok ( ( ) ) ,
191
+ Err ( CommandError :: ExecutionFailed { status : _, stderr } ) if yanked_deps => {
192
+ Err ( PrepareError :: YankedDependencies ( stderr) . into ( ) )
193
+ }
189
194
Err ( CommandError :: ExecutionFailed { status : _, stderr } ) if missing_deps => {
190
195
Err ( PrepareError :: MissingDependencies ( stderr) . into ( ) )
191
196
}
You can’t perform that action at this time.
0 commit comments