On Tue, 15 Sep 2020 at 18:10, Wes Turner <[email protected]> wrote: > > json.loads and json.dumps exist only because there was no way to distinguish > between a string containing JSON and a file path string. > (They probably should've been .loadstr and .dumpstr, but it's too late for > that now)
Well, if you see the code of msutils.jsonLoad I linked before, it does a simple try. Not very elegant, but effective. _______________________________________________ Python-ideas mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/[email protected]/message/2LSXRUEBP2MEE7M3EHCHIGGI2NZ3NROL/ Code of Conduct: http://python.org/psf/codeofconduct/
