Never crash: deny panic lints in the already-clean crates and apps
These crates have no production panic sites: add the deny attribute so they stay clean (geom, color, model, automation, host, export, plugin, and the desktop, CLI and web apps). The plugin's wasm-only test module gets a separate cfg(test) attribute so clippy recognises it as test code. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
10644a83aa
commit
c5e33f1a02
|
|
@ -34,6 +34,8 @@
|
||||||
//! `<comp>` is a comp id or name (`-` = the active comp); `<layer>` an id, `#n` or name; `<value>`
|
//! `<comp>` is a comp id or name (`-` = the active comp); `<layer>` an id, `#n` or name; `<value>`
|
||||||
//! is JSON (`50`, `[960,540]`, `"#ff0000"`) or a bare string. See `docs/agents.md`.
|
//! is JSON (`50`, `[960,540]`, `"#ff0000"`) or a bare string. See `docs/agents.md`.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
use effectcraft_automation::tools::{self, Reply};
|
use effectcraft_automation::tools::{self, Reply};
|
||||||
use effectcraft_automation::{Backend, McpServer};
|
use effectcraft_automation::{Backend, McpServer};
|
||||||
use serde_json::{Value, json};
|
use serde_json::{Value, json};
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,8 @@
|
||||||
//!
|
//!
|
||||||
//! [`store`] is portable (unit-tested natively); everything else is `wasm32`-only.
|
//! [`store`] is portable (unit-tested natively); everything else is `wasm32`-only.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
pub mod store;
|
pub mod store;
|
||||||
|
|
||||||
#[cfg(target_arch = "wasm32")]
|
#[cfg(target_arch = "wasm32")]
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,8 @@
|
||||||
//! `--control <port>` (or `EFFECTCRAFT_CONTROL_PORT`) starts a localhost JSON-lines control server;
|
//! `--control <port>` (or `EFFECTCRAFT_CONTROL_PORT`) starts a localhost JSON-lines control server;
|
||||||
//! see `effectcraft_ui_egui::control` for the methods.
|
//! see `effectcraft_ui_egui::control` for the methods.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
mod audio_out;
|
mod audio_out;
|
||||||
mod control_server;
|
mod control_server;
|
||||||
#[cfg(target_os = "macos")]
|
#[cfg(target_os = "macos")]
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,4 @@
|
||||||
|
allow-unwrap-in-tests = true
|
||||||
|
allow-expect-in-tests = true
|
||||||
|
allow-panic-in-tests = true
|
||||||
|
allow-indexing-slicing-in-tests = true
|
||||||
|
|
@ -13,6 +13,8 @@
|
||||||
//! Layering: depends on `effectcraft-engine` only (never egui); the CLI injects a fully wired
|
//! Layering: depends on `effectcraft-engine` only (never egui); the CLI injects a fully wired
|
||||||
//! session (`effectcraft_host::session()`).
|
//! session (`effectcraft_host::session()`).
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
pub mod backend;
|
pub mod backend;
|
||||||
pub mod base64;
|
pub mod base64;
|
||||||
pub mod bridge;
|
pub mod bridge;
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,8 @@
|
||||||
//! standard definitions of the "classic" photographic modes; they are applied to un-premultiplied
|
//! standard definitions of the "classic" photographic modes; they are applied to un-premultiplied
|
||||||
//! colour and composited with Porter-Duff source-over on premultiplied pixels.
|
//! colour and composited with Porter-Duff source-over on premultiplied pixels.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
pub mod blend;
|
pub mod blend;
|
||||||
pub mod icc;
|
pub mod icc;
|
||||||
pub mod space;
|
pub mod space;
|
||||||
|
|
|
||||||
|
|
@ -28,6 +28,8 @@
|
||||||
//! H.264 requires even dimensions: odd output sizes are cropped by one pixel (padded when the
|
//! H.264 requires even dimensions: odd output sizes are cropped by one pixel (padded when the
|
||||||
//! output is a single pixel wide/high).
|
//! output is a single pixel wide/high).
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
mod encode;
|
mod encode;
|
||||||
mod hevc_av1;
|
mod hevc_av1;
|
||||||
mod out;
|
mod out;
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,8 @@
|
||||||
//! clockwise on screen, 3D uses a left-handed system with +z pointing into the screen, and a 3D
|
//! clockwise on screen, 3D uses a left-handed system with +z pointing into the screen, and a 3D
|
||||||
//! layer's rotation is Orientation (X, Y, Z) followed by X Rotation, Y Rotation, Z Rotation.
|
//! layer's rotation is Orientation (X, Y, Z) followed by X Rotation, Y Rotation, Z Rotation.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
use std::ops::{Add, AddAssign, Div, Mul, MulAssign, Neg, Sub, SubAssign};
|
use std::ops::{Add, AddAssign, Div, Mul, MulAssign, Neg, Sub, SubAssign};
|
||||||
|
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,8 @@
|
||||||
//! Render Queue export through `effectcraft-export` (FilmCraft's encoders). Frontends (desktop,
|
//! Render Queue export through `effectcraft-export` (FilmCraft's encoders). Frontends (desktop,
|
||||||
//! CLI, MCP, web) start here.
|
//! CLI, MCP, web) start here.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
use std::sync::Arc;
|
use std::sync::Arc;
|
||||||
|
|
||||||
use effectcraft_engine::project::render_queue::OutputFormat;
|
use effectcraft_engine::project::render_queue::OutputFormat;
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,8 @@
|
||||||
//! Models are in their own units with +Y up (glTF's convention); the renderer maps them into
|
//! Models are in their own units with +Y up (glTF's convention); the renderer maps them into
|
||||||
//! After Effects' Y-down pixel space.
|
//! After Effects' Y-down pixel space.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
pub mod extrude;
|
pub mod extrude;
|
||||||
pub mod gltf;
|
pub mod gltf;
|
||||||
pub mod obj;
|
pub mod obj;
|
||||||
|
|
|
||||||
|
|
@ -22,6 +22,8 @@
|
||||||
//! differently on another machine. The runtime is the `wasm` feature (on for the desktop app and
|
//! differently on another machine. The runtime is the `wasm` feature (on for the desktop app and
|
||||||
//! the CLI); without it [`load_wasm`] says plug-ins are unavailable.
|
//! the CLI); without it [`load_wasm`] says plug-ins are unavailable.
|
||||||
|
|
||||||
|
#![deny(clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable)]
|
||||||
|
|
||||||
use effectcraft_effects::EffectSpec;
|
use effectcraft_effects::EffectSpec;
|
||||||
pub use effectcraft_effects::plugin::{EffectPlugin, PLUGIN_API_VERSION, PluginFrame, PluginManifest, PluginParams, register_plugin};
|
pub use effectcraft_effects::plugin::{EffectPlugin, PLUGIN_API_VERSION, PluginFrame, PluginManifest, PluginParams, register_plugin};
|
||||||
|
|
||||||
|
|
@ -62,5 +64,7 @@ pub fn loader(bytes: &[u8], source: &str) -> Result<serde_json::Value, String> {
|
||||||
}))
|
}))
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(all(test, feature = "wasm"))]
|
// Two attributes, so clippy sees `cfg(test)` and treats the module as test code.
|
||||||
|
#[cfg(test)]
|
||||||
|
#[cfg(feature = "wasm")]
|
||||||
mod tests;
|
mod tests;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue