Bug 1491658
Summary: | Author name can only contain letters from printable ASCII range | ||||||
---|---|---|---|---|---|---|---|
Product: | [Retired] Beaker | Reporter: | Mirek Długosz <mzalewsk> | ||||
Component: | wizard | Assignee: | Dan Callaghan <dcallagh> | ||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Anwesha Chatterjee <achatter> | ||||
Severity: | medium | Docs Contact: | |||||
Priority: | low | ||||||
Version: | develop | CC: | achatter, dcallagh, mjia, mzalewsk, ohudlick, rjoost | ||||
Target Milestone: | 25.0 | Keywords: | Patch | ||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | All | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | If docs needed, set a value | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2018-03-19 04:18:13 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Mirek Długosz
2017-09-14 11:10:39 UTC
Created attachment 1325914 [details]
Very simple patch to solve this issue (untested)
I would go one step further and say there is no reason why we should be requiring that people's names be either two or three space-separated elements, either. Possibly that is designed to catch the cause where someone's name has wrongly been guessed as their username (like "dcallagh") although if someone really wants to use that as their name, I don't see why the wizard should stop them. However, we might have a problem one layer down, in the testinfo.desc parser. I tried putting a non-ASCII name into a task Makefile and I get: rhts-lint testinfo.desc testinfo.desc:1: error: "Gęśla Jaźń <dcallagh>" is not a valid Owner field (should be a valid RFC2822 name_addr, such as John Doe <jdoe>) make: *** [testinfo.desc] Error 1 so that might need fixing too... So, this was surprisingly hard to fully fix. :-) https://gerrit.beaker-project.org/5885 beaker-wizard: don't enforce any restrictions on author name https://gerrit.beaker-project.org/5884 accept non-ASCII names in testinfo.desc https://gerrit.beaker-project.org/5886 accept non-ASCII names in testinfo.desc The random smattering of .decode() in testinfo.py makes me nervous though. So I'm thinking I should audit that whole module for unicode-cleanliness first, and then these patches can go on top. Bumping this to 25.0 since it's not really a minor fix. I feel more confident now with this: https://gerrit.beaker-project.org/5904 testinfo.py: deal exclusively in unicode not bytes https://gerrit.beaker-project.org/5884 accept non-ASCII names in testinfo.desc and matching changes on the Beaker side: https://gerrit.beaker-project.org/5905 testinfo.py: deal exclusively in unicode not bytes https://gerrit.beaker-project.org/5906 accept non-ASCII names in testinfo.desc Although now that I think about it, the Beaker-side patches should really include a test case with a task with non-ASCII chars in the name... A test on testinfo.desc with an owner name with special characters produces this error
> rhts-lint testinfo.desc
testinfo2.desc:1: error: "Gęśla Jaźń <bpeck>" is not a valid Owner field (should be a valid RFC2822 name_addr, such as John Doe <jdoe>)
Turns out my patch: https://gerrit.beaker-project.org/c/5904/ was not complete. rhts-lint and rhts-mk-generate-specfile do their own file handling which is currently still dealing in bytes and not unicode. (In reply to Dan Callaghan from comment #8) https://gerrit.beaker-project.org/5967 This bug fix is included in rhts-4.73-1.git.4.8daecb4 which is currently available for download here: https://beaker-project.org/yum/client-testing/ Verified that * with beaker-client-25.0-0.git.176.b72276ac3.el6eng.noarch.rpm installed * Running: `beaker-wizard -n 'Gęśla Jaźń'` No longer produces the error "not a valid author", and produces a Makefile with the provided author name. * Running: `make rpm` in the directory with the makefile builds successfully and * Running: `rhts-lint testinfo.desc` Does not throw any errors Beaker 25.0 has been released. Release notes are available upstream: https://beaker-project.org/docs/whats-new/release-25.html |