From: Hannes Laimer <h.laimer@proxmox.com>
To: Lukas Sichert <l.sichert@proxmox.com>, pve-devel@lists.proxmox.com
Subject: Re: [PATCH manager v2] ui: fabrics: skip unsupported interface properties on submit
Date: Fri, 5 Jun 2026 10:04:16 +0200 [thread overview]
Message-ID: <1b32c40c-fa34-40ed-9190-9325be3fcb54@proxmox.com> (raw)
In-Reply-To: <20260603155521.125175-1-l.sichert@proxmox.com>
LGTM! could reproduce the problem, and this does work as advertised,
consider this:
Tested-by: Hannes Laimer <h.laimer@proxmox.com>
Reviewed-by: Hannes Laimer <h.laimer@proxmox.com>
On 2026-06-03 17:54, Lukas Sichert wrote:
> BGP unnumbered interfaces have neither IPv4 nor IPv6 addresses, but the
> base interface panel always added the IPv4 column and only allowed child
> panels to disable IPv6. This meant BGP still exposed an IPv4 field and
> would also serialize existing IPv4 and IPv6 data from the node interface
> record. When submitting such an interface, the backend rejects the
> unsupported property with: 'format error interfaces[0].ip: property is
> not defined in schema'
>
> Add a 'hasIpv4Support' flag matching the existing IPv6 handling and use
> both support flags to skip unsupported IP columns and properties during
> serialization.
>
> Signed-off-by: Lukas Sichert <l.sichert@proxmox.com>
> ---
> www/manager6/sdn/fabrics/InterfacePanel.js | 37 ++++++++++++-------
> .../sdn/fabrics/bgp/InterfacePanel.js | 11 +-----
> 2 files changed, 24 insertions(+), 24 deletions(-)
>
> diff --git a/www/manager6/sdn/fabrics/InterfacePanel.js b/www/manager6/sdn/fabrics/InterfacePanel.js
> index f07e7859..e325340f 100644
> --- a/www/manager6/sdn/fabrics/InterfacePanel.js
> +++ b/www/manager6/sdn/fabrics/InterfacePanel.js
> @@ -6,6 +6,7 @@ Ext.define('PVE.sdn.Fabric.InterfacePanel', {
>
> nodeInterfaces: {},
>
> + hasIpv4Support: true,
> hasIpv6Support: true,
>
> selModel: {
> @@ -59,19 +60,6 @@ Ext.define('PVE.sdn.Fabric.InterfacePanel', {
> dataIndex: 'type',
> flex: 1,
> },
> - {
> - text: gettext('IPv4'),
> - xtype: 'widgetcolumn',
> - dataIndex: 'ip',
> - flex: 1,
> - widget: {
> - xtype: 'proxmoxtextfield',
> - isFormField: false,
> - bind: {
> - disabled: '{record.isDisabled}',
> - },
> - },
> - },
> ],
>
> additionalColumns: [],
> @@ -112,6 +100,23 @@ Ext.define('PVE.sdn.Fabric.InterfacePanel', {
>
> let columns = [...me.commonColumns];
>
> +
> + if (me.hasIpv4Support) {
> + columns.push({
> + text: gettext('IPv4'),
> + xtype: 'widgetcolumn',
> + dataIndex: 'ip',
> + flex: 1,
> + widget: {
> + xtype: 'proxmoxtextfield',
> + isFormField: false,
> + bind: {
> + disabled: '{record.isDisabled}',
> + },
> + },
> + });
> + }
> +
> if (me.hasIpv6Support) {
> columns.push({
> text: gettext('IPv6'),
> @@ -174,7 +179,11 @@ Ext.define('PVE.sdn.Fabric.InterfacePanel', {
> continue;
> }
>
> - if (['type', 'isDisabled'].includes(key)) {
> + if (
> + ['type', 'isDisabled'].includes(key) ||
> + (key === 'ip' && !me.hasIpv4Support) ||
> + (key === 'ip6' && !me.hasIpv6Support)
> + ) {
> continue;
> }
>
> diff --git a/www/manager6/sdn/fabrics/bgp/InterfacePanel.js b/www/manager6/sdn/fabrics/bgp/InterfacePanel.js
> index c7ac7627..fd5e6f4b 100644
> --- a/www/manager6/sdn/fabrics/bgp/InterfacePanel.js
> +++ b/www/manager6/sdn/fabrics/bgp/InterfacePanel.js
> @@ -1,15 +1,6 @@
> Ext.define('PVE.sdn.Fabric.Bgp.InterfacePanel', {
> extend: 'PVE.sdn.Fabric.InterfacePanel',
>
> + hasIpv4Support: false,
> hasIpv6Support: false,
> -
> - // BGP unnumbered interfaces have no IP - override commonColumns to
> - // exclude the IP column that the base class defines.
> - initComponent: function () {
> - let me = this;
> -
> - me.commonColumns = me.commonColumns.filter((col) => col.dataIndex !== 'ip');
> -
> - me.callParent();
> - },
> });
prev parent reply other threads:[~2026-06-05 8:04 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-03 15:55 [PATCH manager v2] ui: fabrics: skip unsupported interface properties on submit Lukas Sichert
2026-06-05 8:04 ` Hannes Laimer [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=1b32c40c-fa34-40ed-9190-9325be3fcb54@proxmox.com \
--to=h.laimer@proxmox.com \
--cc=l.sichert@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 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.