Skip to content

add nix flake

add nix flake #112

Triggered via push March 5, 2024 05:38
Status Failure
Total duration 1m 44s
Artifacts

test.yml

on: push
Fit to window
Zoom out
Zoom in

Annotations

2 errors and 36 warnings
this loop never actually loops: pm64/src/bgm/de.rs#L532
error: this loop never actually loops --> pm64/src/bgm/de.rs:532:9 | 532 | / for (offset, command) in commands.0.split_off(&OffsetEventMap::atob(size)).into_iter() { 533 | | panic!("command after end of parsed sequence {:?} @ {:#X}", command, offset); 534 | | } | |_________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#never_loop = note: `#[deny(clippy::never_loop)]` on by default help: if you need the first element of the iterator, try writing | 532 | if let Some((offset, command)) = commands.0.split_off(&OffsetEventMap::atob(size)).into_iter().next() { | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lint
Clippy had exited with the 101 exit code
test
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v2, actions-rs/toolchain@v1, Swatinem/rust-cache@v1, actions-rs/cargo@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, Swatinem/rust-cache@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `save-state` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `save-state` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `save-state` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
using `SeekFrom::Current` to start from current position: pm64/src/rw.rs#L10
warning: using `SeekFrom::Current` to start from current position --> pm64/src/rw.rs:10:9 | 10 | self.seek(SeekFrom::Current(0)) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `self.stream_position()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#seek_from_current = note: `#[warn(clippy::seek_from_current)]` on by default
unnecessary use of `get(&id).is_none()`: pm64/src/bgm/mod.rs#L94
warning: unnecessary use of `get(&id).is_none()` --> pm64/src/bgm/mod.rs:94:40 | 94 | debug_assert!(self.track_lists.get(&id).is_none()); | -----------------^^^^^^^^^^^^^^^^^^ | | | help: replace it with: `!self.track_lists.contains_key(&id)` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check = note: `#[warn(clippy::unnecessary_get_then_check)]` on by default
casting to the same type is unnecessary (`usize` -> `usize`): pm64/src/bgm/cmd.rs#L682
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> pm64/src/bgm/cmd.rs:682:42 | 682 | self.current_time += *delta_time as usize; | ^^^^^^^^^^^^^^^^^^^^ help: try: `*delta_time` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
casting to the same type is unnecessary (`usize` -> `usize`): pm64/src/bgm/cmd.rs#L354
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> pm64/src/bgm/cmd.rs:354:33 | 354 | current_time += *delta_time as usize; | ^^^^^^^^^^^^^^^^^^^^ help: try: `*delta_time` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
casting to the same type is unnecessary (`usize` -> `usize`): pm64/src/bgm/cmd.rs#L191
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> pm64/src/bgm/cmd.rs:191:55 | 191 | Command::Delay { value: delta } => time + delta as usize, | ^^^^^^^^^^^^^^ help: try: `delta` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
casting to the same type is unnecessary (`usize` -> `usize`): pm64/src/bgm/cmd.rs#L178
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> pm64/src/bgm/cmd.rs:178:25 | 178 | time += *delta_time as usize; | ^^^^^^^^^^^^^^^^^^^^ help: try: `*delta_time` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
casting to the same type is unnecessary (`usize` -> `usize`): pm64/src/bgm/cmd.rs#L110
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> pm64/src/bgm/cmd.rs:110:35 | 110 | delta_time += *t as usize; | ^^^^^^^^^^^ help: try: `*t` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
casting to the same type is unnecessary (`usize` -> `usize`): pm64/src/bgm/midi.rs#L419
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> pm64/src/bgm/midi.rs:419:74 | 419 | ... length: convert_time(length as usize, time_divisor) as u16, | ^^^^^^^^^^^^^^^ help: try: `length` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
casting to the same type is unnecessary (`usize` -> `usize`): pm64/src/bgm/midi.rs#L257
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> pm64/src/bgm/midi.rs:257:66 | 257 | ... length: convert_time(length as usize, time_divisor) as u16, | ^^^^^^^^^^^^^^^ help: try: `length` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast = note: `#[warn(clippy::unnecessary_cast)]` on by default
accessing first element with `smf.tracks.get(0)`: pm64/src/bgm/midi.rs#L61
warning: accessing first element with `smf.tracks.get(0)` --> pm64/src/bgm/midi.rs:61:17 | 61 | smf.tracks.get(0), | ^^^^^^^^^^^^^^^^^ help: try: `smf.tracks.first()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first = note: `#[warn(clippy::get_first)]` on by default
iterating on a map's values: pm64/src/bgm/de.rs#L599
warning: iterating on a map's values --> pm64/src/bgm/de.rs:599:9 | 599 | map.0.into_iter().map(|(_, cmd)| cmd).collect() | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `map.0.into_values()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_kv_map = note: `#[warn(clippy::iter_kv_map)]` on by default
manual backwards iteration: pm64/src/bgm/de.rs#L590
warning: manual backwards iteration --> pm64/src/bgm/de.rs:590:20 | 590 | .iter() | ____________________^ 591 | | .rev() 592 | | .next() //self.0.last_key_value() | |___________________^ help: use: `.next_back()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_next_back = note: `#[warn(clippy::manual_next_back)]` on by default
useless conversion to the same type: `std::ops::Range<u16>`: pm64/src/bgm/de.rs#L220
warning: useless conversion to the same type: `std::ops::Range<u16>` --> pm64/src/bgm/de.rs:220:31 | 220 | bgm.instruments = (0..voices_count) | _______________________________^ 221 | | .into_iter() | |____________________________^ help: consider removing `.into_iter()`: `(0..voices_count)` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
useless conversion to the same type: `std::ops::Range<u16>`: pm64/src/bgm/de.rs#L212
warning: useless conversion to the same type: `std::ops::Range<u16>` --> pm64/src/bgm/de.rs:212:25 | 212 | bgm.drums = (0..drums_count) | _________________________^ 213 | | .into_iter() | |____________________________^ help: consider removing `.into_iter()`: `(0..drums_count)` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
useless conversion to the same type: `std::ops::Range<i32>`: pm64/src/bgm/de.rs#L150
warning: useless conversion to the same type: `std::ops::Range<i32>` --> pm64/src/bgm/de.rs:150:43 | 150 | let variation_offsets: Vec<u16> = (0..4) | ___________________________________________^ 151 | | .into_iter() | |________________________^ help: consider removing `.into_iter()`: `(0..4)` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
useless conversion to the same type: `std::ops::Range<usize>`: pm64/src/bgm/en.rs#L77
warning: useless conversion to the same type: `std::ops::Range<usize>` --> pm64/src/bgm/en.rs:77:31 | 77 | let segment_offsets = (0..self.variations.len()) | _______________________________^ 78 | | .into_iter() | |________________________^ help: consider removing `.into_iter()`: `(0..self.variations.len())` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion = note: `#[warn(clippy::useless_conversion)]` on by default
method `write_cstring_lossy` is never used: pm64/src/rw.rs#L87
warning: method `write_cstring_lossy` is never used --> pm64/src/rw.rs:87:8 | 82 | pub trait WriteExt: Write + Seek { | -------- method in this trait ... 87 | fn write_cstring_lossy(&mut self, string: &str, max_len: usize) -> Result<()>; // len includes null terminator | ^^^^^^^^^^^^^^^^^^^
method `read_i16_be` is never used: pm64/src/rw.rs#L18
warning: method `read_i16_be` is never used --> pm64/src/rw.rs:18:8 | 14 | pub trait ReadExt: Read { | ------- method in this trait ... 18 | fn read_i16_be(&mut self) -> Result<i16>; | ^^^^^^^^^^^
method `collect_array` is never used: pm64/src/bgm/de.rs#L71
warning: method `collect_array` is never used --> pm64/src/bgm/de.rs:71:8 | 68 | trait CollectArray<T, E, U: Default + AsMut<[T]>>: Sized + Iterator<Item = Result<T, E>> { | ------------ method in this trait ... 71 | fn collect_array(mut self) -> Result<U, E> { | ^^^^^^^^^^^^^ | = note: `#[warn(dead_code)]` on by default
the item `HashMap` is imported redundantly: pm64/src/bgm/en.rs#L1
warning: the item `HashMap` is imported redundantly --> pm64/src/bgm/en.rs:1:5 | 1 | use std::collections::HashMap; | ^^^^^^^^^^^^^^^^^^^^^^^^^ ... 8 | use super::*; | -------- the item `HashMap` is already imported here | = note: `#[warn(unused_imports)]` on by default
lint
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1, jetli/[email protected], actions-rs/clippy-check@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
lint
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1, jetli/[email protected], 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/
lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/