Skip to content

@remotion/compositor: Fix operation not permitted error in compositor #5354

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 5, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified packages/compositor-darwin-arm64/remotion
Binary file not shown.
Binary file modified packages/compositor-darwin-x64/remotion
Binary file not shown.
Binary file modified packages/compositor-linux-arm64-gnu/remotion
Binary file not shown.
Binary file modified packages/compositor-linux-arm64-musl/remotion
Binary file not shown.
Binary file modified packages/compositor-linux-x64-gnu/remotion
Binary file not shown.
Binary file modified packages/compositor-linux-x64-musl/remotion
Binary file not shown.
1 change: 0 additions & 1 deletion packages/compositor/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ function isMusl() {
}

const targets = [
'x86_64-pc-windows-gnu',
'x86_64-unknown-linux-musl',
'aarch64-unknown-linux-gnu',
'x86_64-unknown-linux-gnu',
Expand Down
27 changes: 24 additions & 3 deletions packages/compositor/rust/opened_stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -304,16 +304,37 @@ impl OpenedStream {
let new_position_to_seek_to = pts - 1;
stop_after_n_diverging_pts = None;

self.input.seek(
let res = self.input.seek(
self.stream_index as i32,
0,
pts,
new_position_to_seek_to,
0,
)?;
);
match res {
Ok(_) => {}
Err(err) => {
if err.to_string().contains("Operation not permitted") {
_print_verbose(&format!(
"Could not perform seek. Got 'Operation not permitted' error."
))?;
_print_verbose(&format!("Attempting to seek to the beginning of the file."))?;
self.input.seek(
self.stream_index as i32,
0,
pts,
new_position_to_seek_to,
AVSEEK_FLAG_ANY ,
)?;
}
else {
panic!("{}", err.to_string());
}
}
}
}
None => {}
}
};
continue;
}
}
Expand Down
2 changes: 1 addition & 1 deletion packages/renderer/src/compositor/compositor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ export const startCompositor = <T extends keyof CompositorCommand>({
runningStatus.signal
? ` with signal ${runningStatus.signal}`
: ''
}: ${runningStatus.error}`,
}: ${runningStatus.error.trim()}`,
),
);
return;
Expand Down
Loading