Commit Graph

432 Commits

Author SHA1 Message Date
Steve Howell 986c46d417 Color code "Messages sent"
(imported from commit d648bfbcdd054a57fb6b39d14d0579819c963c40)
2013-12-18 17:30:47 -05:00
Steve Howell ef089692ed Right-justify numbers on /activity.
(imported from commit 11f167626fc3f1338143fc1cf68a1bb1663a93b9)
2013-12-18 16:38:50 -05:00
Steve Howell 5d85bfbf6b Improve "Messages sent" formatting on /activity.
(imported from commit 891760c116d5a3290b49fb2d75eae0f0b227540d)
2013-12-18 16:34:03 -05:00
Steve Howell ef959a748e Exclude mit.edu from history counts.
(imported from commit eb27f4bb0f6eb07c2d72d4f32fa21995f215254e)
2013-12-18 16:34:03 -05:00
Steve Howell 7cded2a956 Show realm history on the main activity page.
This shows the number of messages sent by humans for the last
eight 24-hour periods, for each realm.  "Messages sent" isn't a
perfect metric of activity, but it's easier to query with our
current data model than certain other statistics.

(imported from commit 9de3c479640a0b9dbc017b245dda21d951f4efa4)
2013-12-18 16:01:44 -05:00
Steve Howell 532fa9fae8 Remove dead code in /activity reports.
(imported from commit ea9ddae01fd5527c6a4ceefaaa5fac091618f544)
2013-12-18 13:42:30 -05:00
Steve Howell 0c1f57815c Add grahite to link to /realm_activity.
(imported from commit 6d2a23ffcca23a65e5aadb2ed8499645e42131e0)
2013-12-18 13:40:07 -05:00
Tim Abbott 3b7bf691e7 Add tool to query our usage stats as of a given date.
This contains the various fixes that needed to be made in order to get
accurate statistics.

Most notably, the active_users_between function in the previous
version of zerver/lib/statistics.py was broken for end dates in the
past, because it used the UserActivity table to get its data -- so in
fact it really was querying "users last active between".

This commit isn't super clean, but I figure we're probably better off
having our latest code for historical usage data in git so it doesn't
bitrot and anyone can improve on it.

(imported from commit 24ff2f24a22e5bdc004ea8043d8da12deb97ff2f)
2013-12-17 15:34:44 -05:00
Leo Franchi 1e7a22f14e Replace other non-zerver uses of iPhone client
(imported from commit 0988e2c9bd0499a0711daed97f89aa672776f085)
2013-12-03 14:35:24 -05:00
Steve Howell 14ae79b311 Count /api/*/external/* messages as "sent" in /realm_activity.
This makes it easier to see how many messages are being sent
by webhook bots.  This assumes a 1:1 relationship between
hitting webhook endpoints and sending messages, which is probably
valid enough in the near future.

(imported from commit eb272cd38b9cabd54d317ce2dfdf12099d302fce)
2013-11-25 15:37:19 -05:00
Steve Howell b5707b9c7b Add is_active check to /realm_activity report.
(imported from commit e531446bc73caf7173e4aa1d22b35f3942c9c1f9)
2013-11-24 16:35:19 -05:00
Steve Howell 07d4dd66c4 Show admins on /realm_activity page.
(imported from commit 7d6beb4145b86d95b872b175ea8a567b7ce56d23)
2013-11-18 14:41:37 -05:00
Steve Howell 91a463def0 Show webhook clients in activity pages.
(imported from commit 423df7def53583ab8122a26271068423f03a687c)
2013-11-18 12:58:39 -05:00
Steve Howell 76a1754357 Use from/import style for datetime imports in activity views.
(imported from commit 72772f63f00d1b5e9d5d0ccefb56b6714d1a2370)
2013-11-18 12:36:25 -05:00
Steve Howell 38a7aa2255 Highlight recently active users in /realm_activity.
(imported from commit 307ed9c17ea1055f40cd983d5c2b2f308203f3f7)
2013-11-18 12:36:24 -05:00
Steve Howell ae77b98155 DRY up East Coast time formatting.
(imported from commit b5b5787816c2dc641bbe4cfb351f4ff765e44969)
2013-11-18 12:36:24 -05:00
Steve Howell dd53b92efc Add row_class support to /activity tables.
(imported from commit 69dcbeccc3b048053b2dcca82c628b0cfccddfbb)
2013-11-18 12:36:24 -05:00
Steve Howell 6e19f8b86f Split humans/bots in History tab for realm reports.
(imported from commit 02e398590f4f844ce30e76703006262296301b97)
2013-11-14 15:46:10 -05:00
Steve Howell 6ddfa35a49 Remove detailed "At risk users" tab
(imported from commit d5630fa3ae5a35d238e3c947a01e1a648668817f)
2013-11-14 14:07:24 -05:00
Steve Howell d4c0334b3b Show counts of at-risk users on Activity page.
(imported from commit 4ce1ecf47259f3a95ddf9cbbc356fa0247044e0f)
2013-11-14 14:07:24 -05:00
Steve Howell f60fa1b274 Don't linkify "Total" on the main Activity tab.
(imported from commit 2098f488f1276a022b4c585b99c25c3a5a66ca06)
2013-11-14 13:28:41 -05:00
Steve Howell 0c74d55d6b Clean up time display on the Activity page.
(imported from commit fc1d0cad1ed8a70ddf34c29633569ed473430fc8)
2013-11-14 13:28:41 -05:00
Steve Howell c214691a1e Linkify more realms on the Activity page.
(imported from commit f9a5ab46ce77b13ff9cf5dcc80231bfb1d11bbee)
2013-11-14 13:28:40 -05:00
Steve Howell b690918480 Extract user_activity_link() for activity reports.
(imported from commit 0ae3770a8dcba2bb9fad6a22133635316f74b0d7)
2013-11-14 13:28:40 -05:00
Kevin Mehall a593a798f8 Move send_stats management command back to zerver/
It's not analytics, and it's needed for restart-server.

(imported from commit 979fa15715ea437cbbc5d986c859ee4d6c668da8)
2013-11-12 15:50:08 -05:00
Waseem Daher 76fa95a5e9 activity: Display times in US/Eastern.
(imported from commit 730d37e0b8da046c1fe9e0c0cfc9b420da560865)
2013-11-08 11:39:59 -05:00
Waseem Daher 8b89a56922 Exclude wdaher.com from our analytics dashboard.
It really shouldn't count.

(imported from commit ad91ecfacbd421bc1e10ef3a15ef28ca9e87a0ae)
2013-11-08 10:47:50 -05:00
Steve Howell 59ec080a8d Simplify analytics/activity.html.
For legacy reasons, this template wanted each tab's content as
a one-key dictionary, instead of a string.  Each tab already has
a tuple to allow for fields like title, so this wasn't really giving us
any long term flexibility; it was just crufting up the calling
code.

(imported from commit 2a316107ec223a83efa8735f4810a6fa43107541)
2013-11-08 10:44:20 -05:00
Steve Howell 38e479d4a6 Extract make_table() in analytics/views.py.
(imported from commit f1457763ac491d32de19221fb9a2d11e43d58106)
2013-11-08 10:44:20 -05:00
Steve Howell 64fb17f9c2 Move management commands to the analytics app.
Move commands related to stats collection and reporting from
zilencer to analytics.  To do this, we had to make "analytics"
officially an app.

(imported from commit 63ef6c68d1b1ebb5043ee4aca999aa209e7f494d)
2013-11-06 16:51:08 -05:00
Steve Howell a32b47f7d6 Exclude bots from Active Users in main activity counts.
(imported from commit f0b0d46470dc5a2f7f80fe8f2329e3df9384bc07)
2013-11-06 15:38:25 -05:00
Steve Howell f5bb2409ef Create "analytics" app with activity reports.
(imported from commit 6385935c3d7894fe52bcc265faecc30b07629717)
2013-11-06 12:07:32 -05:00