Interview Prep/Jenkins/Jenkinsfile syntax, Groovy & CPS errors

`WorkflowScript: 22: Invalid condition "sucess" - valid conditions are [always, changed, fixed, regression, aborted, success, unsuccessful, unstable, failure, notBuilt, cleanup]`

BeginnerTroubleshootingJenkinsfile syntax, Groovy & CPS errors
Answer

Likely causes → Typo in a post condition.

Diagnose → The error lists valid names; compare with line 22.

Fix → post { success { ... } }.

Prevent → Linting in PR checks catches it before merge.

All Jenkins questions Roadmap: Jenkins

More on Jenkinsfile syntax, Groovy & CPS errors