Page MenuHomePhabricator

Arcanist Windows install docs - adding in additional php extensions
Closed, WontfixPublic

Description

I use cygwin on windows for my dev/git/etc.

The windows install docs (rP/src/docs/user/userguide/arcanist_windows.diviner) talk about installing PHP from the windows binaries and then specifically mention configuring the curl extension to php.

I'd like the docs to mention all required extensions. When installing PHP into my cygwin, based on the docs I manually selected php-curl to install additionally. No other extensions were selected.

When running arc for the first time I got this message:

This build of PHP was compiled with the configure flag '--without-json', which means it does not have the function 'json_decode'. This function is required for arc to run. Rebuild PHP without this flag. You may also be able to build or install the relevant extension separately.

This was quickly and easily resolved by installing 'php-jsonc' in cygwin, but it could have been avoided if there was a list of extensions required listed on this page. (i.e. curl & json)

Event Timeline

How did you install PHP, exactly?

The JSON extension is on by default in all versions of PHP since 5.2.0, so the expectation is that we do not need to tell you to install it explicitly because you would have to go out of your way to disable it.

In particular, the install instructions tell you to:

Download the latest stable PHP binary release from: http://windows.php.net/download/

Is that what you did, and you ended up without the JSON extension? Or did you do something else?

I didn't use the windows-binary installer, I installed php into my cygwin install using the cygwin installer. (It's still on windows, but through another process).

When adding those cygwin modules, you need to be fairly explicit as to which extensions you want...

Cygwin.PNG (631×999 px, 45 KB)

(Yes, I know the docs specifically refer to installing the php binary, but I wanted my php accessed/useable by my cygwin only, not the whole world)

epriestley claimed this task.

The instructions are correct as written, and are aimed at being as simple as possible for users who may not be familiar with PHP. We can not possibly include instructions for every imaginable installer, see also T4200.

You chose to deviate from the instructions, and received a completely reasonable, specific error message indicating the problem when you did, which you were able to resolve. I think this behavior is reasonable. See also T5055.

See also Contributing Bug Reports:

We do NOT support third-party packages or instructions. If you installed Phabricator (or configured some aspect of it) using a third-party package or by following a third-party guide (like a blog post), we can not help you. ...

I'm not looking for support for third-party packages. What I am trying to offer is a contribution to your 'as simple as possible' instructions.

You currently mention running php -i. The sheer amount of output from that tool can be daunting for the very 'users who may not be familiar with PHP'. Perhaps then explaining better how a user would find the specific sections in the output to verify that indeed curl is installed and working would be more prudent. While there - they may as well double check the presence of any other prerequisite (like json).

In fact, one could even say the instructions given are inadequate. The default windows commandline application only has a back-buffer of 2-300 lines configured by default. The output of php -i (latest php 5, 5.6.21, using your instructions) outputs 783 lines. The head end of this (where the curl - and json - information lies) will get lost past the beginning of the buffer, yet the user won't have any way of knowing this - so they'll have to trawl through 300 odd lines of output to try and find an obscure reference to curl. (remember: being unfamiliar with PHP they won't know what exact line they're looking for. The docs simply say 'looking for curl in the output')