r78661 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r78660‎ | r78661 | r78662 >
Date:03:17, 21 December 2010
Author:rfaulk
Status:deferred (Comments)
Tags:
Comment:
This is the log comment.
Modified paths:
  • /trunk/fundraiser-statistics/fundraiser-scripts/fundraiser_reporting.py (modified) (history)
  • /trunk/fundraiser-statistics/fundraiser-scripts/html (added) (history)
  • /trunk/fundraiser-statistics/fundraiser-scripts/logs (added) (history)
  • /trunk/fundraiser-statistics/fundraiser-scripts/squid_miner_script.py (modified) (history)
  • /trunk/fundraiser-statistics/reporting/banner_test_proc.php (modified) (history)
  • /trunk/fundraiser-statistics/reporting/reporting_totals.html (modified) (history)
  • /trunk/fundraiser-statistics/standalone-queries/impression_by_hour.sql (modified) (history)
  • /trunk/fundraiser-statistics/standalone-queries/landing_by_hour.sql (modified) (history)

Diff [purge]

Index: trunk/fundraiser-statistics/standalone-queries/landing_by_hour.sql
@@ -1,7 +1,7 @@
22 use faulkner;
33
4 -set @s = '20101220000000';
5 -set @e = '20101220100000';
 4+set @s = '20101220160000';
 5+set @e = '20101221020000';
66
77 select
88 DATE_FORMAT(request_time, '%Y-%m-%d %H') as stamp,
Index: trunk/fundraiser-statistics/standalone-queries/impression_by_hour.sql
@@ -1,7 +1,7 @@
22 use faulkner;
33
4 -set @s = '20101220000000';
5 -set @e = '20101220100000';
 4+set @s = '20101220160000';
 5+set @e = '20101221020000';
66
77 select
88 DATE_FORMAT(on_minute, '%Y-%m-%d %H') as stamp,
Index: trunk/fundraiser-statistics/fundraiser-scripts/fundraiser_reporting.py
@@ -465,7 +465,7 @@
466466 except:
467467 self.db.rollback()
468468 sys.exit("Database Interface Exception:\n" + err_msg)
469 -
 469+
470470 """ Convert Times to Integers """
471471 # Find the earliest date
472472 max_i = 0
@@ -537,9 +537,9 @@
538538
539539 # Current date & time
540540 now = datetime.datetime.now()
541 - #UTC = 8
542 - #delta = datetime.timedelta(hours=UTC)
543 - #now = now + delta
 541+ UTC = 8
 542+ delta = datetime.timedelta(hours=UTC)
 543+ now = now + delta
544544
545545 # ESTABLISH THE START TIME TO PULL ANALYTICS
546546 hours_back = 24
Index: trunk/fundraiser-statistics/fundraiser-scripts/squid_miner_script.py
@@ -76,50 +76,6 @@
7777
7878 """
7979
80 -fname_parts = logFileName.split('-')
81 -
82 -year = int(fname_parts[1])
83 -month = int(fname_parts[2])
84 -day = int(fname_parts[3])
85 -hour = int(fname_parts[4][0:2])
86 -min = int(fname_parts[6][0:2])
87 -
88 -# Is this an afternoon log?
89 -afternoon = (fname_parts[4][2:4] == 'PM')
90 -
91 -if afternoon and hour < 12:
92 - hour = hour + 12
93 -
94 -next_hr = mh.getNextHour(year, month, day, hour)
95 -log_start = str(year) + '-' + str(month) + '-' + str(day) + ' ' + str(hour) + ':' + str(min) + ':00'
96 -log_end = str(next_hr[0]) + '-' + str(next_hr[1]) + '-' + str(next_hr[2]) + ' ' + str(next_hr[3]) + ':' + str(min) + ':00'
97 -"""
98 -try:
99 - val = '(convert(\'' + log_start + '\',datetime), convert(\'' + log_end + '\',datetime), \'Auto-Generated\');'
100 - cur.execute(insertStmt_tr + val)
101 -except:
102 - db.rollback()
103 - sys.exit("Database Interface Exception: Could not execute statement:\n" + insertStmt_tr + val)
104 -
105 -try:
106 - cur.execute(selectStmt_tr)
107 - # results = cur.fetchall()
108 - # for row in results:
109 - row = cur.fetchone()
110 - run_id = int(row[0])
111 -
112 -except:
113 - db.rollback()
114 - sys.exit("Database Interface Exception: Could not execute statement:\n" + selectStmt_tr)
115 -
116 -"""
117 -
118 -"""
119 -
120 -A log_run record has been created for this log
121 -call the mining scripts for the respective
122 -
123 -"""
12480 run_id = 0
12581 if mine_option == 'l':
12682 mlp.mine_landing_pages(run_id, logFileName, db, cur)
Index: trunk/fundraiser-statistics/reporting/reporting_totals.html
@@ -37,7 +37,7 @@
3838 <br>
3939
4040 <h3><u>Total Donation Amounts by Hour</u></h3>
41 -<OBJECT WIDTH="1600" HEIGHT="800" data="report_total_amounts_by_hr.png" type="image/png">
 41+<OBJECT WIDTH="1600" HEIGHT="800" data="report_total_amounts_by_hr_BAN_EM.png" type="image/png">
4242 <p>Total donation amounts over a given period.</p>
4343 </OBJECT>
4444
@@ -51,13 +51,13 @@
5252 <br>
5353
5454 <h3><u>Credit Card / Paypal Total Amounts</u></h3>
55 -<OBJECT WIDTH="1600" HEIGHT="800" data="report_banner_metrics_don_per_imp.png" type="image/png">
 55+<OBJECT WIDTH="1600" HEIGHT="800" data="report_total_amounts_by_hr_CC_PP_amount.png" type="image/png">
5656 </OBJECT>
5757
5858 <br>
5959
6060 <h3><u>Credit Card / Paypal Completion Rates</u></h3>
61 -<OBJECT WIDTH="1600" HEIGHT="800" data="report_banner_metrics_click_rate.png" type="image/png">
 61+<OBJECT WIDTH="1600" HEIGHT="800" data="report_total_amounts_by_hr_CC_PP_completion.png" type="image/png">
6262 </OBJECT>
6363
6464 <br>
Index: trunk/fundraiser-statistics/reporting/banner_test_proc.php
@@ -9,7 +9,7 @@
1010 // Authenticate form
1111 $pwd_key=$_POST["pwd"];
1212
13 -if ($pwd_key != "fundra1535TaT5") {
 13+if ($pwd_key != "angelface") {
1414 $message = "Invalid Key.\n";
1515 die($message);
1616 }

Comments

#Comment by Ryan lane (talk | contribs)   03:19, 21 December 2010

hah

Status & tagging log