A sandoxed system script doesn't support multiple assignments (with Tuples):
- This is working in non sandboxed mode, but not in sandboxed mode.
- Reproduced on the latest OSS LTS (2.138.3), with Groovy Plugin version 2.0 and Script Security Plugin version 1.49.
Do not use multiple assignments.
It is supported in a Pipeline (as of workflow-cps 2.46, JENKINS-45575). It also works in non sandboxed mode.