Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extra newline not sanitized in 'edit' textarea for multiple choice survey answer options #4866

Closed
rebeccahhh opened this issue Oct 1, 2019 · 6 comments
Labels

Comments

@rebeccahhh
Copy link
Member

ISSUE TYPE
  • Bug Report
SUMMARY

A newline is being left in when a multiple choice survey answers list contains newlines.
Most are sanitized out, but the top one is left in the options for editing (although not the options when the survey is actually executed). This may or may not be related to #4192

ENVIRONMENT
  • AWX version: 7.0.0
  • AWX install method: docker on linux
  • Ansible version: 2.8.5
  • Operating System: Fedora 30
  • Web Browser: Firefox
STEPS TO REPRODUCE

create a survey in a job template, make it a multiple choice. Enter in several options with random extra newlines, then save. Click edit to see if the extra space is still there.

EXPECTED RESULTS

The input should be sanitized, removing all blank newlines.

ACTUAL RESULTS

The topmost newline after the first valid answer option remains in the edit box as long as there is another list item before it, all other newlines are sanitized.
This video shows more
This video doesn't show what happens when hitting save and re-opening the edit, but the newline persists there as well.

ADDITIONAL INFORMATION
@rebeccahhh rebeccahhh changed the title Extra newline not sanitized out in edit multiple choice survey input box Extra newline not sanitized in 'edit' textarea for multiple choice survey answer options Oct 1, 2019
@rebeccahhh rebeccahhh removed their assignment Oct 4, 2019
@awithrow9
Copy link

@rebeccahhh is this ready for test? If so can you add the label?

@rebeccahhh
Copy link
Member Author

@awithrow9 it hasn't been worked on, I only found and reported the bug. I can validate it's still present if needed.

@ryanpetrello
Copy link
Contributor

@rebeccahhh I'm going to move the milestone, thanks.

@wenottingham
Copy link
Contributor

punting low-priority UI nits to ui-next

@mabashian
Copy link
Member

Thinking a bit about this one. The way to solve it may be a completely different interface for specifying multiple choice answers. If we came up with a more user friendly way to do this (not a textarea where each line is a survey answer) then this problem would likely go away.

@unlikelyzero
Copy link

Fixed in the rewrite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

7 participants