Skip to content

Tried to show an alert while not attached to an Activity #46201

Closed

Description

@birdofpreyru

Description

Migrating my existing libraries / apps from RN@0.74 to the latest RN@0.75.2. Using new architecture, targeting Android. Got Tried to show an alert while not attached to an Activity error when calling Alert.alert('abc', 'def');. Seems to be a regression of an old bug #13439?

P.S.: No, I had no chance yet to check whether it is reproducible in a clean RN app.

Steps to reproduce

Above.

React Native Version

0.75.2

Affected Platforms

Runtime - Android

Areas

Other (please specify)

Output of npx react-native info

N/A

Stacktrace or Logs

N/A

Reproducer

N/A

Screenshots and Videos

No response

Activity

  1. react-native-bot commented on Aug 24, 2024

    @react-native-bot
    Collaborator
    ⚠️ Missing Reproducible Example
    ℹ️ We could not detect a reproducible example in your issue report. Please provide either:
    • If your bug is UI related: a Snack
    • If your bug is build/update related: use our Reproducer Template. A reproducer needs to be in a GitHub repository under your username.
  2. react-native-bot commented on Aug 24, 2024

    @react-native-bot
    Collaborator
    ⚠️ Missing Reproducible Example
    ℹ️ We could not detect a reproducible example in your issue report. Please provide either:
  3. cipolleschi commented on Aug 28, 2024

    @cipolleschi
    Contributor

    @birdofpreyru could you provide a reproducer using this template? You can add whichever library you need to make the reproducer work.

    It's quite hard for us to help out if we don't know how to repro it.

  4. cipolleschi commented on Aug 29, 2024

    @cipolleschi
    Contributor

    It seems to work fine on my side... Am I missing something?

    Screen.Recording.2024-08-29.at.16.32.45.mov
  5. birdofpreyru commented on Aug 29, 2024

    @birdofpreyru
    ContributorAuthor

    Hmm... it works now for me as well 0.o Tried everything that comes to my mind — the older commit at which I was when reporting it, a clean build, a few different Android versions in the emulator... still no problem anymore.

  6. added
    Resolution: AnsweredWhen the issue is resolved with a simple answer
    and removed
    Type: New ArchitectureIssues and PRs related to new architecture (Fabric/Turbo Modules)
    Needs: AttentionIssues where the author has responded to feedback.
    on Sep 11, 2024
  7. camerontbelt commented on Feb 24, 2025

    @camerontbelt

    I had react-native-bottom-action-sheet installed, I started seeing this error and uninstalled bottom sheet and the error resolved.

  8. jenskuhrjorgensen commented on Aug 19, 2025

    @jenskuhrjorgensen

    I got here with the same issue and reading that it magically fixed itself for others made me try to close and reopen the app - and then it was also magically fixed on my end..

  9. Pingou commented on Aug 28, 2025

    @Pingou

    Same problem, a restart helped, there must be some underlying bug though, can we reopen?

  10. jpancotti commented on Feb 12, 2026

    @jpancotti

    Fought this for an hour before finding this and restarting solved mine as well.
    Do we have any idea if this is isolated to dev builds? I am concerned that alerts may be failing in production for whatever the same root cause is...

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

    API: AlertNeeds: ReproThis issue could be improved with a clear list of steps to reproduce the issue.Resolution: AnsweredWhen the issue is resolved with a simple answer

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions