question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ENOSPC: System limit for number of file watchers reached

See original GitHub issue

Description of the bug

Basically a duplicate of https://github.com/expo/expo-cli/issues/277

To Reproduce

Run expo publish using default configuration in README, with slight modifications:

  • use yarn instead of NPM
  • use a release-channel option

I don’t believe these options may result in not being able to publish though.

name: Expo Review App
on:
  pull_request:
    types: [opened, synchronize, reopened]
jobs:
  publish:
    name: Install and publish
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1
      - uses: actions/setup-node@v1
        with:
          node-version: 12.x
      - uses: expo/expo-github-action@v4
        with:
          expo-version: 3.x
          expo-username: ${{ secrets.EXPO_CLI_USERNAME }}
          expo-password: ${{ secrets.EXPO_CLI_PASSWORD }}
      - run: yarn install
      - run: expo publish --release-channel=pr-${{ github.event.number }}

Expected behavior

expo publish to succeed

Actual behavior

Following error in the expo publish ... step

ENOSPC: System limit for number of file watchers reached

Additional context

I’m curious, because you state that running expo publish is not working in the related issue, and that’s actually what I see too.

However you also seem to succeed publishing using this action and default configuration 🤷‍♂

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:7
  • Comments:22 (10 by maintainers)

github_iconTop GitHub Comments

25reactions
vongohrencommented, Oct 14, 2019

So, there exists a fix, that seemed to work for me when I tried. What I did was to follow this guys tip: “Increasing the number of watchers” — @JNYBGR https://link.medium.com/9Zbt3B4pM0

I then did this in my main action.yml With all the specifics underneath the dev release

    steps:
    - uses: actions/checkout@v1
    - name: Setup kernel for react native, increase watchers
      run: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
    - name: Run dev release fastlane inside docker action

I can confirm that I got past the watch step and was able to finish my dockerized fastlane build and release action

8reactions
nicolasrouannecommented, Oct 14, 2019

@vongohren It works indeed 🎉

Here is my complete configuration for reference:

name: Expo Publish
on:
  push:
    branches:
      - master
jobs:
  publish:
    name: Install and publish
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1
      - name: Setup kernel for react native, increase watchers
        run: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
      - uses: actions/setup-node@v1
        with:
          node-version: 12.x
      - run: npm ci
      - uses: docker://bycedric/expo-cli-fix-inotify:latest
        with:
          args: publish
        env:
          EXPO_CLI_USERNAME: ${{ secrets.EXPO_CLI_USERNAME }}
          EXPO_CLI_PASSWORD: ${{ secrets.EXPO_CLI_PASSWORD }}
Read more comments on GitHub >

github_iconTop Results From Across the Web

React Native Error: ENOSPC: System limit for number of file ...
Each file watch takes up 540 bytes (32-bit) or ~1kB (64-bit), so assuming that all 524,288 watches are consumed, that results in an...
Read more >
System limit for number of file watchers reached [Solved]
The error "System limit for number of file watchers reached" occurs when your system has reached its limit for the number of files...
Read more >
ENOSPC: System limit for number of file watchers reached.
Method $1: This happens when you have multiple react projects open. Try to close other projects and test again. This happens because your ......
Read more >
How To Fix - Error "ENOSPC: System Limit for Number of File ...
First thing first – ENOSPC -> Denotes that means that there is not sufficient space on the drive (or Temp folder also) to...
Read more >
System Limit for Number of File Watchers Reached ReactJs
This error occurs when running the “npm start” command. Causes of ENOSPC errors: System limit for number of file watchers reached because the ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found