Skip to content

rebase master #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 371 commits into from
Jul 27, 2023
Merged

rebase master #1

merged 371 commits into from
Jul 27, 2023

Conversation

himanshuzeptonow
Copy link
Collaborator

Summary:

Changelog:

Test Plan:

sammy-SC and others added 30 commits June 27, 2023 09:01
Summary:
Pull Request resolved: #38075

changelog: [internal]

`SharedFunction<>` is created with nullptr for its internal `std::function`. If called after created with default constructor, it crashes app. It also does not have API to check if its internal function is not nullptr.

With image cancelation, there is a race between when native component calls `imageRequest.cancel()` and when cancelation function is set in `RCTImageManager`.
To fix this, this diff adds a nullptr check inside SharedFunction. So it is always safe to call.

Reviewed By: javache

Differential Revision: D47022957

fbshipit-source-id: 0a04a87cd1ffe6bf3ca2fded38f689f06cc92ca9
Summary:
I added the contentType parameter to Blob.slice like it's in the MDN Web docs.
This PR fixes #38058

When i slice a Blob for chunked uploads with react native i lost the content type, e.g. "image/jpeg", so the server doesn't know what kind of file he gets. In the docs of MDN the slice method was described with a third contentType parameter which was missing in Metas implementation.
## Changelog:
 [GENERAL] [ADDED] added a third parameter "contentType" to method slice of class Blob.

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: #38078

Test Plan:
I tested it with the unit-tests:
yarn run test Blob-test.js
yarn run v1.22.19
$ jest Blob-test.js
 PASS  packages/react-native/Libraries/Blob/__tests__/Blob-test.js
  Blob
    ✓ should create empty blob (5 ms)
    ✓ should create blob from other blobs and strings
    ✓ should slice a blob (1 ms)
    ✓ should slice a blob and sets a contentType
    ✓ should close a blob (4 ms)

My added unit test results "✓ should slice a blob and sets a contentType".

Reviewed By: hoxyq

Differential Revision: D47057162

Pulled By: blakef

fbshipit-source-id: 0931b0b828f81b9b90562ffd51d4111c81034ffc
Summary:
Pull Request resolved: #38097

Changelog: [Internal]

Reviewed By: mroch

Differential Revision: D47056034

fbshipit-source-id: 3a5f387722b637ad56a7871008bd9afecb0c52c8
Summary:
Pull Request resolved: #37835

Chrome Dev Tools doesn't correctly display grouped console logs (i.e. console output between a `console.group` and `console.groupEnd`) when timestamps are all zero.

Populate the timestamp field so grouping functions as expected.

Changelog: [General] [Fixed] Fix timestamps and grouped display of console messages within in a `console.group`

Reviewed By: fbmal7

Differential Revision: D46605659

fbshipit-source-id: c5821bfb4807c7f0ce28b7bb95ea08de29caf8a2
Summary:
Add getsentry to the React Native incubating partners list.

If you are interested in Sentry's work in the RN Core, see the ReactWG Post -> [Better Error Reporting for the New Architecture
](reactwg/react-native-new-architecture#122)
## Changelog:

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests
-->

[Internal] - Add getsentry to the React Native incubating partners list

Pull Request resolved: #38091

Test Plan: None - Docs update

Reviewed By: cortinico, sammy-SC

Differential Revision: D47060764

Pulled By: blakef

fbshipit-source-id: 9a42a5d9ff9012eb4ec7ffb04fac850c750f3c65
Summary:
I removed the code checking iOS 12 availability because the iOS minimum deployment target is now iOS 12.4 after these commits (982ca30, c71e6ef).

My previous pull requests regarding iOS 11
* [Remove iOS 11 version check by ken0nek · Pull Request #32151 · facebook/react-native](#32151)
* [Remove iOS 11 availability check by ken0nek · Pull Request #32488 · facebook/react-native](#32488)
* [Remove iOS 11 deprecation warnings around SafeArea by ken0nek · Pull Request #32851 · facebook/react-native](#32851)

## Changelog

<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://github.com/facebook/react-native/wiki/Changelog
-->

[iOS] [Changed] - Remove iOS 12 availability check

Pull Request resolved: #33460

Reviewed By: NickGerleman

Differential Revision: D35021632

Pulled By: javache

fbshipit-source-id: bf85d44874a2c10cb345d33df7c9e4789312a7cd
Summary:
Chronos Job Instance ID: 1125907907694341
Sandcastle Job Instance ID: 22517999117287273
allow-large-files
ignore-conflict-markers
opt-out-review

Differential Revision: D47069434

fbshipit-source-id: 89018bf327fbf77f911ad422d512be8c365e2410
…r React Native (#38079)

Summary:
Pull Request resolved: #38079

This diff fixes the
```
out-of-line definition of constexpr static data member is redundant in C++17 and is deprecated [-Werror,-Wdeprecated]
```
error in `RAMBundleRegistry`

## Changelog:
[internal] - Fix Xcode 15 namespace build errors in `RAMBundleRegistry`.

Reviewed By: javache, cipolleschi

Differential Revision: D46988689

fbshipit-source-id: 5dc34b0f7d6fb266bc379b3639244bf69505aa88
Summary:
Pull Request resolved: #38098

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D47065254

fbshipit-source-id: 77c4694d8e1b31ef4dbd60cbf30d8fa1267a2819
Summary:
Pull Request resolved: #38085

Changelog: [Internal]

the path instance attribute on `Project` is not actually supposed to be `String`, but `Pathname`: https://www.rubydoc.info/github/CocoaPods/Xcodeproj/Xcodeproj/Project#path-instance_method

i need this actually to be a pathname, so doing the refactor in this diff

Reviewed By: cipolleschi

Differential Revision: D47041355

fbshipit-source-id: 8b43c3a6f1cbc0f930749f380bd9d06ed44c0c37
Summary:
Pull Request resolved: #38106

Changelog: [Internal]

Reviewed By: gkz

Differential Revision: D47081653

fbshipit-source-id: e739ac2c868aed39bc5168607074fc2ee69b49ae
… bridgeless mode (#37865)

Summary:
Pull Request resolved: #37865

In bridge mode UIManager's `constants` contain view configs for every registered native component and possibly some extra data.

On iOS there is no extra data, but on Android in addition to view configs there are `genericBubblingEventTypes` and `genericDirectEventTypes`. They are then [merged](https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/ReactNative/getNativeComponentAttributes.js#L110-L116) into `bubblingEventTypes` and `directEventTypes` of every view config.

This diff replaces `getNativeViewConfig` binding with `getConstants` to make this behaviour possible in the bridgeless mode.

This diff also removes caching on native side with the expectation that `constants` will be cached on JS side just as [it is done](https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/ReactNative/PaperUIManager.js#L24-L32) in bridge mode.

Changelog: [Internal] - Expose UIManager.getConstants instead of getNativeViewConfig to JS in bridgeless mode.

Reviewed By: RSNara

Differential Revision: D46698717

fbshipit-source-id: f9c96e220e49f6947766336ea545c01e38cb46ac
Summary:
Pull Request resolved: #38092

Reverts #36777.

This is motivated by reducing user friction when the widespread assumption is for `react-native/metro-config` to export a complete Metro config, as with Expo/rnx-kit, and like previously understood uses of `metro-config`. See facebook/metro#1010 (comment) for further notes.

Fixes:
- facebook/metro#1010
- #38069
- kristerkari/react-native-svg-transformer#276

Note that we do not intend for `react-native/metro-config` to directly export `assetExts` etc — these can be accessed on the `resolver` property from the full config object.

Changelog: [General][Changed] `react-native/metro-config` now includes all base config values from `metro-config`

Reviewed By: robhogan

Differential Revision: D47055973

fbshipit-source-id: 5ad23cc9700397110de5c0e81c7d76299761ef0a
Summary:
Chronos Job Instance ID: 1125907908196726
Sandcastle Job Instance ID: 13510799864709483
allow-large-files
ignore-conflict-markers
opt-out-review

Differential Revision: D47092881

fbshipit-source-id: 857554a3854e3d421a075f2d3d66adce6ee01c62
Summary:
Pull Request resolved: #38104

With the introduction of [new utility types](https://flow.org/en/docs/types/utilities/#toc-return-type) in Flow, these $Call are no longer needed

Changelog: [Internal]

Reviewed By: javache

Differential Revision: D47078502

fbshipit-source-id: 7fc5f6aa08052b8de8e3f0a45ce2d7a24cb4e1b5
Summary:
According to the podfiles, the minimum version is 13.4

## Changelog:

[General] [Fixed] - Updated docs to match iOS 13.4 minimum requirement.

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: #38108

Reviewed By: jacdebug

Differential Revision: D47093313

Pulled By: blakef

fbshipit-source-id: f59b1be3a6608082fd680e42396aff9a269c77a0
Summary:
Pull Request resolved: #38086

Changelog: [Internal]

in this diff, we update the developer's Info.plists to have the correct ATS settings

introducing usage of files: https://www.rubydoc.info/github/CocoaPods/Xcodeproj/Xcodeproj/Project#files-instance_method, in order to retrieve the plists

Reviewed By: cipolleschi

Differential Revision: D47041590

fbshipit-source-id: 3797ab18cf4f25ee377c8155a8cc4bb61f2bdcf1
Summary:
Pull Request resolved: #38084

Changelog: [Internal]

addings tests for D47041590

Reviewed By: cipolleschi

Differential Revision: D46961587

fbshipit-source-id: 6b93a20c8539d692db2f84836a0ab79d899197fa
Summary:
Pull Request resolved: #37923

Changelog: [Internal]

in this change, i'm looking to make sure our app template will not violate apple best practices and minimize probability of app rejection.

this change entails two guardrails:
- explicitly marking disabling ATS as disabled with a comment. even though this is already the case, this will make it more unlikely someone will override this
- replacing the localhost domain override with the apple provided NSAllowsLocalNetworking key, which is the recommendation

Reviewed By: sammy-SC

Differential Revision: D46707159

fbshipit-source-id: 8fe407d08767269a18fb15c80fdd83a58cf2a4a8
Summary:
Fix the following error:
 {F1038388240}

Calling ```setRuntimeConfigProvider``` multiple times is not always a wrong behaviour, the following could happen and before this diff App C will raise above error:
- App A has main bundle X
- App B has main bundle Y
- App C has main bundle X and bundle Y

To fix we guarantee ```setRuntimeConfigProvider``` only called once instead of raising an error.

Changelog:
[iOS][Changed] Fix setRuntimeConfigProvider called multiple times error

Reviewed By: dmytrorykun

Differential Revision: D47094267

fbshipit-source-id: c8473f4f7d639a73e0201c6d72781c01e6cf95fd
Summary:
Pull Request resolved: #38114

Changelog: [Android] [Internal] - W3CPointerEvents: add unit test for JSPointerDispatcher

This adds a basic test for JSPointerDispatcher. Right now this asserts that when a MotionEvent with ACTION_DOWN is received, we send out a pointerdown event.

There's a lot to be desired here in terms of e.g. ensuring that we're dispatching the event to the right target, which we can pursue as future work (of course, more complex test cases should also be added). I suspect we'll need to do a bit more refactoring to make this code more deeply testable (e.g. right now it's not straightforward to access Event properties from the test).

Reviewed By: javache

Differential Revision: D47035119

fbshipit-source-id: 1b49e2458325d6f0cc53d3b7ade8d6328141360f
Summary:
Pull Request resolved: #38081

Changelog: [Internal]

As part of refactoring ReactSurface, ensuring the methods expose interfaces instead of internal classes, e.g. use TaskInterface instead of Task,

Reviewed By: cortinico

Differential Revision: D47026648

fbshipit-source-id: 5fc42693b307af057b51a869133c52de0b1dca3a
Summary:
Chronos Job Instance ID: 1125907908530012
Sandcastle Job Instance ID: 9007200235834664
allow-large-files
ignore-conflict-markers
opt-out-review

Differential Revision: D47108063

fbshipit-source-id: c355735d9db580cb63e2628ba8ab5ca1e94108fd
Summary:
Chronos Job Instance ID: 1125907908625836
Sandcastle Job Instance ID: 985666883
allow-large-files
ignore-conflict-markers
opt-out-review

Differential Revision: D47117968

fbshipit-source-id: 66b6978e1099d9f2bba668dfd9fafadbe398eca9
Summary:
Pull Request resolved: #38126

Towards react-native-community/cli#1987. Will be paired with a CLI PR targeting React Native 0.72.1.

Changelog: None

Reviewed By: motiz88

Differential Revision: D47125080

fbshipit-source-id: b3b9d93ba747240f5168021ccb793ffe5d34251d
Summary:
X-link: facebook/yoga#1317

Pull Request resolved: #37374

This is edge-casey enough, and I actually broke this in D42282358 without us noticing (I changed height to width of the bottom usage, instead, copy/pasting the value of the top one).

Reviewed By: yungsters

Differential Revision: D45766764

fbshipit-source-id: b600b79b8436534fe48ef2acbfde8ba64068e593
Summary:
Changelog: [Internal] - Update some RNTester examples to allow for internal snapshot tests

Pull Request resolved: #38045

From 0.72 border breakage, adding screenshot tests for our border examples in RNTester

Reviewed By: NickGerleman

Differential Revision: D46993114

fbshipit-source-id: b2d569c8a09098271ed74a6a88744ae75e373003
Summary:
Chronos Job Instance ID: 1125907909241891
Sandcastle Job Instance ID: 4503600611310924
allow-large-files
ignore-conflict-markers
opt-out-review

Differential Revision: D47142727

fbshipit-source-id: 5889656b2714716a3b12862a898a9b1a235f3bdc
Summary:
This fixes a bug that started with React Native 0.72.0 when using the new architecture and installing a native lib that has Swift code (in my case, `datadog/mobile-react-native`).

Running `pod install` errors with the following output (`DatadogSDKReactNative` is the pod containing the Swift code):

```
[...]
Analyzing dependencies
Downloading dependencies
Installing DatadogSDKReactNative 1.8.0-rc0
[!] The following Swift pods cannot yet be integrated as static libraries:

The Swift pod `DatadogSDKReactNative` depends upon `React-Fabric`, `React-graphics`, `React-utils`, and `React-debug`, which do not define modules. To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set `use_modular_headers!` globally in your Podfile, or specify `:modular_headers => true` for particular dependencies.
```

Indeed, this pods were added as dependencies in `packages/react-native/scripts/cocoapods/new_architecture.rb` but do not define modules contrary to the other pods in the list.

This PR is solving a problem that already occured in the past and was solved here: #33743
It's a new implementation for the PR initially opened here: #38039

## Changelog:
[IOS] [FIXED] - Fix pod install for libraries using Swift code when the new architecture is enabled

Pull Request resolved: #38121

Test Plan:
1. Clone [this](https://github.com/louiszawadzki/react-native) repo
2. From `main`, add a Swift file to the `MyNativeView` native module in the RN tester app (see inspiration from [this commit](fortmarek@26958fc))
3. Try to run `RCT_NEW_ARCH_ENABLED=1 USE_HERMES=0 bundle exec pod install` inside the `packages/rn-tester`
4. Observe errors
5. Apply [the commit](7b7c3ff) from this PR
6. Both pod install and the subsequent build should succeed.
7. Revert the changes and repeat steps 2 to 6 with `RCT_NEW_ARCH_ENABLED=1 USE_HERMES=1 bundle exec pod install`

Reviewed By: cortinico

Differential Revision: D47127854

Pulled By: cipolleschi

fbshipit-source-id: bf7f65e0d126195a76a0fafbe2f3172f00d5adc1
Summary:
Adds changelog for new patch.

## Changelog:

<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests
-->

[Internal] [Changed] - add changelog entry for 0.72.1

Pull Request resolved: #38131

Test Plan: N/A

Reviewed By: cortinico

Differential Revision: D47149515

Pulled By: cipolleschi

fbshipit-source-id: 737032c204d68749770801fa34ecb8d212b8958f
Intl Scheduler and others added 28 commits July 24, 2023 14:56
Summary:
Chronos Job Instance ID: 1125907928272332
Sandcastle Job Instance ID: 31525198392657606
allow-large-files
ignore-conflict-markers
opt-out-review

Differential Revision: D47736198

fbshipit-source-id: 680439ecbf2dd89d7c5d2902c9d94ddeaf7c8161
Summary:
Currently, `metro-config` does not have `hermes-parser` enabled by default. This is because `hermes-parser` does not yet support parsing all of TypeScript's syntax nodes.

However, this also means we cannot yet utilize any Flow langauge features that require the use of `hermes-parser` (and are unsupported by Babel). Mapped types falls into this category, so we cannot use them.

This backs out a recent change that tried to adopt Flow mapped types in `EventEmitter`, for now. We can revisit after making the necessary changes to `metro-config`.

Changelog:
[Internal]

Reviewed By: pieterv

Differential Revision: D47729818

fbshipit-source-id: ec90b38e113a9c3ad952f33777fabbd82519cffb
Summary:
With moving the TypeScript declarations into the repo, the NativeSyntheticEvent type was copied incorrectly from DefinitelyTyped.

This was the old one: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/react-native/v0.70/index.d.ts#L355

## Changelog:

[GENERAL] [FIXED] - Correct the NativeSyntheticEvent type

Pull Request resolved: #38600

Test Plan: Added a test and ran `yarn test-typescript`

Reviewed By: NickGerleman

Differential Revision: D47739191

Pulled By: lunaleaps

fbshipit-source-id: 0c8b51a62f589a716121e9bfa8ce7e6103f37f6b
Summary:
X-link: facebook/relay#4391

Pull Request resolved: #38605

Changelog: [Internal]

Reviewed By: samwgoldman

Differential Revision: D47744471

fbshipit-source-id: 8e2e2e55610020cc6b85cd73d0221bf23c4b7c3b
Summary:
Pull Request resolved: #38551

I think we can safely remove the StaticFrameworks tests: the DynamicFrameworks are stricter than the static, so if something works in a dynamic frameworks setup, it will work also in the static framework one.

we can safely delete the following tests
- test_ios_template-NewArch-Debug-WithoutFlipper-Hermes-StaticFrameworks
- test_ios_template-NewArch-Debug-WithoutFlipper-JSC-StaticFrameworks
- test_ios_template-NewArch-Release-WithoutFlipper-Hermes-StaticFrameworks
- test_ios_template-NewArch-Release-WithoutFlipper-JSC-StaticFrameworks
- test_ios_template-OldArch-Debug-WithoutFlipper-Hermes-StaticFrameworks
- test_ios_template-OldArch-Debug-WithoutFlipper-JSC-StaticFrameworks
- test_ios_template-OldArch-Release-WithoutFlipper-Hermes-StaticFrameworks
- test_ios_template-OldArch-Release-WithoutFlipper-JSC-StaticFrameworks
- test_ios_rntester-NewArch-Hermes-StaticFrameworks
- test_ios_rntester-NewArch-JSC-StaticFrameworks
- test_ios_rntester-OldArch-Hermes-StaticFrameworks
- test_ios_rntester-OldArch-JSC-StaticFrameworks

## Changelog
[Internal] - Remove static frameworks tests in CircleCI

Reviewed By: dmytrorykun

Differential Revision: D47669902

fbshipit-source-id: 4888bbf88bb23284e410936910e5f71c969408d0
Summary:
Pull Request resolved: #38611

For Ruby tests, we are already testing the least recent (2.6.10) and the most recent version (3.2.0).

Testig on 2.7.7 (a minor greater than 2.6.10) was an over-cautious measure we can safely remove now after few months where we saw that no changes broke this specific version of ruby.

## Changelog:
[Internal] - Remove tests on Ruby 2.7.7

Reviewed By: cortinico

Differential Revision: D47715594

fbshipit-source-id: 854b5e0369f390d8801b72f1231fe6ce30069e09
Summary:
Chronos Job Instance ID: 1125907928667724
Sandcastle Job Instance ID: 9007200254843019
allow-large-files
ignore-conflict-markers
opt-out-review

Differential Revision: D47757619

fbshipit-source-id: 73a096ce8946bce00007412b6eb3a6c2570ce1da
…#36267)

Summary:
The motivation is to create an E2E testing solution for the RNTester app that can be used to flag when things break and the release crew can use to validate more of the codebase ahead of a release.

This first PR wants to just showcase the main flow (how tests are made, where the E2E folder lives, how it's used by CircleCI) and then we can build on top of it with subsequent PRs, with the help of an umbrella issue to get the community involved in making more tests!

This work is being done cooperation with Callstack developers (mateuszm22 , adzironman, and others) - reason why the branch [lives in a fork](https://github.com/mateuszm22/react-native/tree/k%2Bm/new-rn-tester-E2E).

### [Read the RFC for more details ](react-native-community/discussions-and-proposals#684)

### Extra notes

We are still on WebDriverIO 7 because during the exploratory phase, WDIO was a bit problematic and the workarounds needed to make it work don't seem very nice - see this PR: kelset/react-native-e2e-jest-appium-webdriverio#4 --- this will be revisited in the future, once there's a better path for upgrading.

### Things that will be handled as follow up work

* upgrade to WDIO 8
* [an automated yarn run-e2e-test script](#36267 (comment))
* [a small refactoring into a js script](#36267 (comment))

## Changelog:

[INTERNAL] [ADDED] - Added first working configuration for e2e testing

Pull Request resolved: #36267

Test Plan:
You can play with this locally by [follow the readme](https://github.com/mateuszm22/react-native/blob/k+m/new-rn-tester-E2E/packages/rn-tester-e2e/README.md).

CircleCI jobs will be added.

Reviewed By: cipolleschi

Differential Revision: D46225747

Pulled By: cortinico

fbshipit-source-id: e5428c439afd84ed3dd219d6ada538263120d7c6
Summary:
Fixes exception thrown when `getJavaScriptExecutorFactory()` is not implemented on bridgeless.

Changelog: [Internal]

Reviewed By: cortinico

Differential Revision: D47755422

fbshipit-source-id: 80170db521ab02c4f23c9ddf3c2f5b0381df020b
…ium, WDIO and Jest

Differential Revision:
D46225747

Original commit changeset: e5428c439afd

Original Phabricator Diff: D46225747

fbshipit-source-id: b2136b5338a38fc52493f5c9a47dcb806d6a5f52
Summary:
Bumps NDK to current LTS Release.

## Changelog:

[Android] [Changed] - Bump NDK to 25

Pull Request resolved: #37974

Test Plan: CI Green ✅

Reviewed By: christophpurrer

Differential Revision: D47754763

Pulled By: cortinico

fbshipit-source-id: 24fbca503b3814c28a05aada5223c741e14bda28
Summary:
Pull Request resolved: #38515

Regenerate `babel/traverse` and `babel/types` Flow library definitions from the runtime code at the current lockfile versions, using Metro's `yarn update-babel-flow-lib-defs`.

Changelog: [Internal]

Reviewed By: motiz88

Differential Revision: D47588687

fbshipit-source-id: 065a741ce4a9d765427455a26d23892ea6401f9a
Summary:
Pull Request resolved: #38601

This file is forked in out of tree platforms as:

- macOS > https://github.com/microsoft/react-native-macos/blob/main/Libraries/Components/SafeAreaView/SafeAreaView.js#L28-L33
- Windows > https://github.com/microsoft/react-native-windows/blob/0.71-stable/vnext/src/Libraries/Components/SafeAreaView/SafeAreaView.windows.js#L30-L36

The change here removes the need of forking this file

Changelog:
[General] [Fixed] - [SafeAreaView] Remove need for platform overrides in SafeAreaView.js

Reviewed By: NickGerleman

Differential Revision: D47734944

fbshipit-source-id: 84249a3b3e7e3807b3d5ee4bfa4b1cb140541b8b
…plementedView (#38608)

Summary:
Pull Request resolved: #38608

This file is forked in out of tree platforms as:

- macOS > https://github.com/microsoft/react-native-macos/blob/main/Libraries/Components/ProgressBarAndroid/ProgressBarAndroid.macos.js
- Windows > https://github.com/microsoft/react-native-windows/blob/0.71-stable/vnext/src/Libraries/Components/ProgressBarAndroid/ProgressBarAndroid.windows.js

The change here removes the need of forking this file

Changelog:
[General] [Fixed] - [ProgressBarAndroid] Remove need for each platform to implement ProgressBarAndroid as UnimplementedView

Reviewed By: rozele

Differential Revision: D47747116

fbshipit-source-id: 8c6d40baf8efc69fc8bf359ab400b6d2eec03839
…mplementedView (#38609)

Summary:
Pull Request resolved: #38609

This file is forked in out of tree platforms as:

- macOS > https://github.com/microsoft/react-native-macos/blob/main/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.macos.js
- Windows > https://github.com/microsoft/react-native-windows/blob/0.71-stable/vnext/src/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.windows.js

The change here removes the need of forking this file

Changelog:
[General] [Fixed] - [DrawerAndroid] Remove need for each platform to implement DrawerLayoutAndroid as UnimplementedView

Reviewed By: rozele

Differential Revision: D47747205

fbshipit-source-id: 67d79243d63a5494963330d6edd06749abe6741b
…tedView (#38606)

Summary:
Pull Request resolved: #38606

Today, any host platform implementation of React Native must add ToastAndroid.platform.js.

- https://github.com/microsoft/react-native-macos/blob/main/Libraries/Components/ToastAndroid/ToastAndroid.macos.js
- https://github.com/microsoft/react-native-windows/blob/0.71-stable/vnext/src/Libraries/Components/ToastAndroid/ToastAndroid.windows.js

Now they don't have to do it anymore.

Changelog:
[General] [Fixed] - ToastAndroid] Remove need for each platform to implement ToastAndroid as UnimplementedView

Reviewed By: rozele

Differential Revision: D47744187

fbshipit-source-id: 510aa7aa00a768ba5a37f3d40246f7ef620e0b58
Summary:
Pull Request resolved: #38607

Today, any host platform implementation of React Native must add Settings.platform.js.

- https://github.com/microsoft/react-native-windows/blob/0.71-stable/vnext/src/Libraries/Settings/Settings.windows.js

Now they don't have to do it anymore.

For this case, macOS actually wants to share the iOS specific logic > https://github.com/microsoft/react-native-macos/blob/main/Libraries/Settings/Settings.macos.js

Changelog:
[General] [Fixed] - [Settings] Remove need for platform overrides to Settings

Reviewed By: rozele

Differential Revision: D47747018

fbshipit-source-id: 8e4e8d318b3285a9a64e0b4f052f721f6242f871
Summary:
Pull Request resolved: #38627

Upgrade hermes parser packages to the latest released versions.

Changelog is here: https://github.com/facebook/hermes/blob/main/tools/hermes-parser/js/CHANGELOG.md

Changelog: [Internal]

Reviewed By: SamChou19815

Differential Revision: D47763733

fbshipit-source-id: 773da536034a57b540649a91507b4bf278d7e815
Summary:
The bot message is split in a wrong way:
#38603 (comment)
I'm updating it to use `<br/><br/>` instead which renders correctly inside tables.

Changelog:
[Internal] [Changed] - Properly split the "Too Old Version of React Native" message

Reviewed By: NickGerleman

Differential Revision: D47764363

fbshipit-source-id: 7a80f03b4228a3f0c69d718b8eb60ecd4ac60a2b
…tters to lowercase or uppercase in TextInput"

Summary:
Changelog: [Internal] - Back out #35929 due to #35929 (comment)

Original Phabricator Diff: D47243817

Reviewed By: sunzhaoyuan

Differential Revision: D47785787

fbshipit-source-id: 81598be3f0b4e0e753dfbee4cee781673f900827
Summary:
Pull Request resolved: #38613

The `value` string of the ReactAccessibilityDelegate's `fromValue` method is marked as `Nullable`, however the `null` case is not handled.

This change handle the `null` case setting the accesssibility role to NONE.

## Changelog:
[Android][Fixed] - Set the accessibility role to `NONE` when a `null` string is passed to `fromValue`

Reviewed By: cortinico

Differential Revision: D47752098

fbshipit-source-id: e8a44bdd8874e996d8127cb2ee29e5135210b196
Summary:
The `Request` interface provided by `types/react-native` doesn't have a `signal` property when it should as this is something that is accessible on the `Request` object.

![image](https://github.com/facebook/react-native/assets/10697889/f2d75973-61ff-4874-ad8e-2c0898b82d27)

For example, running the following:

#### Without providing a `signal`

```ts
console.log(new Request('https://www.facebook.com'));
```

will result in the following:

```ts
{"_bodyInit": undefined, "_bodyText": "", "bodyUsed": false, "credentials": "same-origin", "headers": {"map": {}}, "method": "GET", "mode": null, "referrer": null, "signal": {}, "url": "https://www.facebook.com"}
```

## Changelog:

[GENERAL] [FIXED] - Fixed missing property `signal` for the `Request` interface

## Reproduce

1. Add `new Request('https://www.facebook.com').signal` to a typescript file
2. TS will error `Property 'signal' does not exist on type 'Request'`

Pull Request resolved: #38536

Test Plan:
Adding to `global.d.ts` in a file will resolve the problem, demonstrating that this works.

```ts
interface Request {
    readonly signal: AbortSignal | undefined
}
```

Reviewed By: NickGerleman

Differential Revision: D47660506

Pulled By: jacdebug

fbshipit-source-id: ef1459fbaca5d8f31bf8539bd61ac5e447111fec
Summary:
Pull Request resolved: #38634

To reduce the noise of the `check-for-reproducer` bot, this restricts the event
that trigger the bot to only the issue creation.

Changelog:
[Internal] [Changed] - Let check-for-reproducer run only on newly created issues

Reviewed By: cipolleschi

Differential Revision: D47792374

fbshipit-source-id: 738a9342899e234022029e94f43b0dccebc21819
…#36267)

Summary:
The motivation is to create an E2E testing solution for the RNTester app that can be used to flag when things break and the release crew can use to validate more of the codebase ahead of a release.

This first PR wants to just showcase the main flow (how tests are made, where the E2E folder lives, how it's used by CircleCI) and then we can build on top of it with subsequent PRs, with the help of an umbrella issue to get the community involved in making more tests!

This work is being done cooperation with Callstack developers (mateuszm22 , adzironman, and others) - reason why the branch [lives in a fork](https://github.com/mateuszm22/react-native/tree/k%2Bm/new-rn-tester-E2E).

### [Read the RFC for more details ](react-native-community/discussions-and-proposals#684)

### Extra notes

We are still on WebDriverIO 7 because during the exploratory phase, WDIO was a bit problematic and the workarounds needed to make it work don't seem very nice - see this PR: kelset/react-native-e2e-jest-appium-webdriverio#4 --- this will be revisited in the future, once there's a better path for upgrading.

### Things that will be handled as follow up work

* upgrade to WDIO 8
* [an automated yarn run-e2e-test script](#36267 (comment))
* [a small refactoring into a js script](#36267 (comment))

## Changelog:

[INTERNAL] [ADDED] - Added first working configuration for e2e testing

Pull Request resolved: #36267

Test Plan:
You can play with this locally by [follow the readme](https://github.com/mateuszm22/react-native/blob/k+m/new-rn-tester-E2E/packages/rn-tester-e2e/README.md).

CircleCI jobs will be added.

Reviewed By: cipolleschi

Differential Revision: D47763012

Pulled By: cortinico

fbshipit-source-id: 6eb9674182b8ee97aea4784158c69bf017f379e5
Summary:
Pull Request resolved: #38623

Changelog: [Internal]

Looks like this field is unused.

Reviewed By: robhogan

Differential Revision: D47758294

fbshipit-source-id: 5bf9f8c11eba07a2074290b2b35f4432c80eaa5d
Summary:
Pull Request resolved: #38638

A new stable version of Android Gradle Plugin has just been released which I'm bumping over here, and applying all the required changes.

Changelog:
[Internal] [Changed] - Bump AGP to 8.1.0

Reviewed By: cipolleschi

Differential Revision: D47798273

fbshipit-source-id: 57672b10444ffb6079aa5881ff09d033d2a5e895
Summary:
Pull Request resolved: #38642

isHighlighted is only used for iOS. Even macOS disables it (see microsoft#1346).

This change ensures that the isHighlighted prop is only updated for iOS.

## Changelog:

[General] [Fixed] - Avoids re-renders during text selection on desktop platforms by limiting native-only `isHighlighted` prop to iOS

Reviewed By: lenaic, sammy-SC

Differential Revision: D47800845

fbshipit-source-id: af109be17027b2fbc9408e2ec9e1b841c709fe35
…ts/view (#38637)

Summary:
Pull Request resolved: #38637

ComponentDescriptor and ConcreteComponentDescriptor expose a virtual method to interpolate props for LayoutAnimation. The implementation of this virtual method in ConcreteComponentDescriptor calls ViewPropsInterpolation, creating a circular dependency between react/renderer/core and react/renderer/components/view.

To break this circular dependency, this change lifts the props interpolation functionality out of ComponentDescriptor into LayoutAnimationKeyFrameManager.

Please note, while this is technically a "breaking" change, as component descriptors for 3p components may have overridden this method, it's not supported because LayoutAnimation only works on View props.

## Changelog:
[General] [Breaking] - Remove interpolateProps functionality from ComponentDescriptor to fix circular dependency between react/renderer/core and react/renderer/components/view

Reviewed By: christophpurrer

Differential Revision: D47797967

fbshipit-source-id: 5285da7cc9de29f21ce14c96b850a3c58c579e94
@himanshuzeptonow himanshuzeptonow merged commit 3ec19aa into zeptonow:main Jul 27, 2023
amitmundraz08 pushed a commit that referenced this pull request Jun 12, 2025
…tion for existing view (facebook#51294)

Summary:
Pull Request resolved: facebook#51294

changelog: [internal]

Fix a crash where a node that is supposed to be culled doesn't get visited because culling context is not updated.
The differentiator would generate a create instruction for a view that already exists.

Stack trace for the crash:
```
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT
  * frame #0: 0x0000000111740874 libsystem_kernel.dylib`__pthread_kill + 8
    frame #1: 0x00000001117aa2ec libsystem_pthread.dylib`pthread_kill + 264
    frame #2: 0x0000000180171ea8 libsystem_c.dylib`abort + 100
    frame #3: 0x00000001802b0144 libc++abi.dylib`abort_message + 128
    frame #4: 0x000000018029fe4c libc++abi.dylib`demangling_terminate_handler() + 296
    frame #5: 0x000000018006f220 libobjc.A.dylib`_objc_terminate() + 124
    frame #6: 0x00000001375d1964 INFRAFramework`meta_terminate() + 5468
    frame #7: 0x00000001802af570 libc++abi.dylib`std::__terminate(void (*)()) + 12
    frame #8: 0x00000001802b2498 libc++abi.dylib`__cxxabiv1::failed_throw(__cxxabiv1::__cxa_exception*) + 32
    frame #9: 0x00000001802b2478 libc++abi.dylib`__cxa_throw + 88
    frame #10: 0x0000000180093904 libobjc.A.dylib`objc_exception_throw + 384
    frame #11: 0x0000000180e6999c Foundation`-[NSAssertionHandler handleFailureInFunction:file:lineNumber:description:] + 268
    frame #12: 0x000000031a3bcfc8 XPLAT_6_Framework`-[RCTComponentViewRegistry dequeueComponentViewWithComponentHandle:tag:] + 528
    frame facebook#13: 0x000000031a3ccdec XPLAT_6_Framework`RCTPerformMountInstructions(std::__1::vector<facebook::react::ShadowViewMutation, std::__1::allocator<facebook::react::ShadowViewMutation>> const&, RCTComponentViewRegistry*, RCTMountingTransactionObserverCoordinator&, int) + 356
    frame facebook#14: 0x000000031a3ccc7c XPLAT_6_Framework`-[RCTMountingManager performTransaction:]::$_1::operator()(facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&) const + 80
    frame facebook#15: 0x000000031a3ccc20 XPLAT_6_Framework`decltype(std::declval<-[RCTMountingManager performTransaction:]::$_1&>()(std::declval<facebook::react::MountingTransaction const&>(), std::declval<facebook::react::SurfaceTelemetry const&>())) std::__1::__invoke[abi:ne190102]<-[RCTMountingManager performTransaction:]::$_1&, facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&>(-[RCTMountingManager performTransaction:]::$_1&, facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&) + 40
    frame facebook#16: 0x000000031a3ccbc8 XPLAT_6_Framework`void std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:ne190102]<-[RCTMountingManager performTransaction:]::$_1&, facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&>(-[RCTMountingManager performTransaction:]::$_1&, facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&) + 40
    frame facebook#17: 0x000000031a3ccb94 XPLAT_6_Framework`std::__1::__function::__alloc_func<-[RCTMountingManager performTransaction:]::$_1, std::__1::allocator<-[RCTMountingManager performTransaction:]::$_1>, void (facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&)>::operator()[abi:ne190102](facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&) + 44
    frame facebook#18: 0x000000031a3cba1c XPLAT_6_Framework`std::__1::__function::__func<-[RCTMountingManager performTransaction:]::$_1, std::__1::allocator<-[RCTMountingManager performTransaction:]::$_1>, void (facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&)>::operator()(facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&) + 44
    frame facebook#20: 0x000000032f219804 XPLAT_1_Framework`std::__1::function<void (facebook::react::MountingTransaction const&, facebook::react::SurfaceTelemetry const&)>::operator()(this=0x000000016d4f0c78, __arg=0x000000016d4f0a10, __arg=0x000000016d4f0978) const at function.h:989:10
    frame facebook#21: 0x000000032f219668 XPLAT_1_Framework`facebook::react::TelemetryController::pullTransaction(this=0x00000003f4680f00, willMount=0x000000016d4f0c98, doMount=0x000000016d4f0c78, didMount=0x000000016d4f0c58) const at TelemetryController.cpp:39:3
    frame facebook#22: 0x000000031a3c5b28 XPLAT_6_Framework`-[RCTMountingManager performTransaction:] + 544
    frame facebook#23: 0x000000031a3c5864 XPLAT_6_Framework`-[RCTMountingManager initiateTransaction:] + 456
    frame facebook#24: 0x000000031a3c5240 XPLAT_6_Framework`__42-[RCTMountingManager scheduleTransaction:]_block_invoke + 308
    frame facebook#25: 0x0000000131f81b84 BOTTOMFramework`__RCTExecuteOnMainQueue_block_invoke + 40
    frame facebook#26: 0x000000018017c788 libdispatch.dylib`_dispatch_call_block_and_release + 24
    frame facebook#27: 0x0000000180197278 libdispatch.dylib`_dispatch_client_callout + 12
    frame facebook#28: 0x00000001801b2fcc libdispatch.dylib`_dispatch_main_queue_drain.cold.7 + 24
    frame facebook#29: 0x000000018018c1c4 libdispatch.dylib`_dispatch_main_queue_drain + 1184
    frame facebook#30: 0x000000018018bd14 libdispatch.dylib`_dispatch_main_queue_callback_4CF + 40
    frame facebook#31: 0x0000000180427fec CoreFoundation`__CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 12
    frame facebook#32: 0x00000001804229f8 CoreFoundation`__CFRunLoopRun + 1920
    frame facebook#33: 0x0000000180421e3c CoreFoundation`CFRunLoopRunSpecific + 536
    frame facebook#34: 0x0000000190f62d00 GraphicsServices`GSEventRunModal + 164
    frame facebook#35: 0x0000000185bcec98 UIKitCore`-[UIApplication _run] + 796
    frame facebook#36: 0x0000000185bd3064 UIKitCore`UIApplicationMain + 124
    frame facebook#37: 0x0000000115fbf0bc PRODUCTFramework`main + 200
    frame facebook#38: 0x00000001114293d8 dyld_sim`start_sim + 20
    frame facebook#39: 0x0000000111506b4c dyld`start + 6000
```

Reviewed By: rubennorte

Differential Revision: D74654157

fbshipit-source-id: 9181bcd28524c71d0ca4620bd630dc0baa172386
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.