callstack / repack

A Webpack-based toolkit to build your React Native application with full support of Webpack ecosystem.
https://re-pack.dev
MIT License
1.49k stars 110 forks source link

Cache value is not valid when script is failed #770

Closed hosseinmd closed 1 month ago

hosseinmd commented 1 month ago

Describe the bug

In some situation, for example network failed when loading a script, The failed script is cached.

System Info

repack 4.3.3
react-native 75.4

Re.Pack Version

4.3.3

Reproduction

https://github.com/callstack/repack

Steps to reproduce

Make your app fail to load remote script, then restart the app. Here the failed script doesn't download again, and it is trying to execute from cache, but there is no cache file.

jbroma commented 1 month ago

@hosseinmd, I'm finishing the work on MF2 and should release V5 RC very soon 🙏 I would put this issue on hold until we can verify that it's also happening on V5

hosseinmd commented 1 month ago

Please review this https://github.com/callstack/repack/pull/771 I made a good test scenario which can show you the problem

jbroma commented 1 month ago

Thank you for handling this @hosseinmd!

Closing since this was fixed by #771.

Fix available in 5.0.0-rc.0 version of Re.Pack.