-
Notifications
You must be signed in to change notification settings - Fork 631
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix - removing an async dependency may incorrectly free its target
Summary: Metro's core `Graph` maintains a `CountingSet` of inverse "eager" dependencies for each module - zero inverse dependencies triggers a module's removal from the graph. Currently, this is not decremented with on dependency removals consistently with the way it is incremented. In particular, removing an async dependency (in combination with `options.lazy`) removes an inverse dependency, even though the reverse does not add one. This leads to incorrect deletion of module B from the graph when module A has both sync and async dependencies on B, and the async dependency is removed. ``` * **[Fix]**: Fix Fast Refresh edge case where removing an async dependency could incorrectly remove modules from the graph. ``` Reviewed By: motiz88 Differential Revision: D50309038 fbshipit-source-id: 4a44703ac31fc400736c5666a51ca26783a34d19
- Loading branch information
1 parent
71cf575
commit 5f446f3
Showing
3 changed files
with
75 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters