redux-devtools
redux-devtools copied to clipboard
[redux-devtools-inspector] Infinite recursion for circular references
See https://github.com/alexkuz/redux-devtools-inspector/pull/40 for the details and repro. It's related to https://github.com/benjamine/jsondiffpatch/issues/152. The solution suggested there doesn't work for all cases and would impact the perf. Maybe we could add a timeout to prevent crashing the browser.
For the extension by default we are stripping circular references and it's not a problem for most use cases.
@zalmoxisus Would it be acceptable to implement the suggested solution behind a feature flag, or even a circularCheckDepth
prop to specify how many levels it will check for circular references? Currently the standalone debugger is totally freezing on circular references in the specific case outlined in https://github.com/jhen0409/react-native-debugger/issues/249
Should I open a separate issue in remotedev-inspector-monitor
, or will changes here be picked up there as well?
@zalmoxisus I pr'ed a WIP for an alternate solution: https://github.com/zalmoxisus/remotedev-inspector-monitor/pull/6
This tracks visited nodes in order to determine whether a circular reference exists. It still needs some polish but has worked well in my testing so far.
I've experienced same issue. Storing a data with circular dependency in NgRx store and Redux Devtools started to crash. Pls any chance for this bug to be addressed? Or at least mention this somewhere in documentation or QA section.