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

The app has not responded to the network requests below: (id = -1000) isReady: {} #3754

Closed
marcoizzo opened this issue Dec 12, 2022 · 13 comments

Comments

@marcoizzo
Copy link

Description

Hi here.
Thanks a lot for this library and for the great work behind it.

I'm facing an issue that I'not able to solve, nothing is present on the web (searching as my best).

Seems that my test suite goes in timeout even if the emulator is launched successfully. This happen only with iOS, no problem on android (on the physical device)

I got multiple times this message during the running:
detox[13719] i The app is busy with the following tasks: • Run loop "Main Run Loop" is awake. • There are 2 work items pending on the dispatch queue: "Main Queue (<OS_dispatch_queue_main: com.apple.main-thread>)".

And in the end:
detox[13719] i The app has not responded to the network requests below: (id = -1000) isReady: {} Unresponded network requests might result in timeout errors in Detox tests.

All tests fail since they go in timeout

● Example › should perform a sign in

  thrown: "Exceeded timeout of 480000 ms for a hook.
  Use jest.setTimeout(newTimeout) to increase the timeout value, if this is a long-running test."

    41 |
    42 | describe('Example', () => {
  > 43 |   beforeAll(async () => {
       |   ^
    44 |     await device.launchApp({
    45 |       permissions: {
    46 |         notifications: 'YES',

I've also tried to investigate with the command
/usr/bin/xcrun simctl spawn 48317052-1C9B-41B8-AFC4-BE97867A0C21 log stream --level debug --style compact --predicate 'process == "........"'
but honestly I do not have any idea on what search...

Anyone can assist me?
Thanks

Your environment

Detox version: 20.0.3
React Native version: 0.68.2
Node version: 14.19.0
Device model: iPhone 13 Pro Max
OS: 15.5 / 16.1
Test-runner (select one): jest

@asafkorem
Copy link
Contributor

asafkorem commented Dec 12, 2022

Thanks @marcoizzo. Can you please provide the device logs as well? I'll take a look.
you can save them by running your tests with --record-logs failing.

@marcoizzo
Copy link
Author

Thank @asafkorem for the feedback and help.

PFA the artifacts folder

artifacts.zip

@Saad-Bashar
Copy link

I have come here to report a similar issue. After updating my react native app to 0.67.5 I am getting the following error,

detox[47743] INFO:  [APP_STATUS] The app is busy with the following tasks:
• Run loop "Main Run Loop" is awake.
• There are 1 work items pending on the dispatch queue: "Main Queue (<OS_dispatch_queue_main: com.apple.main-thread>)".
• 1 enqueued JavaScript timers:
  - Timer #1:
    + JS timer ID: 218.
    + Duration: 0.05.
    + Is recurring: NO.

Here is my log file,
detox_pid_47743.log

Thanks for any help or suggestions!

@Saad-Bashar
Copy link

@marcoizzo , did you figure anything out yet?

@marcoizzo
Copy link
Author

Unfortunately not @Saad-Bashar. Still waiting for someone to support. Maybe @asafkorem is kind enough to help? :)

@Saad-Bashar
Copy link

It turns out in our app, because of sentry the detox is hanging. Sentry has a timer when we do performance monitoring. So we will need to turn off the sentry performance monitoring while running the detox tests. This was our issue exactly, getsentry/sentry-react-native#1921

@marcoizzo
Copy link
Author

Hey guys, are there any chance to investigate this problem?

I was not able to solve it anymore and the solution shared by @Saad-Bashar it's not valid for me since I do not have sentry-react-native package installed

Thanks

@codesinghanoop
Copy link

codesinghanoop commented Jan 23, 2023

Hello guys, thanks for raising the issue. We are also facing the same issue in "expo": "^47.0.0", "detox": "^20.1.2", "jest": "^29.3.1", & "react-native": "0.70.5" . Any help would be appreciated. Below is the logs after running npx detox test --configuration ios.sim.release

The app is busy with the following tasks:
• 1 enqueued native timers:

  • Timer:
    • Fire date: none.
    • Time until fire: 0.000.
    • Repeat interval: 0.
    • Is recurring: YES.
      • Run loop "Main Run Loop" is awake.
      • There are 1 work items pending on the dispatch queue: "Main Queue (<OS_dispatch_queue_main: com.apple.main-thread>)".

@marcoizzo
Copy link
Author

Finally after a lot of investigation I was able to identify the root cause.
In my case was AppLovinQualityService, removing it from Build Phases list the tests start

I suggest to remove packages in batches and simply the App.js to identify where the issue is

@codesinghanoop
Copy link

@marcoizzo It seems i have an issue in firebase sdk. It blocks the main native queue with a native timer. But it seems we can't stop firebase init. so we are going ahead with disable detox sync on launch param.

@stale
Copy link

stale bot commented Mar 14, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
If you believe the issue is still relevant, please test on the latest Detox and report back.

Thank you for your contributions!

For more information on bots in this repository, read this discussion.

@stale stale bot added the 🏚 stale label Mar 14, 2023
@stale
Copy link

stale bot commented Mar 24, 2023

The issue has been closed for inactivity.

@stale stale bot closed this as completed Mar 24, 2023
@asaltari
Copy link

asaltari commented Dec 20, 2023

The issue has been solved.
Please
look at #4282

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

No branches or pull requests

5 participants