Bug 2341307 - ruff: FTBFS in Fedora rawhide/f42
Summary: ruff: FTBFS in Fedora rawhide/f42
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: ruff
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Fabio Valentini
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: F42FTBFS
TreeView+ depends on / blocked
 
Reported: 2025-01-22 21:52 UTC by Fedora Release Engineering
Modified: 2025-02-24 17:15 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2025-02-24 17:15:43 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
build.log (32.00 KB, text/plain)
2025-01-22 21:52 UTC, Fedora Release Engineering
no flags Details
root.log (32.00 KB, text/plain)
2025-01-22 21:52 UTC, Fedora Release Engineering
no flags Details
state.log (1.61 KB, text/plain)
2025-01-22 21:52 UTC, Fedora Release Engineering
no flags Details

Description Fedora Release Engineering 2025-01-22 21:52:25 UTC
ruff failed to build from source in Fedora rawhide/f42

https://koji.fedoraproject.org/koji/taskinfo?taskID=128110125


For details on the mass rebuild see:

https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
Please fix ruff at your earliest convenience and set the bug's status to
ASSIGNED when you start fixing it. If the bug remains in NEW state for 8 weeks,
ruff will be orphaned. Before branching of Fedora 43,
ruff will be retired, if it still fails to build.

For more details on the FTBFS policy, please visit:
https://docs.fedoraproject.org/en-US/fesco/Fails_to_build_from_source_Fails_to_install/

Comment 1 Fedora Release Engineering 2025-01-22 21:52:28 UTC
Created attachment 2072441 [details]
build.log

file build.log too big, will only attach last 32768 bytes

Comment 2 Fedora Release Engineering 2025-01-22 21:52:29 UTC
Created attachment 2072442 [details]
root.log

file root.log too big, will only attach last 32768 bytes

Comment 3 Fedora Release Engineering 2025-01-22 21:52:31 UTC
Created attachment 2072443 [details]
state.log

Comment 4 Ben Beasley 2025-01-22 22:40:29 UTC
test tests/compile-fail/get-set-on-private-input-field.rs ... mismatch

EXPECTED:
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
error[E0624]: method `field` is private
  --> tests/compile-fail/get-set-on-private-input-field.rs:14:11
   |
4  |     #[salsa::input]
   |     --------------- private method defined here
...
14 |     input.field(&db);
   |           ^^^^^ private method

error[E0624]: method `set_field` is private
  --> tests/compile-fail/get-set-on-private-input-field.rs:15:11
   |
4  |     #[salsa::input]
   |     --------------- private method defined here
...
15 |     input.set_field(&mut db).to(23);
   |           ^^^^^^^^^ private method

warning: unused import: `salsa::prelude`
 --> tests/compile-fail/get-set-on-private-input-field.rs:1:5
  |
1 | use salsa::prelude::*;
  |     ^^^^^^^^^^^^^^
  |
  = note: `#[warn(unused_imports)]` on by default
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈

ACTUAL OUTPUT:
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
error[E0624]: method `field` is private
  --> tests/compile-fail/get-set-on-private-input-field.rs:14:11
   |
4  |     #[salsa::input]
   |     --------------- private method defined here
...
14 |     input.field(&db);
   |           ^^^^^ private method

error[E0624]: method `set_field` is private
  --> tests/compile-fail/get-set-on-private-input-field.rs:15:11
   |
4  |     #[salsa::input]
   |     --------------- private method defined here
...
15 |     input.set_field(&mut db).to(23);
   |           ^^^^^^^^^ private method
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
note: If the actual output is the correct output you can bless it by rerunning
      your test with the environment variable TRYBUILD=overwrite
test tests/compile-fail/input_struct_incompatibles.rs ... ok
test tests/compile-fail/interned_struct_incompatibles.rs ... ok
test tests/compile-fail/lru_can_not_be_used_with_specify.rs ... ok
test tests/compile-fail/panic-when-reading-fields-of-tracked-structs-from-older-revisions.rs ... ok
test tests/compile-fail/salsa_fields_incompatibles.rs ... ok
test tests/compile-fail/singleton_only_for_input.rs ... ok
test tests/compile-fail/span-input-setter.rs ... ok
test tests/compile-fail/span-tracked-getter.rs ... ok
test tests/compile-fail/specify-does-not-work-if-the-key-is-a-salsa-input.rs ... ok
test tests/compile-fail/specify-does-not-work-if-the-key-is-a-salsa-interned.rs ... ok
test tests/compile-fail/tracked_fn_incompatibles.rs ... ok
test tests/compile-fail/tracked_impl_incompatibles.rs ... mismatch

EXPECTED:
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
error: unexpected token
 --> tests/compile-fail/tracked_impl_incompatibles.rs:6:18
  |
6 | #[salsa::tracked(return_ref)]
  |                  ^^^^^^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:11:18
   |
11 | #[salsa::tracked(specify)]
   |                  ^^^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:16:18
   |
16 | #[salsa::tracked(no_eq)]
   |                  ^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:21:18
   |
21 | #[salsa::tracked(data = Data)]
   |                  ^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:26:18
   |
26 | #[salsa::tracked(db = Db)]
   |                  ^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:31:18
   |
31 | #[salsa::tracked(recover_fn = recover)]
   |                  ^^^^^^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:36:18
   |
36 | #[salsa::tracked(lru = 32)]
   |                  ^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:41:18
   |
41 | #[salsa::tracked(constructor = Constructor)]
   |                  ^^^^^^^^^^^

error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
  --> tests/compile-fail/tracked_impl_incompatibles.rs:47:1
   |
47 | impl<'db> std::default::Default for [MyTracked<'db>; 12] {
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------
   | |                                   |
   | |                                   this is not defined in the current crate because arrays are always foreign
   | impl doesn't use only types from inside the current crate
   |
   = note: define and implement a trait or new type instead

error[E0308]: mismatched types
  --> tests/compile-fail/tracked_impl_incompatibles.rs:48:21
   |
48 |     fn default() -> Self {}
   |        -------      ^^^^ expected `[MyTracked<'_>; 12]`, found `()`
   |        |
   |        implicitly returns `()` as its body has no tail or `return` expression
   |
   = note:  expected array `[MyTracked<'db>; 12]`
           found unit type `()`
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈

ACTUAL OUTPUT:
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
error: unexpected token
 --> tests/compile-fail/tracked_impl_incompatibles.rs:6:18
  |
6 | #[salsa::tracked(return_ref)]
  |                  ^^^^^^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:11:18
   |
11 | #[salsa::tracked(specify)]
   |                  ^^^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:16:18
   |
16 | #[salsa::tracked(no_eq)]
   |                  ^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:21:18
   |
21 | #[salsa::tracked(data = Data)]
   |                  ^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:26:18
   |
26 | #[salsa::tracked(db = Db)]
   |                  ^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:31:18
   |
31 | #[salsa::tracked(recover_fn = recover)]
   |                  ^^^^^^^^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:36:18
   |
36 | #[salsa::tracked(lru = 32)]
   |                  ^^^

error: unexpected token
  --> tests/compile-fail/tracked_impl_incompatibles.rs:41:18
   |
41 | #[salsa::tracked(constructor = Constructor)]
   |                  ^^^^^^^^^^^

error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
  --> tests/compile-fail/tracked_impl_incompatibles.rs:47:1
   |
47 | impl<'db> std::default::Default for [MyTracked<'db>; 12] {
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------
   |                                     |
   |                                     this is not defined in the current crate because arrays are always foreign
   |
   = note: impl doesn't have any local type before any uncovered type parameters
   = note: for more information see https://doc.rust-lang.org/reference/items/implementations.html#orphan-rules
   = note: define and implement a trait or new type instead

error[E0308]: mismatched types
  --> tests/compile-fail/tracked_impl_incompatibles.rs:48:21
   |
48 |     fn default() -> Self {}
   |        -------      ^^^^ expected `[MyTracked<'_>; 12]`, found `()`
   |        |
   |        implicitly returns `()` as its body has no tail or `return` expression
   |
   = note:  expected array `[MyTracked<'db>; 12]`
           found unit type `()`
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
note: If the actual output is the correct output you can bless it by rerunning
      your test with the environment variable TRYBUILD=overwrite
test tests/compile-fail/tracked_method_incompatibles.rs ... ok
test tests/compile-fail/tracked_method_on_untracked_impl.rs ... ok
test tests/compile-fail/tracked_struct_incompatibles.rs ... ok

test compile_fail ... FAILED
failures:
---- compile_fail stdout ----
thread 'compile_fail' panicked at /usr/share/cargo/registry/trybuild-1.0.99/src/run.rs:101:13:
2 of 19 tests failed
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
failures:
    compile_fail
test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 17.59s
error: test failed, to rerun pass `-p salsa --test compile_fail`

Comment 5 Fabio Valentini 2025-01-23 11:47:18 UTC
Thanks. I have been aware of this, it's a new test failure in the bundled "salsa" crate since Rust 1.84.
It looks like they are harmless formatting / string differences in generated code.

I'll just ignore those tests if they aren't fixed by the time I need to submit the next update.

Comment 6 Ben Beasley 2025-02-24 12:29:18 UTC
This has started to work in Rawhide again. Either one of these updates (https://koschei.fedoraproject.org/build/19902230) fixed it, or (less likely) the failure might be flaky. Building ruff takes too long for me to want to prove definitively which is the case right now.

Comment 7 Fabio Valentini 2025-02-24 17:15:43 UTC
Yeah, I "fixed" this by adding this line:
https://src.fedoraproject.org/rpms/ruff/blob/rawhide/f/ruff.spec#_177
The trybuild tests in the bundled "salsa" crate are brittle, I don't want to keep babysitting them.


Note You need to log in before you can comment on or make changes to this bug.