Skip to content

update installer and workflow #58

update installer and workflow

update installer and workflow #58

GitHub Actions / clippy succeeded Dec 28, 2023 in 0s

clippy

6 warnings

Details

Results

Message level Amount
Internal compiler error 0
Error 0
Warning 6
Note 0
Help 0

Versions

  • rustc 1.75.0 (82e1608df 2023-12-21)
  • cargo 1.75.0 (1d8b05cdd 2023-11-20)
  • clippy 0.1.75 (82e1608 2023-12-21)

Annotations

Check warning on line 37 in bin/nanocld/src/utils/job.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

accessing first element with `state .config .hosts.get(0)`

warning: accessing first element with `state
             .config
             .hosts.get(0)`
  --> bin/nanocld/src/utils/job.rs:34:14
   |
34 |     let host = state
   |  ______________^
35 | |     .config
36 | |     .hosts
37 | |     .get(0)
   | |___________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first
help: try
   |
34 ~   let host = state
35 +     .config
36 +     .hosts.first()
   |

Check warning on line 104 in bin/nanocld/src/utils/namespace.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

accessing first element with `ipam_config.get(0)`

warning: accessing first element with `ipam_config.get(0)`
   --> bin/nanocld/src/utils/namespace.rs:103:19
    |
103 |       let gateway = ipam_config
    |  ___________________^
104 | |       .get(0)
    | |_____________^ help: try: `ipam_config.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

Check warning on line 126 in bin/nanocl/src/models/cargo_image.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

accessing first element with `value .repo_tags.get(0)`

warning: accessing first element with `value
               .repo_tags.get(0)`
   --> bin/nanocl/src/models/cargo_image.rs:124:19
    |
124 |       let binding = value
    |  ___________________^
125 | |       .repo_tags
126 | |       .get(0)
    | |_____________^
    |
    = 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
help: try
    |
124 ~     let binding = value
125 +       .repo_tags.first()
    |

Check warning on line 124 in bin/ncproxy/src/subsystem/metric.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

accessing first element with `event.paths.get(0)`

warning: accessing first element with `event.paths.get(0)`
   --> bin/ncproxy/src/subsystem/metric.rs:124:19
    |
124 |       let path = &event.paths.get(0);
    |                   ^^^^^^^^^^^^^^^^^^ help: try: `event.paths.first()`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first

Check warning on line 19 in bin/ncdns/src/utils.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

accessing first element with `configs.get(0)`

warning: accessing first element with `configs.get(0)`
  --> bin/ncdns/src/utils.rs:19:16
   |
19 |   let config = configs.get(0).ok_or(IoError::not_found(
   |                ^^^^^^^^^^^^^^ help: try: `configs.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

Check warning on line 126 in bin/nanocl/./src/models/cargo_image.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

accessing first element with `value .repo_tags.get(0)`

warning: accessing first element with `value
               .repo_tags.get(0)`
   --> bin/nanocl/./src/models/cargo_image.rs:124:19
    |
124 |       let binding = value
    |  ___________________^
125 | |       .repo_tags
126 | |       .get(0)
    | |_____________^
    |
    = 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
help: try
    |
124 ~     let binding = value
125 +       .repo_tags.first()
    |