Skip to content

Refactor: ReactInstance: Pull "fatal error" bool into JsErrorHandler#43956

Closed
RSNara wants to merge 5 commits intofacebook:mainfrom
RSNara:export-D55547897
Closed

Refactor: ReactInstance: Pull "fatal error" bool into JsErrorHandler#43956
RSNara wants to merge 5 commits intofacebook:mainfrom
RSNara:export-D55547897

Conversation

@RSNara
Copy link
Copy Markdown
Contributor

@RSNara RSNara commented Apr 7, 2024

Summary:
I think we should try to centralize all things js error handling related inside JsErrorHandler. So, I moved this bool into JsErrorHandler.

This makes ReactInstance easier to understand: it removes one member variable from ReactInstance.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D55547897

@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Facebook Partner: Facebook Partner labels Apr 7, 2024
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@analysis-bot
Copy link
Copy Markdown

analysis-bot commented Apr 7, 2024

Platform Engine Arch Size (bytes) Diff
android hermes arm64-v8a 19,217,871 -6
android hermes armeabi-v7a n/a --
android hermes x86 n/a --
android hermes x86_64 n/a --
android jsc arm64-v8a 22,594,643 +12
android jsc armeabi-v7a n/a --
android jsc x86 n/a --
android jsc x86_64 n/a --

Base commit: f77d028
Branch: main

@RSNara RSNara force-pushed the export-D55547897 branch from afa57df to 0c1a27d Compare April 7, 2024 19:04
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from 0c1a27d to bf2659a Compare April 7, 2024 19:21
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from bf2659a to 113aab4 Compare April 7, 2024 19:39
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from 113aab4 to 45110fe Compare April 7, 2024 19:56
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from 45110fe to 376894b Compare April 7, 2024 20:24
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from 376894b to a2ebf00 Compare April 7, 2024 20:36
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from a2ebf00 to c1c19b8 Compare April 7, 2024 23:41
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from c1c19b8 to bbfa898 Compare April 8, 2024 01:15
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from bbfa898 to 76a9bb4 Compare April 8, 2024 17:55
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from 76a9bb4 to 6634a9f Compare April 8, 2024 18:02
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

@RSNara RSNara force-pushed the export-D55547897 branch from 6634a9f to 1a81193 Compare April 8, 2024 18:23
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

RSNara added 5 commits April 8, 2024 12:19
Summary:
getRuntimeScheduler() allows things to schedule work on the js thread by bypassing main bundle buffering.

This is unsafe: almost everything should be using the buffered runtime executor, unless it sets up bindings used in the main bundle.

I filed a task for the investigation to see if there's any problems. And added it to the code in this diff.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D55547899
Summary:
RuntimeScheduler's ErrorUtils.h is redundant.

Let's just remove it.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D55547905
Summary:
Now, all the defaulting is in RuntimeScheduler.h.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D55547900
Summary:
Just makes it easier to pass around JsErrorHandler.

We'll need this in D55547897, when we start storing the "has fataled" boolean inside the JsErrorHandler.

Changelog: [internal]

Reviewed By: cipolleschi

Differential Revision: D55547898
Summary:
I think we should try to centralize all things js error handling related inside JsErrorHandler. So, I moved this bool into JsErrorHandler.

This makes ReactInstance easier to understand: it removes one member variable from ReactInstance.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D55547897
@RSNara RSNara force-pushed the export-D55547897 branch from 1a81193 to 71391db Compare April 8, 2024 19:20
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D55547897

RSNara added a commit to RSNara/react-native that referenced this pull request Apr 8, 2024
…orHandler (facebook#43956)

Summary:

I think we should try to centralize all things js error handling related inside JsErrorHandler. So, I moved this bool into JsErrorHandler.

This makes ReactInstance easier to understand: it removes one member variable from ReactInstance.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D55547897
RSNara added a commit to RSNara/react-native that referenced this pull request Apr 8, 2024
…orHandler (facebook#43956)

Summary:

I think we should try to centralize all things js error handling related inside JsErrorHandler. So, I moved this bool into JsErrorHandler.

This makes ReactInstance easier to understand: it removes one member variable from ReactInstance.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D55547897
@facebook-github-bot facebook-github-bot added the Merged This PR has been merged. label Apr 9, 2024
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request has been merged in ba3e078.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. p: Facebook Partner: Facebook Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants