Page MenuHomePhabricator

Fix 'PHABRICATOR_USER should be defined' during land to hosted git repo
Needs ReviewPublic

Authored by darabi on Jun 5 2014, 8:09 AM.
Tags
None
Referenced Files
F13288266: D9387.diff
Tue, Jun 4, 10:05 AM
F13276284: D9387.diff
Fri, May 31, 5:47 AM
F13262668: D9387.diff
May 27 2024, 2:23 AM
F13261104: D9387.diff
May 27 2024, 12:43 AM
F13248303: D9387.id.diff
May 24 2024, 2:29 AM
F13212801: D9387.diff
May 17 2024, 7:06 AM
F13197317: D9387.diff
May 13 2024, 12:05 AM
F13179960: D9387.diff
May 8 2024, 9:33 PM
Subscribers
None
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

In contrast to what is stated in D8719, the feature T182 works well
for us after applying this trivial change. Without this change, we
constantly had the same issue as

https://github.com/phacility/phabricator/issues/566

The error appears for me on a git repo hosted over http, while the
creator of that issue experiences the problem with a ssh-served
repo.

The root cause seems to be the following in phabricator/bin/commit-hook:

$username = getenv(DiffusionCommitHookEngine::ENV_USER);
if (!strlen($username)) {
  throw new Exception(
    pht('usage: %s should be defined!', DiffusionCommitHookEngine::ENV_USER));
}
Test Plan

on a server with a hosted git repo, open a revision and use 'Land to Hosted Repository'

Diff Detail

Repository
rP Phabricator
Branch
master
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 867
Build 867: [Placeholder Plan] Wait for 30 Seconds

Event Timeline

darabi retitled this revision from to Fix 'PHABRICATOR_USER should be defined' during land to hosted git repo.
darabi updated this object.
darabi edited the test plan for this revision. (Show Details)
darabi added a reviewer: Blessed Reviewers.