Bug#1143751: debian-codemods: FTBFS: error[E0277]: the trait bound Vec<Box<dyn DebianBuildFixer>>: AsRef<dyn DebianBuildFixer> is not satisfied
| Newsgroups | gmane.linux.debian.devel.bugs.rc |
|---|---|
| Message-ID | <[email protected]> |
0.183 fails because ognibuild's default_fixers() changed from returning a Vec to returning a Result somewhere between 0.2.15 and 0.2.19. main.rs still treats it as a Vec, which is where the AsRef error comes from. The fix already exists in git but hasn't been released: https://salsa.debian.org/jelmer/debian-codemods/-/commit/5af42ff70ab029d13cfb4e54d50a4e1628b41357 Attached is just that fix, isolated and tested against 0.183 - it builds clean.
1143751-fix.patch
(application/octet-stream, 649 B)
diff --git a/debianize/src/main.rs b/debianize/src/main.rs
index 95c9e277..4ee5cc9b 100644
--- a/debianize/src/main.rs
+++ b/debianize/src/main.rs
@@ -641,7 +641,8 @@ fn main() -> Result<(), i32> {
false,
Some(Box::new(breezyshim::commit::ReportCommitToLog::new())),
);
- let fixers = ognibuild::debian::fixers::default_fixers(&context, &apt);
+ let fixers = ognibuild::debian::fixers::default_fixers(&context, &apt)
+ .map_err(IterateBuildError::Other)?;
ognibuild::debian::fix_build::build_incrementally(
wt,
None,