{"action":"opened","issue":{"url":"https://api.github.com/repos/broadinstitute/cromwell/issues/1514","repository_url":"https://api.github.com/repos/broadinstitute/cromwell","labels_url":"https://api.github.com/repos/broadinstitute/cromwell/issues/1514/labels{/name}","comments_url":"https://api.github.com/repos/broadinstitute/cromwell/issues/1514/comments","events_url":"https://api.github.com/repos/broadinstitute/cromwell/issues/1514/events","html_url":"https://github.com/broadinstitute/cromwell/issues/1514","id":181057738,"number":1514,"title":"REST API query endpoint status param values are validated case-insensitively but checked for equality case-sensitively","user":{"login":"delocalizer","id":817809,"avatar_url":"https://avatars.githubusercontent.com/u/817809?v=3","gravatar_id":"","url":"https://api.github.com/users/delocalizer","html_url":"https://github.com/delocalizer","followers_url":"https://api.github.com/users/delocalizer/followers","following_url":"https://api.github.com/users/delocalizer/following{/other_user}","gists_url":"https://api.github.com/users/delocalizer/gists{/gist_id}","starred_url":"https://api.github.com/users/delocalizer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/delocalizer/subscriptions","organizations_url":"https://api.github.com/users/delocalizer/orgs","repos_url":"https://api.github.com/users/delocalizer/repos","events_url":"https://api.github.com/users/delocalizer/events{/privacy}","received_events_url":"https://api.github.com/users/delocalizer/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-10-05T03:36:14Z","updated_at":"2016-10-05T03:36:14Z","closed_at":null,"body":"REST API correctly gives error on unknown status value:\r\n\r\n```\r\n[conradL@qimr13054 cromwell-executions]$ curl localhost:8000/api/workflows/V1/query?status=blah\r\n{\r\n  \"status\": \"fail\",\r\n  \"message\": \"Unrecognized status values: blah\"\r\n}\r\n```\r\n\r\nand correctly gives results for status with exact case-sensitive spelling (\"Failed\"):\r\n\r\n```\r\n[conradL@qimr13054 cromwell-executions]$ curl localhost:8000/api/workflows/V1/query?status=Failed\r\n{\r\n  \"results\": [{\r\n    \"id\": \"8b8ce542-9e4a-4549-8fd3-c72ea325f392\",\r\n    \"status\": \"Failed\",\r\n    \"start\": \"2016-10-05T11:15:38.214+10:00\",\r\n    \"end\": \"2016-10-05T11:15:38.217+10:00\"\r\n  }, {\r\n    \"id\": \"1784a44d-e623-42fd-bf7a-90b00d300017\",\r\n    \"status\": \"Failed\",\r\n    \"start\": \"2016-10-05T11:16:38.273+10:00\",\r\n    \"end\": \"2016-10-05T11:16:38.275+10:00\"\r\n  }]\r\n}\r\n```\r\n\r\nBut returns neither error nor results when given a status value that is only case-insensitively correct (\"failed\"):\r\n\r\n```\r\n[conradL@qimr13054 cromwell-executions]$ curl localhost:8000/api/workflows/V1/query?status=failed\r\n{\r\n  \"results\": []\r\n}\r\n```"}}
{"actor":{"display_login":"delocalizer"}}