lib: modules.sh should check JSON output for predictability
#275264
Merged
modules.sh should check JSON output for predictability
#275264