Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Overwriting php location causes console errors that --php is not a valid options #465

Open
paul999 opened this issue Aug 27, 2023 · 0 comments

Comments

@paul999
Copy link

paul999 commented Aug 27, 2023

Since #444 there is an option to provide a php binary location. If you are using this option, at least on macOS to overwrite your binary location for php version, this causes a
error from the symfony console that --php doesn't exists.

Without php binary, the following args are added:
[ '--target=/Users/paulsohier/PhpstormProjects/filament_uno/var/cache/fosRoutes.tmp.json', '--format=json' ]

With php binary added as option, it is:
[ '--target=/Users/paulsohier/PhpstormProjects/filament_uno/var/cache/fosRoutes.tmp.json', '--format=json' ]

which causes:

Error: Command failed: /opt/homebrew/bin/php bin/console fos:js-routing:dump --target=/Users/paulsohier/PhpstormProjects/filament_uno/var/cache/fosRoutes.tmp.json --php=/opt/homebrew/bin/php --format=json

                                      
  The "--php" option does not exist.  
                                      

fos:js-routing:dump [--callback CALLBACK] [--format FORMAT] [--target [TARGET]] [--locale [LOCALE]] [-p|--pretty-print] [--domain [DOMAIN]]


    at ChildProcess.exithandler (node:child_process:419:12)
    at ChildProcess.emit (node:events:512:28)
    at maybeClose (node:internal/child_process:1098:16)
    at ChildProcess._handle.onexit (node:internal/child_process:304:5) {
  code: 1,
  killed: false,
  signal: null,
  cmd: '/opt/homebrew/bin/php bin/console fos:js-routing:dump --target=/Users/paulsohier/PhpstormProjects/filament_uno/var/cache/fosRoutes.tmp.json --php=/opt/homebrew/bin/php --format=json',
  stdout: '',
  stderr: '\n' +
    '                                      \n' +
    '  The "--php" option does not exist.  \n' +
    '                                      \n' +
    '\n' +
    'fos:js-routing:dump [--callback CALLBACK] [--format FORMAT] [--target [TARGET]] [--locale [LOCALE]] [-p|--pretty-print] [--domain [DOMAIN]]\n' +
    '\n'
}

I do believe the php option shouldn't be included in args if the php binary is overwritten.

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

No branches or pull requests

1 participant