forge icon indicating copy to clipboard operation
forge copied to clipboard

Parameters and Tags with numeric values with a leading 0 are interpreted as octal

Open nathandines opened this issue 7 years ago • 0 comments

Example:

---
ParameterHere: 0123456  # Result: "42798"
ParameterFail: 0456789  # FAIL: Returns an error due to an invalid octal number

Workaround:

Wrap your values in quotes to prevent it from being parsed as a number.

---
ParameterHere: '0123456'  # Result: "0123456"
ParameterFail: '0456789'  # Result: "0456789"

Potential Corrective Action:

We're a little dependent on the language for this one, and it doesn't look like this one will be fixed: https://github.com/golang/go/issues/151

nathandines avatar Apr 09 '18 22:04 nathandines