action #177267
closedcoordination #102915: [saga][epic] Automated classification of failures
QA (public) - coordination #94105: [epic] Use feedback from openqa-investigate to automatically inform on github pull requests, open tickets, weed out automatically failed tests
Forbid unprintable characters, white space, colons, equal signs and quotes in TEST names size:S
0%
Description
Motivation¶
Currently you can put just about any character into the TEST variable, including stuff like vertical tabs, colons, equal signs, quotes and colons.
That can create problems in various places (see #176886 for example, where =
would make a scope setting impossible)
Note that in our YAML schema we are already a bit more restrictive, e.g.
job_templates:
type: object
additionalProperties: false
patternProperties:
^[A-Za-z\s0-9_*.+-]+$:
But I think the \s
there was a mistake and should be a simple space instead. We don't want tabs or vertical tabs or newlines...
Acceptance Criteria¶
- AC1:: The TEST name is limited to certain characters
- AC2:
The YAML schema allows the same characters as required elsewhere
Suggestions¶
- Research exactly where this is relevant e.g. the schema used in the context of isos post
- openqa-clone-job can also override the test name, it may not be checked there
- Use of the openqa-clone-custom-refspec script?
- Any command where you can specify settings including
TEST=...
- Restrict the initial and last character to words e.g. a test name would never started with a & or +
- If you allow unicode characters, make sure they actually work, because at the moment they end up as garbage when specified on the commandlime, e.g.
TEST=测试
- Use
\p{Word}
instead of\w
to allow unicode words - The YAML schema should be more restrictive. Original test names should not allow things like
@#/
because for example#
and/
are part of github urls that are used for pull request tests. Normal test names don't need to allow them, and shouldn't, because then when seeing#/
it's usually clear that it's from a PR / branch. - Check the
jobs.test
column in the database for what has been used in the past
Updated by tinita 15 days ago
- Related to action #176886: A "+" and other characters used in test names in $var are considered invalid in WORKER_CLASS:$var size:S added
Updated by livdywan 9 days ago
- Subject changed from Forbid unprintable characters, white space, colons, equal signs and quotes in TEST names to Forbid unprintable characters, white space, colons, equal signs and quotes in TEST names size:S
- Description updated (diff)
- Status changed from New to Workable
Updated by livdywan 9 days ago
- Target version changed from Tools - Next to Ready
I guess we need this ticket then. See #176886#note-11