chimei-ruiju.orgへの対応: repository
にchimei-ruiju用の構造体を定義
#77
Annotations
5 warnings
The following actions use a deprecated Node.js version and will be forced to run on node20: giraffate/clippy-action@v1. For more info: https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/
|
Code review with clippy:
core/src/domain/chimei_ruiju/error.rs#L4
[clippy] reported by reviewdog 🐶
<pre><code>warning: variants `Network`, `NotFound`, and `Deserialize` are never constructed
--> core/src/domain/chimei_ruiju/error.rs:6:5
|
4 | pub enum ApiError {
| -------- variants in this enum
5 | #[error("network error occurs: {url}")]
6 | Network { url: String },
| ^^^^^^^
7 | #[error("resource not found: {url}")]
8 | NotFound { url: String },
| ^^^^^^^^
9 | #[error("deserialize error occurs: {url}")]
10 | Deserialize { url: String },
| ^^^^^^^^^^^
|
= note: `ApiError` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis
</code></pre>
Raw Output:
core/src/domain/chimei_ruiju/error.rs:4:10:w:
<pre><code>warning: variants `Network`, `NotFound`, and `Deserialize` are never constructed
--> core/src/domain/chimei_ruiju/error.rs:6:5
|
4 | pub enum ApiError {
| -------- variants in this enum
5 | #[error("network error occurs: {url}")]
6 | Network { url: String },
| ^^^^^^^
7 | #[error("resource not found: {url}")]
8 | NotFound { url: String },
| ^^^^^^^^
9 | #[error("deserialize error occurs: {url}")]
10 | Deserialize { url: String },
| ^^^^^^^^^^^
|
= note: `ApiError` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis
</code></pre>
__END__
|
Code review with clippy:
core/src/service/chimei_ruiju.rs#L7
[clippy] reported by reviewdog 🐶
<pre><code>warning: method `get` is never used
--> core/src/service/chimei_ruiju.rs:8:18
|
7 | impl ChimeiRuijuApiService {
| -------------------------- method in this implementation
8 | pub async fn get<T>(&self, url: &str) -> Result<T, ApiError>
| ^^^
</code></pre>
Raw Output:
core/src/service/chimei_ruiju.rs:7:1:w:
<pre><code>warning: method `get` is never used
--> core/src/service/chimei_ruiju.rs:8:18
|
7 | impl ChimeiRuijuApiService {
| -------------------------- method in this implementation
8 | pub async fn get<T>(&self, url: &str) -> Result<T, ApiError>
| ^^^
</code></pre>
__END__
|
Code review with clippy:
core/src/service/chimei_ruiju.rs#L30
[clippy] reported by reviewdog 🐶
<pre><code>warning: method `get_blocking` is never used
--> core/src/service/chimei_ruiju.rs:31:12
|
30 | impl ChimeiRuijuApiService {
| -------------------------- method in this implementation
31 | pub fn get_blocking<T>(&self, url: &str) -> Result<T, ApiError>
| ^^^^^^^^^^^^
</code></pre>
Raw Output:
core/src/service/chimei_ruiju.rs:30:1:w:
<pre><code>warning: method `get_blocking` is never used
--> core/src/service/chimei_ruiju.rs:31:12
|
30 | impl ChimeiRuijuApiService {
| -------------------------- method in this implementation
31 | pub fn get_blocking<T>(&self, url: &str) -> Result<T, ApiError>
| ^^^^^^^^^^^^
</code></pre>
__END__
|
Code review with clippy:
wasm/src/lib.rs#L42
[clippy] reported by reviewdog 🐶
<pre><code>warning: you should consider adding a `Default` implementation for `Parser`
--> wasm/src/lib.rs:42:5
|
42 | / pub fn new() -> Self {
43 | | #[cfg(feature = "debug")]
44 | | console_error_panic_hook::set_once();
45 | | Parser {
46 | | async_api: Arc::new(Default::default()),
47 | | }
48 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default
note: the lint level is defined here
--> wasm/src/lib.rs:38:8
|
38 | #[warn(clippy::new_without_default)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
help: try adding this
|
40 + impl Default for Parser {
41 + fn default() -> Self {
42 + Self::new()
43 + }
44 + }
|
</code></pre>
Raw Output:
wasm/src/lib.rs:42:5:w:
<pre><code>warning: you should consider adding a `Default` implementation for `Parser`
--> wasm/src/lib.rs:42:5
|
42 | / pub fn new() -> Self {
43 | | #[cfg(feature = "debug")]
44 | | console_error_panic_hook::set_once();
45 | | Parser {
46 | | async_api: Arc::new(Default::default()),
47 | | }
48 | | }
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default
note: the lint level is defined here
--> wasm/src/lib.rs:38:8
|
38 | #[warn(clippy::new_without_default)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
help: try adding this
|
40 + impl Default for Parser {
41 + fn default() -> Self {
42 + Self::new()
43 + }
44 + }
|
</code></pre>
__END__
|
Loading