@@ -1216,8 +1216,6 @@ fn write_ice_to_disk(info: &panic::PanicInfo<'_>) -> Result<(String, String), Ic
1216
1216
1217
1217
writeln ! ( file, "{}" , version) ?;
1218
1218
args. push ( ( "version" , version. as_str ( ) ) ) ;
1219
- let backtrace_msg = format ! ( "please include the contents of `{}` here" , path. display( ) ) ;
1220
- args. push ( ( "backtrace" , & backtrace_msg) ) ;
1221
1219
1222
1220
if let Some ( ( flags, excluded_cargo_defaults) ) = extra_compiler_flags ( ) {
1223
1221
writeln ! ( file, "compiler flags:" ) ?;
@@ -1229,8 +1227,6 @@ fn write_ice_to_disk(info: &panic::PanicInfo<'_>) -> Result<(String, String), Ic
1229
1227
}
1230
1228
}
1231
1229
writeln ! ( file, "" ) ?;
1232
- let mut text = String :: new ( ) ;
1233
- text. push_str ( & format ! ( "{:?} {:?}" , info. message( ) , info. location( ) ) ) ;
1234
1230
match ( info. message ( ) , info. location ( ) ) {
1235
1231
( Some ( message) , Some ( location) ) => {
1236
1232
writeln ! ( file, "panicked at {location}:\n {message}" ) ?;
@@ -1247,6 +1243,7 @@ fn write_ice_to_disk(info: &panic::PanicInfo<'_>) -> Result<(String, String), Ic
1247
1243
}
1248
1244
1249
1245
writeln ! ( file, "" ) ?;
1246
+ let capture = format ! ( "{capture}" ) ;
1250
1247
writeln ! ( file, "{capture}" ) ?;
1251
1248
1252
1249
// Be careful relying on global state here: this code is called from
@@ -1304,7 +1301,8 @@ static DEFAULT_HOOK: LazyLock<Box<dyn Fn(&panic::PanicInfo<'_>) + Sync + Send +
1304
1301
&& std:: env:: var ( "RUSTC_BACKTRACE_FORCE" ) . as_deref ( ) != Ok ( "0" )
1305
1302
} ,
1306
1303
) ;
1307
- let written_ice = if !is_dev { write_ice_to_disk ( info) } else { Err ( IceError ) } ;
1304
+ let written_ice =
1305
+ if !is_dev && !ci_info:: is_ci ( ) { write_ice_to_disk ( info) } else { Err ( IceError ) } ;
1308
1306
// Invoke the default handler, which prints the actual panic message and optionally a backtrace
1309
1307
// Don't do this for delayed bugs, which already emit their own more useful backtrace.
1310
1308
if !info. payload ( ) . is :: < rustc_errors:: DelayedBugPanic > ( ) && written_ice. is_err ( ) {
@@ -1359,8 +1357,7 @@ pub fn report_ice(
1359
1357
}
1360
1358
1361
1359
let xs: Vec < Cow < ' static , str > > = if let Some ( ( path, custom_url) ) = & reported_ice {
1362
- let link = format ! ( "\x1b ]8;;{custom_url}\x1b \\ {bug_report_url}\x1b ]8;;\x1b \\ " ) ;
1363
- let path = format ! ( "\x1b ]8;;file://{path}\x1b \\ {path}\x1b ]8;;\x1b \\ " ) ;
1360
+ let link = format ! ( "\x1b ]8;;{custom_url}\x07 {bug_report_url}\x1b ]8;;\x07 " ) ;
1364
1361
vec ! [
1365
1362
format!( "all necessary context about this bug was written to `{path}`" ) . into( ) ,
1366
1363
format!( "we would appreciate a bug report with this context at {link}" ) . into( ) ,
0 commit comments