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
Unknown Object (File)
Sat, May 4, 7:12 PM
Unknown Object (File)
Wed, May 1, 1:03 AM
Unknown Object (File)
Tue, Apr 16, 5:31 PM
Unknown Object (File)
Apr 3 2024, 4:16 PM
Unknown Object (File)
Apr 3 2024, 4:14 PM
Unknown Object (File)
Apr 3 2024, 4:13 PM
Unknown Object (File)
Feb 21 2024, 8:56 PM
Unknown Object (File)
Dec 31 2023, 6:26 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.