Skip to content

macOS: app crashes on launch with the New Architecture (no RNCProgressViewComponentView) #180

Done

Description

@Naturalclar

Problem

On macOS with the New Architecture (RCT_NEW_ARCH_ENABLED=1), an app that uses this library crashes on launch:

*** Terminating app due to uncaught exception 'NSInvalidArgumentException',
reason: '*** -[__NSPlaceholderDictionary initWithObjects:forKeys:count:]: attempt to insert nil object from objects[0]'

Reproduced with the example app (react-native-macos 0.81.9) after #179 made it build.

Cause

codegenConfig.ios.componentProvider maps RNCProgressView to RNCProgressViewComponentView. Codegen also uses that for macOS, so the generated RCTThirdPartyComponentsProvider.mm contains:

@"RNCProgressView": NSClassFromString(@"RNCProgressViewComponentView"),

The only RNCProgressViewComponentView is ios/Fabric/RNCProgressViewComponentView.mm, which is UIKit-only (UIProgressView) and isn't compiled on macOS (#179). NSClassFromString returns nil there, and the dictionary literal throws.

The old architecture on macOS is not affected: the example app launches and runs there.

Options

  1. Implement a macOS Fabric component view (NSProgressIndicator-based, mirroring macos/RNCProgressView.m) under the same class name. This gives proper New Architecture support on macOS.
  2. Ship a macOS RNCProgressViewComponentView that falls back to the legacy view through the interop layer. Smaller, but still needs a class with that name on macOS.

Activity

  1. Naturalclar commented on Nov 25, 2026

    @Naturalclar
    MemberAuthor

    🚧 このIssueに着手します。

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions