Skip to content
Snippets Groups Projects
Commit c78ddab6 authored by Adam G-H's avatar Adam G-H
Browse files

Issue #3393633: Build tests can fail randomly if the stage ID begins with a -

parent 95b81e3c
No related branches found
No related tags found
No related merge requests found
......@@ -262,7 +262,11 @@ class ConsoleUpdateStage extends UpdateStage {
* The ID of the current stage.
*/
protected function triggerPostApply(string $stage_id): void {
$arguments = "post-apply $stage_id";
// The stage ID needs to be quoted in order to prevent it from being parsed
// as a command-line option if it begins with -, which is a possibility
// because we use \Drupal\Component\Utility\Crypt::randomBytesBase64() to
// generate the stage ID, and the string it returns might begin with -.
$arguments = sprintf('post-apply "%s"', $stage_id);
if ($this->isFromWeb) {
$arguments .= ' --is-from-web';
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment