Bug: T16023
Details
Details
- Reviewers
valerio.bozzolan - Group Reviewers
O1: Blessed Committers - Maniphest Tasks
- T16023: Regression in Config: console generates errors when some libraries are not managed by Git
- Commits
- rPa81f20e0f228: Config: Fix git errors when .git does not exist
Delete .git and visit /config/
Diff Detail
Diff Detail
- Repository
- rP Phorge
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Comment Actions
Thanks my friend. I 100% understand the problem and I'm happy you shared the stack trace in the task and I'm happy about this test plan that helped me to reproduce,
However the current implementation raises some considerations to me:
- checking for the .git directory before running git is a micro-optimization that has sense only for your specific use-case, that is an un-official way to install Phorge/Phabricator.
- As solution, probably we should just execute git normally like before, but intercepting the specific exception fatal: not a git repository (or any of the parent directories): .git and just do not log anything in that specific case.
- whenever we may want to introduce such micro-optimization, or not; you may still want to run that inside a Future, object, (I mean, just like it's happening in the git commands) so that the filesystem check can be parallelized and you do not introduce extra "N+1 performance issue" (some doc here https://we.phorge.it/book/contrib/article/n_plus_one/ ). Specifically, running the filesystem check in parallel in both Arcanist and Phorge is better than checking one after one. This may sound silly for 2 libraries, but think about installations with more extensions, and I'm more than 1% sure that the would be shown there.
What do you think about both points? Note that probably we can ignore the second point if we agree on the first. Thanks my friend and happy Phorging
src/applications/config/controller/PhabricatorConfigConsoleController.php | ||
---|---|---|
384 | You can probably omit this line 376 thanks to line 354 |