Page MenuHomePhabricator

Make sure failure to remove temporary files does not cause error exit codes

Authored by hach-que on Jul 23 2015, 12:53 AM.


Group Reviewers
Blessed Reviewers

For some reason on Windows, the files used for the streaming stdout / stderr remain locked when PHP exits. In this case, the automatic unlink fails, and PHP returns an error code.

Because we don't have much control of Windows and how it does it's file locking nonsense, gracefully ignore failure to remove TempFiles if $temp->setIgnoreRemovalFailure(true) is called.

Also, have a free "latest XHPAST built for Windows".

Test Plan

Replicated the issue and then set:


and saw the failure go away. Set those values to false and saw the exception appear again. Set them back to true before running arc diff so that we actually fix the issue.

Diff Detail

Lint SkippedExcuse: I get an exception about duplicate symbols, which looks like it's prefixing a comment block before the symbol name. It's most likely line endings causing this.
Unit Tests Skipped
Build Status
Buildable 7359
Build 7758: [Placeholder Plan] Wait for 30 Seconds
Build 7757: arc lint + arc unit

Event Timeline

hach-que updated this revision to Diff 33085.Jul 23 2015, 12:53 AM
hach-que retitled this revision from to Make sure failure to remove temporary files does not cause error exit codes.
hach-que updated this object.
hach-que edited the test plan for this revision. (Show Details)
hach-que added a reviewer: epriestley.
eadler added a subscriber: eadler.Jul 23 2015, 1:14 AM
hach-que abandoned this revision.Dec 3 2015, 8:50 AM

We'll keep this patched locally while-ever we keep encountering the issue.