Skip to content
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

56.0 IOS Can't find variable: window (lldb) #20169

Closed
3 tasks done
kmend opened this issue Jul 12, 2018 · 5 comments
Closed
3 tasks done

56.0 IOS Can't find variable: window (lldb) #20169

kmend opened this issue Jul 12, 2018 · 5 comments
Labels
Platform: iOS iOS applications. Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@kmend
Copy link

kmend commented Jul 12, 2018

Environment

 React Native Environment Info:
    System:
      OS: macOS High Sierra 10.13.5
      CPU: x64 Intel(R) Core(TM) i7-6700HQ CPU @ 2.60GHz
      Memory: 2.82 GB / 16.00 GB
      Shell: 3.2.57 - /bin/bash
    Binaries:
      Node: 8.11.2 - /usr/local/bin/node
      Yarn: yarn install v0.24.5
[1/4] Resolving packages...
success Already up-to-date.
Done in 0.75s. - /usr/local/bin/yarn
      npm: 5.6.0 - /usr/local/bin/npm
      Watchman: 4.9.0 - /usr/local/bin/watchman
    SDKs:
      iOS SDK:
        Platforms: iOS 11.4, macOS 10.13, tvOS 11.4, watchOS 4.3
      Android SDK:
        Build Tools: 23.0.1, 23.0.2, 23.0.3, 25.0.0, 25.0.1, 25.0.2, 25.0.3, 26.0.1, 26.0.2, 26.0.3, 27.0.0, 27.0.3
        API Levels: 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28
    IDEs:
      Android Studio: 3.1 AI-173.4819257
      Xcode: 9.4.1/9F2000 - /usr/bin/xcodebuild
    npmPackages:
      react: 16.4.1 => 16.4.1 
      react-native: 0.56.0 => 0.56.0 
    npmGlobalPackages:
      create-react-native-app: 1.0.0
      react-native-cli: 2.0.1
      react-native-git-upgrade: 0.2.7

Description

bundle production error

An error occurred after the compilation was completed Can't find variable: window

Run scripts

react-native bundle --entry-file index.ios.js --bundle-output ./ios/bundle/index.ios.jsbundle --platform ios --assets-dest ./ios/bundle --dev false --verbose --reset-cache
Compilation success

XCode run Release

2018-07-12 19:16:43.699 [fatal][tid:main] Unhandled JS Exception: Can't find variable: window (/var/containers/Bundle/Application/B9F3C17A-CE82-4514-BD0A-0F3B5647EF48/apdnews.app/main.jsbundle:371)
2018-07-12 19:16:43.699894+0800 apdnews[13373:1580984] Unhandled JS Exception: Can't find variable: window (/var/containers/Bundle/Application/B9F3C17A-CE82-4514-BD0A-0F3B5647EF48/apdnews.app/main.jsbundle:371)
2018-07-12 19:16:43.700093+0800 apdnews[13373:1580984] *** Terminating app due to uncaught exception 'RCTFatalException: Unhandled JS Exception: Can't find variable: window (/var/containers/Bundle/Application/B9F3C17A-CE82-4514-BD0A-0F3B5647EF48/apdnews.app/main.jsbundle:371)', reason: 'Unhandled JS Exception: Can't find variable: window (/var/containers/Bundle...'
*** First throw call stack:
(0x183b6ed8c 0x182d285ec 0x104e2b170 0x104e171f0 0x1057051dc 0x10570519c 0x105709d2c 0x183b17070 0x183b14bc8 0x183a34da8 0x185a19020 0x18da51758 0x104dc2d34 0x1834c5fc0)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)

@react-native-bot
Copy link
Collaborator

It looks like your issue may be missing some necessary information. Can you run react-native info and edit your issue to include these results under the Environment section?

@danielgindi
Copy link
Contributor

Might be related to #20171

@jsu93
Copy link

jsu93 commented Jul 19, 2018

Bump metro version to latest will solve this problem

@stale
Copy link

stale bot commented Oct 18, 2018

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as "For Discussion" or "Good first issue" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Oct 18, 2018
@stale
Copy link

stale bot commented Oct 25, 2018

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.

@stale stale bot closed this as completed Oct 25, 2018
@facebook facebook locked as resolved and limited conversation to collaborators Oct 25, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Platform: iOS iOS applications. Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests

5 participants