public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Stefan Hanreich <s.hanreich@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: Re: [PATCH-SERIES network 0/2] assert vnet zone exists on create and update
Date: Wed, 15 Jul 2026 15:45:53 +0200	[thread overview]
Message-ID: <69b374b5-d86a-490d-8acf-eafbbccba6a1@proxmox.com> (raw)
In-Reply-To: <20260703104750.117988-1-d.kral@proxmox.com>

On 7/3/26 12:47 PM, Daniel Kral wrote:
> If a VNet is created or updated with an empty zone '' or a non-existing
> zone identifier, the API handler will die with a slighly confusing error
> message:
> 
> create sdn vnet object failed: cannot lookup undefined type! at
> /usr/share/perl5/PVE/API2/Network/SDN/Vnets.pm line 326.
> 
> Therefore, use the helper sdn_zones_config(), which asserts whether the
> zone identifier is non-empty and existing.

Thanks for the patch! Reproduced this locally and then tested with those
patches applied. Does what it says on the tin and improves error
messages. Code lgtm as well - consider this:

Tested-by: Stefan Hanreich <s.hanreich@proxmox.com>
Reviewed-by: Stefan Hanreich <s.hanreich@proxmox.com>




      parent reply	other threads:[~2026-07-15 13:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-03 10:47 [PATCH-SERIES network 0/2] assert vnet zone exists on create and update Daniel Kral
2026-07-03 10:47 ` [PATCH network 1/2] prefix specific sdn resource type to existence assertion string Daniel Kral
2026-07-03 10:47 ` [PATCH network 2/2] api: vnets: assert vnet zone exists on create and update Daniel Kral
2026-07-15 13:45 ` Stefan Hanreich [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=69b374b5-d86a-490d-8acf-eafbbccba6a1@proxmox.com \
    --to=s.hanreich@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