Open con-f-use opened 2 years ago
@scopatz @gforsyth
json.dumps({"key": LazyObject(lambda: "nope", {}, 'lo')}) # TypeError: Object of type str is not JSON serializable
Gives the confusing (pun) error message of TypeError: Object of type str is not JSON serializable. Yes it is, Mr. Python, Sir!
TypeError: Object of type str is not JSON serializable
Not sure but maybe the __hash__ method must be passed through or something. One might think about pickle and __get_state__, too.
__hash__
__get_state__
@scopatz @gforsyth
Gives the confusing (pun) error message of
TypeError: Object of type str is not JSON serializable
. Yes it is, Mr. Python, Sir!Not sure but maybe the
__hash__
method must be passed through or something. One might think about pickle and__get_state__
, too.