* Re: [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output
2026-08-27 15:47 [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output Jonas Theisen
@ 2026-08-28 6:31 ` Maximiliano Sandoval
2026-08-28 7:09 ` Christian Ebner
` (2 subsequent siblings)
3 siblings, 0 replies; 6+ messages in thread
From: Maximiliano Sandoval @ 2026-08-28 6:31 UTC (permalink / raw)
To: Jonas Theisen; +Cc: pbs-devel
Jonas Theisen <j.theisen@proxmox.com> writes:
> Currently running tasks are returned by the PBS API in the query
> for errored tasks.
> This patch adds an additional condition to filter out running tasks
> when queried for errored tasks.
>
> Reported in https://forum.proxmox.com/threads/163872/,
> https://forum.proxmox.com/threads/185999/ and
> https://bugzilla.proxmox.com/show_bug.cgi?id=6251
>
> Signed-off-by: Jonas Theisen <j.theisen@proxmox.com>
> ---
> src/api2/node/tasks.rs | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/src/api2/node/tasks.rs b/src/api2/node/tasks.rs
> index 96f5e080f..4786820a3 100644
> --- a/src/api2/node/tasks.rs
> +++ b/src/api2/node/tasks.rs
> @@ -610,6 +610,7 @@ pub fn list_tasks(
> (Some(state), Some(filters)) if !filters.contains(&tasktype(state)) => {
> continue;
> }
> + (None, _) if errors => continue,
> (None, Some(_)) => continue,
> _ => {}
> }
What I tested:
>From one terminal:
proxmox-backup-manager garbage-collection start <datastore>
before the task finished, from another terminal:
proxmox-backup-debug api get /nodes/$(hostname)/tasks --limit 3 --errors true
Without this patch, the GC task would show in the task list even though
it does not have errors. This is addressed by the patch.
lgtm.
Tested-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
Reviewed-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
--
Maximiliano
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output
2026-08-27 15:47 [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output Jonas Theisen
2026-08-28 6:31 ` Maximiliano Sandoval
@ 2026-08-28 7:09 ` Christian Ebner
2026-08-28 15:54 ` Jonas Theisen
2026-09-29 14:50 ` Jonas Theisen
2026-10-02 12:34 ` applied: " Thomas Lamprecht
3 siblings, 1 reply; 6+ messages in thread
From: Christian Ebner @ 2026-08-28 7:09 UTC (permalink / raw)
To: Jonas Theisen, pbs-devel
On 8/27/26 5:48 PM, Jonas Theisen wrote:
> Currently running tasks are returned by the PBS API in the query
> for errored tasks.
> This patch adds an additional condition to filter out running tasks
> when queried for errored tasks.
>
> Reported in https://forum.proxmox.com/threads/163872/,
> https://forum.proxmox.com/threads/185999/ and
> https://bugzilla.proxmox.com/show_bug.cgi?id=6251
>
> Signed-off-by: Jonas Theisen <j.theisen@proxmox.com>
> ---
> src/api2/node/tasks.rs | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/src/api2/node/tasks.rs b/src/api2/node/tasks.rs
> index 96f5e080f..4786820a3 100644
> --- a/src/api2/node/tasks.rs
> +++ b/src/api2/node/tasks.rs
> @@ -610,6 +610,7 @@ pub fn list_tasks(
> (Some(state), Some(filters)) if !filters.contains(&tasktype(state)) => {
> continue;
> }
> + (None, _) if errors => continue,
> (None, Some(_)) => continue,
> _ => {}
> }
Thanks for the patch! Did you also check the task filter implementations
in PVE/PDM?
At least for PDM there is some analogous logic [0] which at first glance
requires adaption as well. Note that there it is shared for PVE and PBS.
[0]
https://git.proxmox.com/?p=proxmox-datacenter-manager.git;a=blob;f=server/src/remote_tasks/mod.rs;h=5fba867dfc675970ebc5037165f49efee439f545;hb=HEAD#l143
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output
2026-08-27 15:47 [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output Jonas Theisen
2026-08-28 6:31 ` Maximiliano Sandoval
2026-08-28 7:09 ` Christian Ebner
@ 2026-09-29 14:50 ` Jonas Theisen
2026-10-02 12:34 ` applied: " Thomas Lamprecht
3 siblings, 0 replies; 6+ messages in thread
From: Jonas Theisen @ 2026-09-29 14:50 UTC (permalink / raw)
To: pbs-devel
Gentle ping
On 8/27/26 17:47, Jonas Theisen wrote:
> Currently running tasks are returned by the PBS API in the query
> for errored tasks.
> This patch adds an additional condition to filter out running tasks
> when queried for errored tasks.
>
> Reported in https://forum.proxmox.com/threads/163872/,
> https://forum.proxmox.com/threads/185999/ and
> https://bugzilla.proxmox.com/show_bug.cgi?id=6251
>
> Signed-off-by: Jonas Theisen <j.theisen@proxmox.com>
> ---
> src/api2/node/tasks.rs | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/src/api2/node/tasks.rs b/src/api2/node/tasks.rs
> index 96f5e080f..4786820a3 100644
> --- a/src/api2/node/tasks.rs
> +++ b/src/api2/node/tasks.rs
> @@ -610,6 +610,7 @@ pub fn list_tasks(
> (Some(state), Some(filters)) if !filters.contains(&tasktype(state)) => {
> continue;
> }
> + (None, _) if errors => continue,
> (None, Some(_)) => continue,
> _ => {}
> }
^ permalink raw reply [flat|nested] 6+ messages in thread* applied: [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output
2026-08-27 15:47 [PATCH proxmox-backup] fix #6251: api: Remove running tasks from errors output Jonas Theisen
` (2 preceding siblings ...)
2026-09-29 14:50 ` Jonas Theisen
@ 2026-10-02 12:34 ` Thomas Lamprecht
3 siblings, 0 replies; 6+ messages in thread
From: Thomas Lamprecht @ 2026-10-02 12:34 UTC (permalink / raw)
To: pbs-devel, Jonas Theisen
On Thu, 27 Aug 2026 17:47:32 +0200, Jonas Theisen wrote:
> Currently running tasks are returned by the PBS API in the query
> for errored tasks.
> This patch adds an additional condition to filter out running tasks
> when queried for errored tasks.
>
> Reported in https://forum.proxmox.com/threads/163872/,
> https://forum.proxmox.com/threads/185999/ and
> https://bugzilla.proxmox.com/show_bug.cgi?id=6251
>
> [...]
Applied, thanks!
[1/1] fix #6251: api: Remove running tasks from errors output
commit: b64a75ac2f38dd9d21ab82faecff8bbb9109e0b0
^ permalink raw reply [flat|nested] 6+ messages in thread