Giter Club home page Giter Club logo

Comments (7)

staabm avatar staabm commented on June 1, 2024

just did some test, which confirmed that my problem is proc_open is on the disable_function list.

would be great to get a better error message in this case, so you dont need to dig into the dark.

from process.

kelunik avatar kelunik commented on June 1, 2024

@staabm Do you want to provide a PR?

from process.

staabm avatar staabm commented on June 1, 2024

I will give it a try. Could take a few weeks though

from process.

staabm avatar staabm commented on June 1, 2024

tried to repro this behaviour on my windows laptop at home and could't repro with basic-command from within the process\examples repos.

C:\xampp7.1.4\htdocs\amphp\process>C:\xampp7.1.4\php\php.exe examples\basic-command.php
PHP Fatal error:  Uncaught Amp\Process\ProcessException: Could not start process Errno: 2; proc_open() has been disabled for security reasons in C:\xampp7.1.4\htdocs\amphp\process\lib\Internal\Windows\Runner.php:88
Stack trace:
#0 C:\xampp7.1.4\htdocs\amphp\process\lib\Process.php(96): Amp\Process\Internal\Windows\Runner->start('cmd /c echo Hel...', '', Array, Array)
#1 C:\xampp7.1.4\htdocs\amphp\process\examples\basic-command.php(14): Amp\Process\Process->start()
#2 [internal function]: {closure}('a', NULL)
#3 C:\xampp7.1.4\htdocs\amphp\process\vendor\amphp\amp\lib\Coroutine.php(39): Generator->current()
#4 C:\xampp7.1.4\htdocs\amphp\process\vendor\amphp\amp\lib\Loop\Driver.php(119): Amp\Coroutine->__construct(Object(Generator))
#5 C:\xampp7.1.4\htdocs\amphp\process\vendor\amphp\amp\lib\Loop\Driver.php(70): Amp\Loop\Driver->tick()
#6 C:\xampp7.1.4\htdocs\amphp\process\vendor\amphp\amp\lib\Loop.php(76): Amp\Loop\Driver->run()
#7 C:\xampp7.1.4\htdocs\amphp\process\examples\basic-command.php(20): Amp\Loop::run(Object(Closure))
# in C:\xampp7.1.4\htdocs\amphp\process\lib\Internal\Windows\Runner.php on line 88

so it seems the origin issue might be related to non-windows builds, or it is somehow related to the Abstraction classes used in the more complex example scripts posted above.

still investigating.

from process.

staabm avatar staabm commented on June 1, 2024

another idea: this is fixed behaviour in the current master version which is not yet published (or is not part) of the installed package of my at-office VM (can verify this only in a few weeks after PTO)

from process.

staabm avatar staabm commented on June 1, 2024

tried to repro the code from the initial description on windows with latest parallel/process and couldn't repro the error neither.

from process.

kelunik avatar kelunik commented on June 1, 2024

Closing this issue then.

from process.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.