Edit Instance - description box should not accept multi-line input
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Dashboard (Horizon) |
Fix Released
|
Low
|
Unassigned |
Bug Description
Currently, the text box for the Description is a multi-line text area. But if you try to enter more than one line it fails saying "Error: Unable to modify instance "name of instance".
It turns out that the Nova / Nova client will reject any description that doesn't match a gnarly regex. And newlines are rejected by that regex. The error message you get from the CLI is like this:
Invalid input for field/attribute description. Value: helloworld. 'hello\nworld' does not match '^[\\ -\\~\xa0-
... which you would NOT want to show to an end user!
Possible fixes for the problem would include:
- Add help text to the Edit Instance form to describe the limitations on the text allowed in the Description.
- Change the "look and feel" of the box to avoid giving the impression that multi-line descriptions are OK.
- Change the UI to reject descriptions with bad characters ... before the get sent to nova / nova client
- Detect the specific response message and translate it into a meaningful user error message; e.g. something like "Error: Description contains one or more unacceptable characters".
At least the first one ... please.
This syndrome may apply to other name, description and other text fields in the UI. I didn't do looking for examples.
Changed in horizon: | |
status: | New → Confirmed |
importance: | Undecided → Low |
Fix proposed to branch: master /review. opendev. org/c/openstack /horizon/ +/914824
Review: https:/