Bug 1437906 - Unable to interact with ansible playbook service
Summary: Unable to interact with ansible playbook service
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.8.0
Hardware: All
OS: All
medium
medium
Target Milestone: GA
: 5.9.0
Assignee: Harpreet Kataria
QA Contact: Dmitry Misharov
URL:
Whiteboard: ui:ansible:service
Depends On:
Blocks: 1438907
TreeView+ depends on / blocked
 
Reported: 2017-03-31 12:33 UTC by Dmitry Misharov
Modified: 2018-03-06 14:51 UTC (History)
8 users (show)

Fixed In Version: 5.9.0.1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1438907 (view as bug list)
Environment:
Last Closed: 2018-03-06 14:51:50 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Screenshot of the bug (23.73 KB, image/png)
2017-03-31 12:33 UTC, Dmitry Misharov
no flags Details

Description Dmitry Misharov 2017-03-31 12:33:32 UTC
Created attachment 1267843 [details]
Screenshot of the bug

Description of problem:
If a bad host was provided during ordering "Ansible playbook" service then it will be impossible to interact with that service in My Services. It can't be viewed , edited or deleted.

Version-Release number of selected component (if applicable):
5.8.0.8-alpha1.20170328221054_e6ca7a2

How reproducible:
Always

Steps to Reproduce:
1. Enable Embedded Ansible role.
2. Wait until it will be enabled.
3. Add some ansible repository, credential in Automation/Ansible.
4. Navigate to Services/Catalogs/Catalog Items.
5. Create "Ansible Playbook" Catalog Item.
6. Navigate to Services/Service Catalogs.
7. Click "Order" button of the service.
8. In the "Hosts" field enter random string.
9. Navigate to Services/My Services.
10. Click on the service in the tree.

Actual results:
"Configuration" button is disabled, the service cannot be deleted or edited or viewed.

Expected results:
The service shouldn't appear in My services at all.

Additional info:
In browser console the error appears in the response:
throw "error";
Error text:\n\u003c/h2\u003e\n\u003cbr\u003e\n\u003ch3\u003e
\nincompatible character encodings: UTF-8 and ASCII-8BIT [service/x_show]\n\u003c/h3\u003e\n\u003c/div
\u003e\n");

Comment 2 Dmitry Misharov 2017-03-31 12:42:47 UTC
The host should contain non ASCII characters.

Comment 3 Greg McCullough 2017-03-31 13:09:27 UTC
Can you verify if you submitted the order or not?  From the steps above it sounds like you did not submit the order but the service was still created.

Is that part of the issue being reported?

Also, please give an example of a random string for the "Hosts" field that causes this issue for you as the characters used may be relevant.

If there is a reproducing appliance that we can connect to that would be useful as well.

Comment 5 Greg McCullough 2017-03-31 14:07:47 UTC
Passing to the UI team to review the UI errors reported in the bug description.

Comment 6 Harpreet Kataria 2017-04-03 20:56:42 UTC
https://github.com/ManageIQ/manageiq-ui-classic/pull/894

Comment 7 CFME Bot 2017-04-04 16:53:26 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:
https://github.com/ManageIQ/manageiq-ui-classic/commit/bce5e5fb77f5e55be33ed1fd143aac2067cc4087

commit bce5e5fb77f5e55be33ed1fd143aac2067cc4087
Author:     Harpreet Kataria <hkataria>
AuthorDate: Mon Apr 3 16:51:04 2017 -0400
Commit:     Harpreet Kataria <hkataria>
CommitDate: Tue Apr 4 10:13:04 2017 -0400

    Added force_encoding to display contents of stdout correctly on screen
    
    Added force_encoding to display contents of stdout to pass them to codemirror so it can be correctly on screen to fix the following error:
    [----] F, [2017-04-03T11:48:28.706445 #7517:50b9460] FATAL -- : Error caught: [ActionView::Template::Error] incompatible character encodings: UTF-8 and ASCII-8BIT
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1437906

 app/views/service/_svcs_show.html.haml | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

Comment 9 Dmitry Misharov 2017-10-18 06:23:27 UTC
Verified in 5.9.0.2.20171010190026_0413a06. Non-ascii characters don't break the ui.


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