* [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow
@ 2024-08-07 7:43 Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 02/10] apt: clippy: don't clone types implementing Copy Maximiliano Sandoval
` (10 more replies)
0 siblings, 11 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the clippy warning:
warning: this expression borrows a value the compiler would automatically borrow
--> proxmox-apt/src/repositories/file/sources_parser.rs:111:40
|
111 | ... types.push((&package_type[..]).parse()?);
| ^^^^^^^^^^^^^^^^^^^ help: change this to: `package_type[..]`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
= note: `#[warn(clippy::needless_borrow)]` on by default
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-apt/src/repositories/file/sources_parser.rs | 2 +-
proxmox-router/src/cli/completion.rs | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/proxmox-apt/src/repositories/file/sources_parser.rs b/proxmox-apt/src/repositories/file/sources_parser.rs
index 017162bb..2510d107 100644
--- a/proxmox-apt/src/repositories/file/sources_parser.rs
+++ b/proxmox-apt/src/repositories/file/sources_parser.rs
@@ -108,7 +108,7 @@ impl<R: BufRead> APTSourcesFileParser<R> {
}
let mut types = Vec::<APTRepositoryPackageType>::new();
for package_type in values {
- types.push((&package_type[..]).parse()?);
+ types.push((package_type[..]).parse()?);
}
repo.types = types;
}
diff --git a/proxmox-router/src/cli/completion.rs b/proxmox-router/src/cli/completion.rs
index 47444243..5a899eec 100644
--- a/proxmox-router/src/cli/completion.rs
+++ b/proxmox-router/src/cli/completion.rs
@@ -151,7 +151,7 @@ fn get_simple_completion_do(
return get_property_completion(
schema,
prop_name,
- &completion_functions,
+ completion_functions,
&args[0],
done,
);
@@ -198,7 +198,7 @@ fn get_simple_completion_do(
return get_property_completion(
schema,
prop_name,
- &completion_functions,
+ completion_functions,
prefix,
done,
);
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 02/10] apt: clippy: don't clone types implementing Copy
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 03/10] docs: clippy: add indentation to doc list items Maximiliano Sandoval
` (9 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the clippy warnings:
warning: `proxmox-apt` (lib) generated 1 warning
warning: using `clone` on type `Option<[u8; 32]>` which implements the `Copy` trait
--> proxmox-apt/tests/repositories.rs:117:22
|
117 | let old_digest = file.digest.clone().unwrap();
| ^^^^^^^^^^^^^^^^^^^ help: try removing the `clone` call: `file.digest`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
= note: `#[warn(clippy::clone_on_copy)]` on by default
warning: using `clone` on type `[u8; 32]` which implements the `Copy` trait
--> proxmox-apt/tests/repositories.rs:135:24
|
135 | file.digest = Some(old_digest.clone());
| ^^^^^^^^^^^^^^^^^^ help: try removing the `clone` call: `old_digest`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-apt/tests/repositories.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/proxmox-apt/tests/repositories.rs b/proxmox-apt/tests/repositories.rs
index 5211a360..b55bb420 100644
--- a/proxmox-apt/tests/repositories.rs
+++ b/proxmox-apt/tests/repositories.rs
@@ -114,7 +114,7 @@ fn test_digest() -> Result<(), Error> {
let new_path = write_dir.join(path.file_name().unwrap());
file.path = Some(new_path.clone().into_os_string().into_string().unwrap());
- let old_digest = file.digest.clone().unwrap();
+ let old_digest = file.digest.unwrap();
// file does not exist yet...
assert!(file.read_with_digest().is_err());
@@ -132,7 +132,7 @@ fn test_digest() -> Result<(), Error> {
repo.enabled = !repo.enabled;
// ...then it should work
- file.digest = Some(old_digest.clone());
+ file.digest = Some(old_digest);
file.write()?;
// expect a different digest, because the repo was modified
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 03/10] docs: clippy: add indentation to doc list items
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 02/10] apt: clippy: don't clone types implementing Copy Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 04/10] property_string: clippy: define bound once Maximiliano Sandoval
` (8 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the clippy warning:
warning: doc list item missing indentation
--> proxmox-subscription/src/subscription_info.rs:179:9
|
179 | /// (this mode is used to decide whether to refresh the subscription information)
| ^
|
= help: if this is supposed to be its own paragraph, add a blank line
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation
= note: `#[warn(clippy::doc_lazy_continuation)]` on by default
help: indent this line
|
179 | /// (this mode is used to decide whether to refresh the subscription information)
| +
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-auth-api/src/types.rs | 2 +-
proxmox-rest-server/src/worker_task.rs | 2 +-
proxmox-subscription/src/subscription_info.rs | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/proxmox-auth-api/src/types.rs b/proxmox-auth-api/src/types.rs
index 21136824..25e5feff 100644
--- a/proxmox-auth-api/src/types.rs
+++ b/proxmox-auth-api/src/types.rs
@@ -14,7 +14,7 @@
//! * [`TokennameRef`]: a borrowed `Tokenname` (`str` equivalent).
//! * [`Userid`]: an owned user id (`"user@realm"`).
//! * [`Authid`]: an owned Authentication ID (a `Userid` with an optional `Tokenname`).
-//! Note that `Userid` and `Authid` do not have a separate borrowed type.
+//! Note that `Userid` and `Authid` do not have a separate borrowed type.
//!
//! Note that `Username`s are not unique, therefore they do not implement `Eq` and cannot be
//! compared directly. If a direct comparison is really required, they can be compared as strings
diff --git a/proxmox-rest-server/src/worker_task.rs b/proxmox-rest-server/src/worker_task.rs
index 8691748e..62e5893f 100644
--- a/proxmox-rest-server/src/worker_task.rs
+++ b/proxmox-rest-server/src/worker_task.rs
@@ -553,7 +553,7 @@ pub fn worker_is_active_local(upid: &UPID) -> bool {
/// * ``worker-task-abort <UPID>``: calls [abort_local_worker]
///
/// * ``worker-task-status <UPID>``: return true of false, depending on
-/// whether the worker is running or stopped.
+/// whether the worker is running or stopped.
pub fn register_task_control_commands(commando_sock: &mut CommandSocket) -> Result<(), Error> {
fn get_upid(args: Option<&Value>) -> Result<UPID, Error> {
let args = if let Some(args) = args {
diff --git a/proxmox-subscription/src/subscription_info.rs b/proxmox-subscription/src/subscription_info.rs
index ae40dbff..a86572d0 100644
--- a/proxmox-subscription/src/subscription_info.rs
+++ b/proxmox-subscription/src/subscription_info.rs
@@ -176,7 +176,7 @@ impl SubscriptionInfo {
/// - Signed instances are valid for up to a year, clamped by the next due date
/// - Unsigned instances are valid for 30+5 days
/// - If `recheck` is set to `true`, unsigned instances are only treated as valid for 5 days
- /// (this mode is used to decide whether to refresh the subscription information)
+ /// (this mode is used to decide whether to refresh the subscription information)
///
/// If the criteria are not met, `status` is set to [SubscriptionStatus::Invalid] and `message`
/// to a human-readable error message.
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 04/10] property_string: clippy: define bound once
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 02/10] apt: clippy: don't clone types implementing Copy Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 03/10] docs: clippy: add indentation to doc list items Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 05/10] client: docs: remove redundant link Maximiliano Sandoval
` (7 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the clippy lint:
warning: bound is defined in more than one place
--> proxmox-schema/src/property_string.rs:352:14
|
352 | pub fn parse<T: ApiType>(value: &str) -> Result<T, Error>
| ^
353 | where
354 | T: for<'de> Deserialize<'de>,
| ^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations
= note: `#[warn(clippy::multiple_bound_locations)]` on by default
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-schema/src/property_string.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/proxmox-schema/src/property_string.rs b/proxmox-schema/src/property_string.rs
index 7dd60f76..7b5a4ed1 100644
--- a/proxmox-schema/src/property_string.rs
+++ b/proxmox-schema/src/property_string.rs
@@ -349,9 +349,9 @@ pub fn print<T: Serialize + ApiType>(value: &T) -> Result<String, Error> {
}
/// Deserialize a value from a property string.
-pub fn parse<T: ApiType>(value: &str) -> Result<T, Error>
+pub fn parse<T>(value: &str) -> Result<T, Error>
where
- T: for<'de> Deserialize<'de>,
+ T: for<'de> Deserialize<'de> + ApiType,
{
parse_with_schema(value, &T::API_SCHEMA)
}
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 05/10] client: docs: remove redundant link
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (2 preceding siblings ...)
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 04/10] property_string: clippy: define bound once Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 06/10] ldap: docs: turn uri into link Maximiliano Sandoval
` (6 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the cargo doc warnings:
warning: redundant explicit link target
--> proxmox-http/src/client/mod.rs:4:19
|
4 | //! in [`Client`](crate::client::Client).
| -------- ^^^^^^^^^^^^^^^^^^^^^ explicit target is redundant
| |
| because label contains path that resolves to same destination
|
= note: when a link's destination is not specified,
the label is used to resolve intra-doc links
= note: `#[warn(rustdoc::redundant_explicit_links)]` on by default
help: remove explicit link target
|
4 | //! in [`Client`].
| ~~~~~~~~~~
warning: redundant explicit link target
--> proxmox-http/src/client/mod.rs:7:22
|
7 | //! [`sync::Client`](crate::client::sync::Client).
| -------------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^ explicit target is redundant
| |
| because label contains path that resolves to same destination
|
= note: when a link's destination is not specified,
the label is used to resolve intra-doc links
help: remove explicit link target
|
7 | //! [`sync::Client`].
| ~~~~~~~~~~~~~~~~
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-http/src/client/mod.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/proxmox-http/src/client/mod.rs b/proxmox-http/src/client/mod.rs
index 2b638605..eb694518 100644
--- a/proxmox-http/src/client/mod.rs
+++ b/proxmox-http/src/client/mod.rs
@@ -1,10 +1,10 @@
//! Simple TLS capable HTTP client implementations.
//!
//! Feature `client` contains a lightweight wrapper around `hyper` with support for TLS connections
-//! in [`Client`](crate::client::Client).
+//! in [`Client`].
//!
//! Feature `client-sync` contains a lightweight wrapper around `ureq` in
-//! [`sync::Client`](crate::client::sync::Client).
+//! [`sync::Client`].
//!
//! Both clients implement [`HttpClient`](crate::HttpClient) if the feature `client-trait` is enabled.
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 06/10] ldap: docs: turn uri into link
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (3 preceding siblings ...)
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 05/10] client: docs: remove redundant link Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 07/10] login: docs: fix typo and add escape html tags Maximiliano Sandoval
` (5 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the following cargo doc warning:
warning: this URL is not a hyperlink
--> proxmox-ldap/src/lib.rs:199:9
|
199 | /// https://www.rfc-editor.org/rfc/rfc4512#section-5.1
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use an automatic link instead: `<https://www.rfc-editor.org/rfc/rfc4512#section-5.1>`
|
= note: bare URLs are not automatically turned into clickable links
= note: `#[warn(rustdoc::bare_urls)]` on by default
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-ldap/src/lib.rs | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/proxmox-ldap/src/lib.rs b/proxmox-ldap/src/lib.rs
index 014bdcc1..4766f338 100644
--- a/proxmox-ldap/src/lib.rs
+++ b/proxmox-ldap/src/lib.rs
@@ -195,8 +195,9 @@ impl Connection {
Ok(())
}
- /// Retrieves an attribute from the root DSE according to RFC 4512, Section 5.1
- /// https://www.rfc-editor.org/rfc/rfc4512#section-5.1
+ /// Retrieves an attribute from the root DSE according to [RFC 4512], Section 5.1
+ ///
+ /// [RFC 4512]: https://www.rfc-editor.org/rfc/rfc4512#section-5.1
pub async fn retrieve_root_dse_attr(&self, attr: &str) -> Result<Vec<String>, Error> {
let mut ldap = self.create_connection().await?;
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 07/10] login: docs: fix typo and add escape html tags
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (4 preceding siblings ...)
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 06/10] ldap: docs: turn uri into link Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 08/10] serde: docs: " Maximiliano Sandoval
` (4 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the cargo docs warning:
warning: unclosed HTML tag `username`
--> proxmox-login/src/api.rs:35:47
|
35 | /// realm is simply added to the username <username>@<relam>.
| ^^^^^^^^^^
|
= note: `#[warn(rustdoc::invalid_html_tags)]` on by default
warning: unclosed HTML tag `relam`
--> proxmox-login/src/api.rs:35:58
|
35 | /// realm is simply added to the username <username>@<relam>.
| ^^^^^^^
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-login/src/api.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/proxmox-login/src/api.rs b/proxmox-login/src/api.rs
index 44232b6f..aa8575fe 100644
--- a/proxmox-login/src/api.rs
+++ b/proxmox-login/src/api.rs
@@ -32,7 +32,7 @@ pub struct CreateTicket {
pub privs: Option<String>,
/// You can optionally pass the realm using this parameter. Normally the
- /// realm is simply added to the username <username>@<relam>.
+ /// realm is simply added to the username `<username>@<realm>`.
#[serde(default, skip_serializing_if = "Option::is_none")]
pub realm: Option<String>,
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 08/10] serde: docs: escape html tags
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (5 preceding siblings ...)
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 07/10] login: docs: fix typo and add escape html tags Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 09/10] server: docs: fix unresolved link to systemd_notify Maximiliano Sandoval
` (3 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the cargo docs warning:
warning: unclosed HTML tag `u8`
--> proxmox-serde/src/lib.rs:55:18
|
55 | /// Serialize Vec<u8> as base64 encoded string.
| ^^^^
|
= note: `#[warn(rustdoc::invalid_html_tags)]` on by default
help: try marking as source code
|
55 | /// Serialize `Vec<u8>` as base64 encoded string.
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-serde/src/lib.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/proxmox-serde/src/lib.rs b/proxmox-serde/src/lib.rs
index 88986698..c1628349 100644
--- a/proxmox-serde/src/lib.rs
+++ b/proxmox-serde/src/lib.rs
@@ -52,7 +52,7 @@ pub mod epoch_as_rfc3339 {
}
}
-/// Serialize Vec<u8> as base64 encoded string.
+/// Serialize `Vec<u8>` as base64 encoded string.
///
/// Usage example:
/// ```
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 09/10] server: docs: fix unresolved link to systemd_notify
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (6 preceding siblings ...)
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 08/10] serde: docs: " Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 10/10] auth-api: docs: remove wrong return info Maximiliano Sandoval
` (2 subsequent siblings)
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
Fixes the cargo docs warning:
warning: unresolved link to `systemd_notify`
--> proxmox-daemon/src/server.rs:314:6
|
314 | /// [systemd_notify] with [SystemdNotify::Ready](proxmox_systemd::notify::SystemdNotify) when the
| ^^^^^^^^^^^^^^ no item named `systemd_notify` in scope
|
= help: to escape `[` and `]` characters, add '\' before them like `\[` or `\]`
= note: `#[warn(rustdoc::broken_intra_doc_links)]` on by default
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-daemon/src/server.rs | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/proxmox-daemon/src/server.rs b/proxmox-daemon/src/server.rs
index e86d5e51..efea9078 100644
--- a/proxmox-daemon/src/server.rs
+++ b/proxmox-daemon/src/server.rs
@@ -311,7 +311,8 @@ impl Listenable for tokio::net::UnixListener {
/// If the variable already exists, its contents will instead be used to restore the listening
/// socket. The finished listening socket is then passed to the `create_service` function which
/// can be used to setup the TLS and the HTTP daemon. The returned future has to call
-/// [systemd_notify] with [SystemdNotify::Ready](proxmox_systemd::notify::SystemdNotify) when the
+/// [SystemdNotify::notify](proxmox_systemd::notify::SystemdNotify::notify) with
+/// [SystemdNotify::Ready](proxmox_systemd::notify::SystemdNotify) when the
/// service is ready.
pub async fn create_daemon<F, S, L>(
address: L::Address,
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] [PATCH proxmox 10/10] auth-api: docs: remove wrong return info
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (7 preceding siblings ...)
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 09/10] server: docs: fix unresolved link to systemd_notify Maximiliano Sandoval
@ 2024-08-07 7:43 ` Maximiliano Sandoval
2024-08-07 9:32 ` [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Lukas Wagner
2024-08-07 18:59 ` [pbs-devel] applied-series: " Thomas Lamprecht
10 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-07 7:43 UTC (permalink / raw)
To: pbs-devel
The method returns a boolean.
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-auth-api/src/api/mod.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/proxmox-auth-api/src/api/mod.rs b/proxmox-auth-api/src/api/mod.rs
index 82b4d42a..a6f9d425 100644
--- a/proxmox-auth-api/src/api/mod.rs
+++ b/proxmox-auth-api/src/api/mod.rs
@@ -63,7 +63,7 @@ pub trait AuthContext: Send + Sync {
/// Access the TFA config with an exclusive lock.
fn tfa_config_write_lock(&self) -> Result<Box<dyn LockedTfaConfig>, Error>;
- /// Check if a userid is enabled and return a [`UserInformation`] handle.
+ /// Check if a userid is enabled.
fn auth_id_is_active(&self, auth_id: &Authid) -> Result<bool, Error>;
/// CSRF prevention token secret data.
--
2.39.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (8 preceding siblings ...)
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 10/10] auth-api: docs: remove wrong return info Maximiliano Sandoval
@ 2024-08-07 9:32 ` Lukas Wagner
2024-08-07 18:59 ` [pbs-devel] applied-series: " Thomas Lamprecht
10 siblings, 0 replies; 13+ messages in thread
From: Lukas Wagner @ 2024-08-07 9:32 UTC (permalink / raw)
To: Proxmox Backup Server development discussion, Maximiliano Sandoval
Reviewed-by: Lukas Wagner <l.wagner@proxmox.com>
Looks good to me.
--
- Lukas
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* [pbs-devel] applied-series: [PATCH proxmox 01/10] clippy: remove needless borrow
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
` (9 preceding siblings ...)
2024-08-07 9:32 ` [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Lukas Wagner
@ 2024-08-07 18:59 ` Thomas Lamprecht
2024-08-09 11:11 ` Maximiliano Sandoval
10 siblings, 1 reply; 13+ messages in thread
From: Thomas Lamprecht @ 2024-08-07 18:59 UTC (permalink / raw)
To: Proxmox Backup Server development discussion, Maximiliano Sandoval
On 07/08/2024 09:43, Maximiliano Sandoval wrote:
> Fixes the clippy warning:
>
> warning: this expression borrows a value the compiler would automatically borrow
> --> proxmox-apt/src/repositories/file/sources_parser.rs:111:40
> |
> 111 | ... types.push((&package_type[..]).parse()?);
> | ^^^^^^^^^^^^^^^^^^^ help: change this to: `package_type[..]`
> |
> = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
> = note: `#[warn(clippy::needless_borrow)]` on by default
>
> Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
> ---
> proxmox-apt/src/repositories/file/sources_parser.rs | 2 +-
> proxmox-router/src/cli/completion.rs | 4 ++--
> 2 files changed, 3 insertions(+), 3 deletions(-)
>
>
applied series with Lukas' R-b, thanks!
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [pbs-devel] applied-series: [PATCH proxmox 01/10] clippy: remove needless borrow
2024-08-07 18:59 ` [pbs-devel] applied-series: " Thomas Lamprecht
@ 2024-08-09 11:11 ` Maximiliano Sandoval
0 siblings, 0 replies; 13+ messages in thread
From: Maximiliano Sandoval @ 2024-08-09 11:11 UTC (permalink / raw)
To: Thomas Lamprecht; +Cc: Proxmox Backup Server development discussion
Thomas Lamprecht <t.lamprecht@proxmox.com> writes:
> On 07/08/2024 09:43, Maximiliano Sandoval wrote:
>> Fixes the clippy warning:
>>
>> warning: this expression borrows a value the compiler would automatically borrow
>> --> proxmox-apt/src/repositories/file/sources_parser.rs:111:40
>> |
>> 111 | ... types.push((&package_type[..]).parse()?);
>> | ^^^^^^^^^^^^^^^^^^^ help: change this to: `package_type[..]`
>> |
>> = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
>> = note: `#[warn(clippy::needless_borrow)]` on by default
>>
>> Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
>
> applied series with Lukas' R-b, thanks!
Thanks! I don't see the first commit in the series ()`clippy: remove
needless borrow`) in the repository, is it possible that it slipped by?
--
Maximiliano
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2024-08-09 11:11 UTC | newest]
Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-08-07 7:43 [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 02/10] apt: clippy: don't clone types implementing Copy Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 03/10] docs: clippy: add indentation to doc list items Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 04/10] property_string: clippy: define bound once Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 05/10] client: docs: remove redundant link Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 06/10] ldap: docs: turn uri into link Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 07/10] login: docs: fix typo and add escape html tags Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 08/10] serde: docs: " Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 09/10] server: docs: fix unresolved link to systemd_notify Maximiliano Sandoval
2024-08-07 7:43 ` [pbs-devel] [PATCH proxmox 10/10] auth-api: docs: remove wrong return info Maximiliano Sandoval
2024-08-07 9:32 ` [pbs-devel] [PATCH proxmox 01/10] clippy: remove needless borrow Lukas Wagner
2024-08-07 18:59 ` [pbs-devel] applied-series: " Thomas Lamprecht
2024-08-09 11:11 ` Maximiliano Sandoval
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal