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

Error "Unable to set stream resource to non-blocking mode" In ReadableResourceStream.php line 56: #82

Closed
rogeriopradoj opened this issue Feb 24, 2019 · 3 comments

Comments

@rogeriopradoj
Copy link

  • Error output:
$ vendor/bin/phpunit-watcher watch


In ReadableResourceStream.php line 56:
                                                      
  Unable to set stream resource to non-blocking mode  
                                                      

watch [<phpunit-options>]
  • S.O.: Windows 10
  • How I installed the package: composer require spatie/phpunit-watcher --dev
  • Command (the result error is the same):
    • vendor/bin/phpunit-watcher watch (git-bash)
    • or vendor\bin\phpunit-watcher watch (cmd)
  • Using a configuration file: yes, .phpunit-watcher.yml
  • Content of configuration file:
watch:
  directories:
    - src
    - tests
  fileMask: '*.php'
notifications:
  passingTests: false
  failingTests: true
phpunit:
  binaryPath: vendor/bin/simple-phpunit
  arguments: '--testsuite unit'

References:

@AnderSouza
Copy link

I've got the exact same problem here.

Anyone knows how to solve this?

@clue
Copy link

clue commented May 11, 2019

Due to platform inconsistencies, PHP does not provide support for reading from standard console input without blocking on Windows. Unfortunately, until the underlying PHP feature request is implemented (which is unlikely to happen any time soon), there's little we can do in the library responsible for handling console I/O, see clue/reactphp-stdio#18. If anybody feels like investing (a possibly unreasonable amount of) time in work arounds for Windows, clue/reactphp-stdio#83 may be good starting point 🥇 👍

Recommended alternative for now: Don't run this natively on Windows, consider running from WSL (Windows Subsystem for Linux) instead or sponsor the above feature ticket 👍

@spatie-bot
Copy link

Dear contributor,

because this issue seems to be inactive for quite some time now, I've automatically closed it. If you feel this issue deserves some attention from my human colleagues feel free to reopen it.

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

No branches or pull requests

4 participants