Bug 1489885 - internal server error when limit is 0 and offset is specified for paging
Summary: internal server error when limit is 0 and offset is specified for paging
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: API
Version: 5.9.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: GA
: 5.9.0
Assignee: Jillian Tullo
QA Contact: Martin Kourim
URL:
Whiteboard: api:rest
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-09-08 14:50 UTC by Martin Kourim
Modified: 2018-03-06 14:41 UTC (History)
4 users (show)

Fixed In Version: 5.9.0.1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-03-06 14:41:28 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:


Attachments (Terms of Use)

Description Martin Kourim 2017-09-08 14:50:51 UTC
Description of problem:

GET /api/features?limit=0&offset=10
results in
{
    "error": {
        "kind": "internal_server_error",
        "message": "Infinity",
        "klass": "FloatDomainError"
    }
}

There should be better input value checking.
Should fail with e.g. bad_request.

Version:
build from 20170828

Comment 2 Jillian Tullo 2017-09-29 12:35:28 UTC
PR: https://github.com/ManageIQ/manageiq-api/pull/90

Comment 3 Martin Kourim 2017-10-18 16:29:37 UTC
Verified that the request now fails with "bad_request".


Note You need to log in before you can comment on or make changes to this bug.