public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: Proxmox VE development discussion <pve-devel@lists.proxmox.com>,
	Fiona Ebner <f.ebner@proxmox.com>
Subject: [pve-devel] applied: [PATCH manager] pvesh: proxy handler: fix handling array parameters
Date: Fri, 17 Nov 2023 16:17:39 +0100	[thread overview]
Message-ID: <4dfc3dda-9add-4983-a994-78c3a9019b79@proxmox.com> (raw)
In-Reply-To: <20231117145805.17056-1-f.ebner@proxmox.com>

Am 17/11/2023 um 15:58 schrieb Fiona Ebner:
> As reported in the community forum and reproduced locally, issuing a
> QEMU guest agent command would lead to an error when proxying to
> another node:
> 
>> root@pve8a2 ~ # pvesh create /nodes/pve8a1/qemu/126/agent/exec --command 'whoami'
>> Wide character in die at /usr/share/perl5/PVE/RESTHandler.pm line 918.
>> proxy handler failed: Agent error: Guest agent command failed, error was 'Failed to execute child process “ARRAY(0x55842bb161a0)” (No such file or directory)'
> 
> Fix it, by splitting up array references correctly.
> 
> [0]: https://forum.proxmox.com/threads/136520/
> 
> Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
> ---
> 
> Not sure if this is the correct place to fix it?

from a quick check I think this should be fine here, as one should expect
arrays on when handling API stuff since pve-comnmon's 07f136d ("JSONSchema: add
support for array parameter in api calls, cli and config"), like the command for
QGA's exec, which is marked as array.
And here it's centrally enough for pvesh for this use case.

 
>  PVE/CLI/pvesh.pm | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
>

applied, thanks!




      reply	other threads:[~2023-11-17 15:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-17 14:58 [pve-devel] " Fiona Ebner
2023-11-17 15:17 ` Thomas Lamprecht [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4dfc3dda-9add-4983-a994-78c3a9019b79@proxmox.com \
    --to=t.lamprecht@proxmox.com \
    --cc=f.ebner@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal