Failure to read script file should result in a more useful error
Passing a script filename that does not exist to RunScript will cause an AggregateException/InvalidOperationException/NullReferenceException, which will show a red box with the error "One or more errors occurred." when running the debug server and will otherwise go unhandled.
This is certainly an invalid operation, however, the issue being raised here is whether there is anything that could be done to make reporting this error more graceful/useful. The red box will show only the error "One or more errors occurred," which I believe is the AggregateException text. The inner exception, however, does contain a more useful message {"File read exception for asset '
The cause for the invalid filename in our application is still not clear.
The following is the exception information from Windows Event Viewer when running a release bundle build:
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.NullReferenceException
at PCLStorage.FileExtensions+
Exception Info: System.InvalidOperationException
at ReactNative.Chakra.Executor.ChakraJavaScriptExecutor+
Exception Info: System.AggregateException
at System.Threading.Tasks.Task1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].GetResultCore(Boolean)
at ReactNative.Chakra.Executor.ChakraJavaScriptExecutor.RunScript(System.String, System.String)
at ReactNative.Bridge.ReactBridge.RunScript(System.String, System.String)
at ReactNative.Bridge.JavaScriptBundleLoader+FileJavaScriptBundleLoader.LoadScript(ReactNative.Bridge.IReactBridge)
at ReactNative.Bridge.ReactInstance.<InitializeBridgeAsync>b__20_1()
at ReactNative.Bridge.Queue.MessageQueueThreadExtensions+<>c__DisplayClass1_01[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].
@pre10der89 is this still an issue?
@rozele This was a suggestion for improvement in error reporting. I can only assume it is still relevant, but have no qualms if it is closed
This is a valid issue with a repro case and active participant. I’d like to keep it open for people who browse/search open issues.
We are not investing in new features or lower priority bug fixes on vCurrent. The bulk of investment is now in vNext as we prepare to make that the default choice. If this issue is still relevant on the vNext implementation please open a vNext issue. If this issue is of significant severity for a vCurrent app and vNext is not an option, re-open with justification.