From b467e583585c3ff4203e3c5916115d9b78822f59 Mon Sep 17 00:00:00 2001 From: epriestley Date: Mon, 13 Apr 2015 11:11:18 -0700 Subject: [PATCH] Fix two minor issues Summary: Ref T7811. Fixes two minor issues I observed in the cluster: - Sometimes APC doesn't give us key names. Not sure exactly what's up here, but we can do a better job with this. - The `%` in `25%` actually needs more escaping, since it's interpreted by both `pht()` (immediately) and `console_format()` (later). Test Plan: - First one is just from an error log, not sure how to repro offhand. - Ran `bin/phd help start` for the second one. Reviewers: btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T7814, T7811 Differential Revision: https://secure.phabricator.com/D12395 --- src/applications/cache/spec/PhabricatorDataCacheSpec.php | 3 ++- .../daemon/management/PhabricatorDaemonManagementWorkflow.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/applications/cache/spec/PhabricatorDataCacheSpec.php b/src/applications/cache/spec/PhabricatorDataCacheSpec.php index 455191f73c..b1364ff569 100644 --- a/src/applications/cache/spec/PhabricatorDataCacheSpec.php +++ b/src/applications/cache/spec/PhabricatorDataCacheSpec.php @@ -83,7 +83,8 @@ final class PhabricatorDataCacheSpec extends PhabricatorCacheSpec { $cache = $info['cache_list']; $state = array(); foreach ($cache as $item) { - $key = self::getKeyPattern($item['info']); + $info = idx($item, 'info', ''); + $key = self::getKeyPattern($info); if (empty($state[$key])) { $state[$key] = array( 'max' => 0, diff --git a/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php b/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php index d922b7cbf0..def781b4a5 100644 --- a/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php +++ b/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php @@ -619,7 +619,7 @@ abstract class PhabricatorDaemonManagementWorkflow 'Specify a proportion of machine memory which must be free '. 'before autoscale pools will grow. For example, a value of 0.25 '. 'means that pools will not grow unless the machine has at least '. - '25%% of its RAM free.'), + '25%%%% of its RAM free.'), ); }