(#19779) Call PSON::pretty_generate instead of jj

The `jj` method can be clobbered if other JSON libraries, notably `json_pure`,
are loaded. When this occurs, `puppet master --compile` silently fails to
produce any output.
Merge branch 'pull-1534'

This closes GH-1534.