tags filter doesn't support operator

Bug #1744642 reported by Shiv Kumar
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Glare
Confirmed
Wishlist
Unassigned

Bug Description

Acc. to glare documentation (https://github.com/openstack/glare/blob/master/doc/source/developer/webapi/v1.rst), tags support eq,neq and in operator. But when I try to give ?tags=neq:abc Glare throws below error:

{
    "explanation": "The server could not comply with the request since it is either malformed or otherwise incorrect.",
    "code": 400,
    "error": {
        "message": "Tags are filtered without operator",
        "type": "BadRequest"
    },
    "title": "Bad Request"
}

How can I pass a neq operator for tags filter?

Revision history for this message
Mike Fedosin (mfedosin) wrote :

Hello! There are OpenStack requirements that define filtering by tags: https://specs.openstack.org/openstack/api-wg/guidelines/tags.html#filtering-and-searching-by-tags

Therefore we use slightly different syntax from other similar fields, i.e. tags=a,b,c or tags-any=a,b,c

You can find more example in the provided document.

Unfortunately only "tags" and "tags-any" filters are supported now by glare API, "not-tags" and "not-tags-any" are not implemented at the moment.

Mike Fedosin (mfedosin)
Changed in glare:
status: New → Confirmed
importance: Undecided → Wishlist
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.