RE action for catching up naming table + typechecking a single file
commitfe2b87ccd4c4934420358a17b14e828587382e6a
authorBob Ren <bobren@fb.com>
Fri, 16 Apr 2021 01:35:55 +0000 (15 18:35 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Fri, 16 Apr 2021 01:37:15 +0000 (15 18:37 -0700)
tree3b82d7344c69586d8df5aeb1b5188b2cb5be5fe7
parent557539c3e23263057ba957dcddc2a84680ea1560
RE action for catching up naming table + typechecking a single file

Summary:
This diff adds the ability to run hh with the flag --single-remote-execution

Running this will do the following

1) Update both forwards and reverse naming table to catch up with local state. If no saved state exists, it'll download one and bootstrap from that.
2) Typechecks the file you passed in
3) Returns a list of dep edges discovered in JSON format as well as errors discovered in typechecking as basic stdout

The next step is to have a coordinator  that will
1) calculate the fanout
2) acquire a lease if it doesn't yet have one
3) distribute single file actions using hh --single-remote-execution via RE
4) aggregating errors and returning back to user
5) aggregating dep edges and updating dep edges accordingly

In the future we'll likely want to support batch of files. However for the sake of getting a working example, I figured having a single file version is sufficient for now.

Differential Revision: D27555605

fbshipit-source-id: 0d9301b4ede35dbff9be953380b6ec485ef49850
13 files changed:
hphp/hack/src/client/clientArgs.ml
hphp/hack/src/client/clientCheck.ml
hphp/hack/src/client/clientEnv.ml
hphp/hack/src/server/dune
hphp/hack/src/server/serverCommand.ml
hphp/hack/src/server/serverCommandTypes.ml
hphp/hack/src/server/serverCommandTypesUtils.ml
hphp/hack/src/server/serverEnv.ml
hphp/hack/src/server/serverEnv.mli
hphp/hack/src/server/serverEnvBuild.ml
hphp/hack/src/server/serverRpc.ml
hphp/hack/src/server/serverStatusSingleRemoteExecution.ml [new file with mode: 0644]
hphp/hack/src/server/serverTypeCheck.ml