mirror of
https://github.com/opentffoundation/opentf.git
synced 2025-12-19 17:59:05 -05:00
The GODEBUG environment variable is a side-channel that allows dynamically opting in to a million billion different variations of Go runtime and standard library behavior, and we can obviously not routinely test OpenTofu's behavior across all of those different variations. Just in case someone encounters a problem caused by running OpenTofu with a combination of settings that are not enabled in our default build configuration, we'll include an explicit note in the logs so that we can tell when we're investigating a bug report that it might only be reproducible when the Go runtime behavior has been overridden in this way, and so that someone debugging their own problem can notice that they are using OpenTofu in an unsupported way and could potentially solve their own problem by unsetting that environment variable. This is a generalization of the previous addition of a log message when running in FIPS 140-3 mode, which is also updated here to use [WARN] instead of [WARNING] as the prefix because our logging system does not actually understand "WARNING" as a valid prefix. Keeping the separate specialized message for FIPS 140-3 mode is warranted because we _know_ that OpenTofu does not behave as intended when that mode is enabled, while we've not tested with any other combination of settings so we cannot predict whether they will cause misbehavior or not. Signed-off-by: Martin Atkins <mart@degeneration.co.uk>