Skip to content

Invalid query generated for port list with fixed IPs #2807

@mdbooth

Description

@mdbooth

The following ListOpts generates an incorrect query:

ports.ListOpts{
	FixedIPs: []ports.FixedIPOpts{
		{SubnetID: "41701fe5-decf-4ab4-b3bb-410e7404a9cf", IPAddress: "10.0.128.1"},
	},
},

It generates:

&fixed_ips=ip-address=10.0.128.1,subnet_id=41701fe5-decf-4ab4-b3bb-410e7404a9cf

OpenStack client generates:

&fixed_ips=subnet_id=41701fe5-decf-4ab4-b3bb-410e7404a9cf&fixed_ips=ip_address=10.0.128.1

OpenStack client's query correctly returns the matched port. Gophercloud's query does not.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions