Merge pull request #13167 from appwrite/fix/specs-fail-loudly

fix(specs): fail the task when a spec cannot be generated
This commit is contained in:
Harsh Mahajan authored and GitHub committed 2026-08-10 10:52:55 +05:30
commit 87887d0f54
1 file changed
+4 -1
+4 -1
View File
@@ -779,7 +779,10 @@ class Specs extends Action
$parsedSpecs = $specs->parse();
$this->verifyParsedSpec($parsedSpecs);
} catch (\RuntimeException $e) {
throw new \RuntimeException("Spec generation failed for {$platform} ({$format}): " . $e->getMessage(), 0, $e);
// A throw is reported and carried on from, so stop here
Console::error("Spec generation failed for {$platform} ({$format}): " . $e->getMessage());
Console::exit(1);
return;
}
$encodedSpecs = \json_encode($parsedSpecs, JSON_PRETTY_PRINT);