Description of problem: When creating from a template contains invalid resource type, it gives "Cannot create object. Unknown API version v1 for kind Test.", it should give error "Cannot create object. Unrecognized kind Test." Version-Release number of selected component (if applicable): fork_ami_openshift3_userinterface_public_576_177 How reproducible: Always Steps to Reproduce: 1.Create a template "ruby-helloworld-sample" from examples/sample-app/application-template-stibuild.json 2. Change "kind": "Service" to "kind":"Test" for frontend service 3. Create from template on web console Actual results: Error "Cannot create object. Unknown API version v1 for kind Test" printed on next step page Expected results: Error "Cannot create object. Unrecognized kind Test" should printed Additional info:
Here are some details about APIGroups that may require updating your tests. - We have a list of v1 resources & can verify before making API calls - We will not have a list of resources under each API Group. We simply have to make the request and handle the 403, 404 errors if they happen So in the template.json, We can look this up and know if it will succeed or fail: "kind": "Test", "apiVersion": "v1", But, we will not know if this will succeed or fail: "kind": "Test", "apiVersion": "foo/v1", I'll have to update the error message to something like this: - "Kind Test is invalid for API version v1" And will try to pass up useful messages for 403,404 errors (from API groups) to the UI.
For "kind": "Test", "apiVersion": "v1", Message will be: - Cannot create object. Kind Test is invalid for v1.
Fix will be coming in next fork_ami. Will update trello card when fork_ami is generated.
tested on fork_ami_openshift3_userinterface_public_576_193, when create from template includes fakegroup, error info [Cannot create fakegroup.tests. User "yapei" cannot create fakegroup.tests in project "yapei-test".] will be displayed on next step page, works as expected