You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I encountered the same issue. The reason is that we only add objects to the set seen and never remove them (https://github.com/dpranke/pyjson5/blob/master/json5/lib.py#L210-L215). When detecting circular reference, the object needs to be removed after being processed, i.e., before each return of function _dumps.
When I call
json5.dumps
on a previously loaded and modified object, I get the following exception:My environment info:
Code to recreate the issue (I know there's a logical error since
REGION
is modified for bothdevelopment
andt
):Workaround:
Import
from copy import deepcopy
and changeall_configs["t"] = new_config
toall_configs["t"] = deepcopy(new_config)
.The text was updated successfully, but these errors were encountered: