Improve error handling in constrained genFromSpec
#4822
+2
−8
Merged
genFromSpec
#4822