Skip to content

most of it works

most of it works #89

Triggered via push November 4, 2023 16:28
Status Failure
Total duration 1m 18s
Artifacts

build.yml

on: push
Matrix: build
Fit to window
Zoom out
Zoom in

Annotations

7 errors and 34 warnings
this `else { if .. }` block can be collapsed: src/model/servertoml/mod.rs#L119
error: this `else { if .. }` block can be collapsed --> src/model/servertoml/mod.rs:119:20 | 119 | } else { | ____________________^ 120 | | if is_vanilla { 121 | | v.loaders.contains(&"datapack".to_owned()) 122 | | } else { 123 | | true 124 | | } 125 | | } | |_____________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_else_if help: collapse nested if block | 119 ~ } else if is_vanilla { 120 + v.loaders.contains(&"datapack".to_owned()) 121 + } else { 122 + true 123 + } |
this `else { if .. }` block can be collapsed: src/app/mod.rs#L111
error: this `else { if .. }` block can be collapsed --> src/app/mod.rs:111:20 | 111 | } else { | ____________________^ 112 | | if k.starts_with("NW_") { 113 | | if let Some(nw) = &self.network { 114 | | nw.variables.get(k.strip_prefix("NW_").unwrap()).cloned() ... | 120 | | } 121 | | } | |_____________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_else_if note: the lint level is defined here --> src/main.rs:1:9 | 1 | #![deny(clippy::all)] | ^^^^^^^^^^^ = note: `#[deny(clippy::collapsible_else_if)]` implied by `#[deny(clippy::all)]` help: collapse nested if block | 111 ~ } else if k.starts_with("NW_") { 112 + if let Some(nw) = &self.network { 113 + nw.variables.get(k.strip_prefix("NW_").unwrap()).cloned() 114 + } else { 115 + None 116 + } 117 + } else { 118 + self.server.variables.get(k).cloned() 119 + } |
unresolved import `notify::ReadDirectoryChangesWatcher`: src/hot_reload/mod.rs#L6
error[E0432]: unresolved import `notify::ReadDirectoryChangesWatcher` --> src/hot_reload/mod.rs:6:70 | 6 | use notify::{recommended_watcher, EventKind, Watcher, RecursiveMode, ReadDirectoryChangesWatcher}; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ no `ReadDirectoryChangesWatcher` in the root | = help: consider importing this variant instead: notify::WatcherKind::ReadDirectoryChangesWatcher note: found an item that was configured out --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/notify-6.0.1/src/lib.rs:201:18 | 201 | pub use windows::ReadDirectoryChangesWatcher; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: the item is gated behind the `windows` feature
clippy
Clippy had exited with the 101 exit code
build (ubuntu-latest)
Process completed with exit code 101.
build (windows-latest)
The job was canceled because "ubuntu-latest" failed.
build (windows-latest)
The operation was canceled.
unused import: `Watcher`: src/hot_reload/mod.rs#L6
warning: unused import: `Watcher` --> src/hot_reload/mod.rs:6:46 | 6 | use notify::{recommended_watcher, EventKind, Watcher, RecursiveMode, ReadDirectoryChangesWatcher}; | ^^^^^^^
value assigned to `is_stopping` is never read: src/hot_reload/mod.rs#L112
warning: value assigned to `is_stopping` is never read --> src/hot_reload/mod.rs:112:29 | 112 | ... is_stopping = true; | ^^^^^^^^^^^ | = help: maybe it is overwritten before being read? = note: `#[warn(unused_assignments)]` on by default
unused variable: `resolved`: src/core/worlds.rs#L49
warning: unused variable: `resolved` --> src/core/worlds.rs:49:28 | 49 | let (path, resolved) = self.downloadable(dl, ".mcman-cache", Some(progress_bar)).await?; | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_resolved`
unused variable: `query`: src/commands/add/modrinth.rs#L17
warning: unused variable: `query` --> src/commands/add/modrinth.rs:17:9 | 17 | let query = if let Some(s) = args.search { | ^^^^^ help: if this is intentional, prefix it with an underscore: `_query`
unreachable expression: src/commands/add/modrinth.rs#L165
warning: unreachable expression --> src/commands/add/modrinth.rs:165:5 | 23 | todo!(); | ------- any code following this expression is unreachable ... 165 | Ok(()) | ^^^^^^ unreachable expression
unused variable: `test_mode`: src/commands/run.rs#L17
warning: unused variable: `test_mode` --> src/commands/run.rs:17:9 | 17 | let test_mode = args.test; | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_test_mode`
unused variable: `ctx`: src/commands/run.rs#L15
warning: unused variable: `ctx` --> src/commands/run.rs:15:13 | 15 | let mut ctx = super::build::run(app, args.build_args).await?; | ^^^ help: if this is intentional, prefix it with an underscore: `_ctx`
unused variable: `cf_usecdn`: src/commands/export/packwiz.rs#L21
warning: unused variable: `cf_usecdn` --> src/commands/export/packwiz.rs:21:9 | 21 | let cf_usecdn = args.cfcdn; | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_cf_usecdn`
unused variable: `output_dir`: src/commands/export/packwiz.rs#L19
warning: unused variable: `output_dir` --> src/commands/export/packwiz.rs:19:9 | 19 | let output_dir = args.output.unwrap_or(default_output); | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_dir` | = note: `#[warn(unused_variables)]` on by default
unreachable expression: src/commands/export/packwiz.rs#L25
warning: unreachable expression --> src/commands/export/packwiz.rs:25:5 | 23 | todo!(); | ------- any code following this expression is unreachable 24 | 25 | Ok(()) | ^^^^^^ unreachable expression | = note: `#[warn(unreachable_code)]` on by default
unused imports: `app::App`, `model::Lockfile`: src/hot_reload/mod.rs#L10
warning: unused imports: `app::App`, `model::Lockfile` --> src/hot_reload/mod.rs:10:33 | 10 | use crate::{core::BuildContext, model::Lockfile, app::App}; | ^^^^^^^^^^^^^^^ ^^^^^^^^
unused import: `task::JoinHandle`: src/hot_reload/mod.rs#L8
warning: unused import: `task::JoinHandle` --> src/hot_reload/mod.rs:8:74 | 8 | use tokio::{io::{AsyncBufReadExt, AsyncWriteExt, BufReader}, sync::mpsc, task::JoinHandle, process::Child}; | ^^^^^^^^^^^^^^^^
unused import: `Theme`: src/hot_reload/mod.rs#L5
warning: unused import: `Theme` --> src/hot_reload/mod.rs:5:32 | 5 | use dialoguer::{Input, theme::{Theme, SimpleTheme}}; | ^^^^^
unused import: `Context`: src/hot_reload/mod.rs#L3
warning: unused import: `Context` --> src/hot_reload/mod.rs:3:22 | 3 | use anyhow::{Result, Context}; | ^^^^^^^
unused import: `commands`: src/model/servertoml/mod.rs#L12
warning: unused import: `commands` --> src/model/servertoml/mod.rs:12:13 | 12 | use crate::{commands, sources::modrinth}; | ^^^^^^^^
unused import: `Context`: src/model/servertoml/mod.rs#L9
warning: unused import: `Context` --> src/model/servertoml/mod.rs:9:28 | 9 | use anyhow::{anyhow, bail, Context, Result}; | ^^^^^^^
unused import: `console::style`: src/core/scripts.rs#L4
warning: unused import: `console::style` --> src/core/scripts.rs:4:5 | 4 | use console::style; | ^^^^^^^^^^^^^^
unused import: `crate::app::App`: src/core/runner.rs#L13
warning: unused import: `crate::app::App` --> src/core/runner.rs:13:5 | 13 | use crate::app::App; | ^^^^^^^^^^^^^^^
unused imports: `RwLock`, `mpsc`: src/core/runner.rs#L11
warning: unused imports: `RwLock`, `mpsc` --> src/core/runner.rs:11:28 | 11 | use tokio::sync::{oneshot, RwLock, mpsc}; | ^^^^^^ ^^^^
unused imports: `ChildStderr`, `ChildStdin`, `ChildStdout`, `Child`, `Stdio`: src/core/runner.rs#L3
warning: unused imports: `ChildStderr`, `ChildStdin`, `ChildStdout`, `Child`, `Stdio` --> src/core/runner.rs:3:27 | 3 | process::{ExitStatus, Stdio, Child, ChildStdin, ChildStdout, ChildStderr}, | ^^^^^ ^^^^^ ^^^^^^^^^^ ^^^^^^^^^^^ ^^^^^^^^^^^
unused import: `Context`: src/core/addons.rs#L3
warning: unused import: `Context` --> src/core/addons.rs:3:14 | 3 | use anyhow::{Context, Result}; | ^^^^^^^
unused imports: `Downloadable`, `Server`, `SoftwareType`, `sources::modrinth`, `util::SelectItem`: src/commands/add/modrinth.rs#L6
warning: unused imports: `Downloadable`, `Server`, `SoftwareType`, `sources::modrinth`, `util::SelectItem` --> src/commands/add/modrinth.rs:6:13 | 6 | model::{Downloadable, Server, SoftwareType}, | ^^^^^^^^^^^^ ^^^^^^ ^^^^^^^^^^^^ 7 | sources::modrinth, | ^^^^^^^^^^^^^^^^^ 8 | util::SelectItem, app::App, | ^^^^^^^^^^^^^^^^
unused imports: `Input`, `Select`, `theme::ColorfulTheme`: src/commands/add/modrinth.rs#L3
warning: unused imports: `Input`, `Select`, `theme::ColorfulTheme` --> src/commands/add/modrinth.rs:3:17 | 3 | use dialoguer::{theme::ColorfulTheme, Input, Select}; | ^^^^^^^^^^^^^^^^^^^^ ^^^^^ ^^^^^^
unused import: `console::style`: src/commands/add/modrinth.rs#L2
warning: unused import: `console::style` --> src/commands/add/modrinth.rs:2:5 | 2 | use console::style; | ^^^^^^^^^^^^^^
unused imports: `Context`, `bail`: src/commands/add/modrinth.rs#L1
warning: unused imports: `Context`, `bail` --> src/commands/add/modrinth.rs:1:14 | 1 | use anyhow::{bail, Context, Result}; | ^^^^ ^^^^^^^
unused imports: `Context`, `anyhow`: src/commands/run.rs#L1
warning: unused imports: `Context`, `anyhow` --> src/commands/run.rs:1:14 | 1 | use anyhow::{anyhow, Context, Result}; | ^^^^^^ ^^^^^^^
unused imports: `Downloadable`, `Server`: src/commands/import/datapack.rs#L6
warning: unused imports: `Downloadable`, `Server` --> src/commands/import/datapack.rs:6:13 | 6 | model::{Downloadable, Server}, app::App, | ^^^^^^^^^^^^ ^^^^^^
unused import: `dialoguer::Input`: src/commands/import/datapack.rs#L3
warning: unused import: `dialoguer::Input` --> src/commands/import/datapack.rs:3:5 | 3 | use dialoguer::Input; | ^^^^^^^^^^^^^^^^
unused import: `console::style`: src/commands/import/datapack.rs#L2
warning: unused import: `console::style` --> src/commands/import/datapack.rs:2:5 | 2 | use console::style; | ^^^^^^^^^^^^^^
unused import: `Context`: src/commands/import/datapack.rs#L1
warning: unused import: `Context` --> src/commands/import/datapack.rs:1:14 | 1 | use anyhow::{Context, Result}; | ^^^^^^^
unused import: `Context`: src/commands/export/packwiz.rs#L3
warning: unused import: `Context` --> src/commands/export/packwiz.rs:3:14 | 3 | use anyhow::{Context, Result}; | ^^^^^^^
unused import: `model::Server`: src/commands/env/docker.rs#L5
warning: unused import: `model::Server` --> src/commands/env/docker.rs:5:5 | 5 | model::Server, | ^^^^^^^^^^^^^
unused import: `console::style`: src/commands/env/docker.rs#L2
warning: unused import: `console::style` --> src/commands/env/docker.rs:2:5 | 2 | use console::style; | ^^^^^^^^^^^^^^ | = note: `#[warn(unused_imports)]` on by default
clippy
The following actions uses node12 which is deprecated and will be forced to run on node16: actions-rs/clippy-check@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/