gwynne          Mon, 20 Jul 2009 16:00:09 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=284451

Log:
Most of that debug stuff is unneeded. Just switch to only getbug instead of 
ncomment for debug.

Changed paths:
        U   SVNROOT/commit-bugs.php

Modified: SVNROOT/commit-bugs.php
===================================================================
--- SVNROOT/commit-bugs.php     2009-07-20 15:57:11 UTC (rev 284450)
+++ SVNROOT/commit-bugs.php     2009-07-20 16:00:09 UTC (rev 284451)
@@ -39,9 +39,7 @@

 // 
-----------------------------------------------------------------------------------------------------------------------------
 // Make an RPC call for each bug
-if (!$is_DEBUG) {
-    include __DIR__ . '/secret.inc';
-}
+include __DIR__ . '/secret.inc';
 foreach ($bug_list as &$bug) {
     // Only do this for core PHP bugs
     if ($bug['project'] !== '') {
@@ -56,21 +54,15 @@
                     'user' => $commit_info['author'],
                     'id' => $bug['number'],
                     'ncomment' => $comment,
-                    'MAGIC_COOKIE' => $is_DEBUG ? 'nonsense' : 
$SVN_MAGIC_COOKIE,
+                    'MAGIC_COOKIE' => $SVN_MAGIC_COOKIE,
                 );
+    if ($is_DEBUG) {
+        unset($postdata['ncomment']);
+        $postdata['getbug'] = 1;
+    }
     array_walk($postdata, create_function('&$v, $k', '$v = rawurlencode($k) . 
"=" . rawurlencode($v);'));
     $postdata = implode('&', $postdata);

-    if ($is_DEBUG) {
-        print "DEBUG: Bug #{$bug['number']}: Would have posted this 
rawurlencoded string to {$bug_rpc_url}:\n{$postdata}\n";
-        if (mt_rand(0, 1) === 1) {
-            $bug['error'] = 'DEBUG-some kind of error';
-        } else {
-            $bug['status'] = 'DEBUG-unknown';
-            $bug['short_desc'] = "DEBUG-Bug #{$bug['number']}";
-        }
-        continue;
-    }
     // Hook an env var so emails can be resent without messing with bugs
     if (getenv('NOBUG')) {
         continue;

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to