[MediaWiki-commits] [Gerrit] analytics/wikistats2[release]: Release 2.1.5

2018-01-18 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/405069 )

Change subject: Release 2.1.5
..


Release 2.1.5

Change-Id: Ib43ea5ee56f8c48d5dec97a966f9939c59a31656
---
M .gitignore
A dist/0.533d5eb48952f3ca733b.js
M dist/index.html
A dist/main.bundle.9097f6ac147e6e58665a.css
A dist/main.bundle.9097f6ac147e6e58665a.js
M package.json
M src/apis/aqs.js
M src/apis/sitematrix.js
M src/components/TopicExplorer.vue
M src/components/WikiSelector.vue
M src/components/dashboard/MetricListWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
D src/components/detail/chart/MapChart.vue
A src/components/detail/chart/MapChart/MapChart.vue
A src/components/detail/chart/MapChart/MapLegend.vue
A src/components/detail/chart/MapChart/MapTooltip.vue
A src/components/detail/chart/MapChart/index.js
A src/components/detail/chart/MapChart/isoLookup.js
A src/components/detail/chart/MapChart/world-50m.js
M src/components/detail/chart/TableChart.vue
M src/components/widgets/SearchResults.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/contributing.js
M src/config/metrics/metricSchema.js
M src/config/metrics/reading.js
M src/lodash-custom-bundle.js
M src/main.js
M src/models/DimensionalData.js
M src/models/GraphModel.js
33 files changed, 2,030 insertions(+), 413 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/405069
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib43ea5ee56f8c48d5dec97a966f9939c59a31656
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: release
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[release]: Release 2.1.5

2018-01-18 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/405069 )

Change subject: Release 2.1.5
..

Release 2.1.5

Change-Id: Ib43ea5ee56f8c48d5dec97a966f9939c59a31656
---
M .gitignore
A dist/0.533d5eb48952f3ca733b.js
M dist/index.html
A dist/main.bundle.9097f6ac147e6e58665a.css
A dist/main.bundle.9097f6ac147e6e58665a.js
M package.json
M src/apis/aqs.js
M src/apis/sitematrix.js
M src/components/TopicExplorer.vue
M src/components/WikiSelector.vue
M src/components/dashboard/MetricListWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
D src/components/detail/chart/MapChart.vue
A src/components/detail/chart/MapChart/MapChart.vue
A src/components/detail/chart/MapChart/MapLegend.vue
A src/components/detail/chart/MapChart/MapTooltip.vue
A src/components/detail/chart/MapChart/index.js
A src/components/detail/chart/MapChart/isoLookup.js
A src/components/detail/chart/MapChart/world-50m.js
M src/components/detail/chart/TableChart.vue
M src/components/widgets/SearchResults.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/contributing.js
M src/config/metrics/metricSchema.js
M src/config/metrics/reading.js
M src/lodash-custom-bundle.js
M src/main.js
M src/models/DimensionalData.js
M src/models/GraphModel.js
33 files changed, 2,030 insertions(+), 413 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/69/405069/1


-- 
To view, visit https://gerrit.wikimedia.org/r/405069
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib43ea5ee56f8c48d5dec97a966f9939c59a31656
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: release
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[release]: Release 2.1.5

2018-01-18 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/405067 )

Change subject: Release 2.1.5
..

Release 2.1.5

Change-Id: Icbb4b0273e582c5e02677b150396fc4f13f68621
---
M .babelrc
M .gitignore
A .gitreview
A dist/0.533d5eb48952f3ca733b.js
M dist/index.html
A dist/main.bundle.9097f6ac147e6e58665a.css
A dist/main.bundle.9097f6ac147e6e58665a.js
M package.json
M src/App.vue
M src/apis/aqs.js
M src/apis/sitematrix.js
M src/components/RouterLink.vue
M src/components/TopNav.vue
M src/components/TopicExplorer.vue
M src/components/WikiSelector.vue
M src/components/dashboard/MetricListWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/Detail.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
D src/components/detail/chart/MapChart.vue
A src/components/detail/chart/MapChart/MapChart.vue
A src/components/detail/chart/MapChart/MapLegend.vue
A src/components/detail/chart/MapChart/MapTooltip.vue
A src/components/detail/chart/MapChart/index.js
A src/components/detail/chart/MapChart/isoLookup.js
A src/components/detail/chart/MapChart/world-50m.js
M src/components/detail/chart/TableChart.vue
M src/components/widgets/SearchResults.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/contributing.js
M src/config/metrics/metricSchema.js
M src/config/metrics/reading.js
M src/lodash-custom-bundle.js
M src/main.js
M src/models/DimensionalData.js
M src/models/GraphModel.js
M src/utils.js
M test/components/LineChart.spec.js
M webpack/base.config.js
M webpack/dev.config.js
M webpack/prod.config.js
45 files changed, 2,216 insertions(+), 470 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/67/405067/1


-- 
To view, visit https://gerrit.wikimedia.org/r/405067
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Icbb4b0273e582c5e02677b150396fc4f13f68621
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: release
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Release 2.1.5

2018-01-18 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/405065 )

Change subject: Release 2.1.5
..


Release 2.1.5

Change-Id: I92ad752bff32bf09f53e2dfcb2bc2f6760e8f457
---
A dist/0.533d5eb48952f3ca733b.js
D dist/0.9155a7e9a34a43778291.js
M dist/index.html
R dist/main.bundle.9097f6ac147e6e58665a.css
A dist/main.bundle.9097f6ac147e6e58665a.js
D dist/main.bundle.ef2f15d9277ad60530b9.js
D package-lock.json
M package.json
8 files changed, 51 insertions(+), 11,386 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/405065
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I92ad752bff32bf09f53e2dfcb2bc2f6760e8f457
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Release 2.1.5

2018-01-18 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/405065 )

Change subject: Release 2.1.5
..

Release 2.1.5

Change-Id: I92ad752bff32bf09f53e2dfcb2bc2f6760e8f457
---
A dist/0.533d5eb48952f3ca733b.js
D dist/0.9155a7e9a34a43778291.js
M dist/index.html
R dist/main.bundle.9097f6ac147e6e58665a.css
A dist/main.bundle.9097f6ac147e6e58665a.js
D dist/main.bundle.ef2f15d9277ad60530b9.js
D package-lock.json
M package.json
8 files changed, 51 insertions(+), 11,386 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/65/405065/1


-- 
To view, visit https://gerrit.wikimedia.org/r/405065
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I92ad752bff32bf09f53e2dfcb2bc2f6760e8f457
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Improve WikiSelector

2018-01-18 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/402387 )

Change subject: Improve WikiSelector
..


Improve WikiSelector

Fixes bugs and adds new features to the WikiSelector.
For a full list see comments in phab task.

Bug: T179530
Change-Id: I13cde25388677072c153529c6c2f413e68cc0e15
---
M .gitignore
A package-lock.json
M src/apis/sitematrix.js
M src/components/WikiSelector.vue
M src/components/widgets/SearchResults.vue
M src/lodash-custom-bundle.js
6 files changed, 12,071 insertions(+), 300 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/402387
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I13cde25388677072c153529c6c2f413e68cc0e15
Gerrit-PatchSet: 11
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Mforns 
Gerrit-Reviewer: Fdans 
Gerrit-Reviewer: Mforns 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: Nuria 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Fix blocking problems with map component

2018-01-18 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/405061 )

Change subject: Fix blocking problems with map component
..


Fix blocking problems with map component

Change-Id: I697e9d118f822da1dcde6ba32522a9fa1472e346
---
M src/components/detail/GraphPanel.vue
M src/components/detail/chart/MapChart/MapLegend.vue
M src/config/index.js
M src/config/metrics/contributing.js
M src/config/metrics/reading.js
5 files changed, 36 insertions(+), 30 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/src/components/detail/GraphPanel.vue 
b/src/components/detail/GraphPanel.vue
index 23c400a..c183164 100644
--- a/src/components/detail/GraphPanel.vue
+++ b/src/components/detail/GraphPanel.vue
@@ -101,17 +101,32 @@
 StatusOverlay
 },
 props: ['fullscreen', 'graphModel', 'overlayMessage', 'granularity'],
+data () {
+return {
+chartType: 'empty',
+availableChartTypes: {
+empty   : { chart: 'empty', icon: 'question' },
+bar : { chart: 'bar', icon: 'bar' },
+line: { chart: 'line', icon: 'line' },
+map : { chart: 'map', icon: 'globe' },
+table   : { chart: 'table', icon: 'table' },
+}
+}
+},
 computed: {
 chartTypes: function () {
-return this.getChartTypes();
+return !this.graphModel ? [] : {
+map: ['map', 'table'],
+bars: ['bar', 'table'],
+lines: ['line', 'table'],
+list: ['table'],
+}[this.graphModel.config.type].map(k => 
this.availableChartTypes[k]);
 },
 chartIcon: function () {
-return this.availableChartTypes.find(type => type.chart === 
this.chartComponent.replace('-chart', '')).icon;
+return this.availableChartTypes[this.chartType].icon;
 },
 chartComponent: function () {
-if (this.chartType) return this.chartType + '-chart';
-let chartTypes = this.getChartTypes();
-return (chartTypes[0].chart || 'empty') + '-chart';
+return this.chartType  + '-chart';
 },
 aggregate: function () {
 return this.graphModel && this.graphModel.getAggregate();
@@ -124,16 +139,13 @@
 return this.graphModel.activeBreakdown;
 },
 },
-data () {
-return {
-chartType: null,
-availableChartTypes: [
-{ chart: 'bar', icon: 'bar' },
-{ chart: 'line', icon: 'line' },
-{ chart: 'map', icon: 'globe' },
-{ chart: 'table', icon: 'table' },
-]
-}
+
+watch: {
+chartTypes () {
+if (this.chartTypes.length) {
+this.changeChart(this.chartTypes[0]);
+}
+},
 },
 
 methods: {
@@ -148,15 +160,6 @@
 },
 changeTimeRange (range) {
 this.$emit('changeTimeRange', range);
-},
-getChartTypes () {
-return this.availableChartTypes.filter((c) => {
-if (!this.graphModel) { return false; }
-if (c.chart === 'table') return true;
-if (c.chart === 'map') return true;
-if (this.graphModel.config.type === 'bars') { return c.chart 
!== 'line'; }
-if (this.graphModel.config.type === 'lines') { return c.chart 
=== 'line'; }
-});
 },
 toggleFullscreen () {
 this.$emit('toggleFullscreen');
diff --git a/src/components/detail/chart/MapChart/MapLegend.vue 
b/src/components/detail/chart/MapChart/MapLegend.vue
index 0d5ab0d..78350d0 100644
--- a/src/components/detail/chart/MapChart/MapLegend.vue
+++ b/src/components/detail/chart/MapChart/MapLegend.vue
@@ -56,7 +56,7 @@
 .map.legend {
 width: 300px;
 position: absolute;
-bottom: 10px;
+bottom: 120px;
 right: 10px;
 background-color: rgba(255,255,255,0.8);
 }
@@ -74,4 +74,4 @@
 text-anchor: middle;
 }
 
-
\ No newline at end of file
+
diff --git a/src/config/index.js b/src/config/index.js
index dd515fb..b6ac8fa 100644
--- a/src/config/index.js
+++ b/src/config/index.js
@@ -99,7 +99,7 @@
 metrics: [
 'total-pageviews',
 'unique-devices',
-'pageviews-by-country'
+'top-viewed-articles'
 ]
 }
 },
@@ -128,7 +128,11 @@
 ];
 
 
-const metrics = require('./metrics');
+const allMetrics = require('./metrics');
+const metrics = {};
+
+Object.keys(allMetrics).filter(k => !(allMetrics[k].disabled))
+.forEach(k => metrics[k] = allMetrics[k]);
 
 const questions = Object.keys(metrics).map(k => ({
 id: k,
diff --git a/src/config/metrics/contributing.js 
b/src/config/metrics/contributing.js

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Fix blocking problems with map component

2018-01-18 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/405061 )

Change subject: Fix blocking problems with map component
..

Fix blocking problems with map component

Change-Id: I697e9d118f822da1dcde6ba32522a9fa1472e346
---
M src/components/detail/GraphPanel.vue
M src/components/detail/chart/MapChart/MapLegend.vue
M src/config/index.js
M src/config/metrics/contributing.js
M src/config/metrics/reading.js
5 files changed, 36 insertions(+), 30 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/61/405061/1

diff --git a/src/components/detail/GraphPanel.vue 
b/src/components/detail/GraphPanel.vue
index 23c400a..c183164 100644
--- a/src/components/detail/GraphPanel.vue
+++ b/src/components/detail/GraphPanel.vue
@@ -101,17 +101,32 @@
 StatusOverlay
 },
 props: ['fullscreen', 'graphModel', 'overlayMessage', 'granularity'],
+data () {
+return {
+chartType: 'empty',
+availableChartTypes: {
+empty   : { chart: 'empty', icon: 'question' },
+bar : { chart: 'bar', icon: 'bar' },
+line: { chart: 'line', icon: 'line' },
+map : { chart: 'map', icon: 'globe' },
+table   : { chart: 'table', icon: 'table' },
+}
+}
+},
 computed: {
 chartTypes: function () {
-return this.getChartTypes();
+return !this.graphModel ? [] : {
+map: ['map', 'table'],
+bars: ['bar', 'table'],
+lines: ['line', 'table'],
+list: ['table'],
+}[this.graphModel.config.type].map(k => 
this.availableChartTypes[k]);
 },
 chartIcon: function () {
-return this.availableChartTypes.find(type => type.chart === 
this.chartComponent.replace('-chart', '')).icon;
+return this.availableChartTypes[this.chartType].icon;
 },
 chartComponent: function () {
-if (this.chartType) return this.chartType + '-chart';
-let chartTypes = this.getChartTypes();
-return (chartTypes[0].chart || 'empty') + '-chart';
+return this.chartType  + '-chart';
 },
 aggregate: function () {
 return this.graphModel && this.graphModel.getAggregate();
@@ -124,16 +139,13 @@
 return this.graphModel.activeBreakdown;
 },
 },
-data () {
-return {
-chartType: null,
-availableChartTypes: [
-{ chart: 'bar', icon: 'bar' },
-{ chart: 'line', icon: 'line' },
-{ chart: 'map', icon: 'globe' },
-{ chart: 'table', icon: 'table' },
-]
-}
+
+watch: {
+chartTypes () {
+if (this.chartTypes.length) {
+this.changeChart(this.chartTypes[0]);
+}
+},
 },
 
 methods: {
@@ -148,15 +160,6 @@
 },
 changeTimeRange (range) {
 this.$emit('changeTimeRange', range);
-},
-getChartTypes () {
-return this.availableChartTypes.filter((c) => {
-if (!this.graphModel) { return false; }
-if (c.chart === 'table') return true;
-if (c.chart === 'map') return true;
-if (this.graphModel.config.type === 'bars') { return c.chart 
!== 'line'; }
-if (this.graphModel.config.type === 'lines') { return c.chart 
=== 'line'; }
-});
 },
 toggleFullscreen () {
 this.$emit('toggleFullscreen');
diff --git a/src/components/detail/chart/MapChart/MapLegend.vue 
b/src/components/detail/chart/MapChart/MapLegend.vue
index 0d5ab0d..78350d0 100644
--- a/src/components/detail/chart/MapChart/MapLegend.vue
+++ b/src/components/detail/chart/MapChart/MapLegend.vue
@@ -56,7 +56,7 @@
 .map.legend {
 width: 300px;
 position: absolute;
-bottom: 10px;
+bottom: 120px;
 right: 10px;
 background-color: rgba(255,255,255,0.8);
 }
@@ -74,4 +74,4 @@
 text-anchor: middle;
 }
 
-
\ No newline at end of file
+
diff --git a/src/config/index.js b/src/config/index.js
index dd515fb..b6ac8fa 100644
--- a/src/config/index.js
+++ b/src/config/index.js
@@ -99,7 +99,7 @@
 metrics: [
 'total-pageviews',
 'unique-devices',
-'pageviews-by-country'
+'top-viewed-articles'
 ]
 }
 },
@@ -128,7 +128,11 @@
 ];
 
 
-const metrics = require('./metrics');
+const allMetrics = require('./metrics');
+const metrics = {};
+
+Object.keys(allMetrics).filter(k => !(allMetrics[k].disabled))
+.forEach(k => metrics[k] = allMetrics[k]);
 
 const questions = Object.keys(metrics).map(k => ({
 id: k,
diff --git a/src/config/metrics/contributing.js 

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Map component and Pageviews by Country metric

2018-01-18 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/392661 )

Change subject: Map component and Pageviews by Country metric
..


Map component and Pageviews by Country metric

Bug: T181529

Change-Id: I32260459b37603dfe9c4734a436010089d25f557
---
M package.json
M src/apis/aqs.js
M src/components/dashboard/MetricListWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/GraphPanel.vue
D src/components/detail/chart/MapChart.vue
A src/components/detail/chart/MapChart/MapChart.vue
A src/components/detail/chart/MapChart/MapLegend.vue
A src/components/detail/chart/MapChart/MapTooltip.vue
A src/components/detail/chart/MapChart/index.js
A src/components/detail/chart/MapChart/isoLookup.js
A src/components/detail/chart/MapChart/world-50m.js
M src/components/detail/chart/TableChart.vue
M src/config/index.js
M src/config/metrics/metricSchema.js
M src/config/metrics/reading.js
M src/main.js
M src/models/DimensionalData.js
M src/models/GraphModel.js
19 files changed, 922 insertions(+), 54 deletions(-)

Approvals:
  Milimetric: Looks good to me, approved
  jenkins-bot: Verified




-- 
To view, visit https://gerrit.wikimedia.org/r/392661
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I32260459b37603dfe9c4734a436010089d25f557
Gerrit-PatchSet: 14
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Fdans 
Gerrit-Reviewer: Fdans 
Gerrit-Reviewer: Mforns 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Correct the column order

2018-01-12 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/403946 )

Change subject: Correct the column order
..

Correct the column order

The interlanguage_navigation table had current and previous columns in
an order different from the insert/select statement that updates the
table.  This should have worked because the columns in the select are
labeled but apparently hive doesn't work like that, so I corrected the
data manually and this commit makes the table agree with the insert
statement (it's easier this way, because it doesn't require re-starting
or re-running any jobs).

Change-Id: Ida44ca3bab93d73fd10cdb97b776fdc047807da2
---
M hive/interlanguage/create_interlanguage_navigation_table.hql
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery 
refs/changes/46/403946/1

diff --git a/hive/interlanguage/create_interlanguage_navigation_table.hql 
b/hive/interlanguage/create_interlanguage_navigation_table.hql
index a54629d..03678a0 100644
--- a/hive/interlanguage/create_interlanguage_navigation_table.hql
+++ b/hive/interlanguage/create_interlanguage_navigation_table.hql
@@ -10,8 +10,8 @@
 
 CREATE EXTERNAL TABLE IF NOT EXISTS `wmf.interlanguage_navigation` (
 `project_family`string  COMMENT 'The project family to aggregate on',
-`previous_project`  string  COMMENT 'The project (language) found in the 
referers of this group of requests',
 `current_project`   string  COMMENT 'The project (language) of this group 
of requests',
+`previous_project`  string  COMMENT 'The project (language) found in the 
referers of this group of requests',
 `navigation_count`  bigint  COMMENT 'The number of times a user navigated 
from the previous to the current project'
 )
 PARTITIONED BY (

-- 
To view, visit https://gerrit.wikimedia.org/r/403946
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ida44ca3bab93d73fd10cdb97b776fdc047807da2
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Correct the column order

2018-01-12 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/403946 )

Change subject: Correct the column order
..


Correct the column order

The interlanguage_navigation table had current and previous columns in
an order different from the insert/select statement that updates the
table.  This should have worked because the columns in the select are
labeled but apparently hive doesn't work like that, so I corrected the
data manually and this commit makes the table agree with the insert
statement (it's easier this way, because it doesn't require re-starting
or re-running any jobs).

Change-Id: Ida44ca3bab93d73fd10cdb97b776fdc047807da2
---
M hive/interlanguage/create_interlanguage_navigation_table.hql
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/hive/interlanguage/create_interlanguage_navigation_table.hql 
b/hive/interlanguage/create_interlanguage_navigation_table.hql
index a54629d..03678a0 100644
--- a/hive/interlanguage/create_interlanguage_navigation_table.hql
+++ b/hive/interlanguage/create_interlanguage_navigation_table.hql
@@ -10,8 +10,8 @@
 
 CREATE EXTERNAL TABLE IF NOT EXISTS `wmf.interlanguage_navigation` (
 `project_family`string  COMMENT 'The project family to aggregate on',
-`previous_project`  string  COMMENT 'The project (language) found in the 
referers of this group of requests',
 `current_project`   string  COMMENT 'The project (language) of this group 
of requests',
+`previous_project`  string  COMMENT 'The project (language) found in the 
referers of this group of requests',
 `navigation_count`  bigint  COMMENT 'The number of times a user navigated 
from the previous to the current project'
 )
 PARTITIONED BY (

-- 
To view, visit https://gerrit.wikimedia.org/r/403946
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ida44ca3bab93d73fd10cdb97b776fdc047807da2
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Translate g according to the y-axis width

2018-01-11 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/403184 )

Change subject: Translate g according to the y-axis width
..


Translate g according to the y-axis width

Before we were using a constant value, so long numbers would cut off

Bug: T184138
Change-Id: I3f8ccb260e31d7effcdb2bf03715ff50fed6a994
---
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
2 files changed, 13 insertions(+), 11 deletions(-)

Approvals:
  Milimetric: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/components/detail/chart/BarChart.vue 
b/src/components/detail/chart/BarChart.vue
index 518a3fd..1487419 100644
--- a/src/components/detail/chart/BarChart.vue
+++ b/src/components/detail/chart/BarChart.vue
@@ -48,9 +48,7 @@
 root.selectAll('*').remove();
 
 const svg = root.append('svg'),
-  g = svg.append('g').attr(
-'transform', `translate(${margin.left + 
padding},${margin.top})`
-  );
+  g = svg.append('g');
 
 const n = root.node();
 const activeDict = this.graphModel.getActiveBreakdownValues();
@@ -69,6 +67,9 @@
 .style('font-size', '13px')
 .style('font-family', 'Lato, "Open Sans"');
 const yAxisContainerWidth = yAxisContainer.node().getBBox().width;
+g.attr(
+'transform', `translate(${yAxisContainerWidth},${margin.top})`
+);
 
 let width = n.offsetWidth - margin.left - margin.right - 
yAxisContainerWidth;
 let xW = scales.scaleBand()
diff --git a/src/components/detail/chart/LineChart.vue 
b/src/components/detail/chart/LineChart.vue
index bfca190..5c2ebe7 100644
--- a/src/components/detail/chart/LineChart.vue
+++ b/src/components/detail/chart/LineChart.vue
@@ -39,7 +39,8 @@
 
 data () {
 return {
-hoveredPoint: null
+hoveredPoint: null,
+margin: {top: 6, right: 0, bottom: 20, left: 40}
 };
 },
 
@@ -87,14 +88,11 @@
 this.hoveredPoint = null;
 
 const root = d3.select(this.$el).select('.big'),
-  margin = {top: 6, right: 0, bottom: 20, left: 40},
   padding = 4;
 
 const svg = root.select('svg');
 svg.attr('width', 0).attr('height', 0);
-const g = svg.select('.graph').attr(
-'transform', `translate(${margin.left},${margin.top})`
-);
+const g = svg.select('.graph')
 g.selectAll('*').remove();
 let activeBreakdown = this.graphModel.activeBreakdown;
 const { min, max } = this.graphModel.getMinMax();
@@ -104,12 +102,12 @@
 // Generate the x and y scales that we'll use to calculate the line
 // and the two axes.
 
-const width = n.offsetWidth - margin.left - margin.right;
+const width = n.offsetWidth - this.margin.left - this.margin.right;
 let x = scales.scaleTime().rangeRound([0, width]);
 const dates = this.data.map((d) => d.month);
 x.domain(arr.extent(dates));
 
-const height = n.offsetHeight - margin.top - margin.bottom - 
padding;
+const height = n.offsetHeight - this.margin.top - 
this.margin.bottom - padding;
 let y = scales.scaleLinear().rangeRound([height, 0]);
 y.domain([min, max]);
 
@@ -190,7 +188,7 @@
 const xAxis = axes.axisBottom(x),
   yAxis = axes.axisLeft(y).ticks(7)
 
.tickFormat(this.graphModel.formatNumberForMetric.bind(this.graphModel));
-g.append('g')
+const yContainer = g.append('g')
 .call(yAxis)
 .attr('class', 'yAxis')
 .style('font-size', '13px')
@@ -205,6 +203,9 @@
 .attr("dx", "-.8em")
 .attr("dy", ".15em")
 .attr("transform", "rotate(-45)");
+g.attr(
+'transform', 
`translate(${yContainer.node().getBBox().width},${this.margin.top})`
+);
 },
 
 getColorForBreakdown (key) {

-- 
To view, visit https://gerrit.wikimedia.org/r/403184
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I3f8ccb260e31d7effcdb2bf03715ff50fed6a994
Gerrit-PatchSet: 3
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Fdans 
Gerrit-Reviewer: Fdans 
Gerrit-Reviewer: Mforns 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org

[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Point data and success flags to the same directory

2018-01-10 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/403484 )

Change subject: Point data and success flags to the same directory
..

Point data and success flags to the same directory

While working on re-starting this job, I noticed the output data was
actually going to a different directory than the success flags.  I
missed this in manual oozie testing because it has to do with the table
definition, and I was using a different test table in my own db.  I'm
not sure how to test this in production, so a sanity check from someone
doing the code review would be nice.

Bug: T170764
Change-Id: I54e5d2017cd6baeb5ec2c1ba0764107b97b3afeb
---
M hive/interlanguage/create_interlanguage_navigation_table.hql
M oozie/interlanguage/daily/README.md
M oozie/interlanguage/datasets.xml
3 files changed, 3 insertions(+), 11 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery 
refs/changes/84/403484/1

diff --git a/hive/interlanguage/create_interlanguage_navigation_table.hql 
b/hive/interlanguage/create_interlanguage_navigation_table.hql
index 939f8fa..a54629d 100644
--- a/hive/interlanguage/create_interlanguage_navigation_table.hql
+++ b/hive/interlanguage/create_interlanguage_navigation_table.hql
@@ -18,5 +18,5 @@
 `date`  string  COMMENT 'Date in -MM-DD format'
 )
 STORED AS PARQUET
-LOCATION '/wmf/data/wmf/interlanguage/navigation'
+LOCATION '/wmf/data/wmf/interlanguage/navigation/daily'
 ;
diff --git a/oozie/interlanguage/daily/README.md 
b/oozie/interlanguage/daily/README.md
index 5cc51cf..6f56798 100644
--- a/oozie/interlanguage/daily/README.md
+++ b/oozie/interlanguage/daily/README.md
@@ -4,4 +4,4 @@
 from one wiki project to another.  Only counting desktop site browsing.
 
 Output is appended into (-mm-dd) daily partitions
-in /wmf/data/wmf/interlanguage/navigation
+in /wmf/data/wmf/interlanguage/navigation/daily
diff --git a/oozie/interlanguage/datasets.xml b/oozie/interlanguage/datasets.xml
index 18875b5..fb1d59b 100644
--- a/oozie/interlanguage/datasets.xml
+++ b/oozie/interlanguage/datasets.xml
@@ -16,20 +16,12 @@
 that are referred from another wiki within the same project family but
 in a different language.  This allows the tracking of inter-language user
 navigation.
-
-Note that we do not use “${...}” but “${"$"}{...}", as dataset files are
-passed to EL twice in cascade, and in the first EL level, ${MONTH}
-evaluates to the string “${MONTH}”. Hence, we escape the dollar sign in
-“${}" to “${"$"}{...}”. At the first EL level, “${"$"}” gets turned
-into a dollar sign, and “{...}”  is just passed along. Hence, we arrive
-at “${...}” as input for the second EL level. There, the variables hold
-their expected values, and we can start unpadding them.
 -->
 
-
${interlanguage_data_directory}/navigation/daily/date=${YEAR}-${"$"}{MONTH
 + 0}-${"$"}{DAY + 0}
+
${interlanguage_data_directory}/navigation/daily/date=${YEAR}-${MONTH}-${DAY}
 _SUCCESS
 
 

-- 
To view, visit https://gerrit.wikimedia.org/r/403484
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I54e5d2017cd6baeb5ec2c1ba0764107b97b3afeb
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: [WIP] Don't merge

2018-01-08 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/402907 )

Change subject: [WIP] Don't merge
..

[WIP] Don't merge

Working out details for retention with Roan and team, so this is just
preliminary.  Right now the change is adding all fields from
Schema:ChangesListFilterGrouping and Schema:ChangesListFilters except
userId.

Change-Id: I3e9cc04a32a04283d2722a5d8659e3408c9bdee9
---
M 
modules/profile/files/mariadb/misc/eventlogging/eventlogging_purging_whitelist.tsv
1 file changed, 29 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/07/402907/1

diff --git 
a/modules/profile/files/mariadb/misc/eventlogging/eventlogging_purging_whitelist.tsv
 
b/modules/profile/files/mariadb/misc/eventlogging/eventlogging_purging_whitelist.tsv
index ec3dd9c..aa52059 100644
--- 
a/modules/profile/files/mariadb/misc/eventlogging/eventlogging_purging_whitelist.tsv
+++ 
b/modules/profile/files/mariadb/misc/eventlogging/eventlogging_purging_whitelist.tsv
@@ -1,3 +1,32 @@
+ChangesListFilterGrouping  action
+ChangesListFilterGrouping  groupIdentifier
+ChangesListFilterGrouping  filter
+ChangesListFilters pagename
+ChangesListFilters enhancedFiltersEnabled
+ChangesListFilters hideminor
+ChangesListFilters hidemajor
+ChangesListFilters hidebots
+ChangesListFilters hidehumans
+ChangesListFilters hideanons
+ChangesListFilters hidepatrolled
+ChangesListFilters hideunpatrolled
+ChangesListFilters hidemyself
+ChangesListFilters hidebyothers
+ChangesListFilters hideliu
+ChangesListFilters hidecategorization
+ChangesListFilters hidepageedits
+ChangesListFilters hidenewpages
+ChangesListFilters hidelog
+ChangesListFilters hideWikibase
+ChangesListFilters hideReviewed
+ChangesListFilters hidenondamaging
+ChangesListFilters damaging
+ChangesListFilters goodfaith
+ChangesListFilters namespace
+ChangesListFilters userExpLevel
+ChangesListFilters tagfilter
+ChangesListFilters invert
+ChangesListFilters associated
 DiacriticsPoll webHost
 DiacriticsPoll wiki
 DiacriticsPoll event_country

-- 
To view, visit https://gerrit.wikimedia.org/r/402907
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3e9cc04a32a04283d2722a5d8659e3408c9bdee9
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Fix bad input events

2018-01-08 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/402379 )

Change subject: Fix bad input events
..


Fix bad input events

The job was only running on the first hour of the day, not the whole day
as it should.  Fixed the input events with @joal's help.  To really fix,
the data should all be deleted and the job restarted from the beginning.

Bug: T170764
Change-Id: I96cbdd1db7d8a976c5aa97dbed5a82c58ae955e2
---
M oozie/interlanguage/daily/coordinator.xml
1 file changed, 2 insertions(+), 1 deletion(-)

Approvals:
  Milimetric: Verified
  Joal: Looks good to me, approved



diff --git a/oozie/interlanguage/daily/coordinator.xml 
b/oozie/interlanguage/daily/coordinator.xml
index d367fc7..3b72467 100644
--- a/oozie/interlanguage/daily/coordinator.xml
+++ b/oozie/interlanguage/daily/coordinator.xml
@@ -64,7 +64,8 @@
 
 
 
-${coord:current(0)}
+${coord:current(0)}
+${coord:current(23)}
 
 
 

-- 
To view, visit https://gerrit.wikimedia.org/r/402379
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I96cbdd1db7d8a976c5aa97dbed5a82c58ae955e2
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Joal 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: Nikerabbit 
Gerrit-Reviewer: Nuria 
Gerrit-Reviewer: Ottomata 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Add documentation links to each metric

2018-01-05 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/402466 )

Change subject: Add documentation links to each metric
..

Add documentation links to each metric

As part of this, a new landing page has been created at
https://meta.wikimedia.org/wiki/Research:Wikistats_metrics and sub-pages
that define each metric were linked from each metric configuration.
These pages should be improved going forward, but this change fixes the
more immediate problem that right now metrics don't link anywhere.

Bug: T183188
Change-Id: Ib580427b341b104b2f47289b41a19b2dd3593fa6
---
M src/components/detail/GraphPanel.vue
M src/config/metrics/content.js
M src/config/metrics/contributing.js
M src/config/metrics/metricSchema.js
M src/config/metrics/reading.js
5 files changed, 30 insertions(+), 17 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/66/402466/1

diff --git a/src/components/detail/GraphPanel.vue 
b/src/components/detail/GraphPanel.vue
index 520077e..375276b 100644
--- a/src/components/detail/GraphPanel.vue
+++ b/src/components/detail/GraphPanel.vue
@@ -3,7 +3,8 @@
 
 
 
-
+
 {{graphModel.config.fullName || 'No data yet... '}}
 
 {{granularity}}
@@ -51,7 +52,12 @@
 
 {{changeOverRange}}% over this time range.
 
-{{graphModel.config.description}}. More info about this 
metric.
+{{graphModel.config.description}}.
+
+More info about this metric.
+
+
 
 
 
diff --git a/src/config/metrics/content.js b/src/config/metrics/content.js
index b4ec096..1631cef 100644
--- a/src/config/metrics/content.js
+++ b/src/config/metrics/content.js
@@ -1,8 +1,9 @@
 module.exports = {
 'absolute-bytes': {
 fullName: 'Absolute bytes diff',
-description: 'Absolute sum of all diff bytes in a project',
-question: 'How many bytes have been changed?',
+description: 'The sum of the absolute differences in bytes made by 
each edit (or revision), including edits on redirects. In other words, counting 
negative differences as positive',
+question: 'What are the total number of bytes added and removed?',
+infoUrl: 
'https://meta.wikimedia.org/wiki/Research:Wikistats_metrics/Bytes#Absolute_Bytes_Difference',
 defaults: {
 unique: {
 project: ['all-projects'],
@@ -41,8 +42,9 @@
 },
 'edited-pages': {
 fullName: 'Edited pages',
-description: 'Number of pages edited',
+description: 'The number of pages edited, excluding redirect pages',
 question: 'How many pages are edited?',
+infoUrl: 
'https://meta.wikimedia.org/wiki/Research:Wikistats_metrics/Edited_pages',
 defaults: {
 unique: {
 project: ['all-projects'],
@@ -90,8 +92,9 @@
 },
 'net-bytes': {
 fullName: 'Net bytes difference',
-description: 'Net difference between current byte size of a project 
and last period\'s',
-question: 'How did the size in bytes change since last period?',
+description: 'The sum of the differences in bytes made by each edit 
(or revision), including edits on redirects',
+question: 'How did the overall size in bytes change since last 
period?',
+infoUrl: 
'https://meta.wikimedia.org/wiki/Research:Wikistats_metrics/Bytes#Net_Bytes_Difference',
 defaults: {
 unique: {
 project: ['all-projects'],
diff --git a/src/config/metrics/contributing.js 
b/src/config/metrics/contributing.js
index 7308dea..0335596 100644
--- a/src/config/metrics/contributing.js
+++ b/src/config/metrics/contributing.js
@@ -2,8 +2,9 @@
 'editors': {
 disabled: true,
 fullName: 'Editors',
-description: 'Number of editors at a time period.',
+description: 'The count of editors performing edits, including on 
redirect pages',
 question: 'How many editors are there?',
+infoUrl: 
'https://meta.wikimedia.org/wiki/Research:Wikistats_metrics/Editors',
 defaults: {
 unique: {
 project: ['all-projects'],
@@ -51,8 +52,9 @@
 },
 'edits': {
 fullName: 'Edits',
-description: 'Number of wiki edits in a time period',
+description: 'The count of edits (or revisions), including edits on 
redirects',
 question: 'How many edits have been made?',
+infoUrl: 
'https://meta.wikimedia.org/wiki/Research:Wikistats_metrics/Edits',
 defaults: {
 unique: {
 project: ['all-projects'],
@@ -91,8 +93,9 @@
 'new-pages': {
 disabled: true,
 fullName: 'New 

[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Fix bad input events

2018-01-05 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/402379 )

Change subject: Fix bad input events
..

Fix bad input events

The job was only running on the first hour of the day, not the whole day
as it should.  Fixed the input events with @joal's help.  To really fix,
the data should all be deleted and the job restarted from the beginning.

Bug: T170764
Change-Id: I96cbdd1db7d8a976c5aa97dbed5a82c58ae955e2
---
M oozie/interlanguage/daily/coordinator.xml
1 file changed, 2 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery 
refs/changes/79/402379/1

diff --git a/oozie/interlanguage/daily/coordinator.xml 
b/oozie/interlanguage/daily/coordinator.xml
index d367fc7..3b72467 100644
--- a/oozie/interlanguage/daily/coordinator.xml
+++ b/oozie/interlanguage/daily/coordinator.xml
@@ -64,7 +64,8 @@
 
 
 
-${coord:current(0)}
+${coord:current(0)}
+${coord:current(23)}
 
 
 

-- 
To view, visit https://gerrit.wikimedia.org/r/402379
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I96cbdd1db7d8a976c5aa97dbed5a82c58ae955e2
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Replace setTimeout with Vue.nextTick

2018-01-04 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/402026 )

Change subject: Replace setTimeout with Vue.nextTick
..


Replace setTimeout with Vue.nextTick

Bug: T180412
Change-Id: I3c6cbccb6084a2a072a34d38e5adb8b84d508620
---
M src/components/TopicExplorer.vue
M src/components/WikiSelector.vue
2 files changed, 5 insertions(+), 4 deletions(-)

Approvals:
  Milimetric: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/components/TopicExplorer.vue b/src/components/TopicExplorer.vue
index 0371b05..9adabf5 100644
--- a/src/components/TopicExplorer.vue
+++ b/src/components/TopicExplorer.vue
@@ -44,6 +44,7 @@
 
 
 

[MediaWiki-commits] [Gerrit] analytics/analytics.wikimedia.org[master]: Fix reportcard deploy

2017-12-20 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/399472 )

Change subject: Fix reportcard deploy
..


Fix reportcard deploy

Change-Id: I8f5e267a19de6cdb41ed9c7a9d29a8a92659dcd6
---
D dashboards/reportcard/breakdown-toggle-43a8e35.js
D dashboards/reportcard/dygraphs-timeseries-43a8e35.js
A dashboards/reportcard/dygraphs-timeseries-8d20e18.js
A dashboards/reportcard/filter-timeseries-8d20e18.js
A dashboards/reportcard/hierarchy-8d20e18.js
M dashboards/reportcard/index.html
D dashboards/reportcard/out-of-service-43a8e35.js
A dashboards/reportcard/out-of-service-8d20e18.js
D dashboards/reportcard/project-selector-43a8e35.js
M dashboards/reportcard/scripts.js
A dashboards/reportcard/stacked-bars-8d20e18.js
M dashboards/reportcard/styles.css
A dashboards/reportcard/sunburst-8d20e18.js
A dashboards/reportcard/table-timeseries-8d20e18.js
14 files changed, 74,288 insertions(+), 97 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/399472
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I8f5e267a19de6cdb41ed9c7a9d29a8a92659dcd6
Gerrit-PatchSet: 1
Gerrit-Project: analytics/analytics.wikimedia.org
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/analytics.wikimedia.org[master]: Fix reportcard deploy

2017-12-20 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399472 )

Change subject: Fix reportcard deploy
..

Fix reportcard deploy

Change-Id: I8f5e267a19de6cdb41ed9c7a9d29a8a92659dcd6
---
D dashboards/reportcard/breakdown-toggle-43a8e35.js
D dashboards/reportcard/dygraphs-timeseries-43a8e35.js
A dashboards/reportcard/dygraphs-timeseries-8d20e18.js
A dashboards/reportcard/filter-timeseries-8d20e18.js
A dashboards/reportcard/hierarchy-8d20e18.js
M dashboards/reportcard/index.html
D dashboards/reportcard/out-of-service-43a8e35.js
A dashboards/reportcard/out-of-service-8d20e18.js
D dashboards/reportcard/project-selector-43a8e35.js
M dashboards/reportcard/scripts.js
A dashboards/reportcard/stacked-bars-8d20e18.js
M dashboards/reportcard/styles.css
A dashboards/reportcard/sunburst-8d20e18.js
A dashboards/reportcard/table-timeseries-8d20e18.js
14 files changed, 74,288 insertions(+), 97 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/analytics.wikimedia.org 
refs/changes/72/399472/1


-- 
To view, visit https://gerrit.wikimedia.org/r/399472
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8f5e267a19de6cdb41ed9c7a9d29a8a92659dcd6
Gerrit-PatchSet: 1
Gerrit-Project: analytics/analytics.wikimedia.org
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Fix width of axis

2017-12-20 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399438 )

Change subject: Fix width of axis
..

Fix width of axis

Bug: T182817
Change-Id: I995e088c4f2f9fee67ad5223a3c95d4fdf8eeb0f
---
M src/components/detail/chart/BarChart.vue
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/38/399438/1

diff --git a/src/components/detail/chart/BarChart.vue 
b/src/components/detail/chart/BarChart.vue
index 03a3727..518a3fd 100644
--- a/src/components/detail/chart/BarChart.vue
+++ b/src/components/detail/chart/BarChart.vue
@@ -122,7 +122,7 @@
 .style('stroke-width', 0.5);
 }
 const x = scales.scaleTime()
-  .rangeRound([0, graphElement.node().getBBox().width])
+  .rangeRound([0, width])
   .domain(datespan);
 const xAxis = axes.axisBottom(x);
 g.append('g').attr('transform', `translate(0,${height})`)

-- 
To view, visit https://gerrit.wikimedia.org/r/399438
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I995e088c4f2f9fee67ad5223a3c95d4fdf8eeb0f
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Use SI number suffixes

2017-12-20 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/399413 )

Change subject: Use SI number suffixes
..


Use SI number suffixes

Bug: T179906
Change-Id: I3999c4ee85db0af57c096ceb2a81d2e68a71cf5a
---
M src/App.vue
M src/components/detail/chart/BarChart.vue
2 files changed, 17 insertions(+), 1 deletion(-)

Approvals:
  Milimetric: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/App.vue b/src/App.vue
index 9ac3c98..d011195 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -28,6 +28,7 @@
 import Dashboard from './components/dashboard/Dashboard';
 
 import { mapState } from 'vuex';
+import numeral from 'numeral';
 
 /**
 Although the specification for import() supports a dynamic importing of
@@ -51,6 +52,7 @@
 },
 mounted () {
 this.isAdblockerOn() && this.warnAdBlocker();
+this.setUpNumeralLocale();
 },
 
 methods: {
@@ -66,6 +68,21 @@
 message: 'Your ad blocker is preventing Wikistats from showing 
you metrics, because our API uses the word "pageview". There are no ads on any 
Wikimedia sites, but to see all metrics correctly you need to disable your ad 
blocker for this site.',
 level: 'error'
 }
+},
+setUpNumeralLocale() {
+numeral.register('locale', 'international', {
+delimiters: {
+thousands: '',
+decimal: '.'
+},
+abbreviations: {
+thousand: 'k',
+million: 'm',
+billion: 'g',
+trillion: 't'
+}
+});
+numeral.locale('international');
 }
 },
 data () {
diff --git a/src/components/detail/chart/BarChart.vue 
b/src/components/detail/chart/BarChart.vue
index 08c72c7..03a3727 100644
--- a/src/components/detail/chart/BarChart.vue
+++ b/src/components/detail/chart/BarChart.vue
@@ -13,7 +13,6 @@
 import _ from 'lodash';
 
 import config from '../../../config';
-import utils from '../../../utils';
 
 export default {
 name: 'bar-chart',

-- 
To view, visit https://gerrit.wikimedia.org/r/399413
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I3999c4ee85db0af57c096ceb2a81d2e68a71cf5a
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Mforns 
Gerrit-Reviewer: Fdans 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/analytics.wikimedia.org[master]: Add link to wikistats to analytics.wikimedia.org

2017-12-19 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/399309 )

Change subject: Add link to wikistats to analytics.wikimedia.org
..


Add link to wikistats to analytics.wikimedia.org

Bug: T182904
Change-Id: I251ea01ad54a374a24c572336f652b82c3d75137
---
M index.html
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/index.html b/index.html
index 6b5cb1e..d088be5 100644
--- a/index.html
+++ b/index.html
@@ -44,6 +44,7 @@
   Browser 
Statistics
   Readers: 
Pageviews and Unique Devices 
   Reportcard 

+  https://stats.wikimedia.org/v2/;>Wikistats 2
   
   
   

-- 
To view, visit https://gerrit.wikimedia.org/r/399309
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I251ea01ad54a374a24c572336f652b82c3d75137
Gerrit-PatchSet: 1
Gerrit-Project: analytics/analytics.wikimedia.org
Gerrit-Branch: master
Gerrit-Owner: Nuria 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/analytics.wikimedia.org[master]: Update vital-signs and reportcard

2017-12-19 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/399224 )

Change subject: Update vital-signs and reportcard
..


Update vital-signs and reportcard

Change-Id: I7a6525037be865a4543a139866b4b3f9c916766f
---
C dashboards/reportcard/breakdown-toggle-43a8e35.js
R dashboards/reportcard/dygraphs-timeseries-43a8e35.js
D dashboards/reportcard/dygraphs-timeseries-8d20e18.js
D dashboards/reportcard/filter-timeseries-8d20e18.js
D dashboards/reportcard/filter-timeseries-f144407.js
D dashboards/reportcard/hierarchy-8d20e18.js
D dashboards/reportcard/hierarchy-f144407.js
M dashboards/reportcard/index.html
R dashboards/reportcard/out-of-service-43a8e35.js
D dashboards/reportcard/out-of-service-f144407.js
C dashboards/reportcard/project-selector-43a8e35.js
M dashboards/reportcard/scripts.js
D dashboards/reportcard/stacked-bars-8d20e18.js
D dashboards/reportcard/stacked-bars-f144407.js
M dashboards/reportcard/styles.css
D dashboards/reportcard/sunburst-8d20e18.js
D dashboards/reportcard/sunburst-f144407.js
D dashboards/reportcard/table-timeseries-8d20e18.js
D dashboards/reportcard/table-timeseries-f144407.js
M dashboards/reportcard/themes/default/assets/fonts/icons.eot
M dashboards/reportcard/themes/default/assets/fonts/icons.svg
M dashboards/reportcard/themes/default/assets/fonts/icons.ttf
M dashboards/reportcard/themes/default/assets/fonts/icons.woff
M dashboards/reportcard/themes/default/assets/fonts/icons.woff2
R dashboards/vital-signs/breakdown-toggle-43a8e35.js
C dashboards/vital-signs/dygraphs-timeseries-43a8e35.js
D dashboards/vital-signs/dygraphs-timeseries-8d20e18.js
M dashboards/vital-signs/index.html
R dashboards/vital-signs/out-of-service-43a8e35.js
R dashboards/vital-signs/project-selector-43a8e35.js
M dashboards/vital-signs/scripts.js
M dashboards/vital-signs/styles.css
M dashboards/vital-signs/themes/default/assets/fonts/icons.eot
M dashboards/vital-signs/themes/default/assets/fonts/icons.svg
M dashboards/vital-signs/themes/default/assets/fonts/icons.ttf
M dashboards/vital-signs/themes/default/assets/fonts/icons.woff
M dashboards/vital-signs/themes/default/assets/fonts/icons.woff2
37 files changed, 1,491 insertions(+), 5,563 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/399224
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I7a6525037be865a4543a139866b4b3f9c916766f
Gerrit-PatchSet: 1
Gerrit-Project: analytics/analytics.wikimedia.org
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/analytics.wikimedia.org[master]: Update vital-signs and reportcard

2017-12-19 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399224 )

Change subject: Update vital-signs and reportcard
..

Update vital-signs and reportcard

Change-Id: I7a6525037be865a4543a139866b4b3f9c916766f
---
C dashboards/reportcard/breakdown-toggle-43a8e35.js
R dashboards/reportcard/dygraphs-timeseries-43a8e35.js
D dashboards/reportcard/dygraphs-timeseries-8d20e18.js
D dashboards/reportcard/filter-timeseries-8d20e18.js
D dashboards/reportcard/filter-timeseries-f144407.js
D dashboards/reportcard/hierarchy-8d20e18.js
D dashboards/reportcard/hierarchy-f144407.js
M dashboards/reportcard/index.html
R dashboards/reportcard/out-of-service-43a8e35.js
D dashboards/reportcard/out-of-service-f144407.js
C dashboards/reportcard/project-selector-43a8e35.js
M dashboards/reportcard/scripts.js
D dashboards/reportcard/stacked-bars-8d20e18.js
D dashboards/reportcard/stacked-bars-f144407.js
M dashboards/reportcard/styles.css
D dashboards/reportcard/sunburst-8d20e18.js
D dashboards/reportcard/sunburst-f144407.js
D dashboards/reportcard/table-timeseries-8d20e18.js
D dashboards/reportcard/table-timeseries-f144407.js
M dashboards/reportcard/themes/default/assets/fonts/icons.eot
M dashboards/reportcard/themes/default/assets/fonts/icons.svg
M dashboards/reportcard/themes/default/assets/fonts/icons.ttf
M dashboards/reportcard/themes/default/assets/fonts/icons.woff
M dashboards/reportcard/themes/default/assets/fonts/icons.woff2
R dashboards/vital-signs/breakdown-toggle-43a8e35.js
C dashboards/vital-signs/dygraphs-timeseries-43a8e35.js
D dashboards/vital-signs/dygraphs-timeseries-8d20e18.js
M dashboards/vital-signs/index.html
R dashboards/vital-signs/out-of-service-43a8e35.js
R dashboards/vital-signs/project-selector-43a8e35.js
M dashboards/vital-signs/scripts.js
M dashboards/vital-signs/styles.css
M dashboards/vital-signs/themes/default/assets/fonts/icons.eot
M dashboards/vital-signs/themes/default/assets/fonts/icons.svg
M dashboards/vital-signs/themes/default/assets/fonts/icons.ttf
M dashboards/vital-signs/themes/default/assets/fonts/icons.woff
M dashboards/vital-signs/themes/default/assets/fonts/icons.woff2
37 files changed, 1,491 insertions(+), 5,563 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/analytics.wikimedia.org 
refs/changes/24/399224/1


-- 
To view, visit https://gerrit.wikimedia.org/r/399224
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7a6525037be865a4543a139866b4b3f9c916766f
Gerrit-PatchSet: 1
Gerrit-Project: analytics/analytics.wikimedia.org
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/dashiki[master]: Remove unused deploy config

2017-12-19 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/399222 )

Change subject: Remove unused deploy config
..


Remove unused deploy config

Change-Id: Id363f794a0179911169808f3fb725a0014a7f777
---
M config.yaml
1 file changed, 1 insertion(+), 9 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/config.yaml b/config.yaml
index e80420d..28923e4 100644
--- a/config.yaml
+++ b/config.yaml
@@ -1,13 +1,5 @@
 # Deployment config for dashboards
 config:
-browser-reports:
-layout: tabs
-config: Dashiki:SimpleRequestBreakdowns
-piwikHost: piwik.wikimedia.org
-piwikId: 8
-hostname: browser-reports.wmflabs.org
-subfolder:
-
 edit-analysis:
 layout: compare
 config: Dashiki:VisualEditorAndWikitext
@@ -39,7 +31,7 @@
 piwikId: 10
 hostname: edit-analysis.wmflabs.org
 subfolder: beta-enables
-   
+
 editor-engagement:
 layout: metrics-by-project
 config: Dashiki:EditorEngagement

-- 
To view, visit https://gerrit.wikimedia.org/r/399222
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id363f794a0179911169808f3fb725a0014a7f777
Gerrit-PatchSet: 1
Gerrit-Project: analytics/dashiki
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/dashiki[master]: Remove unused deploy config

2017-12-19 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399222 )

Change subject: Remove unused deploy config
..

Remove unused deploy config

Change-Id: Id363f794a0179911169808f3fb725a0014a7f777
---
M config.yaml
1 file changed, 1 insertion(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/dashiki 
refs/changes/22/399222/1

diff --git a/config.yaml b/config.yaml
index e80420d..28923e4 100644
--- a/config.yaml
+++ b/config.yaml
@@ -1,13 +1,5 @@
 # Deployment config for dashboards
 config:
-browser-reports:
-layout: tabs
-config: Dashiki:SimpleRequestBreakdowns
-piwikHost: piwik.wikimedia.org
-piwikId: 8
-hostname: browser-reports.wmflabs.org
-subfolder:
-
 edit-analysis:
 layout: compare
 config: Dashiki:VisualEditorAndWikitext
@@ -39,7 +31,7 @@
 piwikId: 10
 hostname: edit-analysis.wmflabs.org
 subfolder: beta-enables
-   
+
 editor-engagement:
 layout: metrics-by-project
 config: Dashiki:EditorEngagement

-- 
To view, visit https://gerrit.wikimedia.org/r/399222
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id363f794a0179911169808f3fb725a0014a7f777
Gerrit-PatchSet: 1
Gerrit-Project: analytics/dashiki
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/dashiki[master]: Fix visualizer when no startDate specified in conf

2017-12-19 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/399212 )

Change subject: Fix visualizer when no startDate specified in conf
..


Fix visualizer when no startDate specified in conf

Also, add link to CC0 license

Change-Id: I1d44601781e9239309606eb58623106a26255310
---
M src/components/layouts/created-by/created-by.html
M src/components/visualizers/visualizer/visualizer.js
2 files changed, 5 insertions(+), 3 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/src/components/layouts/created-by/created-by.html 
b/src/components/layouts/created-by/created-by.html
index f1b188e..ce1ef76 100644
--- a/src/components/layouts/created-by/created-by.html
+++ b/src/components/layouts/created-by/created-by.html
@@ -6,6 +6,8 @@
 
 
-All data, charts, and other content is 
available under the Creative Commons CC0 dedication.
+All data, charts, and other content is 
available under the
+https://creativecommons.org/publicdomain/zero/1.0/;>Creative Commons 
CC0 dedication.
+
 
 
diff --git a/src/components/visualizers/visualizer/visualizer.js 
b/src/components/visualizers/visualizer/visualizer.js
index 53cd529..4c9b84d 100644
--- a/src/components/visualizers/visualizer/visualizer.js
+++ b/src/components/visualizers/visualizer/visualizer.js
@@ -68,8 +68,8 @@
 }
 }
 }
-this.startDate = ko.observable(moment(graph.startDate).valueOf());
-this.minDate = ko.observable(moment(graph.minDate).valueOf());
+this.startDate = ko.observable(graph.startDate ? 
moment(graph.startDate).valueOf() : null);
+this.minDate = ko.observable(graph.minDate ? 
moment(graph.minDate).valueOf() : null);
 this.endDate = ko.observable();
 
 /** If date is a unix tiemstamp change it to ISO format **/

-- 
To view, visit https://gerrit.wikimedia.org/r/399212
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I1d44601781e9239309606eb58623106a26255310
Gerrit-PatchSet: 2
Gerrit-Project: analytics/dashiki
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/analytics.wikimedia.org[master]: Update browser reports

2017-12-19 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/399220 )

Change subject: Update browser reports
..


Update browser reports

Change-Id: Ib5198e05a4c4bf454fb5ae400fd62ac8ab7016d6
---
D dashboards/browsers/dygraphs-timeseries-8d20e18.js
R dashboards/browsers/dygraphs-timeseries-ba10723.js
D dashboards/browsers/filter-timeseries-8d20e18.js
R dashboards/browsers/filter-timeseries-ba10723.js
D dashboards/browsers/hierarchy-8d20e18.js
R dashboards/browsers/hierarchy-ba10723.js
M dashboards/browsers/index.html
R dashboards/browsers/out-of-service-ba10723.js
D dashboards/browsers/out-of-service-f144407.js
M dashboards/browsers/scripts.js
D dashboards/browsers/stacked-bars-8d20e18.js
R dashboards/browsers/stacked-bars-ba10723.js
M dashboards/browsers/styles.css
D dashboards/browsers/sunburst-8d20e18.js
R dashboards/browsers/sunburst-ba10723.js
R dashboards/browsers/table-timeseries-ba10723.js
D dashboards/browsers/table-timeseries-f144407.js
M dashboards/browsers/themes/default/assets/fonts/icons.eot
M dashboards/browsers/themes/default/assets/fonts/icons.svg
M dashboards/browsers/themes/default/assets/fonts/icons.ttf
M dashboards/browsers/themes/default/assets/fonts/icons.woff
M dashboards/browsers/themes/default/assets/fonts/icons.woff2
22 files changed, 712 insertions(+), 2,727 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/399220
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib5198e05a4c4bf454fb5ae400fd62ac8ab7016d6
Gerrit-PatchSet: 1
Gerrit-Project: analytics/analytics.wikimedia.org
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/analytics.wikimedia.org[master]: Update browser reports

2017-12-19 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399220 )

Change subject: Update browser reports
..

Update browser reports

Change-Id: Ib5198e05a4c4bf454fb5ae400fd62ac8ab7016d6
---
D dashboards/browsers/dygraphs-timeseries-8d20e18.js
R dashboards/browsers/dygraphs-timeseries-ba10723.js
D dashboards/browsers/filter-timeseries-8d20e18.js
R dashboards/browsers/filter-timeseries-ba10723.js
D dashboards/browsers/hierarchy-8d20e18.js
R dashboards/browsers/hierarchy-ba10723.js
M dashboards/browsers/index.html
R dashboards/browsers/out-of-service-ba10723.js
D dashboards/browsers/out-of-service-f144407.js
M dashboards/browsers/scripts.js
D dashboards/browsers/stacked-bars-8d20e18.js
R dashboards/browsers/stacked-bars-ba10723.js
M dashboards/browsers/styles.css
D dashboards/browsers/sunburst-8d20e18.js
R dashboards/browsers/sunburst-ba10723.js
R dashboards/browsers/table-timeseries-ba10723.js
D dashboards/browsers/table-timeseries-f144407.js
M dashboards/browsers/themes/default/assets/fonts/icons.eot
M dashboards/browsers/themes/default/assets/fonts/icons.svg
M dashboards/browsers/themes/default/assets/fonts/icons.ttf
M dashboards/browsers/themes/default/assets/fonts/icons.woff
M dashboards/browsers/themes/default/assets/fonts/icons.woff2
22 files changed, 712 insertions(+), 2,727 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/analytics.wikimedia.org 
refs/changes/20/399220/1


-- 
To view, visit https://gerrit.wikimedia.org/r/399220
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib5198e05a4c4bf454fb5ae400fd62ac8ab7016d6
Gerrit-PatchSet: 1
Gerrit-Project: analytics/analytics.wikimedia.org
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/dashiki[master]: Add link to CC0 license

2017-12-19 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399212 )

Change subject: Add link to CC0 license
..

Add link to CC0 license

Change-Id: I1d44601781e9239309606eb58623106a26255310
---
M src/app/apis/config-api.js
M src/components/layouts/created-by/created-by.html
2 files changed, 4 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/dashiki 
refs/changes/12/399212/1

diff --git a/src/app/apis/config-api.js b/src/app/apis/config-api.js
index 308d7ac..a9a12d0 100644
--- a/src/app/apis/config-api.js
+++ b/src/app/apis/config-api.js
@@ -32,6 +32,7 @@
 var dashboardArticle =
 this.config.dashboardArticle ||
 this.config.defaultDashboardArticleRoot + '/' + layout;
+dashboardArticle = 'Config:Dashiki:FlowReportcard';
 this.getConfig(dashboardArticle, callback);
 
 };
diff --git a/src/components/layouts/created-by/created-by.html 
b/src/components/layouts/created-by/created-by.html
index f1b188e..ce1ef76 100644
--- a/src/components/layouts/created-by/created-by.html
+++ b/src/components/layouts/created-by/created-by.html
@@ -6,6 +6,8 @@
 
 
-All data, charts, and other content is 
available under the Creative Commons CC0 dedication.
+All data, charts, and other content is 
available under the
+https://creativecommons.org/publicdomain/zero/1.0/;>Creative Commons 
CC0 dedication.
+
 
 

-- 
To view, visit https://gerrit.wikimedia.org/r/399212
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1d44601781e9239309606eb58623106a26255310
Gerrit-PatchSet: 1
Gerrit-Project: analytics/dashiki
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] research/recommendation-api[master]: Labs -> Cloud VPS

2017-12-18 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/398824 )

Change subject: Labs -> Cloud VPS
..

Labs -> Cloud VPS

Making the change attempted here:
https://github.com/wikimedia-research/translation-recs-app/pull/83

Change-Id: Id8f897e3d0db88427e5e1b148708340c512fa877
---
M recommendation/web/static/gf-disclaimer.tag
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/research/recommendation-api 
refs/changes/24/398824/1

diff --git a/recommendation/web/static/gf-disclaimer.tag 
b/recommendation/web/static/gf-disclaimer.tag
index 216e17c..8c0ba59 100644
--- a/recommendation/web/static/gf-disclaimer.tag
+++ b/recommendation/web/static/gf-disclaimer.tag
@@ -7,7 +7,7 @@
 
 This experimental tool is hosted on
 https://wikitech.wikimedia.org/wiki/Help:FAQ; 
class="alert-link" target="_blank" rel="noopener">
-Wikimedia Labs.
+Wikimedia Cloud VPS.
 https://phabricator.wikimedia.org/T124503; 
class="alert-link" target="_blank" rel="noopener">
 Information collected
 when you visit this site, and through your use of the

-- 
To view, visit https://gerrit.wikimedia.org/r/398824
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id8f897e3d0db88427e5e1b148708340c512fa877
Gerrit-PatchSet: 1
Gerrit-Project: research/recommendation-api
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Add MIT license

2017-12-14 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/398412 )

Change subject: Add MIT license
..

Add MIT license

Contributors were all employed with WMF at the time of their work:

459  milimetric (Milimetric)
 66  Evan Rosen
 45  Petrea Corneliu Stefan
 28  Nuria Ruiz
 24  Christian Aistleitner
 20  Marcel Ruiz Forns
 13  Teresa Cho
 10  Madhumitha Viswanathan
  8  Nuria
  7  Bahodir Mansurov
  7  Diederik van Liere
  7  Sumana Harihareswara
  6  Antoine Musso
  4  Andrew Otto
  3  Charles Salvia
  3  nuria
  2  Andrew Green
  2  Dereckson
  1  Stefan.petrea
  1  fhocutt

Bug: T60753
Change-Id: Ie33a64f0e89f29f83419eeeb24258909e9e997db
---
A LICENSE
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikimetrics 
refs/changes/12/398412/1

diff --git a/LICENSE b/LICENSE
new file mode 100644
index 000..764cd41
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,7 @@
+Copyright 2013 Wikimedia Foundation
+
+Permission is hereby granted, free of charge, to any person obtaining a copy 
of this software and associated documentation files (the "Software"), to deal 
in the Software without restriction, including without limitation the rights to 
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies 
of the Software, and to permit persons to whom the Software is furnished to do 
so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all 
copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 
SOFTWARE.

-- 
To view, visit https://gerrit.wikimedia.org/r/398412
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie33a64f0e89f29f83419eeeb24258909e9e997db
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/dashiki[master]: Add links to the rendered config wiki article

2017-12-14 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/398411 )

Change subject: Add links to the rendered config wiki article
..

Add links to the rendered config wiki article

Three main things get added in the header/footer/or sidebar depending on
which layout is being shown:

* credit for Dashiki and link to Dashiki documentation (so people know
  what the heck built this thing they're looking at)
* link to the config page that built this dashboard
* data license CC0

Bug: T182477
Change-Id: Ib809030be60b65fa304fdd0a51e064e97e1e8953
---
A LICENSE
M README.md
M gulpfile.js
M package.json
M semantic.json
M src/app/apis/config-api.js
M src/app/config.js
M src/app/startup.js
M src/components/layouts/compare/compare.html
A src/components/layouts/created-by/created-by.html
A src/components/layouts/created-by/created-by.js
M src/components/layouts/metrics-by-project/metrics-by-project.html
M src/components/layouts/tabs/tabs.html
M src/layouts/compare/index.js
M src/layouts/compare/styles.css
M src/layouts/metrics-by-project/index.js
M src/layouts/metrics-by-project/styles.css
M src/layouts/tabs/index.js
M src/layouts/tabs/styles.css
M test/app/apis.js
20 files changed, 108 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/dashiki 
refs/changes/11/398411/1

diff --git a/LICENSE b/LICENSE
new file mode 100644
index 000..9f793ec
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,7 @@
+Copyright 2014 Wikimedia Foundation
+
+Permission is hereby granted, free of charge, to any person obtaining a copy 
of this software and associated documentation files (the "Software"), to deal 
in the Software without restriction, including without limitation the rights to 
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies 
of the Software, and to permit persons to whom the Software is furnished to do 
so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all 
copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 
SOFTWARE.
diff --git a/README.md b/README.md
index 82b393c..0d6deb9 100644
--- a/README.md
+++ b/README.md
@@ -20,7 +20,9 @@
 sudo npm install -g gulp
 cd semantic && gulp build
 
-NOTE: yarn install is under consideration, some incompabilities remain
+NOTE: on Ubuntu, you may need to do `sudo apt-get install libcairo2-dev 
libjpeg-dev libgif-dev` to get npm to work.
+
+NOTE: yarn install is under consideration, some incompabilities remain.
 
 How to build some dashboards:
 gulp --layout metrics-by-project --config Dashiki:VitalSigns
diff --git a/gulpfile.js b/gulpfile.js
index 9d7cd97..f9e9b3b 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -24,7 +24,7 @@
 
 layoutsRoot : './src/layouts/',
 wiki: 'meta.wikimedia.org',
-namespace   : 'Config:', // NOTE: set this up on meta
+namespace   : 'Config:',
 buildConfigPath : './src/config-from-build.js',
 outputPath  : 'dist/',
 requireConfig   : './src/app/require.config',
diff --git a/package.json b/package.json
index beea58a..ec2b944 100644
--- a/package.json
+++ b/package.json
@@ -9,6 +9,7 @@
   "author": "milimetric ",
   "license": "MIT",
   "dependencies": {
+"bower": "^1.8.2",
 "d3": "^3.5.17",
 "d3-scale-chromatic": "^1.1.0",
 "dygraphs": "^1.1.1",
diff --git a/semantic.json b/semantic.json
index a681d3f..fb4f4a7 100644
--- a/semantic.json
+++ b/semantic.json
@@ -18,5 +18,5 @@
   "permission": false,
   "autoInstall": false,
   "rtl": false,
-  "version": "2.2.6"
+  "version": "2.2.13"
 }
\ No newline at end of file
diff --git a/src/app/apis/config-api.js b/src/app/apis/config-api.js
index 049bb6d..24b0671 100644
--- a/src/app/apis/config-api.js
+++ b/src/app/apis/config-api.js
@@ -29,10 +29,10 @@
 
 // The dashboard page can be injected by the build (see gulpfile.js)
 // For development, samples exist at config.defaultDashboardPageRoot
-var dashboardPage =
-this.config.dashboardPage ||
+var dashboardArticle =
+this.config.dashboardArticle ||
 this.config.defaultDashboardPageRoot + '/' + layout;
-this.getConfig(dashboardPage, callback);
+this.getConfig(dashboardArticle, callback);
 
 };
 
diff --git a/src/app/config.js b/src/app/config.js
index 3c07f9e..173e20b 100644
--- a/src/app/config.js
+++ b/src/app/config.js
@@ -50,10 

[MediaWiki-commits] [Gerrit] analytics/limn-edit-data[master]: Update for new Edit schema version 17541122

2017-12-13 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/397626 )

Change subject: Update for new Edit schema version 17541122
..


Update for new Edit schema version 17541122

New action state (loaded, after ready and before saveIntent), which
means some changes to the queries, and editor type (wikitext), which
doesn't.

Bug: T182620
Change-Id: I9bf52dcbaa175ef52dcc9a4b615e14785be753ee
---
M edit/failure_rates_by_type.sql
M edit/failure_types_by_user_type.sql
M edit/rates.sql
M edit/sessions.sql
M edit/success_by_user_type.sql
5 files changed, 133 insertions(+), 32 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/edit/failure_rates_by_type.sql b/edit/failure_rates_by_type.sql
index 05e2500..aa1525f 100644
--- a/edit/failure_rates_by_type.sql
+++ b/edit/failure_rates_by_type.sql
@@ -63,20 +63,38 @@
 timestamp < '{to_timestamp}'
  ) raw_events
 
+ union all
+
+ select
+timestamp,
+event_action,
+`event_action.saveFailure.type`,
+clientIp,
+event_editingSessionId
+ from Edit_17541122
+ where
+event_editor = '{editor}' and
+('{wiki}' = 'all' or wiki = '{wiki}') and
+timestamp >= '{from_timestamp}' and
+timestamp < '{to_timestamp}'
+ ) raw_events
+
  inner join
 (select 'init' as action, 0 as ord
 union all
  select 'ready' as action, 1 as ord
 union all
- select 'saveIntent' as action, 2 as ord
+ select 'loaded' as action, 2 as ord
 union all
- select 'saveAttempt' as action, 3 as ord
+ select 'saveIntent' as action, 3 as ord
 union all
- select 'saveFailure' as action, 4 as ord
+ select 'saveAttempt' as action, 4 as ord
 union all
- select 'saveSuccess' as action, 5 as ord
+ select 'saveFailure' as action, 5 as ord
 union all
- select 'abort' as action, 6 as ord
+ select 'saveSuccess' as action, 6 as ord
+union all
+ select 'abort' as action, 7 as ord
 ) action_order
  on action = event_action
 
diff --git a/edit/failure_types_by_user_type.sql 
b/edit/failure_types_by_user_type.sql
index 6fbfcfc..8b0b029 100644
--- a/edit/failure_types_by_user_type.sql
+++ b/edit/failure_types_by_user_type.sql
@@ -42,6 +42,19 @@
timestamp < '{to_timestamp}' and
`event_action` = 'saveFailure' and
`event_action.saveFailure.type` is not null )
+
+   union all
+
+   ( select timestamp, `event_user.class`,
+   `event_user.editCount`, `event_action.saveFailure.type`
+   from Edit_17541122
+   where
+   event_editor = '{editor}' and
+   ('{wiki}' = 'all' or wiki = '{wiki}') and
+   timestamp >= '{from_timestamp}' and
+   timestamp < '{to_timestamp}' and
+   `event_action` = 'saveFailure' and
+   `event_action.saveFailure.type` is not null )
 ) saveFailures
 
 group by 1, 2
diff --git a/edit/rates.sql b/edit/rates.sql
index eef80db..dc1bfa0 100644
--- a/edit/rates.sql
+++ b/edit/rates.sql
@@ -1,4 +1,5 @@
  select day,
+sum(ready and not loaded) / sum(ready) as `load-failure`,
 sum(ready and not saving) / sum(ready) as `bounce-rate`,
 sum(ready and not attempt) / sum(ready) as `not-attempted-rate`,
 sum(attempt and success) / sum(attempt) as `success-rate`,
@@ -6,6 +7,7 @@
 
from (select day,
 actions like '%ready%' as ready,
+actions like '%loaded%' as loaded,
 actions like '%save%' as saving,
 actions like '%Failure%' as failure,
 actions like '%Attempt%' as attempt,
@@ -44,20 +46,37 @@
timestamp < '{to_timestamp}'
 ) raw_events
 
+union all
+
+select
+   timestamp,
+   event_action,
+   clientIp,
+   event_editingSessionId
+from Edit_17541122
+where
+   event_editor = '{editor}' and
+   ('{wiki}' = 'all' or wiki = '{wiki}') and
+   timestamp >= '{from_timestamp}' and
+   timestamp < '{to_timestamp}'
+) raw_events
+
 inner join
(select 'init' as action, 0 as ord
union all
 select 'ready' as action, 1 as ord
union all
-select 'saveIntent' as action, 2 as ord
+select 'loaded' as action, 2 as ord
union all
-select 'saveAttempt' as action, 3 as ord
+ 

[MediaWiki-commits] [Gerrit] analytics/limn-edit-data[master]: Drop support for the Edit_11448630 schema revision

2017-12-13 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/397627 )

Change subject: Drop support for the Edit_11448630 schema revision
..


Drop support for the Edit_11448630 schema revision

Not been written to (except for very oddly-cached code) since
October 2015. No need to keep querying it.

Change-Id: Ibc248c45f0adb86d53df44299544639df8987eaa
---
M edit/failure_rates_by_type.sql
M edit/failure_types_by_user_type.sql
M edit/rates.sql
M edit/sessions.sql
M edit/success_by_user_type.sql
5 files changed, 0 insertions(+), 80 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/edit/failure_rates_by_type.sql b/edit/failure_rates_by_type.sql
index aa1525f..820d405 100644
--- a/edit/failure_rates_by_type.sql
+++ b/edit/failure_rates_by_type.sql
@@ -38,23 +38,6 @@
 `event_action.saveFailure.type`,
 clientIp,
 event_editingSessionId
- from Edit_11448630
- where
-event_editor = '{editor}' and
-('{wiki}' = 'all' or wiki = '{wiki}') and
-timestamp >= '{from_timestamp}' and
-timestamp < '{to_timestamp}'
-
- # Add in events using the new schema. To be removed once everything
- # is switched over.
- union all
-
- select
-timestamp,
-event_action,
-`event_action.saveFailure.type`,
-clientIp,
-event_editingSessionId
  from Edit_13457736
  where
 event_editor = '{editor}' and
diff --git a/edit/failure_types_by_user_type.sql 
b/edit/failure_types_by_user_type.sql
index 8b0b029..7ffb88d 100644
--- a/edit/failure_types_by_user_type.sql
+++ b/edit/failure_types_by_user_type.sql
@@ -21,19 +21,6 @@
 from (
( select timestamp, `event_user.class`,
`event_user.editCount`, `event_action.saveFailure.type`
-   from Edit_11448630
-   where
-   event_editor = '{editor}' and
-   ('{wiki}' = 'all' or wiki = '{wiki}') and
-   timestamp >= '{from_timestamp}' and
-   timestamp < '{to_timestamp}' and
-   `event_action` = 'saveFailure' and
-   `event_action.saveFailure.type` is not null )
-
-   union all
-
-   ( select timestamp, `event_user.class`,
-   `event_user.editCount`, `event_action.saveFailure.type`
from Edit_13457736
where
event_editor = '{editor}' and
diff --git a/edit/rates.sql b/edit/rates.sql
index dc1bfa0..b5315b0 100644
--- a/edit/rates.sql
+++ b/edit/rates.sql
@@ -22,22 +22,6 @@
event_action,
clientIp,
event_editingSessionId
-from Edit_11448630
-where
-   event_editor = '{editor}' and
-   ('{wiki}' = 'all' or wiki = '{wiki}') and
-   timestamp >= '{from_timestamp}' and
-   timestamp < '{to_timestamp}'
-
-# Add in events using the new schema. To be removed once 
everything
-# is switched over.
-union all
-
-select
-   timestamp,
-   event_action,
-   clientIp,
-   event_editingSessionId
 from Edit_13457736
 where
event_editor = '{editor}' and
diff --git a/edit/sessions.sql b/edit/sessions.sql
index cfe4231..a3210d1 100644
--- a/edit/sessions.sql
+++ b/edit/sessions.sql
@@ -8,22 +8,6 @@
event_action,
clientIp,
event_editingSessionId
-from Edit_11448630
-where
-   event_editor = '{editor}' and
-   ('{wiki}' = 'all' or wiki = '{wiki}') and
-   timestamp >= '{from_timestamp}' and
-   timestamp < '{to_timestamp}'
-
-# Add in events using the new schema. To be removed once 
everything
-# is switched over.
-union all
-
-select
-   timestamp,
-   event_action,
-   clientIp,
-   event_editingSessionId
 from Edit_13457736
 where
event_editor = '{editor}' and
diff --git a/edit/success_by_user_type.sql b/edit/success_by_user_type.sql
index 0fb8612..48ffd21 100644
--- a/edit/success_by_user_type.sql
+++ b/edit/success_by_user_type.sql
@@ -34,24 +34,6 @@
event_editingSessionId,
`event_user.class`,
`event_user.editCount` as edit_count
-from Edit_11448630
-where
-   event_editor = '{editor}' and
-   ('{wiki}' = 'all' or wiki = '{wiki}') and
-   timestamp >= '{from_timestamp}' and
-   timestamp < '{to_timestamp}'
-
- 

[MediaWiki-commits] [Gerrit] analytics/limn-edit-data[master]: Revert "Adding renamed tables to sql union statements"

2017-12-13 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/397625 )

Change subject: Revert "Adding renamed tables to sql union statements"
..


Revert "Adding renamed tables to sql union statements"

This reverts commit 582bcce26e2a16643e1b127834ed825585e33ede.

The temporary table Edit_13457736_15423246 no longer exists, so we can
remove this complexity.

Change-Id: I6327dcaba6ec672f0738d3314ead4ddc9f780a9f
---
M edit/failure_rates_by_type.sql
M edit/failure_types_by_user_type.sql
M edit/rates.sql
M edit/sessions.sql
M edit/success_by_user_type.sql
5 files changed, 4 insertions(+), 84 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/edit/failure_rates_by_type.sql b/edit/failure_rates_by_type.sql
index a4e04e7..05e2500 100644
--- a/edit/failure_rates_by_type.sql
+++ b/edit/failure_rates_by_type.sql
@@ -55,29 +55,13 @@
 `event_action.saveFailure.type`,
 clientIp,
 event_editingSessionId
- from Edit_13457736_15423246
- where
-event_editor = '{editor}' and
-('{wiki}' = 'all' or wiki = '{wiki}') and
-timestamp >= '{from_timestamp}' and
-timestamp < '{to_timestamp}'
-
-union all
-
- select
-timestamp,
-event_action,
-`event_action.saveFailure.type`,
-clientIp,
-event_editingSessionId
  from Edit_13457736
  where
 event_editor = '{editor}' and
 ('{wiki}' = 'all' or wiki = '{wiki}') and
 timestamp >= '{from_timestamp}' and
 timestamp < '{to_timestamp}'
-
-) raw_events
+ ) raw_events
 
  inner join
 (select 'init' as action, 0 as ord
diff --git a/edit/failure_types_by_user_type.sql 
b/edit/failure_types_by_user_type.sql
index edb86cd..6fbfcfc 100644
--- a/edit/failure_types_by_user_type.sql
+++ b/edit/failure_types_by_user_type.sql
@@ -34,19 +34,6 @@
 
( select timestamp, `event_user.class`,
`event_user.editCount`, `event_action.saveFailure.type`
-   from Edit_13457736_15423246
-   where
-   event_editor = '{editor}' and
-   ('{wiki}' = 'all' or wiki = '{wiki}') and
-   timestamp >= '{from_timestamp}' and
-   timestamp < '{to_timestamp}' and
-   `event_action` = 'saveFailure' and
-   `event_action.saveFailure.type` is not null )
-
-union all
-
-   ( select timestamp, `event_user.class`,
-   `event_user.editCount`, `event_action.saveFailure.type`
from Edit_13457736
where
event_editor = '{editor}' and
@@ -55,7 +42,6 @@
timestamp < '{to_timestamp}' and
`event_action` = 'saveFailure' and
`event_action.saveFailure.type` is not null )
-
 ) saveFailures
 
 group by 1, 2
diff --git a/edit/rates.sql b/edit/rates.sql
index d905cd5..eef80db 100644
--- a/edit/rates.sql
+++ b/edit/rates.sql
@@ -15,7 +15,6 @@
date(timestamp) as day,
group_concat(event_action order by timestamp, action_order.ord 
separator '-') as actions
  from (
-
 select
timestamp,
event_action,
@@ -37,28 +36,13 @@
event_action,
clientIp,
event_editingSessionId
-from Edit_13457736_15423246
-where
-   event_editor = '{editor}' and
-   ('{wiki}' = 'all' or wiki = '{wiki}') and
-   timestamp >= '{from_timestamp}' and
-   timestamp < '{to_timestamp}'
-
-   union all
-
-select
-   timestamp,
-   event_action,
-   clientIp,
-   event_editingSessionId
 from Edit_13457736
 where
event_editor = '{editor}' and
('{wiki}' = 'all' or wiki = '{wiki}') and
timestamp >= '{from_timestamp}' and
timestamp < '{to_timestamp}'
-
-) raw_events
+) raw_events
 
 inner join
(select 'init' as action, 0 as ord
diff --git a/edit/sessions.sql b/edit/sessions.sql
index 70c817a..130f090 100644
--- a/edit/sessions.sql
+++ b/edit/sessions.sql
@@ -2,24 +2,7 @@
 actions,
 count(*) as repeated
from (select group_concat(event_action order by timestamp, action_order.ord 
separator '-') as actions
-   from (
-select timestamp,
-event_action,
-clientIp,
-event_editingSessionId
-
-   from Edit_13457736_15423246
-# NOTE: used to union all with Edit_11448630
-# That schema is still used apparently, but very 

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Fix usage of _.sortBy in tops function

2017-12-13 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/398049 )

Change subject: Fix usage of _.sortBy in tops function
..


Fix usage of _.sortBy in tops function

We're currently using a string as an accessor to the _.sortBy lodash
function, which means the list of results is not being sorted as expected.
Using a function as accessor fixes the problem.

Bug: T182772
Change-Id: Iccc35e726201729b152c9abc9c3e0a769964ebea
---
M src/models/GraphModel.js
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Milimetric: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/models/GraphModel.js b/src/models/GraphModel.js
index 5d9fc70..dd27eb6 100644
--- a/src/models/GraphModel.js
+++ b/src/models/GraphModel.js
@@ -38,7 +38,7 @@
 setData (data) {
 this.data = data;
 
-if (this.config.type === 'list') {
+if (['list', 'map'].includes(this.config.type)) {
 this.graphData = this.topXByY();
 return;
 }
@@ -118,7 +118,7 @@
 
 this.data.measure(x);
 const results = this.data.breakdown(y);
-return _.take(_.sortBy(results, y).reverse(), limit || results.length);
+return _.take(_.sortBy(results, (row) => row[y].total).reverse(), 
limit || results.length);
 }
 
 formatNumberForMetric (number) {

-- 
To view, visit https://gerrit.wikimedia.org/r/398049
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iccc35e726201729b152c9abc9c3e0a769964ebea
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Fdans 
Gerrit-Reviewer: Mforns 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Fix infinite loop

2017-12-12 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/397995 )

Change subject: Fix infinite loop
..

Fix infinite loop

For the future, the flow of events and data in WikiSelector is too
circular.  The init calls get triggered when they're not necessary,
after state changes.

Also, the way the hidden div is added with an id is not great, that
should at least have a class and in general should be added relative to
the component in case multiple versions of the same component are used
on the page.

Bug: T182700
Change-Id: I1dd5f4bce62caaf14215b4fa158d030f53e8f084
---
M src/components/WikiSelector.vue
1 file changed, 18 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/95/397995/1

diff --git a/src/components/WikiSelector.vue b/src/components/WikiSelector.vue
index c317788..bf8c50d 100644
--- a/src/components/WikiSelector.vue
+++ b/src/components/WikiSelector.vue
@@ -31,6 +31,8 @@
 
 
 

[MediaWiki-commits] [Gerrit] analytics/limn-flow-data[master]: Fix definition of "active board", "active topic"

2017-12-11 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/396566 )

Change subject: Fix definition of "active board", "active topic"
..


Fix definition of "active board", "active topic"

The queries for "active boards" and "active topics" counted a topic as
active if it was *created* during the given timeframe and was not itself
moderated. This isn't a very sane definition of an active topic, because
an old topic that's still being replied to should also count as active.

* Change "active topics" to be topics that received at least one
  non-moderated post during the given timeframe
* Update "active boards" accordingly
* Keep the old "active topics" query but rename it to "created topics"

Change-Id: Iab5426fa1d44ae9754f6e1551d27d92801cc5ebd
---
M flow/active-boards.sql
M flow/active-topics.sql
M flow/config.yaml
A flow/created-topics.sql
4 files changed, 38 insertions(+), 16 deletions(-)

Approvals:
  Catrope: Looks good to me, approved
  Milimetric: Verified



diff --git a/flow/active-boards.sql b/flow/active-boards.sql
index 0b78e83..d11e731 100644
--- a/flow/active-boards.sql
+++ b/flow/active-boards.sql
@@ -1,13 +1,16 @@
-SELECT DATE('{from_timestamp}') AS weekstart,
+SELECT
+   DATE('{from_timestamp}') AS weekstart,
COUNT(DISTINCT workflow_wiki, workflow_namespace, workflow_title_text) 
AS num_boards
 FROM
 (
-   SELECT *
-   FROM flow_workflow
-   INNER JOIN flow_revision ON rev_type_id = workflow_id AND rev_type = 
'post' # join needed to exclude moderated topics
+   SELECT flow_workflow.*
+   FROM flow_revision AS a
+   LEFT JOIN flow_revision AS b ON a.rev_type = b.rev_type AND 
a.rev_type_id = b.rev_type_id # join needed to exclude moderated posts
+   INNER JOIN flow_tree_node ON tree_descendant_id = a.rev_type_id
+   INNER JOIN flow_workflow ON workflow_id = tree_ancestor_id
WHERE
-   workflow_wiki NOT IN ('testwiki', 'test2wiki') AND
-   workflow_type = 'topic' AND
-   
DATE_FORMAT(FROM_UNIXTIME((conv(substring(hex(workflow_id),1,12),16,10)>>2)/1000),"%Y%m%d%H%i%S")
 BETWEEN '{from_timestamp}' AND '{to_timestamp}'
-   GROUP BY rev_type, rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(rev_change_type), ',', -1) NOT IN ('hide-topic', 
'delete-topic', 'suppress-topic') # exclude topics where last revision was 
moderation
+   a.rev_user_wiki NOT IN ('testwiki', 'test2wiki') AND
+   a.rev_change_type = 'reply' AND
+   
DATE_FORMAT(FROM_UNIXTIME((conv(substring(hex(a.rev_id),1,12),16,10)>>2)/1000),"%Y%m%d%H%i%S")
 BETWEEN '{from_timestamp}' AND '{to_timestamp}'
+   GROUP BY a.rev_type, a.rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(b.rev_change_type), ',', -1) NOT IN ('hide-post', 
'delete-post', 'suppress-post') # exclude posts where last revision was 
moderation
 ) AS temp;
diff --git a/flow/active-topics.sql b/flow/active-topics.sql
index ab288ad..77d86f6 100644
--- a/flow/active-topics.sql
+++ b/flow/active-topics.sql
@@ -1,13 +1,16 @@
-SELECT DATE('{from_timestamp}') AS weekstart,
+SELECT
+   DATE('{from_timestamp}') AS weekstart,
COUNT(DISTINCT workflow_id) AS num_topics
 FROM
 (
-   SELECT *
-   FROM flow_workflow
-   INNER JOIN flow_revision ON rev_type_id = workflow_id AND rev_type = 
'post' # join needed to exclude moderated topics
+   SELECT workflow_id
+   FROM flow_revision AS a
+   LEFT JOIN flow_revision AS b ON a.rev_type = b.rev_type AND 
a.rev_type_id = b.rev_type_id # join needed to exclude moderated posts
+   INNER JOIN flow_tree_node ON tree_descendant_id = a.rev_type_id
+   INNER JOIN flow_workflow ON workflow_id = tree_ancestor_id
WHERE
-   workflow_wiki NOT IN ('testwiki', 'test2wiki') AND
-   workflow_type = 'topic' AND
-   
DATE_FORMAT(FROM_UNIXTIME((conv(substring(hex(workflow_id),1,12),16,10)>>2)/1000),"%Y%m%d%H%i%S")
 BETWEEN '{from_timestamp}' AND '{to_timestamp}'
-   GROUP BY rev_type, rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(rev_change_type), ',', -1) NOT IN ('hide-topic', 
'delete-topic', 'suppress-topic') # exclude topics where last revision was 
moderation
+   a.rev_user_wiki NOT IN ('testwiki', 'test2wiki') AND
+   a.rev_change_type = 'reply' AND
+   
DATE_FORMAT(FROM_UNIXTIME((conv(substring(hex(a.rev_id),1,12),16,10)>>2)/1000),"%Y%m%d%H%i%S")
 BETWEEN '{from_timestamp}' AND '{to_timestamp}'
+   GROUP BY a.rev_type, a.rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(b.rev_change_type), ',', -1) NOT IN ('hide-post', 
'delete-post', 'suppress-post') # exclude posts where last revision was 
moderation
 ) AS temp;
diff --git a/flow/config.yaml b/flow/config.yaml
index 4509cd0..8ece24e 100644
--- a/flow/config.yaml
+++ b/flow/config.yaml
@@ -24,6 +24,9 @@
 active-topics:
 

[MediaWiki-commits] [Gerrit] analytics/limn-flow-data[master]: Correct SQL comments about moderation checks

2017-12-11 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/396558 )

Change subject: Correct SQL comments about moderation checks
..


Correct SQL comments about moderation checks

unique-users and messages-posted exclude moderated *posts*, not topics.

Also use consistent language in the comment explaining why the join is
there (to check moderation status), and consistently add this comment in
every file.

Change-Id: I05acf486a0ae23a9d69983c7113ec1fd7cad8d79
---
M flow/active-boards.sql
M flow/active-topics.sql
M flow/messages-posted.sql
M flow/unique-users.sql
4 files changed, 6 insertions(+), 6 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/flow/active-boards.sql b/flow/active-boards.sql
index 837798d..0b78e83 100644
--- a/flow/active-boards.sql
+++ b/flow/active-boards.sql
@@ -4,7 +4,7 @@
 (
SELECT *
FROM flow_workflow
-   INNER JOIN flow_revision ON rev_type_id = workflow_id AND rev_type = 
'post' # join needed to be able to exclude moderated topics
+   INNER JOIN flow_revision ON rev_type_id = workflow_id AND rev_type = 
'post' # join needed to exclude moderated topics
WHERE
workflow_wiki NOT IN ('testwiki', 'test2wiki') AND
workflow_type = 'topic' AND
diff --git a/flow/active-topics.sql b/flow/active-topics.sql
index 7f589ce..ab288ad 100644
--- a/flow/active-topics.sql
+++ b/flow/active-topics.sql
@@ -4,7 +4,7 @@
 (
SELECT *
FROM flow_workflow
-   INNER JOIN flow_revision ON rev_type_id = workflow_id AND rev_type = 
'post' # join needed to be able to exclude moderated topics
+   INNER JOIN flow_revision ON rev_type_id = workflow_id AND rev_type = 
'post' # join needed to exclude moderated topics
WHERE
workflow_wiki NOT IN ('testwiki', 'test2wiki') AND
workflow_type = 'topic' AND
diff --git a/flow/messages-posted.sql b/flow/messages-posted.sql
index 807c6d7..d66c9b0 100644
--- a/flow/messages-posted.sql
+++ b/flow/messages-posted.sql
@@ -5,10 +5,10 @@
 (
SELECT 1
FROM flow_revision AS a
-   LEFT JOIN flow_revision AS b ON a.rev_type = b.rev_type AND 
a.rev_type_id = b.rev_type_id
+   LEFT JOIN flow_revision AS b ON a.rev_type = b.rev_type AND 
a.rev_type_id = b.rev_type_id # join needed to exclude moderated posts
WHERE
a.rev_user_wiki NOT IN ('testwiki', 'test2wiki') AND
a.rev_change_type = 'reply' AND

DATE_FORMAT(FROM_UNIXTIME((conv(substring(hex(a.rev_id),1,12),16,10)>>2)/1000),"%Y%m%d%H%i%S")
 BETWEEN '{from_timestamp}' AND '{to_timestamp}'
-   GROUP BY a.rev_type, a.rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(b.rev_change_type), ',', -1) NOT IN ('hide-post', 
'delete-post', 'suppress-post') # exclude topics where last revision was 
moderation
+   GROUP BY a.rev_type, a.rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(b.rev_change_type), ',', -1) NOT IN ('hide-post', 
'delete-post', 'suppress-post') # exclude posts where last revision was 
moderation
 ) AS temp;
diff --git a/flow/unique-users.sql b/flow/unique-users.sql
index 23e452b..8019c87 100644
--- a/flow/unique-users.sql
+++ b/flow/unique-users.sql
@@ -7,10 +7,10 @@
a.rev_user_ip,
a.rev_user_wiki
FROM flow_revision AS a
-   LEFT JOIN flow_revision AS b ON a.rev_type = b.rev_type AND 
a.rev_type_id = b.rev_type_id
+   LEFT JOIN flow_revision AS b ON a.rev_type = b.rev_type AND 
a.rev_type_id = b.rev_type_id # join needed to exclude moderated posts
WHERE
a.rev_user_wiki NOT IN ('testwiki', 'test2wiki') AND
a.rev_change_type = 'reply' AND

DATE_FORMAT(FROM_UNIXTIME((conv(substring(hex(a.rev_id),1,12),16,10)>>2)/1000),"%Y%m%d%H%i%S")
 BETWEEN '{from_timestamp}' AND '{to_timestamp}'
-   GROUP BY a.rev_type, a.rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(b.rev_change_type), ',', -1) NOT IN ('hide-post', 
'delete-post', 'suppress-post') # exclude topics where last revision was 
moderation
+   GROUP BY a.rev_type, a.rev_type_id HAVING 
SUBSTRING_INDEX(GROUP_CONCAT(b.rev_change_type), ',', -1) NOT IN ('hide-post', 
'delete-post', 'suppress-post') # exclude posts where last revision was 
moderation
 ) AS temp;

-- 
To view, visit https://gerrit.wikimedia.org/r/396558
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I05acf486a0ae23a9d69983c7113ec1fd7cad8d79
Gerrit-PatchSet: 1
Gerrit-Project: analytics/limn-flow-data
Gerrit-Branch: master
Gerrit-Owner: Catrope 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: Sbisson 
Gerrit-Reviewer: Siebrand 

___
MediaWiki-commits mailing list

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Fix bar chart not re-rendering

2017-12-08 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/396537 )

Change subject: Fix bar chart not re-rendering
..

Fix bar chart not re-rendering

When the table chart was selected on a bar-chart metric detail page, and
the user switched back to the bar chart, the lack of a mounted hook
meant the chart was not drawn.

Bug: T182461
Change-Id: I7047ec310beb912699b00f332eb6565251ebb46f
---
M src/components/detail/chart/BarChart.vue
1 file changed, 4 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/37/396537/1

diff --git a/src/components/detail/chart/BarChart.vue 
b/src/components/detail/chart/BarChart.vue
index 5af18c5..08c72c7 100644
--- a/src/components/detail/chart/BarChart.vue
+++ b/src/components/detail/chart/BarChart.vue
@@ -19,6 +19,10 @@
 name: 'bar-chart',
 props: ['graphModel', 'data'],
 
+mounted () {
+this.drawChart();
+},
+
 watch: {
 data: function () {
 this.drawChart();

-- 
To view, visit https://gerrit.wikimedia.org/r/396537
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7047ec310beb912699b00f332eb6565251ebb46f
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Fix loading sparse data into widgets

2017-12-08 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/396469 )

Change subject: Fix loading sparse data into widgets
..

Fix loading sparse data into widgets

When data isn't continuous, widgets behave in hard-to-predict ways like
showing NaNs and incorrect YoY or MoM totals.  This patch addresses most
of that but I'm not really sure what to do when there's data *more* than
a year ago.  The change from the last available datapoint beyond a year
seems relevant, but it's not YoY change.

Bug: T182224
Change-Id: If911e6dceeb9281887e19e705ae716c1ea1b6772
---
M src/components/dashboard/MetricWidget.vue
1 file changed, 38 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/69/396469/1

diff --git a/src/components/dashboard/MetricWidget.vue 
b/src/components/dashboard/MetricWidget.vue
index 7e3e986..4437531 100644
--- a/src/components/dashboard/MetricWidget.vue
+++ b/src/components/dashboard/MetricWidget.vue
@@ -18,8 +18,13 @@
 
 {{getMonthValue(lastMonth.month)}}
 
-
-{{changeMoM}} % month over month
+
+
+{{changeMoM}} % month over month
+
+
+(no data last month)
+
 
 
 
 
 
-
+
 
{{graphModel.formatNumberForMetric(lastYearAggregation)}}
 
-
+
 
 {{changeYoY}} % year over year
 
 
 
-Year {{aggregationType}} 
({{monthOneYearAgo.month.getFullYear()}})
+
+Year {{aggregationType}} 
({{monthOneYearAgo.month.getFullYear()}})
+{{aggregationType}} (all available 
data)
+
+
+(no data last year)
+
 
 
 
@@ -123,7 +134,16 @@
 monthOneYearAgo: function () {
 if (!this.lastMonth) { return null; }
 
-return this.graphData[_.indexOf(this.graphData, 
this.lastMonth) - 12];
+let last = _.indexOf(this.graphData, this.lastMonth);
+const lastMonth = this.graphData[last].month;
+
+while (last > 0) {
+last--;
+if (lastMonth - this.graphData[last].month >= 3153600) 
{
+return this.graphData[last];
+}
+}
+return null;
 },
 lastYearAggregation: function () {
 return this.graphModel.getLimitedAggregate(12);
@@ -136,12 +156,24 @@
 
 const data = this.graphData;
 const prev = data[data.length - 2];
+
+if (!prev
+|| !prev.total
+|| this.lastMonth.month - prev.month > 276480) {
+return null;
+}
+
 const diff = this.lastMonth.total - prev.total;
 return ((diff / prev.total) * 100).toFixed(2);
 },
 changeYoY: function () {
 // TODO: We're showing more than the last year, but reporting 
YoY.  This can be confusing because the YoY might not match up visually with 
the graph (like for Unique Devices in Achinese).
 
+if (!this.monthOneYearAgo
+|| !this.monthOneYearAgo.total) {
+return null;
+}
+
 const diff = this.lastMonth.total - this.monthOneYearAgo.total;
 return ((diff / this.monthOneYearAgo.total) * 100).toFixed(2);
 },

-- 
To view, visit https://gerrit.wikimedia.org/r/396469
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: If911e6dceeb9281887e19e705ae716c1ea1b6772
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Update jar version in mediawiki-history job

2017-12-07 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/396073 )

Change subject: Update jar version in mediawiki-history job
..


Update jar version in mediawiki-history job

Pick new jar to apply latest patches, including field
renaming and delete/restore updates.

Change-Id: I929aff727a05209e109630126d86eafe74e5bea8
---
M oozie/mediawiki/history/denormalize/coordinator.properties
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/oozie/mediawiki/history/denormalize/coordinator.properties 
b/oozie/mediawiki/history/denormalize/coordinator.properties
index cd72e46..634ca8c 100644
--- a/oozie/mediawiki/history/denormalize/coordinator.properties
+++ b/oozie/mediawiki/history/denormalize/coordinator.properties
@@ -58,7 +58,7 @@
 spark_master  = yarn
 spark_deploy  = cluster
 spark_assembly_jar= 
${name_node}/user/spark/share/lib/spark-assembly.jar
-spark_job_jar = 
${artifacts_directory}/org/wikimedia/analytics/refinery/refinery-job-0.0.53.jar
+spark_job_jar = 
${artifacts_directory}/org/wikimedia/analytics/refinery/refinery-job-0.0.55.jar
 spark_job_class   = 
org.wikimedia.analytics.refinery.job.mediawikihistory.MediawikiHistoryRunner
 spark_job_name= mediawiki_history
 spark_executor_memory = 12G

-- 
To view, visit https://gerrit.wikimedia.org/r/396073
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I929aff727a05209e109630126d86eafe74e5bea8
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Joal 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: Ottomata 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...source[master]: Update changelog for v0.0.55

2017-12-07 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/396074 )

Change subject: Update changelog for v0.0.55
..


Update changelog for v0.0.55

Change-Id: Ie595d1bc8b6babead37edb0f01b2b9dff94e44be
---
M changelog.md
1 file changed, 10 insertions(+), 3 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/changelog.md b/changelog.md
index ece94b3..8fdf836 100644
--- a/changelog.md
+++ b/changelog.md
@@ -1,7 +1,14 @@
-## v0.0.54
-# refinery-core now builds scala.
-* Add JsonRefine job
+## v0.0.55
+* something/something_latest fields change to something_historical/something
+* UDF for extracting primary full-text search request
+* Fix Clickstream job
+* Change Cassandra loader to local quorum write
+* Add Mediawiki API to RestbaseMetrics
+* Fix mediawiki history reconstruction
 
+## v0.0.54
+* refinery-core now builds scala.
+* Add JsonRefine job
 
 ## v0.0.53
 * Correct field names in mediawiki-history spark job (time since previous 
revision)

-- 
To view, visit https://gerrit.wikimedia.org/r/396074
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie595d1bc8b6babead37edb0f01b2b9dff94e44be
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery/source
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...source[master]: Update changelog for v0.0.55

2017-12-07 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/396074 )

Change subject: Update changelog for v0.0.55
..

Update changelog for v0.0.55

Change-Id: Ie595d1bc8b6babead37edb0f01b2b9dff94e44be
---
M changelog.md
1 file changed, 10 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery/source 
refs/changes/74/396074/1

diff --git a/changelog.md b/changelog.md
index ece94b3..8fdf836 100644
--- a/changelog.md
+++ b/changelog.md
@@ -1,7 +1,14 @@
-## v0.0.54
-# refinery-core now builds scala.
-* Add JsonRefine job
+## v0.0.55
+* something/something_latest fields change to something_historical/something
+* UDF for extracting primary full-text search request
+* Fix Clickstream job
+* Change Cassandra loader to local quorum write
+* Add Mediawiki API to RestbaseMetrics
+* Fix mediawiki history reconstruction
 
+## v0.0.54
+* refinery-core now builds scala.
+* Add JsonRefine job
 
 ## v0.0.53
 * Correct field names in mediawiki-history spark job (time since previous 
revision)

-- 
To view, visit https://gerrit.wikimedia.org/r/396074
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie595d1bc8b6babead37edb0f01b2b9dff94e44be
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery/source
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Add and link readme pages for analytics datasets

2017-12-06 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/395917 )

Change subject: Add and link readme pages for analytics datasets
..

Add and link readme pages for analytics datasets

Bug: T167033
Change-Id: Icf47d81cde07bee94b54fdb4241fbc912c84966e
---
A index.html
M modules/dumps/files/web/html/analytics_index.html
A modules/dumps/files/web/html/mediacounts_readme.html
A modules/dumps/files/web/html/pageviews_readme.html
A modules/dumps/files/web/html/unique_devices_readme.html
M modules/dumps/manifests/web/html.pp
6 files changed, 220 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/17/395917/1

diff --git a/index.html b/index.html
new file mode 100644
index 000..1945db2
--- /dev/null
+++ b/index.html
@@ -0,0 +1,60 @@
+
+
+
+ 
+ 
+ 
+ Directory Tree
+ 
+  
+ 
+
+
+   Directory Tree
+   .
+   ├── conftool-data
+   ├── doc
+   ├── environments
+   ├── files
+   ├── Gemfile
+   ├── hieradata
+   ├── index.html
+   ├── manifests
+   ├── modules
+   ├── Rakefile
+   ├── rake_modules
+   ├── README
+   ├── tox.ini
+   ├── typos
+   └── utils
+   
+   
+   
+   
+   
+   
+   
+tree v1.7.0 © 1996 - 2014 by Steve Baker and Thomas Moore 
+HTML output hacked and copyleft © 1998 by Francesc Rocher 
+JSON output hacked and copyleft © 2014 by Florian Sesser 
+Charsets / OS/2 support © 2001 by Kyosuke Tokoro
+   
+
+
diff --git a/modules/dumps/files/web/html/analytics_index.html 
b/modules/dumps/files/web/html/analytics_index.html
index b137939..e1d4d7a 100644
--- a/modules/dumps/files/web/html/analytics_index.html
+++ b/modules/dumps/files/web/html/analytics_index.html
@@ -16,11 +16,11 @@
 
 Pageviews: statistics compiled using the 
current https://meta.wikimedia.org/wiki/Research:Page_view; 
target="_blank">Pageview Definition.  Available as:
 
-Pageview/projectview data 
filtered to what we believe is only human traffic.  Available since May 
2015.
+Pageview/projectview data filtered to what 
we believe is only human traffic.  Available since May 2015.
 
 Pageview/projectview 
data, highly compressed and corrected for outages.  This dataset was 
historically computed using the best source available at the time:
 
-Dec 2015 - now: compressing and correcting the 
pageviews dataset
+Dec 2015 - now: compressing and correcting the 
pageviews dataset
 2007 - Dec 2015: compressing and correcting 
the pagecounts-raw dataset
 
 
@@ -31,14 +31,14 @@
 
 Mediacounts: statistics from all projects on 
media file access.  Available as:
 
-Request counts for the 
upload domain (pictures, movies, audio files)
+Request 
counts for the upload domain (pictures, movies, audio files)
 
 
 
 
 Unique Devices: statistics from all projects 
on unique devices.  Available as:
 
-Estimate of unique 
devices based on a privacy-sensitive last access cookie.
+

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Prepare for release 2.1.0

2017-12-04 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/395090 )

Change subject: Prepare for release 2.1.0
..


Prepare for release 2.1.0

Change-Id: If817b0ebaa477167fb0446f20ea2bc0645d78b0b
---
M dist/index.html
A dist/main.bundle.3bcc116d6d7b4625210b.css
A dist/main.bundle.3bcc116d6d7b4625210b.js
M package.json
4 files changed, 242 insertions(+), 3 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/395090
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If817b0ebaa477167fb0446f20ea2bc0645d78b0b
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Prepare for release 2.1.0

2017-12-04 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/395090 )

Change subject: Prepare for release 2.1.0
..

Prepare for release 2.1.0

Change-Id: If817b0ebaa477167fb0446f20ea2bc0645d78b0b
---
M dist/index.html
A dist/main.bundle.3bcc116d6d7b4625210b.css
A dist/main.bundle.3bcc116d6d7b4625210b.js
M package.json
4 files changed, 242 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/90/395090/1


-- 
To view, visit https://gerrit.wikimedia.org/r/395090
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: If817b0ebaa477167fb0446f20ea2bc0645d78b0b
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[release]: Prepare for release 2.1.0

2017-12-04 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/395089 )

Change subject: Prepare for release 2.1.0
..

Prepare for release 2.1.0

Change-Id: Iaa73a0687aa0f90259dd054625d05cbf7e80d660
---
M dist/index.html
A dist/main.bundle.3bcc116d6d7b4625210b.css
A dist/main.bundle.3bcc116d6d7b4625210b.js
M package.json
4 files changed, 242 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/89/395089/1


-- 
To view, visit https://gerrit.wikimedia.org/r/395089
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iaa73a0687aa0f90259dd054625d05cbf7e80d660
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: release
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[release]: Release 2.1.0

2017-12-04 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/395087 )

Change subject: Release 2.1.0
..


Release 2.1.0

Change-Id: I1bcaa9de38daba73a9a38f53f8d5965fb48da5f8
---
M dist/index.html
D dist/main.bundle.247511c45b47a15db9d1.js
R dist/main.bundle.3bcc116d6d7b4625210b.css
A dist/main.bundle.3bcc116d6d7b4625210b.js
D dist/main.bundle.c4603511208e0d6eb76a.js
D dist/main.bundle.d70de3d4d08da7e3b1bb.js
D dist/main.bundle.e3c077d496d756716af7.js
M package.json
M src/apis/aqs.js
M src/apis/sitematrix.js
M src/components/RouterLink.vue
M src/components/dashboard/MetricBarWidget.vue
M src/components/dashboard/MetricLineWidget.vue
M src/components/dashboard/MetricListWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/Detail.vue
M src/components/detail/DetailSidebar.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/SimpleLegend.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
M src/components/detail/chart/TableChart.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/contributing.js
M src/config/metrics/metricSchema.js
M src/config/metrics/reading.js
M src/lodash-custom-bundle.js
M src/models/DimensionalData.js
M src/models/GraphModel.js
M src/router/index.js
M src/router/routes.js
M src/store/index.js
M src/utils.js
M test/DimensionalData.spec.js
M test/GraphModel.spec.js
M test/Router.spec.js
M test/components/LineChart.spec.js
39 files changed, 718 insertions(+), 883 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved




-- 
To view, visit https://gerrit.wikimedia.org/r/395087
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I1bcaa9de38daba73a9a38f53f8d5965fb48da5f8
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: release
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[release]: Release 2.1.0

2017-12-04 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/395087 )

Change subject: Release 2.1.0
..

Release 2.1.0

Change-Id: I1bcaa9de38daba73a9a38f53f8d5965fb48da5f8
---
M dist/index.html
D dist/main.bundle.247511c45b47a15db9d1.js
R dist/main.bundle.3bcc116d6d7b4625210b.css
A dist/main.bundle.3bcc116d6d7b4625210b.js
D dist/main.bundle.c4603511208e0d6eb76a.js
D dist/main.bundle.d70de3d4d08da7e3b1bb.js
D dist/main.bundle.e3c077d496d756716af7.js
M package.json
M src/apis/aqs.js
M src/apis/sitematrix.js
M src/components/RouterLink.vue
M src/components/dashboard/MetricBarWidget.vue
M src/components/dashboard/MetricLineWidget.vue
M src/components/dashboard/MetricListWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/Detail.vue
M src/components/detail/DetailSidebar.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/SimpleLegend.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
M src/components/detail/chart/TableChart.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/contributing.js
M src/config/metrics/metricSchema.js
M src/config/metrics/reading.js
M src/lodash-custom-bundle.js
M src/models/DimensionalData.js
M src/models/GraphModel.js
M src/router/index.js
M src/router/routes.js
M src/store/index.js
M src/utils.js
M test/DimensionalData.spec.js
M test/GraphModel.spec.js
M test/Router.spec.js
M test/components/LineChart.spec.js
39 files changed, 718 insertions(+), 883 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/87/395087/1


-- 
To view, visit https://gerrit.wikimedia.org/r/395087
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1bcaa9de38daba73a9a38f53f8d5965fb48da5f8
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: release
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] eventlogging[master]: Prefer event capsule defined fields over those found in raw ...

2017-11-27 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/393613 )

Change subject: Prefer event capsule defined fields over those found in raw log 
line
..


Prefer event capsule defined fields over those found in raw log line

Currently, if a an event producer sets capsule level fields AND those
capsule level fields have format specifiers that are used
to parse that field out of the raw log line separate from
the incoming event data, the incoming event data will overwrite
whatever was parsed from the raw non-event data and casted
into that field.

This caused a bug with the Popups schema and userAgent fields.
The Popups EventLogging extension code would set userAgent
sometimes:
https://github.com/wikimedia/mediawiki-extensions-EventLogging/blob/28f871d38c0f32e7b641fa9364e58f4b733e/includes/EventLogging.php#L71

With the code before this patch, this means that the raw userAgent would be 
used, rather than the parsed one.

After this patch, the submitted event capsule's userAgent will be parsed by the 
parse_ua caster function.

I hate the capsule.

Bug: T178440
Change-Id: I37ca9e9bfce7c1c8dae8d8788b8f5c9d20b8a309
---
M eventlogging/parse.py
M tests/test_parser.py
2 files changed, 123 insertions(+), 13 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/eventlogging/parse.py b/eventlogging/parse.py
index b40c293..40fa2d2 100644
--- a/eventlogging/parse.py
+++ b/eventlogging/parse.py
@@ -179,16 +179,69 @@
 """Parse a log line into a map of field names / values."""
 match = self.re.match(line)
 if match is None:
-raise ValueError(self.re, line)
-keys = sorted(match.groupdict(), key=match.start)
-# Filter out the caster-key pairs where caster is None
-caster_key_pairs = [pair for pair in zip(self.casters, keys)
-if pair[0]]
-event = {k: f(match.group(k)) for f, k in caster_key_pairs}
-event.update(event.pop('capsule'))
-event['uuid'] = capsule_uuid(event)
+raise ValueError(self.re.pattern, line)
 
-return Event(event)
+# Dict of capture group name to matched value, e.g userAgent: "..."
+matches = match.groupdict()
+
+if 'capsule' not in matches.keys():
+raise ValueError(
+'\'capsule\' was not matched in line, but it is required',
+(self.re.pattern, line)
+)
+
+# Just the matched capture group names.
+keys = sorted(matches, key=match.start)
+
+# Build a dict of capture group names to caster functions.
+# This works because self.casters is a list of functions in the
+# same order of keys returned by match.groupdict.
+# Also filter out the casters where caster is None, so we omit it.
+caster_dict = dict([pair for pair in zip(keys, self.casters)
+if pair[1]])
+
+# 'capsule' is a required format specifier.
+# Parse it out now as the main event.
+capsule = caster_dict['capsule'](matches['capsule'])
+# capsule at this point MUST be a dict
+if not isinstance(capsule, dict):
+raise ValueError(
+'capsule was successfully parsed, but not as an object.',
+capsule
+)
+
+# Apply caster functions to event 'capsule'
+# level fields that also have casters defined.
+for k in (set(capsule.keys()) & set(caster_dict.keys())):
+capsule[k] = caster_dict[k](capsule[k])
+
+# For other fields that have been parsed out of the raw event log line
+# Apply their specifier 'caster' functions.  Only use the data from
+# the raw line if and only if it is not already present in the
+# capsule data.
+# This is how we keep user submitted event data in the capsule even if
+# there is data for that field in the raw line.  E.g. if the user sent
+# an event capsule with a 'userAgent' field already in it, we will use
+# the user sent userAgent, not the one that might be parsed from the
+# raw log line.  Note that in this example, the userAgent sent in
+# the event capsule data will only be 'cast' (parsed) if the %u
+# speficier was used, and the caster to a 'userAgent' field is
+# defined. This is true for any field.  If it is not in the format
+# string, it will not be 'cast', but just used as is.
+parsed_fields_from_line = {
+k: f(matches[k]) for k, f in caster_dict.items()
+# skip the 'capsule' caster, since we already did it,
+# and also skip any casters that are already in the
+# capsule, since we already did those too.
+if k != 'capsule' and k not in capsule.keys()
+}
+# Add the parsed fields to 

[MediaWiki-commits] [Gerrit] analytics/wikimetrics-deploy[master]: Fix database access by pointing to new servers

2017-11-16 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/391993 )

Change subject: Fix database access by pointing to new servers
..


Fix database access by pointing to new servers

Bug: T180770
Change-Id: Ib6017b4e43af97c08dc8e5222d5ec75d5b52154e
---
M config_templates/db_config.yaml
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/config_templates/db_config.yaml b/config_templates/db_config.yaml
index 3f01017..2a2ecee 100644
--- a/config_templates/db_config.yaml
+++ b/config_templates/db_config.yaml
@@ -8,9 +8,9 @@
 SQL_ECHO: False
 WIKIMETRICS_ENGINE_URL  : 
'mysql://$DB_USER_WIKIMETRICS:$DB_PASSWORD_WIKIMETRICS@$DB_HOST_WIKIMETRICS/$DB_NAME_WIKIMETRICS'
 WIKIMETRICS_POOL_SIZE   : 100
-MEDIAWIKI_ENGINE_URL_TEMPLATE   : 
'mysql://$DB_USER_LABSDB:$DB_PASSWORD_LABSDB@labsdb1001.eqiad.wmnet/{0}_p'
+MEDIAWIKI_ENGINE_URL_TEMPLATE   : 
'mysql://$DB_USER_LABSDB:$db_password_lab...@s1.analytics.db.svc.eqiad.wmflabs/{0}_p'
 MEDIAWIKI_POOL_SIZE : 200
-CENTRALAUTH_ENGINE_URL  : 
'mysql://$DB_USER_LABSDB:$DB_PASSWORD_LABSDB@labsdb1001.eqiad.wmnet/centralauth_p'
+CENTRALAUTH_ENGINE_URL  : 
'mysql://$DB_USER_LABSDB:$db_password_lab...@s1.analytics.db.svc.eqiad.wmflabs/centralauth_p'
 REPLICATION_LAG_MW_PROJECTS : [ 'enwiki', 'eowiki', 'elwiki', 
'commonswiki', 'dewiki', 'frwiki', 'eswiki' ]
 REPLICATION_LAG_THRESHOLD   : 3 # (measured in hours)
 DEBUG   : False

-- 
To view, visit https://gerrit.wikimedia.org/r/391993
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib6017b4e43af97c08dc8e5222d5ec75d5b52154e
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics-deploy
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics-deploy[master]: Fix database access by pointing to new servers

2017-11-16 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/391993 )

Change subject: Fix database access by pointing to new servers
..

Fix database access by pointing to new servers

Bug: T180770
Change-Id: Ib6017b4e43af97c08dc8e5222d5ec75d5b52154e
---
M config_templates/db_config.yaml
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikimetrics-deploy 
refs/changes/93/391993/1

diff --git a/config_templates/db_config.yaml b/config_templates/db_config.yaml
index 3f01017..2a2ecee 100644
--- a/config_templates/db_config.yaml
+++ b/config_templates/db_config.yaml
@@ -8,9 +8,9 @@
 SQL_ECHO: False
 WIKIMETRICS_ENGINE_URL  : 
'mysql://$DB_USER_WIKIMETRICS:$DB_PASSWORD_WIKIMETRICS@$DB_HOST_WIKIMETRICS/$DB_NAME_WIKIMETRICS'
 WIKIMETRICS_POOL_SIZE   : 100
-MEDIAWIKI_ENGINE_URL_TEMPLATE   : 
'mysql://$DB_USER_LABSDB:$DB_PASSWORD_LABSDB@labsdb1001.eqiad.wmnet/{0}_p'
+MEDIAWIKI_ENGINE_URL_TEMPLATE   : 
'mysql://$DB_USER_LABSDB:$db_password_lab...@s1.analytics.db.svc.eqiad.wmflabs/{0}_p'
 MEDIAWIKI_POOL_SIZE : 200
-CENTRALAUTH_ENGINE_URL  : 
'mysql://$DB_USER_LABSDB:$DB_PASSWORD_LABSDB@labsdb1001.eqiad.wmnet/centralauth_p'
+CENTRALAUTH_ENGINE_URL  : 
'mysql://$DB_USER_LABSDB:$db_password_lab...@s1.analytics.db.svc.eqiad.wmflabs/centralauth_p'
 REPLICATION_LAG_MW_PROJECTS : [ 'enwiki', 'eowiki', 'elwiki', 
'commonswiki', 'dewiki', 'frwiki', 'eswiki' ]
 REPLICATION_LAG_THRESHOLD   : 3 # (measured in hours)
 DEBUG   : False

-- 
To view, visit https://gerrit.wikimedia.org/r/391993
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib6017b4e43af97c08dc8e5222d5ec75d5b52154e
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics-deploy
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/geowiki[master]: Update database where data is stored

2017-11-16 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/391841 )

Change subject: Update database where data is stored
..

Update database where data is stored

Change-Id: I37b5b9521b7ea880af76533f746abfbbd300887b
---
M geowiki/process_data.py
M scripts/make_limn_files.py
M scripts/restore_from_files.py
3 files changed, 4 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/geowiki 
refs/changes/41/391841/1

diff --git a/geowiki/process_data.py b/geowiki/process_data.py
index 4180cd3..6c72f69 100755
--- a/geowiki/process_data.py
+++ b/geowiki/process_data.py
@@ -288,7 +288,7 @@
 )
 parser.add_argument(
 '--dest_db_name',
-default='staging',
+default='staging_db1047',
 help='name of database in which to insert results'
 )
 parser.add_argument(
diff --git a/scripts/make_limn_files.py b/scripts/make_limn_files.py
index f32878e..bcccd58 100755
--- a/scripts/make_limn_files.py
+++ b/scripts/make_limn_files.py
@@ -366,10 +366,10 @@
 )
 parser.add_argument(
 '--source_db_name',
-default='staging',
+default='staging_db1047',
 help='name of database to get data from. This database is accessed '
 'through the credentials provided by --source-sql_cnf. '
-'(default: staging)'
+'(default: staging_db1047)'
 )
 
 args = parser.parse_args()
diff --git a/scripts/restore_from_files.py b/scripts/restore_from_files.py
index b5f3e79..cbcd5a4 100755
--- a/scripts/restore_from_files.py
+++ b/scripts/restore_from_files.py
@@ -51,7 +51,7 @@
 )
 parser.add_argument(
 '--dest_db_name',
-default='staging',
+default='staging_db1047',
 help='name of database in which to insert results'
 )
 parser.add_argument(

-- 
To view, visit https://gerrit.wikimedia.org/r/391841
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I37b5b9521b7ea880af76533f746abfbbd300887b
Gerrit-PatchSet: 1
Gerrit-Project: analytics/geowiki
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Create Oozie job for interlanguage nav table

2017-11-16 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/365517 )

Change subject: Create Oozie job for interlanguage nav table
..


Create Oozie job for interlanguage nav table

We are aggregating pageviews from webrequest that are referred from one
language to another inside the same project family.  For example, if
someone navigates from en.wikipedia to de.wikipedia, we count that as
(wikipedia, en, de, 1).  The language team has been doing this manually
so far and we are just oozifying it so it can be monitored, reliable,
and automated.

Bug: T170764
Change-Id: I35bc02e046931735f89c0e7bcda676da172a81aa
---
M .gitignore
A hive/interlanguage/create_interlanguage_navigation_table.hql
A oozie/interlanguage/daily/README.md
A oozie/interlanguage/daily/coordinator.properties
A oozie/interlanguage/daily/coordinator.xml
A oozie/interlanguage/daily/interlanguage_navigation.hql
A oozie/interlanguage/daily/workflow.xml
A oozie/interlanguage/datasets.xml
8 files changed, 473 insertions(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved
  Amire80: Looks good to me, but someone else must approve



diff --git a/.gitignore b/.gitignore
index c9b568f..1559f2e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,3 @@
 *.pyc
 *.swp
+*.swo
diff --git a/hive/interlanguage/create_interlanguage_navigation_table.hql 
b/hive/interlanguage/create_interlanguage_navigation_table.hql
new file mode 100644
index 000..939f8fa
--- /dev/null
+++ b/hive/interlanguage/create_interlanguage_navigation_table.hql
@@ -0,0 +1,22 @@
+-- Create table statement for interlanguage_navigation table.
+--
+-- Parameters:
+-- 
+--
+-- Usage
+-- hive -f create_interlanguage_navigation_table.hql \
+-- --database wmf
+--
+
+CREATE EXTERNAL TABLE IF NOT EXISTS `wmf.interlanguage_navigation` (
+`project_family`string  COMMENT 'The project family to aggregate on',
+`previous_project`  string  COMMENT 'The project (language) found in the 
referers of this group of requests',
+`current_project`   string  COMMENT 'The project (language) of this group 
of requests',
+`navigation_count`  bigint  COMMENT 'The number of times a user navigated 
from the previous to the current project'
+)
+PARTITIONED BY (
+`date`  string  COMMENT 'Date in -MM-DD format'
+)
+STORED AS PARQUET
+LOCATION '/wmf/data/wmf/interlanguage/navigation'
+;
diff --git a/oozie/interlanguage/daily/README.md 
b/oozie/interlanguage/daily/README.md
new file mode 100644
index 000..5cc51cf
--- /dev/null
+++ b/oozie/interlanguage/daily/README.md
@@ -0,0 +1,7 @@
+# Aggregate cross-wiki navigation counts using HTTP referrer
+
+This job aggregates webrequest records into counts of navigation by users
+from one wiki project to another.  Only counting desktop site browsing.
+
+Output is appended into (-mm-dd) daily partitions
+in /wmf/data/wmf/interlanguage/navigation
diff --git a/oozie/interlanguage/daily/coordinator.properties 
b/oozie/interlanguage/daily/coordinator.properties
new file mode 100644
index 000..822b592
--- /dev/null
+++ b/oozie/interlanguage/daily/coordinator.properties
@@ -0,0 +1,72 @@
+# Configures a coordinator to manage automatically aggregating interlanguage 
navigation from
+# the refined webrequest table.
+# Any of the following properties are overidable with -D.
+# Usage:
+#   oozie job -Duser=$USER -Dstart_time=2017-10-03T00:00Z -submit -config 
oozie/interlanguage/daily/coordinator.properties
+#
+# NOTE:  The $oozie_directory must be synced to HDFS so that all relevant
+#.xml files exist there when this job is submitted.
+
+
+name_node = hdfs://analytics-hadoop
+job_tracker   = resourcemanager.analytics.eqiad.wmnet:8032
+queue_name= default
+
+user  = hdfs
+
+# Base path in HDFS to refinery.
+# When submitting this job for production, you should
+# override this to point directly at a deployed
+# directory name, and not the 'symbolic' 'current' directory.
+# E.g.  /wmf/refinery/2015-01-05T17.59.18Z--7bb7f07
+refinery_directory= ${name_node}/wmf/refinery/current
+
+# Base path in HDFS to oozie files.
+# Other files will be used relative to this path.
+oozie_directory   = ${refinery_directory}/oozie
+artifacts_directory   = ${refinery_directory}/artifacts
+
+# Version of Hive UDF jar to import
+refinery_jar_version  = 0.0.53
+
+# HDFS path to hive-site.xml file.  This is needed to run hive actions.
+hive_site_xml = ${name_node}/user/hive/hive-site.xml
+
+# HDFS path to coordinator to run for each webrequest_source.
+coordinator_file  = 
${oozie_directory}/interlanguage/daily/coordinator.xml
+
+# HDFS path to workflow to run.
+workflow_file = 

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: [VERY VERY WIP] Work so far on simplifying and fixing breakd...

2017-11-14 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/391490 )

Change subject: [VERY VERY WIP] Work so far on simplifying and fixing breakdowns
..

[VERY VERY WIP] Work so far on simplifying and fixing breakdowns

Work so far:
* break everything
* unify the breakdown/overall logic and data so it all looks and works
  the same
* simplify the components by factoring out common logic
* simplify the code by factoring out repeated logic
* make sure all the little bits and pieces are still functioning (this
  will mean substantial work)

Bug: T180556
Change-Id: I034b70b3d5a0034aa87013650884691c1c94e9f9
---
M src/components/dashboard/MetricBarWidget.vue
M src/components/dashboard/MetricLineWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/Detail.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
M src/components/detail/chart/TableChart.vue
M src/config/metrics/content.js
M src/models/DimensionalData.js
M src/models/GraphModel.js
M src/utils.js
M test/GraphModel.spec.js
14 files changed, 180 insertions(+), 205 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/90/391490/1

diff --git a/src/components/dashboard/MetricBarWidget.vue 
b/src/components/dashboard/MetricBarWidget.vue
index b2dfc2e..72384c4 100644
--- a/src/components/dashboard/MetricBarWidget.vue
+++ b/src/components/dashboard/MetricBarWidget.vue
@@ -52,7 +52,7 @@
   );
 g.selectAll('*').remove();
 
-const rowData = this.graphModel.getGraphData();
+const rowData = this.graphModel.graphData;
 
 const n = root.node(),
   width = n.offsetWidth - margin.left - margin.right,
diff --git a/src/components/dashboard/MetricLineWidget.vue 
b/src/components/dashboard/MetricLineWidget.vue
index be6f956..c0520de 100644
--- a/src/components/dashboard/MetricLineWidget.vue
+++ b/src/components/dashboard/MetricLineWidget.vue
@@ -47,7 +47,7 @@
   );
 g.selectAll('*').remove();
 
-const rowData = this.graphModel.getGraphData();
+const rowData = this.graphModel.graphData;
 
 function resize () {
 g.html("");
@@ -70,10 +70,10 @@
 g.attr('width', width).attr('height', height);
 g.append('path').datum(rowData)
 .attr('d', area)
-.style('fill', 'url(#grad-'+self.graphModel.getArea()+')')
+.style('fill', 'url(#grad-'+self.graphModel.area+')')
 .style('stroke-width', '0');
 let gradient = g.append('linearGradient')
-.attr('id', 'grad-'+self.graphModel.getArea())
+.attr('id', 'grad-'+self.graphModel.area)
 .attr('x1',"0%")
 .attr('y1',"0%")
 .attr('x2',"0%")
diff --git a/src/components/dashboard/MetricWidget.vue 
b/src/components/dashboard/MetricWidget.vue
index bfcc4c5..a31d027 100644
--- a/src/components/dashboard/MetricWidget.vue
+++ b/src/components/dashboard/MetricWidget.vue
@@ -137,7 +137,7 @@
 return _.last(this.graphData);
 },
 graphData: function () {
-return this.graphModel.getGraphData();
+return this.graphModel.graphData;
 },
 changeMoM: function () {
 const data = this.graphData;
diff --git a/src/components/detail/Breakdowns.vue 
b/src/components/detail/Breakdowns.vue
index 8ee6906..3765dd6 100644
--- a/src/components/detail/Breakdowns.vue
+++ b/src/components/detail/Breakdowns.vue
@@ -4,54 +4,49 @@
 
 Filter and Split
 
-
+
 
 
+v-model="graphModel.activeBreakdown"
+:value="b">
 
-Split by {{b.name}}
-
+
+Overall {{b.name}}
+
+
+
+Split by {{b.name}}
+
+
 
 
 
-
-
-{{bv.name}}
-
+
+
+
+
+{{bv.name}}
+
+
 
 
 
 
 
+import utils from '../../utils';
+
 export default {
 name: 'breakdowns',
 props: ['graphModel'],
+
 methods: {
-breakdownToggled (index) {
-this.graphModel.getBreakdowns().forEach((b, i) => {
-if(i != index) {
-this.graphModel.getBreakdowns()[i].on = false;
-}
-})
-this.updateState();
-},
-shouldBeChecked (index) {
-   

[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Add hif.wiktionary to whitelist

2017-11-06 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/389658 )

Change subject: Add hif.wiktionary to whitelist
..

Add hif.wiktionary to whitelist

Change-Id: I725a786c6ab4c7a1f7a44dbe2cadfa41ec4bb5a0
---
M static_data/pageview/whitelist/whitelist.tsv
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery 
refs/changes/58/389658/1

diff --git a/static_data/pageview/whitelist/whitelist.tsv 
b/static_data/pageview/whitelist/whitelist.tsv
index 5988e91..afbc9d0 100644
--- a/static_data/pageview/whitelist/whitelist.tsv
+++ b/static_data/pageview/whitelist/whitelist.tsv
@@ -298,6 +298,7 @@
 projecthe.wikivoyage   2015-10-12 00:00:00
 projecthe.wiktionary   2015-10-12 00:00:00
 projecthif.wikipedia   2015-10-12 00:00:00
+projecthif.wiktionary  2017-11-06 00:00:00
 projecthi.wikibooks2015-10-12 00:00:00
 projecthi.wikipedia2015-10-12 00:00:00
 projecthi.wikiquote2015-10-12 00:00:00

-- 
To view, visit https://gerrit.wikimedia.org/r/389658
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I725a786c6ab4c7a1f7a44dbe2cadfa41ec4bb5a0
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Add hif.wiktionary to whitelist

2017-11-06 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/389658 )

Change subject: Add hif.wiktionary to whitelist
..


Add hif.wiktionary to whitelist

Change-Id: I725a786c6ab4c7a1f7a44dbe2cadfa41ec4bb5a0
---
M static_data/pageview/whitelist/whitelist.tsv
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/static_data/pageview/whitelist/whitelist.tsv 
b/static_data/pageview/whitelist/whitelist.tsv
index 5988e91..afbc9d0 100644
--- a/static_data/pageview/whitelist/whitelist.tsv
+++ b/static_data/pageview/whitelist/whitelist.tsv
@@ -298,6 +298,7 @@
 projecthe.wikivoyage   2015-10-12 00:00:00
 projecthe.wiktionary   2015-10-12 00:00:00
 projecthif.wikipedia   2015-10-12 00:00:00
+projecthif.wiktionary  2017-11-06 00:00:00
 projecthi.wikibooks2015-10-12 00:00:00
 projecthi.wikipedia2015-10-12 00:00:00
 projecthi.wikiquote2015-10-12 00:00:00

-- 
To view, visit https://gerrit.wikimedia.org/r/389658
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I725a786c6ab4c7a1f7a44dbe2cadfa41ec4bb5a0
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/geowiki[master]: Update hostnames to analytics-store

2017-11-06 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/265213 )

Change subject: Update hostnames to analytics-store
..


Update hostnames to analytics-store

Change-Id: I9b54b0898b2c99173f20edc66c23eda2d1c2dfd2
---
M geowiki/mysql_config.py
1 file changed, 8 insertions(+), 9 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/geowiki/mysql_config.py b/geowiki/mysql_config.py
index 51e8cb1..a8b20ad 100644
--- a/geowiki/mysql_config.py
+++ b/geowiki/mysql_config.py
@@ -132,16 +132,15 @@
 'kowiki': 's7',
 }
 
-# new CNAME system.
-# TODO: abstract mapping to a use just number and then autogenerate CNAMES 
aliases
+# all databases can be found on analytics-store
 db_mapping = {
-'s1': 's1-analytics-slave.eqiad.wmnet',
-'s2': 's2-analytics-slave.eqiad.wmnet',
-'s3': 's3-analytics-slave.eqiad.wmnet',
-'s4': 's4-analytics-slave.eqiad.wmnet',
-'s5': 's5-analytics-slave.eqiad.wmnet',
-'s6': 's6-analytics-slave.eqiad.wmnet',
-'s7': 's7-analytics-slave.eqiad.wmnet',
+'s1': 'analytics-store.eqiad.wmnet',
+'s2': 'analytics-store.eqiad.wmnet',
+'s3': 'analytics-store.eqiad.wmnet',
+'s4': 'analytics-store.eqiad.wmnet',
+'s5': 'analytics-store.eqiad.wmnet',
+'s6': 'analytics-store.eqiad.wmnet',
+'s7': 'analytics-store.eqiad.wmnet',
 }
 
 

-- 
To view, visit https://gerrit.wikimedia.org/r/265213
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9b54b0898b2c99173f20edc66c23eda2d1c2dfd2
Gerrit-PatchSet: 2
Gerrit-Project: analytics/geowiki
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...source[master]: Rename latest/historical fields in mw-history

2017-11-03 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/388265 )

Change subject: Rename latest/historical fields in mw-history
..


Rename latest/historical fields in mw-history

In mediawiki-history reconstruction job, we were using
fieldName as historical field, and fieldNameLatest for
latest version. As pointed by E. Zachte, most people
will care for latest, therefore it makes more sense
to use fieldName for current and fieldNameHistorical
for historical.

Bug: T179689

Change-Id: I98c1dfd6408db756d78368860bd209167cfd8469
---
M 
refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/denormalized/MediawikiEvent.scala
M 
refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/page/PageHistoryBuilder.scala
M 
refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/page/PageHistoryRunner.scala
M 
refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/page/PageState.scala
M 
refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/user/UserHistoryBuilder.scala
M 
refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/user/UserHistoryRunner.scala
M 
refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/user/UserState.scala
M 
refinery-job/src/test/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/denormalized/TestHistoryEventHelpers.scala
M 
refinery-job/src/test/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/page/TestPageHistoryBuilder.scala
M 
refinery-job/src/test/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/page/TestPageHistoryHelpers.scala
M 
refinery-job/src/test/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/user/TestUserHistoryBuilder.scala
M 
refinery-job/src/test/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/user/TestUserHistoryHelpers.scala
12 files changed, 268 insertions(+), 269 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git 
a/refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/denormalized/MediawikiEvent.scala
 
b/refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/denormalized/MediawikiEvent.scala
index 1af27d5..b3d598f 100644
--- 
a/refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/denormalized/MediawikiEvent.scala
+++ 
b/refinery-job/src/main/scala/org/wikimedia/analytics/refinery/job/mediawikihistory/denormalized/MediawikiEvent.scala
@@ -19,25 +19,25 @@
 
 
 case class MediawikiEventPageDetails(pageId: Option[Long] = None,
+ pageTitleHistorical: Option[String] = 
None,
  pageTitle: Option[String] = None,
- pageTitleLatest: Option[String] = None,
+ pageNamespaceHistorical: Option[Int] = 
None,
+ pageNamespaceIsContentHistorical: 
Option[Boolean] = None,
  pageNamespace: Option[Int] = None,
  pageNamespaceIsContent: Option[Boolean] = 
None,
- pageNamespaceLatest: Option[Int] = None,
- pageNamespaceIsContentLatest: 
Option[Boolean] = None,
- pageIsRedirectLatest: Option[Boolean] = 
None,
+ pageIsRedirect: Option[Boolean] = None,
  pageCreationTimestamp: Option[Timestamp] 
= None,
  pageRevisionCount: Option[Long] = None,
  pageSecondsSincePreviousRevision: 
Option[Long] = None
 )
 
 case class MediawikiEventUserDetails(userId: Option[Long] = None,
+ userTextHistorical: Option[String] = None,
  userText: Option[String] = None,
- userTextLatest: Option[String] = None,
+ userBlocksHistorical: Option[Seq[String]] 
= None,
  userBlocks: Option[Seq[String]] = None,
- userBlocksLatest: Option[Seq[String]] = 
None,
+ userGroupsHistorical: Option[Seq[String]] 
= None,
  userGroups: Option[Seq[String]] = None,
- userGroupsLatest: Option[Seq[String]] = 
None,
  userIsCreatedBySelf: Option[Boolean] = 
None,
  userIsCreatedBySystem: Option[Boolean] = 
None,
  

[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Rename latest/historical fields in mw-history

2017-11-03 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/388266 )

Change subject: Rename latest/historical fields in mw-history
..


Rename latest/historical fields in mw-history

In mediawiki-history reconstruction jobs, we were using
fieldName as historical field, and fieldNameLatest for
latest version. As pointed by E. Zachte, most people
will care for latest, therefore it makes more sense
to use fieldName for current and fieldNameHistorical
for historical.

Bug: T179689

Change-Id: Ibeb1ab5f29fb435cc8f5e0b8db9c8c40a5882333
---
M hive/mediawiki/history/create_mediawiki_history_table.hql
M hive/mediawiki/history/create_mediawiki_page_history_table.hql
M hive/mediawiki/history/create_mediawiki_user_history_table.hql
M oozie/mediawiki/history/druid/generate_json_mediawiki_history.hql
M oozie/mediawiki/history/druid/load_mediawiki_history.json.template
M oozie/mediawiki/history/reduced/generate_mediawiki_history_reduced.hql
M oozie/mediawiki/history/reduced/mediawiki-stats-druid.md
7 files changed, 96 insertions(+), 96 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/hive/mediawiki/history/create_mediawiki_history_table.hql 
b/hive/mediawiki/history/create_mediawiki_history_table.hql
index f707b26..b38cf62 100644
--- a/hive/mediawiki/history/create_mediawiki_history_table.hql
+++ b/hive/mediawiki/history/create_mediawiki_history_table.hql
@@ -21,12 +21,12 @@
   --`event_timestamp`   timestamp COMMENT 
'When this event ocurred',
   `event_comment` stringCOMMENT 
'Comment related to this event, sourced from log_comment, rev_comment, etc.',
   `event_user_id` bigintCOMMENT 'Id of 
the user that caused the event',
-  `event_user_text`   stringCOMMENT 
'Historical text of the user that caused the event',
-  `event_user_text_latest`stringCOMMENT 
'Current text of the user that caused the event',
-  `event_user_blocks` array COMMENT 
'Historical blocks of the user that caused the event',
-  `event_user_blocks_latest`  array COMMENT 
'Current blocks of the user that caused the event',
-  `event_user_groups` array COMMENT 
'Historical groups of the user that caused the event',
-  `event_user_groups_latest`  array COMMENT 
'Current groups of the user that caused the event',
+  `event_user_text_historical`stringCOMMENT 
'Historical text of the user that caused the event',
+  `event_user_text`   stringCOMMENT 
'Current text of the user that caused the event',
+  `event_user_blocks_historical`  array COMMENT 
'Historical blocks of the user that caused the event',
+  `event_user_blocks` array COMMENT 
'Current blocks of the user that caused the event',
+  `event_user_groups_historical`  array COMMENT 
'Historical groups of the user that caused the event',
+  `event_user_groups` array COMMENT 
'Current groups of the user that caused the event',
   `event_user_is_created_by_self` boolean   COMMENT 
'Whether the event_user created their own account',
   `event_user_is_created_by_system`   boolean   COMMENT 
'Whether the event_user account was created by mediawiki (eg. centralauth)',
   `event_user_is_created_by_peer` boolean   COMMENT 
'Whether the event_user account was created by another user',
@@ -38,25 +38,25 @@
   `event_user_seconds_since_previous_revision`bigintCOMMENT 'In 
revision events: seconds elapsed since the previous revision made by the 
current event_user_id (only available in revision-create events so far)',
 
   `page_id`   bigintCOMMENT 'In 
revision/page events: id of the page',
-  `page_title`stringCOMMENT 'In 
revision/page events: historical title of the page',
-  `page_title_latest` stringCOMMENT 'In 
revision/page events: current title of the page',
-  `page_namespace`int   COMMENT 'In 
revision/page events: historical namespace of the page.',
-  `page_namespace_is_content` boolean   COMMENT 'In 
revision/page events: historical namespace of the page is categorized as 
content',
-  `page_namespace_latest` int   COMMENT 'In 
revision/page events: current namespace of the page',
-  `page_namespace_is_content_latest`  boolean   COMMENT 'In 
revision/page events: current namespace of the page is categorized as content',
-  

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Handle negative values in graphs

2017-10-31 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/387561 )

Change subject: Handle negative values in graphs
..


Handle negative values in graphs

Adds support for negative values for both line and bar graphs in
the Dashboard and the Detail pages

Bug: T178461
Change-Id: I9ef8487176ad657cbd8f1832e8f56b8c761453a0
---
M src/components/dashboard/MetricBarWidget.vue
M src/components/dashboard/MetricLineWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
5 files changed, 80 insertions(+), 18 deletions(-)

Approvals:
  Milimetric: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/components/dashboard/MetricBarWidget.vue 
b/src/components/dashboard/MetricBarWidget.vue
index 83a1a43..b2dfc2e 100644
--- a/src/components/dashboard/MetricBarWidget.vue
+++ b/src/components/dashboard/MetricBarWidget.vue
@@ -60,8 +60,10 @@
   x = scales.scaleBand().rangeRound([0, width]).padding(0.3),
   y = scales.scaleLinear().rangeRound([height, 0]);
 
+const min = Math.min(0, arr.min(rowData.map((d) => d.total)));
+
 x.domain(rowData.map((d) => d.month));
-y.domain([0, arr.max(rowData.map((d) => d.total))]);
+y.domain([min, arr.max(rowData.map((d) => d.total))]);
 
 svg.attr('width', n.offsetWidth).attr('height', n.offsetHeight);
 g.attr('width', width).attr('height', height);
@@ -69,13 +71,30 @@
 g.append('g').selectAll('.bar').data(rowData)
 .enter().append('rect')
 .attr('x', (d) => x(d.month))
-.attr('y', (d) => y(d.total))
+.attr('y', (d) => {
+if (d.total >= 0) {
+return y(d.total);
+} else {
+return y(0);
+}
+})
 .attr('width', x.bandwidth())
-.attr('height', (d) => height - y(d.total))
+.attr('height', (d) => {
+return Math.abs(y(d.total) - y(0))
+})
 .attr('fill', (d) =>
 d.month === lastMonth ?
 self.metricData.darkColor : 
self.metricData.lightColor
 );
+if (min < 0) {
+g.append('line')
+.attr('x1', 0)
+.attr('x2', width)
+.attr('y1', y(0))
+.attr('y2', y(0))
+.style('stroke', self.metricData.lightColor)
+.style('stroke-width', 0.5);
+}
 
 g.append('g').classed('month-ticks', true)
 .attr('transform', `translate(${
diff --git a/src/components/dashboard/MetricLineWidget.vue 
b/src/components/dashboard/MetricLineWidget.vue
index 926b60d..be6f956 100644
--- a/src/components/dashboard/MetricLineWidget.vue
+++ b/src/components/dashboard/MetricLineWidget.vue
@@ -54,8 +54,9 @@
 const n = root.node(),
   width = n.offsetWidth - margin.left - margin.right,
   height = n.offsetHeight - margin.top - margin.bottom - 
padding,
+  min = Math.min(0, arr.min(rowData.map((d) => d.total))),
   x = scales.scaleTime().rangeRound([0, width]),
-  y = scales.scaleLinear().rangeRound([height, 0]);
+  y = scales.scaleLinear().rangeRound([height, min]);
 
 x.domain(arr.extent(rowData.map((d) => d.month)));
 y.domain([0, arr.max(rowData.map((d) => d.total))]);
diff --git a/src/components/detail/Breakdowns.vue 
b/src/components/detail/Breakdowns.vue
index 4211ca1..8ee6906 100644
--- a/src/components/detail/Breakdowns.vue
+++ b/src/components/detail/Breakdowns.vue
@@ -32,13 +32,11 @@
 props: ['graphModel'],
 methods: {
 breakdownToggled (index) {
-if (this.graphModel.getBreakdowns()[index].on) {
-this.graphModel.getBreakdowns().forEach((b, i) => {
-if(i != index) {
-this.graphModel.getBreakdowns()[i].on = false;
-}
-})
-}
+this.graphModel.getBreakdowns().forEach((b, i) => {
+if(i != index) {
+this.graphModel.getBreakdowns()[i].on = false;
+}
+})
 this.updateState();
 },
 shouldBeChecked (index) {
diff --git a/src/components/detail/chart/BarChart.vue 
b/src/components/detail/chart/BarChart.vue
index b44196d..38b7c86 100644
--- 

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Clean up style and tweak UX

2017-10-30 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/387502 )

Change subject: Clean up style and tweak UX
..

Clean up style and tweak UX

Changes based on how everything feels now that the site is close to
alpha launch.  Also based on Erik's UX feedback.

Bug: T178084
Change-Id: I6ee01999091e88c267bd53d667da4173c4366fc9
---
M src/components/TopicExplorer.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/Detail.vue
M src/components/detail/GraphPanel.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/contributing.js
M src/config/metrics/reading.js
9 files changed, 186 insertions(+), 199 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/02/387502/1

diff --git a/src/components/TopicExplorer.vue b/src/components/TopicExplorer.vue
index 89f36c6..0371b05 100644
--- a/src/components/TopicExplorer.vue
+++ b/src/components/TopicExplorer.vue
@@ -67,7 +67,7 @@
 },
 
 mounted () {
-this.searchData = config.questions.filter(q => q.enabled);
+this.searchData = config.questions;
 },
 
 computed: mapState([
diff --git a/src/components/dashboard/MetricWidget.vue 
b/src/components/dashboard/MetricWidget.vue
index 96d73e0..bfcc4c5 100644
--- a/src/components/dashboard/MetricWidget.vue
+++ b/src/components/dashboard/MetricWidget.vue
@@ -190,13 +190,15 @@
 margin-left: 0.33%;
 margin-right: 0.33%;
 background-color: #ff;
-border-radius: 0 0 10px 10px;
 border: 1px solid #d4d4d5;
 box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.1);
 
 color: #000!important;
 padding: 13px 22px!important;
 }
+.widget.column, .widget.column .status.overlay {
+border-radius: 0 0 10px 10px;
+}
 .widget.column:hover {
 box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.35);
 cursor: pointer;
diff --git a/src/components/detail/Breakdowns.vue 
b/src/components/detail/Breakdowns.vue
index 48268e1..4211ca1 100644
--- a/src/components/detail/Breakdowns.vue
+++ b/src/components/detail/Breakdowns.vue
@@ -2,29 +2,26 @@
 
 
 
-Filters and Breakdowns
+Filter and Split
 
-
-{{b.name}}
+
+
+
+
+Split by {{b.name}}
+
+
+
+
 
 
 {{bv.name}}
 
-
-
-
-
-Breakdown
-Off
-On
-
-
-
 
 
 
@@ -59,3 +56,11 @@
 }
 }
 
+
+
+.breakdown .ui.toggle.checkbox > label { cursor: pointer!important; 
padding-left: 4em; }
+.ui.toggle.checkbox { margin-top: 10px; }
+.ui.toggle.checkbox input:checked ~ label:before {
+background-color: #227634!important;
+}
+
diff --git a/src/components/detail/Detail.vue b/src/components/detail/Detail.vue
index fc7d6c4..2ca9441 100644
--- a/src/components/detail/Detail.vue
+++ b/src/components/detail/Detail.vue
@@ -2,19 +2,20 @@
 
 
 
 
 
 
 
-
-
-
 
 
 {{graphModel.getAggregateLabel()}}:
@@ -58,6 +55,9 @@
 
 
 
+
+
+
 
 
 
diff --git a/src/config/index.js b/src/config/index.js
index c2e1e33..a14f746 100644
--- a/src/config/index.js
+++ b/src/config/index.js
@@ -119,42 +119,12 @@
 
 const metrics = require('./metrics');
 
-const questions = [
-
-{ area: 'contributing', metric: 'Top Contributors', question: 'Who are the 
top contributors?' },
-{ area: 'contributing', metric: 'Active Editors',   question: 'How many 
active editors are there?' },
-{ area: 'contributing', metric: 'Non-bot edits',question: 'How many 
edits have been made by registered human users?' },
-{ area: 'contributing', metric: 'New Editors',question: 'How 
many new editors are there?' },
-{ area: 'contributing', metric: 'Newly registered users', question: 'How 
many new users are there?' },
-{ area: 'contributing', metric: 'Total editors',  question: 'How 
many editors are there?' },
-{ area: 'contributing', metric: 'Editors by language',question: 'How 
many editors are there in the most populated countries?' },
-{ area: 'contributing', metric: 'Total Edits', question: 'How many 
edits have been made?' },
-{ area: 'contributing', metric: 'Anonymous edits', question: 'How many 
edits have been made by anonymous users?' },
-{ area: 'contributing', metric: 'Edits per article',   question: 'How many 
edits does an article receive on average?' },
-{ area: 'contributing', metric: 'Top edited articles', question: 'What are 
the most edited articles?' },
-{ area: 'contributing', metric: 'Total Reverts',   question: 'How many 
edits undo previous edits?' },
-
-{ 

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Query breakdowns only when they are visualised

2017-10-30 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/387320 )

Change subject: Query breakdowns only when they are visualised
..


Query breakdowns only when they are visualised

Until now we were requesting breakdown data regardless of whether we were
using it or not, under the assumption that each metric only had one possible
breakdown option. This change makes the dashboard and detail pages request
data without breakdown filters unless a breakdown value is selected in the
sidebar.

Bug: T178461
Change-Id: I319a3e7e41d61779d7b1158052f32801e7b5d4a1
---
M src/apis/aqs.js
M src/components/dashboard/MetricBarWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/Detail.vue
M src/components/detail/DetailSidebar.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/SimpleLegend.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/reading.js
M src/models/GraphModel.js
M src/store/index.js
14 files changed, 147 insertions(+), 124 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/src/apis/aqs.js b/src/apis/aqs.js
index dd848df..e4f6213 100644
--- a/src/apis/aqs.js
+++ b/src/apis/aqs.js
@@ -95,15 +95,16 @@
 /*
 Takes the common data in an API request and adds it to each individual 
item.
 
-INPUT: OUTPUT:
-
-{  [{
-'a': 'foo','a': 'foo',
-'b': 'bar',  ==>   'b': 'bar',
-'results': [{  'timestamp': 1990,
-'timestamp': 1990, 'x': 20
-'x': 20}, ...
-}, ...]]
+INPUT:   OUTPUT:
+{[
+'granularity': 'monthy', {
+'access-site': 'desktop-site',   
'granularity': 'monthy',
+'results': [==>  
'access-site': 'desktop-site',
+{'timestamp': 
'2017090100',
+'timestamp': '2017090100',   'value': 200
+'value': 200 }, ...
+}, ...
+]
 }
 
 Any hyphens in keys will be replaced by underscores to uniformise 
breakdown keys
diff --git a/src/components/dashboard/MetricBarWidget.vue 
b/src/components/dashboard/MetricBarWidget.vue
index b583485..83a1a43 100644
--- a/src/components/dashboard/MetricBarWidget.vue
+++ b/src/components/dashboard/MetricBarWidget.vue
@@ -54,45 +54,42 @@
 
 const rowData = this.graphModel.getGraphData();
 
-function resize () {
-const n = root.node(),
-  width = n.offsetWidth - margin.left - margin.right,
-  height = n.offsetHeight - margin.top - margin.bottom - 
padding,
-  x = scales.scaleBand().rangeRound([0, 
width]).padding(0.3),
-  y = scales.scaleLinear().rangeRound([height, 0]);
+const n = root.node(),
+  width = n.offsetWidth - margin.left - margin.right,
+  height = n.offsetHeight - margin.top - margin.bottom - 
padding,
+  x = scales.scaleBand().rangeRound([0, width]).padding(0.3),
+  y = scales.scaleLinear().rangeRound([height, 0]);
 
-x.domain(rowData.map((d) => d.month));
-y.domain([0, arr.max(rowData.map((d) => d.total))]);
+x.domain(rowData.map((d) => d.month));
+y.domain([0, arr.max(rowData.map((d) => d.total))]);
 
-svg.attr('width', n.offsetWidth).attr('height', 
n.offsetHeight);
-g.attr('width', width).attr('height', height);
-const lastMonth = rowData[rowData.length - 1].month;
-g.append('g').selectAll('.bar').data(rowData)
-.enter().append('rect')
-.attr('x', (d) => x(d.month))
-.attr('y', (d) => y(d.total))
-.attr('width', x.bandwidth())
-.attr('height', (d) => height - y(d.total))
-.attr('fill', (d) =>
-d.month === lastMonth ?
-self.metricData.darkColor : 
self.metricData.lightColor
-);
+svg.attr('width', n.offsetWidth).attr('height', n.offsetHeight);
+g.attr('width', width).attr('height', height);
+const lastMonth = rowData[rowData.length - 1].month;
+

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Query breakdowns only when they are visualised

2017-10-30 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/387320 )

Change subject: Query breakdowns only when they are visualised
..

Query breakdowns only when they are visualised

Until now we were requesting breakdown data regardless of whether we were
using it or not, under the assumption that each metric only had one possible
breakdown option. This change makes the dashboard and detail pages request
data without breakdown filters unless a breakdown value is selected in the
sidebar.

Bug: T178461
Change-Id: I319a3e7e41d61779d7b1158052f32801e7b5d4a1
---
M src/apis/aqs.js
M src/components/dashboard/MetricBarWidget.vue
M src/components/detail/Breakdowns.vue
M src/components/detail/Detail.vue
M src/components/detail/DetailSidebar.vue
M src/components/detail/GraphPanel.vue
M src/components/detail/SimpleLegend.vue
M src/components/detail/chart/BarChart.vue
M src/components/detail/chart/LineChart.vue
M src/config/index.js
M src/config/metrics/content.js
M src/config/metrics/reading.js
M src/models/GraphModel.js
M src/store/index.js
14 files changed, 147 insertions(+), 124 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/20/387320/1

diff --git a/src/apis/aqs.js b/src/apis/aqs.js
index dd848df..e4f6213 100644
--- a/src/apis/aqs.js
+++ b/src/apis/aqs.js
@@ -95,15 +95,16 @@
 /*
 Takes the common data in an API request and adds it to each individual 
item.
 
-INPUT: OUTPUT:
-
-{  [{
-'a': 'foo','a': 'foo',
-'b': 'bar',  ==>   'b': 'bar',
-'results': [{  'timestamp': 1990,
-'timestamp': 1990, 'x': 20
-'x': 20}, ...
-}, ...]]
+INPUT:   OUTPUT:
+{[
+'granularity': 'monthy', {
+'access-site': 'desktop-site',   
'granularity': 'monthy',
+'results': [==>  
'access-site': 'desktop-site',
+{'timestamp': 
'2017090100',
+'timestamp': '2017090100',   'value': 200
+'value': 200 }, ...
+}, ...
+]
 }
 
 Any hyphens in keys will be replaced by underscores to uniformise 
breakdown keys
diff --git a/src/components/dashboard/MetricBarWidget.vue 
b/src/components/dashboard/MetricBarWidget.vue
index b583485..83a1a43 100644
--- a/src/components/dashboard/MetricBarWidget.vue
+++ b/src/components/dashboard/MetricBarWidget.vue
@@ -54,45 +54,42 @@
 
 const rowData = this.graphModel.getGraphData();
 
-function resize () {
-const n = root.node(),
-  width = n.offsetWidth - margin.left - margin.right,
-  height = n.offsetHeight - margin.top - margin.bottom - 
padding,
-  x = scales.scaleBand().rangeRound([0, 
width]).padding(0.3),
-  y = scales.scaleLinear().rangeRound([height, 0]);
+const n = root.node(),
+  width = n.offsetWidth - margin.left - margin.right,
+  height = n.offsetHeight - margin.top - margin.bottom - 
padding,
+  x = scales.scaleBand().rangeRound([0, width]).padding(0.3),
+  y = scales.scaleLinear().rangeRound([height, 0]);
 
-x.domain(rowData.map((d) => d.month));
-y.domain([0, arr.max(rowData.map((d) => d.total))]);
+x.domain(rowData.map((d) => d.month));
+y.domain([0, arr.max(rowData.map((d) => d.total))]);
 
-svg.attr('width', n.offsetWidth).attr('height', 
n.offsetHeight);
-g.attr('width', width).attr('height', height);
-const lastMonth = rowData[rowData.length - 1].month;
-g.append('g').selectAll('.bar').data(rowData)
-.enter().append('rect')
-.attr('x', (d) => x(d.month))
-.attr('y', (d) => y(d.total))
-.attr('width', x.bandwidth())
-.attr('height', (d) => height - y(d.total))
-.attr('fill', (d) =>
-d.month === lastMonth ?
-self.metricData.darkColor : 
self.metricData.lightColor
-);
+svg.attr('width', n.offsetWidth).attr('height', n.offsetHeight);
+g.attr('width', width).attr('height', height);
+const lastMonth = rowData[rowData.length - 1].month;
+

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Use only js Date objects internally

2017-10-30 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/385186 )

Change subject: Use only js Date objects internally
..


Use only js Date objects internally

- Adds a function that turns all string-based timestamps into Date objects.
- Adapts components so that they use the Date API.
- Creates color gradients for each area color.
- Changes data flattening to conform the new APIs

Bug: T178461

Change-Id: I0847abfef12e43b0b562a8b02eb267f06ca5a60a
---
M src/apis/aqs.js
M src/components/dashboard/MetricBarWidget.vue
M src/components/dashboard/MetricLineWidget.vue
M src/components/dashboard/MetricWidget.vue
M src/models/GraphModel.js
5 files changed, 55 insertions(+), 21 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/src/apis/aqs.js b/src/apis/aqs.js
index c16be31..dd848df 100644
--- a/src/apis/aqs.js
+++ b/src/apis/aqs.js
@@ -72,6 +72,11 @@
 let validData = _.filter(data, d => !d.hasOwnProperty('error'));
 let formattedData = _.flatten(validData.map(d => d.items));
 if (formattedData.length > 0) {
+// Some endpoints return repetitive information in an upper 
level, and then row
+// data in a results array
+if (formattedData[0].results) {
+formattedData = this.transformResults(formattedData);
+}
 if (metricData.type === 'list') {
 formattedData = this.formatTops(formattedData);
 }
@@ -85,6 +90,38 @@
 formatTops (data) {
 return _.flatten(data.map(item => item.articles));
 }
+
+
+/*
+Takes the common data in an API request and adds it to each individual 
item.
+
+INPUT: OUTPUT:
+
+{  [{
+'a': 'foo','a': 'foo',
+'b': 'bar',  ==>   'b': 'bar',
+'results': [{  'timestamp': 1990,
+'timestamp': 1990, 'x': 20
+'x': 20}, ...
+}, ...]]
+}
+
+Any hyphens in keys will be replaced by underscores to uniformise 
breakdown keys
+and parameter names.
+*/
+transformResults (data) {
+return data.reduce((p, c) => {
+let keys = Object.keys(c);
+const resultsIndex = keys.indexOf('results');
+keys.splice(resultsIndex, 1);
+return p.concat(c.results.map((datum) => {
+keys.forEach((key) => {
+datum[key.replace(/-/g, '_')] = c[key];
+})
+return datum
+}))
+}, []);
+}
 }
 
 export default AQS;
diff --git a/src/components/dashboard/MetricBarWidget.vue 
b/src/components/dashboard/MetricBarWidget.vue
index 1cda876..b583485 100644
--- a/src/components/dashboard/MetricBarWidget.vue
+++ b/src/components/dashboard/MetricBarWidget.vue
@@ -95,7 +95,7 @@
 resize();
 },
 getMonthValue (date) {
-return config.months[parseInt(date.split('-')[1])][0];
+return config.months[date.getMonth() + 1][0];
 }
 }
 }
diff --git a/src/components/dashboard/MetricLineWidget.vue 
b/src/components/dashboard/MetricLineWidget.vue
index 14572d2..926b60d 100644
--- a/src/components/dashboard/MetricLineWidget.vue
+++ b/src/components/dashboard/MetricLineWidget.vue
@@ -47,13 +47,7 @@
   );
 g.selectAll('*').remove();
 
-const rowData = this.graphModel.getGraphData().map((row) => {
-const splitDate = row.month.split('-');
-return {
-total: row.total,
-month: new Date(splitDate[0], splitDate[1], splitDate[2])
-};
-});
+const rowData = this.graphModel.getGraphData();
 
 function resize () {
 g.html("");
@@ -75,10 +69,10 @@
 g.attr('width', width).attr('height', height);
 g.append('path').datum(rowData)
 .attr('d', area)
-.style('fill', 'url(#grad)')
+.style('fill', 'url(#grad-'+self.graphModel.getArea()+')')
 .style('stroke-width', '0');
 let gradient = g.append('linearGradient')
-.attr('id', 'grad')
+.attr('id', 'grad-'+self.graphModel.getArea())
 .attr('x1',"0%")
 .attr('y1',"0%")
 .attr('x2',"0%")
@@ -101,9 +95,6 @@
 .style('stroke', self.metricData.darkColor);
 }
 resize();
-},
-getMonthValue (date) {
-return config.months[parseInt(date.split('-')[1])][0];
 }
 }
 }
diff --git 

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: [WIP] Clean up UI and aggregations

2017-10-26 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386774 )

Change subject: [WIP] Clean up UI and aggregations
..

[WIP] Clean up UI and aggregations

This cleans up a few things noticed by Erik in the linked task
It also refactors the aggregation a bit and corrects some calculation
mistakes.  The main thing remaining is to decide what to show on the
Dashboard because YoY numbers are not always going to match the widget
graph visually.

Bug: T178084
Change-Id: Id2bd700f9f72aea6ee56d68234426979d355e04d
---
M src/components/BottomFooter.vue
M src/components/dashboard/MetricWidget.vue
M src/components/detail/GraphPanel.vue
M src/lodash-custom-bundle.js
M src/models/GraphModel.js
A test/GraphModel.spec.js
6 files changed, 135 insertions(+), 32 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/74/386774/1

diff --git a/src/components/BottomFooter.vue b/src/components/BottomFooter.vue
index bb1c2d0..7cacd8f 100644
--- a/src/components/BottomFooter.vue
+++ b/src/components/BottomFooter.vue
@@ -1,17 +1,20 @@
 
-
-
-Find out more https://wikitech.wikimedia.org/wiki/Analytics/Wikistats2.0;>about 
Wikistats and the https://wikitech.wikimedia.org/wiki/Analytics#Datasets;>data that it 
uses
+
+
+Find out more https://wikitech.wikimedia.org/wiki/Analytics/Wikistats2.0;>about 
Wikistats
+and the https://wikitech.wikimedia.org/wiki/Analytics#Datasets;>data it 
uses
 
-
-Wikistats is written with Vue.js and Semantic UI.  If you'd like to contribute, see our 
contributing
 guide or follow this link to report
 a bug
+
+Wikistats is written with Vue.js and Semantic UI.
+See our contributing
 guide to help us build Wikistats.
+Follow this link to report
 a bug
 
-
-Wikistats is designed by Aislinn Grigas.
+
+Designed by Aislinn Grigas.
 
 
-
-All data, charts, and other content is available under the https://creativecommons.org/publicdomain/zero/1.0/; 
target="_new">Creative Commons CC0 dedication.
+
+All data, charts, and other content is available under the https://creativecommons.org/publicdomain/zero/1.0/;>Creative Commons CC0 
dedication.
 
 
 
@@ -29,5 +32,6 @@
 
 
 
-a, a:visited { color: #777; }
+a, a:visited { color: #888; }
+.ui.centered { font-size: 1.1em; }
 
diff --git a/src/components/dashboard/MetricWidget.vue 
b/src/components/dashboard/MetricWidget.vue
index 2856ebc..4f025d2 100644
--- a/src/components/dashboard/MetricWidget.vue
+++ b/src/components/dashboard/MetricWidget.vue
@@ -34,7 +34,7 @@
 
 
 
-{{lastYearAggregation.total | kmb}}
+{{lastYearAggregation | kmb}}
 
 
 
@@ -131,15 +131,7 @@
 return this.graphData[_.indexOf(this.graphData, 
this.lastMonth) - 12];
 },
 lastYearAggregation: function () {
-if (this.metricData.additive) {
-return {
-total: 
_.sumBy(this.graphData.slice(_.indexOf(this.graphData, this.lastMonth) - 12), 
month => month.total)
-};
-} else {
-return {
-total: 
_.sumBy(this.graphData.slice(_.indexOf(this.graphData, this.lastMonth) - 12), 
month => month.total) / 12
-};
-}
+return this.graphModel.getAggregate(12);
 },
 lastMonth: function () {
 return _.last(this.graphData);
@@ -154,6 +146,8 @@
 return ((diff / prev.total) * 100).toFixed(2);
 },
 changeYoY: function () {
+// TODO: We're showing more than the last year, but reporting 
YoY.  This can be confusing because the YoY might not match up visually with 
the graph (like for Unique Devices in Achinese).
+
 const diff = this.lastMonth.total - this.monthOneYearAgo.total;
 return ((diff / this.monthOneYearAgo.total) * 100).toFixed(2);
 },
@@ -161,7 +155,7 @@
 return !this.metricData.global && this.$store.state.project 
=== 'all-projects';
 },
 aggregationType: function () {
-return !this.metricData.additive? 'Average': 'Total';
+return this.graphModel.getAggregateLabel();
 }
 }
 ),
diff --git a/src/components/detail/GraphPanel.vue 
b/src/components/detail/GraphPanel.vue
index e84feec..38c22cb 100644
--- a/src/components/detail/GraphPanel.vue
+++ b/src/components/detail/GraphPanel.vue
@@ -43,14 +43,17 @@
 
 
 
-Total: {{total | kmb}} 

[MediaWiki-commits] [Gerrit] analytics/dashiki[master]: Configure dygraphs so Y-axis starts at '0'

2017-10-26 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/386708 )

Change subject: Configure dygraphs so Y-axis starts at '0'
..


Configure dygraphs so Y-axis starts at '0'

Bug: T178602
Change-Id: I8a302226b812253a39667d49f4bb3e4553ed3c03
---
M src/components/visualizers/dygraphs-timeseries/bindings.js
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/src/components/visualizers/dygraphs-timeseries/bindings.js 
b/src/components/visualizers/dygraphs-timeseries/bindings.js
index 38322a4..287b2df 100644
--- a/src/components/visualizers/dygraphs-timeseries/bindings.js
+++ b/src/components/visualizers/dygraphs-timeseries/bindings.js
@@ -43,6 +43,7 @@
 y: {
 valueFormatter: val.format,
 axisLabelFormatter: val.format,
+valueRange: [0]
 },
 },
 labels: ['Date'],

-- 
To view, visit https://gerrit.wikimedia.org/r/386708
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I8a302226b812253a39667d49f4bb3e4553ed3c03
Gerrit-PatchSet: 1
Gerrit-Project: analytics/dashiki
Gerrit-Branch: master
Gerrit-Owner: Nuria 
Gerrit-Reviewer: Fdans 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Fix refinery banner activity cleaner to allow for email alerts

2017-10-17 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/384530 )

Change subject: Fix refinery banner activity cleaner to allow for email alerts
..


Fix refinery banner activity cleaner to allow for email alerts

Bug: T178302
Change-Id: I9c6ef64c94a414a60a2e3c45f0969eb5b69fd670
---
M bin/refinery-drop-banner-activity-partitions
1 file changed, 38 insertions(+), 11 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/bin/refinery-drop-banner-activity-partitions 
b/bin/refinery-drop-banner-activity-partitions
index 10672e0..890376b 100755
--- a/bin/refinery-drop-banner-activity-partitions
+++ b/bin/refinery-drop-banner-activity-partitions
@@ -41,19 +41,46 @@
 import os
 
 
+# Set up logging to be split:
+#   INFO+DEBUG+WARNING -> stdout
+#   ERROR  -> stderr
+# Thanks to zoey-greer for their solution:
+# 
https://stackoverflow.com/questions/2302315/how-can-info-and-debug-logging-message-be-sent-to-stdout-and-higher-level-messag/31459386#31459386
+class LessThanFilter(logging.Filter):
+def __init__(self, exclusive_maximum, name=""):
+super(LessThanFilter, self).__init__(name)
+self.max_level = exclusive_maximum
+
+def filter(self, record):
+#non-zero return means we log this message
+return 1 if record.levelno < self.max_level else 0
+
+logger = logging.getLogger()
+logger.setLevel(logging.NOTSET)
+
+formatter = logging.Formatter(
+fmt='%(asctime)s %(levelname)-6s %(message)s',
+datefmt='%Y-%m-%dT%H:%M:%S',
+)
+
+handler_out = logging.StreamHandler(sys.stdout)
+handler_out.setLevel(logging.DEBUG)
+handler_out.addFilter(LessThanFilter(logging.ERROR))
+handler_out.setFormatter(formatter)
+logger.addHandler(handler_out)
+
+handler_err = logging.StreamHandler(sys.stderr)
+handler_err.setLevel(logging.ERROR)
+handler_err.setFormatter(formatter)
+logger.addHandler(handler_err)
+
+
 if __name__ == '__main__':
 # parse arguments
 arguments = docopt(__doc__)
 days= int(arguments['--older-than-days'])
 location= arguments['--location']
 dry_run = arguments['--dry-run']
-
-# configure logging
-logging.basicConfig(
-level=logging.INFO,
-format='%(asctime)s %(levelname)-6s %(message)s',
-datefmt='%Y-%m-%dT%H:%M:%S'
-)
 
 # files or folders older than this date should be deleted
 threshold_datetime = datetime.now() - 
relativedelta.relativedelta(days=days)
@@ -94,11 +121,11 @@
 paths_to_delete.append(day_path)
 
 if dry_run:
-logging.info('Listing {0} directories from {1} 
...'.format(len(paths_to_delete), location))
+logger.info('Listing {0} directories from {1} 
...'.format(len(paths_to_delete), location))
 for path_to_delete in paths_to_delete:
 print path_to_delete
-logging.info('Dry run finished!')
+logger.info('Dry run finished!')
 else:
-logging.info('Removing {0} directories from {1} 
...'.format(len(paths_to_delete), location))
+logger.info('Removing {0} directories from {1} 
...'.format(len(paths_to_delete), location))
 HdfsUtils.rm(' '.join(paths_to_delete))
-logging.info('Done!')
+logger.info('Done!')

-- 
To view, visit https://gerrit.wikimedia.org/r/384530
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9c6ef64c94a414a60a2e3c45f0969eb5b69fd670
Gerrit-PatchSet: 2
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Mforns 
Gerrit-Reviewer: Elukey 
Gerrit-Reviewer: Joal 
Gerrit-Reviewer: Mforns 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: Nuria 
Gerrit-Reviewer: Ottomata 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...deploy[master]: Update aqs to fc4abc4

2017-10-16 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/384556 )

Change subject: Update aqs to fc4abc4
..


Update aqs to fc4abc4

List of changes:
fc4abc4 Fix edits monitoring
xxx Update node module dependencies

Change-Id: I54c1019c448e9bb90816c2423187479ec777b371
---
M node_modules/hyperswitch/node_modules/json-stable-stringify/package.json
M node_modules/hyperswitch/node_modules/swagger-ui/package.json
M 
node_modules/restbase-mod-table-cassandra/node_modules/json-stable-stringify/package.json
M 
node_modules/service-runner/node_modules/limitation/node_modules/kad/package.json
M 
node_modules/service-runner/node_modules/limitation/node_modules/readable-stream/node_modules/inherits/package.json
M src
6 files changed, 7 insertions(+), 6 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git 
a/node_modules/hyperswitch/node_modules/json-stable-stringify/package.json 
b/node_modules/hyperswitch/node_modules/json-stable-stringify/package.json
index 0c5d7e8..36b34ca 100644
--- a/node_modules/hyperswitch/node_modules/json-stable-stringify/package.json
+++ b/node_modules/hyperswitch/node_modules/json-stable-stringify/package.json
@@ -50,7 +50,7 @@
 "url": "https://github.com/substack/json-stable-stringify/issues;
   },
   "_id": "json-stable-stringify@1.0.0",
-  "_shasum": "3a24347e19195318d06633decb1ba96f6ae7837e",
+  "_shasum": "f88ba911af11b11a11c5042fd210335c72f91790",
   "_from": "git+https://github.com/wikimedia/json-stable-stringify.git#master;,
   "_resolved": 
"git+https://github.com/wikimedia/json-stable-stringify.git#c05178e4dfc3834017f017732934c1c52ba3dd8f;
 }
diff --git a/node_modules/hyperswitch/node_modules/swagger-ui/package.json 
b/node_modules/hyperswitch/node_modules/swagger-ui/package.json
index f030de2..30da928 100644
--- a/node_modules/hyperswitch/node_modules/swagger-ui/package.json
+++ b/node_modules/hyperswitch/node_modules/swagger-ui/package.json
@@ -73,7 +73,7 @@
 "url": "https://github.com/swagger-api/swagger-ui/issues;
   },
   "_id": "swagger-ui@2.2.8",
-  "_shasum": "34a00133606d0fa412aa439b8b169f518be3d556",
+  "_shasum": "82910e14a36575b06c70663a69242b68e3cbc0fc",
   "_from": "git+https://github.com/wikimedia/swagger-ui.git#master;,
   "_resolved": 
"git+https://github.com/wikimedia/swagger-ui.git#b9b40dc8e00caeb24c19fe636b93250a7e335541;
 }
diff --git 
a/node_modules/restbase-mod-table-cassandra/node_modules/json-stable-stringify/package.json
 
b/node_modules/restbase-mod-table-cassandra/node_modules/json-stable-stringify/package.json
index 0c5d7e8..36b34ca 100644
--- 
a/node_modules/restbase-mod-table-cassandra/node_modules/json-stable-stringify/package.json
+++ 
b/node_modules/restbase-mod-table-cassandra/node_modules/json-stable-stringify/package.json
@@ -50,7 +50,7 @@
 "url": "https://github.com/substack/json-stable-stringify/issues;
   },
   "_id": "json-stable-stringify@1.0.0",
-  "_shasum": "3a24347e19195318d06633decb1ba96f6ae7837e",
+  "_shasum": "f88ba911af11b11a11c5042fd210335c72f91790",
   "_from": "git+https://github.com/wikimedia/json-stable-stringify.git#master;,
   "_resolved": 
"git+https://github.com/wikimedia/json-stable-stringify.git#c05178e4dfc3834017f017732934c1c52ba3dd8f;
 }
diff --git 
a/node_modules/service-runner/node_modules/limitation/node_modules/kad/package.json
 
b/node_modules/service-runner/node_modules/limitation/node_modules/kad/package.json
index e0a7353..f47ff8e 100644
--- 
a/node_modules/service-runner/node_modules/limitation/node_modules/kad/package.json
+++ 
b/node_modules/service-runner/node_modules/limitation/node_modules/kad/package.json
@@ -72,7 +72,7 @@
   },
   "homepage": "https://github.com/kadtools/kad#readme;,
   "_id": "kad@1.3.6",
-  "_shasum": "09a779e395bc7b9704b6473b55958b0c8b3b8e86",
+  "_shasum": "30521e4ed55935df2f6757e3a89a4557078483ea",
   "_from": "git+https://github.com/gwicke/kad.git#master;,
   "_resolved": 
"git+https://github.com/gwicke/kad.git#936c91652d757ea6f9dd30e44698afb0daaa1d17;
 }
diff --git 
a/node_modules/service-runner/node_modules/limitation/node_modules/readable-stream/node_modules/inherits/package.json
 
b/node_modules/service-runner/node_modules/limitation/node_modules/readable-stream/node_modules/inherits/package.json
index 5825a2a..8bb7f92 100644
--- 
a/node_modules/service-runner/node_modules/limitation/node_modules/readable-stream/node_modules/inherits/package.json
+++ 
b/node_modules/service-runner/node_modules/limitation/node_modules/readable-stream/node_modules/inherits/package.json
@@ -58,5 +58,6 @@
 "tmp": "tmp/inherits-2.0.3.tgz_1473295776489_0.08142363070510328"
   },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz;
+  "_resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz;,
+  "readme": "ERROR: No README data found!"
 }
diff --git a/src b/src
index 5beeea6..fc4abc4 

[MediaWiki-commits] [Gerrit] analytics/aqs[master]: Fix edits monitoring

2017-10-16 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/384552 )

Change subject: Fix edits monitoring
..


Fix edits monitoring

Change-Id: I573cab486200a29c0ccacc7db2ca96d57d7e0cbd
---
M v1/edits.yaml
1 file changed, 3 insertions(+), 2 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/v1/edits.yaml b/v1/edits.yaml
index 4ec248e..16f9110 100644
--- a/v1/edits.yaml
+++ b/v1/edits.yaml
@@ -206,8 +206,9 @@
   page-id: 0
   editor-type: all-editor-types
   granularity: daily
-  timestamp: 2001-01-01T00:00:00.000Z
-  edits: 0
+  results:
+- timestamp: 2001-01-01T00:00:00.000Z
+  edits: 0
 
   /per-editor/{project}/{editor-id}/{page-type}/{granularity}/{start}/{end}:
 get:

-- 
To view, visit https://gerrit.wikimedia.org/r/384552
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I573cab486200a29c0ccacc7db2ca96d57d7e0cbd
Gerrit-PatchSet: 1
Gerrit-Project: analytics/aqs
Gerrit-Branch: master
Gerrit-Owner: Joal 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/aqs[master]: Correct typos in endpoint descriptions

2017-10-16 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/384468 )

Change subject: Correct typos in endpoint descriptions
..


Correct typos in endpoint descriptions

The word timeseries was written without s accross endpoints.

Change-Id: I89f3ec78f4e0ddf038dec97b7933c30edb3f4367
---
M v1/bytes-difference.yaml
M v1/edited-pages.yaml
M v1/editors.yaml
M v1/edits.yaml
M v1/registered-users.yaml
5 files changed, 19 insertions(+), 19 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/v1/bytes-difference.yaml b/v1/bytes-difference.yaml
index 11863ab..44b2918 100644
--- a/v1/bytes-difference.yaml
+++ b/v1/bytes-difference.yaml
@@ -41,7 +41,7 @@
 - Bytes difference data
   summary: Get the sum of net text bytes difference between current edit 
and previous one.
   description: |
-Given a Mediawiki project and a date range, returns a timeserie of 
bytes difference net
+Given a Mediawiki project and a date range, returns a timeseries of 
bytes difference net
 sums. You can filter by editors-type (all-editor-types, anonymous, 
group-bot, name-bot,
 user) and page-type (all-page-types, content or non-content). You can 
choose between
 daily and monthly granularity as well.
@@ -118,7 +118,7 @@
 - Bytes difference data
   summary: Get the sum of net text bytes difference per page.
   description: |
-Given a Mediawiki project, a page-id and a date range, returns a 
timeserie of bytes
+Given a Mediawiki project, a page-id and a date range, returns a 
timeseries of bytes
 difference net sums. You can filter by editors-type (all-editor-types, 
anonymous, group-bot,
 name-bot, user). You can choose between daily and monthly granularity 
as well.
 Stability: 
[experimental](https://www.mediawiki.org/wiki/API_versioning#Experimental)
@@ -190,7 +190,7 @@
 - Bytes difference data
   summary: Get the sum of net text bytes difference per editor.
   description: |
-Given a Mediawiki project, an editor-id and a date range, returns a 
timeserie of bytes
+Given a Mediawiki project, an editor-id and a date range, returns a 
timeseries of bytes
 difference net sums. You can filter by page-type (all-page-types, 
content, non-content).
 You can choose between daily and monthly granularity as well.
 Stability: 
[experimental](https://www.mediawiki.org/wiki/API_versioning#Experimental)
@@ -263,7 +263,7 @@
 Get the sum of absolute value of text bytes difference between current 
edit and
 previous one.
   description: |
-Given a Mediawiki project and a date range, returns a timeserie of 
absolute bytes
+Given a Mediawiki project and a date range, returns a timeseries of 
absolute bytes
 difference sums. You can filter by editors-type (all-editor-types, 
anonymous, group-bot,
 name-bot, user) and page-type (all-page-types, content, non-content). 
You can choose
 between daily and monthly granularity as well.
@@ -340,7 +340,7 @@
 - Bytes difference data
   summary: Get the sum of absolute text bytes difference per page.
   description: |
-Given a Mediawiki project, a page-id and a date range, returns a 
timeserie of bytes
+Given a Mediawiki project, a page-id and a date range, returns a 
timeseries of bytes
 difference absolute sums. You can filter by editors-type 
(all-editor-types, anonymous,
 group-bot, name-bot, user). You can choose between daily and monthly 
granularity as well.
 Stability: 
[experimental](https://www.mediawiki.org/wiki/API_versioning#Experimental)
@@ -412,7 +412,7 @@
 - Bytes difference data
   summary: Get the sum of absolute text bytes difference per editor.
   description: |
-Given a Mediawiki project, an editor-id and a date range, returns a 
timeserie of bytes
+Given a Mediawiki project, an editor-id and a date range, returns a 
timeseries of bytes
 difference absolute sums. You can filter by page-type (all-page-types, 
content,
 non-content). You can choose between daily and monthly granularity as 
well.
 Stability: 
[experimental](https://www.mediawiki.org/wiki/API_versioning#Experimental)
diff --git a/v1/edited-pages.yaml b/v1/edited-pages.yaml
index a349379..b2f377f 100644
--- a/v1/edited-pages.yaml
+++ b/v1/edited-pages.yaml
@@ -41,7 +41,7 @@
 - Edited pages data
   summary: Get new pages counts for a project.
   description: |
-Given a Mediawiki project and a date range, returns a timeserie of its 
new pages counts.
+Given a Mediawiki project and a date range, returns a timeseries of 
its new pages counts.
 You can filter by editor type (all-editor-types, anonymous, group-bot, 
name-bot, user) 

[MediaWiki-commits] [Gerrit] analytics/aqs[master]: Correct bug in druid URI building

2017-10-13 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/384103 )

Change subject: Correct bug in druid URI building
..


Correct bug in druid URI building

Change-Id: I799d84ba23c2b7df0a262fada755bb8c3b1f424f
---
M sys/mediawiki-history-metrics.js
1 file changed, 0 insertions(+), 1 deletion(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/sys/mediawiki-history-metrics.js b/sys/mediawiki-history-metrics.js
index 7a7b916..54e9fec 100644
--- a/sys/mediawiki-history-metrics.js
+++ b/sys/mediawiki-history-metrics.js
@@ -44,7 +44,6 @@
 uri += (druid.scheme) ? druid.scheme + '://' : '';
 uri += druid.host || '';
 uri += (druid.port) ? ':' + druid.port : '';
-uri += druid.host || '';
 uri += druid.query_path || '';
 
 return uri;

-- 
To view, visit https://gerrit.wikimedia.org/r/384103
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I799d84ba23c2b7df0a262fada755bb8c3b1f424f
Gerrit-PatchSet: 2
Gerrit-Project: analytics/aqs
Gerrit-Branch: master
Gerrit-Owner: Joal 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Tweak order and alignment of lists for readability

2017-10-11 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/383728 )

Change subject: Tweak order and alignment of lists for readability
..

Tweak order and alignment of lists for readability

Following up on https://www.mediawiki.org/wiki/Topic:Tpdblpjwjr12aktk

Change-Id: I35f1437a764ba09338789c973747859d85ceac1c
---
M src/components/detail/chart/TableChart.vue
1 file changed, 5 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/28/383728/1

diff --git a/src/components/detail/chart/TableChart.vue 
b/src/components/detail/chart/TableChart.vue
index 09ab88f..24ca37f 100644
--- a/src/components/detail/chart/TableChart.vue
+++ b/src/components/detail/chart/TableChart.vue
@@ -7,8 +7,8 @@
 Total
 
 
-Name
 {{metricData.valueName}}
+Name
 
 
 
@@ -17,8 +17,8 @@
 {{m.total}}
 
 
+{{m[metricData.value]}}
 {{m[metricData.key].replace(/_/g, ' ')}}
-{{m[metricData.value]}}
 
 
 
@@ -86,4 +86,7 @@
 td a {
 color: #000;
 }
+td.right.aligned {
+text-align: right;
+}
 

-- 
To view, visit https://gerrit.wikimedia.org/r/383728
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I35f1437a764ba09338789c973747859d85ceac1c
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Exclude bots from pageviews

2017-10-11 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/383725 )

Change subject: Exclude bots from pageviews
..

Exclude bots from pageviews

Per https://www.mediawiki.org/wiki/Topic:Tpqmiprj7rgt2fau

Change-Id: I76b561a9ab3582d6119efcb715a5e094701009c8
---
M src/config.js
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/25/383725/1

diff --git a/src/config.js b/src/config.js
index 23987c3..a1e0409 100644
--- a/src/config.js
+++ b/src/config.js
@@ -82,7 +82,7 @@
 const metrics = {
 'total-pageviews': {
 fullName: 'Total Page Views',
-description: 'A page view is a request for the content of a web page. 
Page views on Wikimedia projects is our most important content consumption 
metric.',
+description: 'Page views on Wikimedia projects count the viewing of 
article content.  In this data we try to exclude bot traffic and focus on human 
user page views.',
 info_url: 'https://meta.wikimedia.org/wiki/Research:Page_view',
 defaults: {
 unique: {
@@ -91,7 +91,7 @@
 },
 common: {
 metric: 'total-pageviews',
-agent_type: 'all-agents',
+agent_type: 'user',
 granularity: 'monthly'
 }
 },

-- 
To view, visit https://gerrit.wikimedia.org/r/383725
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I76b561a9ab3582d6119efcb715a5e094701009c8
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikistats2
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Implement Topic Selector

2017-10-11 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/382636 )

Change subject: Implement Topic Selector
..


Implement Topic Selector

The topic selector reuses the same search-results component built for
the wiki explorer.  It also adds a bit of fancy animation to make it a
reassuring solid part of the interface, especially for users that are
new to wikistats.

Bug: T167676
Change-Id: Ia75f5a0e01304d09359bad1de3ef907a97e5d2ea
---
M src/App.vue
M src/components/TopicExplorer.vue
M src/config.js
M src/store/index.js
4 files changed, 201 insertions(+), 162 deletions(-)

Approvals:
  Fdans: Verified; Looks good to me, approved



diff --git a/src/App.vue b/src/App.vue
index 36bb845..2d3f91f 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -3,8 +3,8 @@
 
 
 
-
-
+
+
 
 
 
@@ -44,6 +44,7 @@
 computed: mapState([
 'project',
 'mainComponent',
+'topicsMinimized',
 ]),
 };
 
@@ -58,11 +59,11 @@
 .ui.top.attached.clearing.segment {
 border-bottom: 4px solid #4A4A4A;
 padding: 35px 44px;
+/* has to have room under it to fit topic selector animation */
+z-index: 10;
 }
 .ui.attached.content.segment {
 background-color: #F6F6F6;
-/* with topic explorer: padding: 53px 32px 27px 32px; */
-/* without topic explorer: */
 padding: 2px 32px 27px 24px;
 }
 .ui.attached.language.segment {
diff --git a/src/components/TopicExplorer.vue b/src/components/TopicExplorer.vue
index f048b61..89f36c6 100644
--- a/src/components/TopicExplorer.vue
+++ b/src/components/TopicExplorer.vue
@@ -1,157 +1,197 @@
 
-
-
-
-
-
-
-Explore Topics
-
-
-
-
+
+
+
+
 
 Explore Topics
-
-Find questions 
you are interested in and click Go for the answers
-
-{{selectedQuestion.q}}
-metric: {{selectedQuestion.m}}
-
-
-Contributing
-
-{{q.q}} metric: {{q.m}}
-
+
+
+
+
 
-Reading
-
-{{q.q}} metric: {{q.m}}
-
+
+Explore Topics
 
-Content
-
-{{q.q}} metric: {{q.m}}
-
+
+
+
 
-More
-
-{{q.q}} metric: {{q.m}}
-
-
-
+
 
-Go
-
-
-
-
-
+
 
+
+
+
+
+
 
 
 
 
 
-import r from '../router/index'
+import { mapState } from 'vuex';
 import _ from '../lodash-custom-bundle';
 import config from '../config'
+import SearchResults from './widgets/SearchResults';
 
 
 export default {
-  name: 'topic-explorer',
+name: 'topic-explorer',
+components: {
+SearchResults,
+},
 
-  data () {
-  return {
-  minimized: true,
+data () {
+return {
+selectedTopic: null,
+searchBoxEl: null,
+searchData: [],
+searchDisplay: '',
+showResults: false,
+};
+},
 
-  selectedQuestion: null
-  }
-  },
+mounted () {
+this.searchData = config.questions.filter(q => q.enabled);
+},
 
-  computed: {
-  contributingQuestions: function () {
-  return config.questions.filter((m) => m.f && m.a === 'contributing');
-  },
-  readingQuestions: function () {
-  return config.questions.filter((m) => m.f && m.a === 'reading');
-  },
-  contentQuestions: function () {
-  return config.questions.filter((m) => m.f && m.a === 'content');
-  },
-  moreQuestions: function () {
-  return config.questions.filter((m) => !m.f);
-  }
-  },
+computed: mapState([
+'topicsMinimized',
+]),
 
-  methods: {
-  selectQuestion (q) {
-  this.selectedQuestion = q;
-  },
+methods: {
+selectQuestion (q) {
+this.selectedQuestion = q;
+},
 
-  go () {
-  const s = this.selectedQuestion;
-  r.push('/' + s.a + '/' + _.kebabCase(s.m));
-  }
-  }
+go () {
+const t = this.selectedTopic;
+this.$store.commit('setState', { area: t.area, metric: 
_.kebabCase(t.metric) });
+},
+
+select () {
+if (this.$refs.searchResults) {
+this.$refs.searchResults.selectHighlighted();
+}
+},
+

[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Filter banners sample_rate = Infinity from Druid

2017-10-06 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/382764 )

Change subject: Filter banners sample_rate = Infinity from Druid
..


Filter banners sample_rate = Infinity from Druid

Druid fails to index numbers having value Infinity.
We have experienced such a value in sample_rate in the banners
dataset. This patch filters such rows out of the dataset before
indexing it to druid.

Bug: T175248
Change-Id: I60eb013b34815f98f1474775124ae11484dfeddb
---
M oozie/banner_activity/druid/daily/generate_daily_druid_banner_activity.hql
1 file changed, 3 insertions(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git 
a/oozie/banner_activity/druid/daily/generate_daily_druid_banner_activity.hql 
b/oozie/banner_activity/druid/daily/generate_daily_druid_banner_activity.hql
index d9ceb38..1d547a7 100644
--- a/oozie/banner_activity/druid/daily/generate_daily_druid_banner_activity.hql
+++ b/oozie/banner_activity/druid/daily/generate_daily_druid_banner_activity.hql
@@ -67,6 +67,9 @@
 AND uri_path = '/beacon/impression'
 AND agent_type = 'user'
 AND uri_param_value('debug', uri_query) = 'false'
+-- sample_rate can be infinity, leading to Druid indexation failing.
+-- We remove those rows from the data
+AND cast(uri_param_value('recordImpressionSampleRate', uri_query) AS 
float) != 'Infinity'
 -- TODO: add once added to webrequest
 -- AND x_analytics_map['proxy'] IS NULL
 GROUP BY

-- 
To view, visit https://gerrit.wikimedia.org/r/382764
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I60eb013b34815f98f1474775124ae11484dfeddb
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Joal 
Gerrit-Reviewer: Joal 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: Nuria 
Gerrit-Reviewer: Ottomata 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Correct bugs in mediawiki_history scripts

2017-10-06 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/382733 )

Change subject: Correct bugs in mediawiki_history scripts
..


Correct bugs in mediawiki_history scripts

A bug was introduced in mediawiki-history creation
schema, and another one in mediawiki-history druid
loading job.
This patch corrects both.

Change-Id: I4db0a630b3a0e7dc13c4f18158ef1b0210b447a0
---
M hive/mediawiki/history/create_mediawiki_history_table.hql
M oozie/mediawiki/history/druid/generate_json_mediawiki_history.hql
2 files changed, 17 insertions(+), 7 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/hive/mediawiki/history/create_mediawiki_history_table.hql 
b/hive/mediawiki/history/create_mediawiki_history_table.hql
index 74e9e5d..f707b26 100644
--- a/hive/mediawiki/history/create_mediawiki_history_table.hql
+++ b/hive/mediawiki/history/create_mediawiki_history_table.hql
@@ -1,5 +1,10 @@
 -- Creates table statement for mediawiki_history table.
 --
+-- WARNING: Timestamp fields are commented in that files
+-- because our version of hive doesn't support them.
+-- Waiting for us to upgrade to hive 1.2 or higher
+-- to update the fields.
+--
 -- Parameters:
 -- 
 --
@@ -12,7 +17,8 @@
   `wiki_db`   stringCOMMENT 
'enwiki, dewiki, eswiktionary, etc.',
   `event_entity`  stringCOMMENT 
'revision, user or page',
   `event_type`stringCOMMENT 
'create, move, delete, etc.  Detailed explanation in the docs under 
#Event_types',
-  `event_timestamp`   timestamp COMMENT 'When 
this event ocurred',
+  `event_timestamp`   stringCOMMENT 'When 
this event ocurred',
+  --`event_timestamp`   timestamp COMMENT 
'When this event ocurred',
   `event_comment` stringCOMMENT 
'Comment related to this event, sourced from log_comment, rev_comment, etc.',
   `event_user_id` bigintCOMMENT 'Id of 
the user that caused the event',
   `event_user_text`   stringCOMMENT 
'Historical text of the user that caused the event',
@@ -26,7 +32,8 @@
   `event_user_is_created_by_peer` boolean   COMMENT 
'Whether the event_user account was created by another user',
   `event_user_is_anonymous`   boolean   COMMENT 
'Whether the event_user is not registered',
   `event_user_is_bot_by_name` boolean   COMMENT 
'Whether the event_user\'s name matches patterns we use to identify bots',
-  `event_user_creation_timestamp` timestamp COMMENT 
'Registration timestamp of the user that caused the event',
+  --`event_user_creation_timestamp` timestamp COMMENT 
'Registration timestamp of the user that caused the event',
+  `event_user_creation_timestamp` stringCOMMENT 
'Registration timestamp of the user that caused the event',
   `event_user_revision_count` bigintCOMMENT 
'Cumulative revision count per user for the current event_user_id (only 
available in revision-create events so far)',
   `event_user_seconds_since_previous_revision`bigintCOMMENT 'In 
revision events: seconds elapsed since the previous revision made by the 
current event_user_id (only available in revision-create events so far)',
 
@@ -38,7 +45,8 @@
   `page_namespace_latest` int   COMMENT 'In 
revision/page events: current namespace of the page',
   `page_namespace_is_content_latest`  boolean   COMMENT 'In 
revision/page events: current namespace of the page is categorized as content',
   `page_is_redirect_latest`   boolean   COMMENT 'In 
revision/page events: whether the page is currently a redirect',
-  `page_creation_timestamp`   timestamp COMMENT 'In 
revision/page events: creation timestamp of the page',
+  --`page_creation_timestamp`   timestamp COMMENT 'In 
revision/page events: creation timestamp of the page',
+  `page_creation_timestamp`   stringCOMMENT 'In 
revision/page events: creation timestamp of the page',
   `page_revision_count`   bigintCOMMENT 'In 
revision/page events: Cumulative revision count per page for the current 
page_id (only available in revision-create events so far)',
   `page_seconds_since_previous_revision`  bigintCOMMENT 'In 
revision/page events: seconds elapsed since the previous revision made on the 
current page_id (only available in revision-create events so far)',
 
@@ -54,7 +62,8 @@
   `user_is_created_by_peer`  

[MediaWiki-commits] [Gerrit] analytics/wikistats2[master]: Implement Topic Selector

2017-10-05 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/382636 )

Change subject: Implement Topic Selector
..

Implement Topic Selector

The topic selector reuses the same search-results component built for
the wiki explorer.  It also adds a bit of fancy animation to make it a
reassuring solid part of the interface, especially for users that are
new to wikistats.

Bug: T167676
Change-Id: Ia75f5a0e01304d09359bad1de3ef907a97e5d2ea
---
M src/App.vue
M src/components/TopicExplorer.vue
M src/config.js
M src/store/index.js
4 files changed, 200 insertions(+), 166 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikistats2 
refs/changes/36/382636/1

diff --git a/src/App.vue b/src/App.vue
index 36bb845..2d3f91f 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -3,8 +3,8 @@
 
 
 
-
-
+
+
 
 
 
@@ -44,6 +44,7 @@
 computed: mapState([
 'project',
 'mainComponent',
+'topicsMinimized',
 ]),
 };
 
@@ -58,11 +59,11 @@
 .ui.top.attached.clearing.segment {
 border-bottom: 4px solid #4A4A4A;
 padding: 35px 44px;
+/* has to have room under it to fit topic selector animation */
+z-index: 10;
 }
 .ui.attached.content.segment {
 background-color: #F6F6F6;
-/* with topic explorer: padding: 53px 32px 27px 32px; */
-/* without topic explorer: */
 padding: 2px 32px 27px 24px;
 }
 .ui.attached.language.segment {
diff --git a/src/components/TopicExplorer.vue b/src/components/TopicExplorer.vue
index f048b61..69dbb59 100644
--- a/src/components/TopicExplorer.vue
+++ b/src/components/TopicExplorer.vue
@@ -1,157 +1,200 @@
 
-
-
-
-
-
-
-Explore Topics
-
-
-
-
+
+
+
+
 
 Explore Topics
-
-Find questions 
you are interested in and click Go for the answers
-
-{{selectedQuestion.q}}
-metric: {{selectedQuestion.m}}
-
-
-Contributing
-
-{{q.q}} metric: {{q.m}}
-
+
+
+
+
 
-Reading
-
-{{q.q}} metric: {{q.m}}
-
+
+Explore Topics
 
-Content
-
-{{q.q}} metric: {{q.m}}
-
+
+
+
 
-More
-
-{{q.q}} metric: {{q.m}}
-
-
-
+
 
-Go
-
-
-
-
-
+
 
+
+
+
+
+
 
 
 
 
 
-import r from '../router/index'
+import { mapState } from 'vuex';
 import _ from '../lodash-custom-bundle';
 import config from '../config'
+import SearchResults from './widgets/SearchResults';
 
 
 export default {
-  name: 'topic-explorer',
+name: 'topic-explorer',
+components: {
+SearchResults,
+},
 
-  data () {
-  return {
-  minimized: true,
+data () {
+return {
+selectedTopic: null,
+searchBoxEl: null,
+searchData: [],
+searchDisplay: '',
+showResults: false,
+};
+},
 
-  selectedQuestion: null
-  }
-  },
+mounted () {
+this.searchData = config.questions;
+},
 
-  computed: {
-  contributingQuestions: function () {
-  return config.questions.filter((m) => m.f && m.a === 'contributing');
-  },
-  readingQuestions: function () {
-  return config.questions.filter((m) => m.f && m.a === 'reading');
-  },
-  contentQuestions: function () {
-  return config.questions.filter((m) => m.f && m.a === 'content');
-  },
-  moreQuestions: function () {
-  return config.questions.filter((m) => !m.f);
-  }
-  },
+computed: mapState([
+'topicsMinimized',
+]),
 
-  methods: {
-  selectQuestion (q) {
-  this.selectedQuestion = q;
-  },
+methods: {
+selectQuestion (q) {
+this.selectedQuestion = q;
+},
 
-  go () {
-  const s = this.selectedQuestion;
-  r.push('/' + s.a + '/' + _.kebabCase(s.m));
-  }
-  }
+go () {
+const t = this.selectedTopic;
+this.$store.commit('setState', { area: t.area, metric: 
_.kebabCase(t.metric) });
+},
+
+select () {
+if (this.$refs.searchResults) {
+this.$refs.searchResults.selectHighlighted();
+}
+},
+   

[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Add am.wikimedia to the whitelist

2017-10-05 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/382471 )

Change subject: Add am.wikimedia to the whitelist
..


Add am.wikimedia to the whitelist

Change-Id: Ifb19d2d992a65b9d5785f3846b894dd325ea9b26
---
M static_data/pageview/whitelist/whitelist.tsv
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/static_data/pageview/whitelist/whitelist.tsv 
b/static_data/pageview/whitelist/whitelist.tsv
index e98b452..5988e91 100644
--- a/static_data/pageview/whitelist/whitelist.tsv
+++ b/static_data/pageview/whitelist/whitelist.tsv
@@ -16,6 +16,7 @@
 projectals.wikipedia   2015-10-12 00:00:00
 projectals.wikiquote   2015-10-12 00:00:00
 projectals.wiktionary  2015-10-12 00:00:00
+projectam.wikimedia2017-10-05 00:00:00
 projectam.wikipedia2015-10-12 00:00:00
 projectam.wikiquote2015-10-12 00:00:00
 projectam.wiktionary   2015-10-12 00:00:00

-- 
To view, visit https://gerrit.wikimedia.org/r/382471
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifb19d2d992a65b9d5785f3846b894dd325ea9b26
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Add am.wikimedia to the whitelist

2017-10-05 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/382471 )

Change subject: Add am.wikimedia to the whitelist
..

Add am.wikimedia to the whitelist

Change-Id: Ifb19d2d992a65b9d5785f3846b894dd325ea9b26
---
M static_data/pageview/whitelist/whitelist.tsv
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery 
refs/changes/71/382471/1

diff --git a/static_data/pageview/whitelist/whitelist.tsv 
b/static_data/pageview/whitelist/whitelist.tsv
index e98b452..5988e91 100644
--- a/static_data/pageview/whitelist/whitelist.tsv
+++ b/static_data/pageview/whitelist/whitelist.tsv
@@ -16,6 +16,7 @@
 projectals.wikipedia   2015-10-12 00:00:00
 projectals.wikiquote   2015-10-12 00:00:00
 projectals.wiktionary  2015-10-12 00:00:00
+projectam.wikimedia2017-10-05 00:00:00
 projectam.wikipedia2015-10-12 00:00:00
 projectam.wikiquote2015-10-12 00:00:00
 projectam.wiktionary   2015-10-12 00:00:00

-- 
To view, visit https://gerrit.wikimedia.org/r/382471
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifb19d2d992a65b9d5785f3846b894dd325ea9b26
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: [WIP] Add druid options to AQS config

2017-09-22 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/379730 )

Change subject: [WIP] Add druid options to AQS config
..

[WIP] Add druid options to AQS config

Questions before merging:
* better way to list the druid hosts instead of hard-coding them?
* where/how do I make the passwords to include with ::passwords::aqs::..

Change-Id: I5c78ce68e8351eb0c379e6f9d0109c3388b757a7
---
M modules/aqs/manifests/init.pp
M modules/aqs/templates/config.yaml.erb
2 files changed, 26 insertions(+), 10 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/30/379730/1

diff --git a/modules/aqs/manifests/init.pp b/modules/aqs/manifests/init.pp
index 49590a8..501ef87 100644
--- a/modules/aqs/manifests/init.pp
+++ b/modules/aqs/manifests/init.pp
@@ -43,22 +43,30 @@
 # [*statsd_port*]
 #   statsd port. Default: 8125
 #
+include ::passwords::aqs::druid_http_auth
 class aqs(
 $cassandra_user = 'cassandra',
 $cassandra_password = 'cassandra',
 $seeds  = [$::ipaddress],
 $cassandra_default_consistency = 'localQuorum',
-$cassandra_local_dc = 'datacenter1',
-$cassandra_datacenters = [ 'datacenter1' ],
-$port   = 7232,
-$salt_key   = 'secretkey',
-$page_size  = 250,
-$logstash_host  = 'localhost',
-$logstash_port  = 12201,
-$logging_level  = 'warn',
-$statsd_host= 'localhost',
-$statsd_port= 8125,
+$cassandra_local_dc= 'datacenter1',
+$cassandra_datacenters = [ 'datacenter1' ],
+$port  = 7232,
+$salt_key  = 'secretkey',
+$page_size = 250,
+$logstash_host = 'localhost',
+$logstash_port = 12201,
+$logging_level = 'warn',
+$statsd_host   = 'localhost',
+$statsd_port   = 8125,
+$druid_hosts   = [ 'druid1001.eqiad.wmnet', 
'druid1001.eqiad.wmnet', 'druid1001.eqiad.wmnet' ],
+$druid_scheme  = 'https',
+$druid_port= 8082,
+$druid_query_path  = '/druid/v2/',
+$druid_http_auth_user  = $::passwords::aqs::druid_http_auth::user,
+$druid_http_auth_password  = 
$::passwords::aqs::druid_http_auth::password,
 ) {
+# NOTE: didn't know how to make the ::passwords::aqs values, they're in 
the private repo, right?
 
 service::node { 'aqs':
 port=> $port,
diff --git a/modules/aqs/templates/config.yaml.erb 
b/modules/aqs/templates/config.yaml.erb
index 2803fe3..556ff6c 100644
--- a/modules/aqs/templates/config.yaml.erb
+++ b/modules/aqs/templates/config.yaml.erb
@@ -18,6 +18,14 @@
   - name: default.group.local
 domains: /./
 
+  druid:
+  hosts: <%= Array(@druid_hosts).join(',') %>
+  scheme: <%= @druid_scheme %>
+  port: <%= @druid_port %>
+  query_path: <%= @druid_query_path %>
+  http_auth_user: <%= @druid_http_auth_user %>
+  http_auth_password: <%= @druid_http_auth_password %>
+
 # Swagger spec root.
 spec: 
   title: "The Analytics RESTBase root"

-- 
To view, visit https://gerrit.wikimedia.org/r/379730
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5c78ce68e8351eb0c379e6f9d0109c3388b757a7
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Try to close the sessions while validating

2017-08-10 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/371218 )

Change subject: Try to close the sessions while validating
..


Try to close the sessions while validating

Change-Id: Ia89de02d748e34cb65a1911b4243c78b5e6abf4a
---
M wikimetrics/models/validate_cohort.py
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/wikimetrics/models/validate_cohort.py 
b/wikimetrics/models/validate_cohort.py
index bfc1a79..546e0f7 100644
--- a/wikimetrics/models/validate_cohort.py
+++ b/wikimetrics/models/validate_cohort.py
@@ -243,6 +243,7 @@
 else:
 clause = MediawikiUser.user_name.in_(users_dict.keys())
 matches = session.query(MediawikiUser).filter(clause).all()
+session.close()
 
 # no need to roll back session because it's just a query
 except OperationalError:

-- 
To view, visit https://gerrit.wikimedia.org/r/371218
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia89de02d748e34cb65a1911b4243c78b5e6abf4a
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Try to close the sessions while validating

2017-08-10 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/371218 )

Change subject: Try to close the sessions while validating
..

Try to close the sessions while validating

Change-Id: Ia89de02d748e34cb65a1911b4243c78b5e6abf4a
---
M wikimetrics/models/validate_cohort.py
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikimetrics 
refs/changes/18/371218/1

diff --git a/wikimetrics/models/validate_cohort.py 
b/wikimetrics/models/validate_cohort.py
index bfc1a79..546e0f7 100644
--- a/wikimetrics/models/validate_cohort.py
+++ b/wikimetrics/models/validate_cohort.py
@@ -243,6 +243,7 @@
 else:
 clause = MediawikiUser.user_name.in_(users_dict.keys())
 matches = session.query(MediawikiUser).filter(clause).all()
+session.close()
 
 # no need to roll back session because it's just a query
 except OperationalError:

-- 
To view, visit https://gerrit.wikimedia.org/r/371218
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia89de02d748e34cb65a1911b4243c78b5e6abf4a
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Fix sqlalchemy version

2017-08-10 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/371216 )

Change subject: Fix sqlalchemy version
..


Fix sqlalchemy version

Change-Id: Id9cf5095bfc065629045728d80fb8a0fd7905bf8
---
M requirements.txt
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/requirements.txt b/requirements.txt
index d30d6e2..dad35de 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,5 +1,5 @@
 distribute>=0.6.28
-sqlalchemy>=0.8.1
+sqlalchemy>=0.8.1,<1.0
 mysql-python==1.2.5
 flask==0.10.1
 flask-login==0.2.4

-- 
To view, visit https://gerrit.wikimedia.org/r/371216
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id9cf5095bfc065629045728d80fb8a0fd7905bf8
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Fix sqlalchemy version

2017-08-10 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/371216 )

Change subject: Fix sqlalchemy version
..

Fix sqlalchemy version

Change-Id: Id9cf5095bfc065629045728d80fb8a0fd7905bf8
---
M requirements.txt
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikimetrics 
refs/changes/16/371216/1

diff --git a/requirements.txt b/requirements.txt
index d30d6e2..dad35de 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,5 +1,5 @@
 distribute>=0.6.28
-sqlalchemy>=0.8.1
+sqlalchemy>=0.8.1,<1.0
 mysql-python==1.2.5
 flask==0.10.1
 flask-login==0.2.4

-- 
To view, visit https://gerrit.wikimedia.org/r/371216
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id9cf5095bfc065629045728d80fb8a0fd7905bf8
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Fix versions of celery

2017-08-10 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/371214 )

Change subject: Fix versions of celery
..


Fix versions of celery

Change-Id: I0fa5612664d054e6b181a24a3fc01be5b533749b
---
M requirements.txt
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/requirements.txt b/requirements.txt
index 8154efe..d30d6e2 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -6,8 +6,8 @@
 flask-oauth==0.12
 blinker==1.3
 wtforms==1.0.4
-celery~=3.0
-celery-with-redis~=3.0
+celery>=3.0,<4.0
+celery-with-redis>=3.0,<4.0
 PyYAML==3.10
 python-dateutil==2.2
 alembic==0.6.4

-- 
To view, visit https://gerrit.wikimedia.org/r/371214
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I0fa5612664d054e6b181a24a3fc01be5b533749b
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Fix versions of celery

2017-08-10 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/371214 )

Change subject: Fix versions of celery
..

Fix versions of celery

Change-Id: I0fa5612664d054e6b181a24a3fc01be5b533749b
---
M requirements.txt
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikimetrics 
refs/changes/14/371214/1

diff --git a/requirements.txt b/requirements.txt
index 8154efe..d30d6e2 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -6,8 +6,8 @@
 flask-oauth==0.12
 blinker==1.3
 wtforms==1.0.4
-celery~=3.0
-celery-with-redis~=3.0
+celery>=3.0,<4.0
+celery-with-redis>=3.0,<4.0
 PyYAML==3.10
 python-dateutil==2.2
 alembic==0.6.4

-- 
To view, visit https://gerrit.wikimedia.org/r/371214
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0fa5612664d054e6b181a24a3fc01be5b533749b
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Fix versions of celery

2017-08-10 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/371213 )

Change subject: Fix versions of celery
..


Fix versions of celery

Change-Id: Ib23d9709fc7257ad1512d2125cb22fdc88ebc79b
---
M requirements.txt
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/requirements.txt b/requirements.txt
index baea2bf..8154efe 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -6,8 +6,8 @@
 flask-oauth==0.12
 blinker==1.3
 wtforms==1.0.4
-celery>=3.0
-celery-with-redis>=3.0
+celery~=3.0
+celery-with-redis~=3.0
 PyYAML==3.10
 python-dateutil==2.2
 alembic==0.6.4

-- 
To view, visit https://gerrit.wikimedia.org/r/371213
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib23d9709fc7257ad1512d2125cb22fdc88ebc79b
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Fix versions of celery

2017-08-10 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/371213 )

Change subject: Fix versions of celery
..

Fix versions of celery

Change-Id: Ib23d9709fc7257ad1512d2125cb22fdc88ebc79b
---
M requirements.txt
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikimetrics 
refs/changes/13/371213/1

diff --git a/requirements.txt b/requirements.txt
index baea2bf..8154efe 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -6,8 +6,8 @@
 flask-oauth==0.12
 blinker==1.3
 wtforms==1.0.4
-celery>=3.0
-celery-with-redis>=3.0
+celery~=3.0
+celery-with-redis~=3.0
 PyYAML==3.10
 python-dateutil==2.2
 alembic==0.6.4

-- 
To view, visit https://gerrit.wikimedia.org/r/371213
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib23d9709fc7257ad1512d2125cb22fdc88ebc79b
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Add more logging to validation errors

2017-08-10 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/371212 )

Change subject: Add more logging to validation errors
..

Add more logging to validation errors

Change-Id: Ia7d5ae6eee034e1f10059644ce189cd105de9c60
---
M wikimetrics/models/validate_cohort.py
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wikimetrics 
refs/changes/12/371212/1

diff --git a/wikimetrics/models/validate_cohort.py 
b/wikimetrics/models/validate_cohort.py
index e124eef..bfc1a79 100644
--- a/wikimetrics/models/validate_cohort.py
+++ b/wikimetrics/models/validate_cohort.py
@@ -250,6 +250,7 @@
 # as it can be recovered, no need to reraise the error
 # but all users have to be marked as invalid
 msg = traceback.format_exc()
+task_logger.warning('While validating users in ' + project)
 task_logger.warning(msg)
 matches = []
 valid_project = False

-- 
To view, visit https://gerrit.wikimedia.org/r/371212
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia7d5ae6eee034e1f10059644ce189cd105de9c60
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/wikimetrics[master]: Add more logging to validation errors

2017-08-10 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/371212 )

Change subject: Add more logging to validation errors
..


Add more logging to validation errors

Change-Id: Ia7d5ae6eee034e1f10059644ce189cd105de9c60
---
M wikimetrics/models/validate_cohort.py
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/wikimetrics/models/validate_cohort.py 
b/wikimetrics/models/validate_cohort.py
index e124eef..bfc1a79 100644
--- a/wikimetrics/models/validate_cohort.py
+++ b/wikimetrics/models/validate_cohort.py
@@ -250,6 +250,7 @@
 # as it can be recovered, no need to reraise the error
 # but all users have to be marked as invalid
 msg = traceback.format_exc()
+task_logger.warning('While validating users in ' + project)
 task_logger.warning(msg)
 matches = []
 valid_project = False

-- 
To view, visit https://gerrit.wikimedia.org/r/371212
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia7d5ae6eee034e1f10059644ce189cd105de9c60
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wikimetrics
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Enable all wikis to sqoop from labs

2017-08-08 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/369409 )

Change subject: Enable all wikis to sqoop from labs
..


Enable all wikis to sqoop from labs

According to https://phabricator.wikimedia.org/T165233#3505597 all wikis
are now available in labs.  This change enables them to be sqooped with
the monthly sqoop job.

Bug: T165233
Change-Id: I01a9237cbbe868671092e40d480082ea1f5880f3
---
M static_data/mediawiki/grouped_wikis/labs_grouped_wikis.csv
1 file changed, 12 insertions(+), 14 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/static_data/mediawiki/grouped_wikis/labs_grouped_wikis.csv 
b/static_data/mediawiki/grouped_wikis/labs_grouped_wikis.csv
index a0f2f56..01c3b89 100644
--- a/static_data/mediawiki/grouped_wikis/labs_grouped_wikis.csv
+++ b/static_data/mediawiki/grouped_wikis/labs_grouped_wikis.csv
@@ -7,7 +7,7 @@
 itwiki,5,76140013
 ruwiki,5,73060171
 frwiki,6,120965605
-# eswiki,6,72672655
+eswiki,6,72672655
 nlwiki,7,43853157
 ptwiki,7,42513795
 plwiki,7,42509616
@@ -16,25 +16,25 @@
 svwiki,8,35052902
 shwiki,8,33506101
 mgwiktionary,9,20228737
-# frwiktionary,9,19881338
-# viwiki,9,18401564
+frwiktionary,9,19881338
+viwiki,9,18401564
 nowiki,9,15727221
 trwiki,9,15595001
-# huwiki,10,15247992
-# metawiki,10,15182371
+huwiki,10,15247992
+metawiki,10,15182371
 fiwiki,10,15027822
-# hewiki,10,14840945
-# ukwiki,10,14787995
-# arwiki,10,14550135
-# fawiki,11,14071138
-# cawiki,11,13685020
+hewiki,10,14840945
+ukwiki,10,14787995
+arwiki,10,14550135
+fawiki,11,14071138
+cawiki,11,13685020
 cswiki,11,13115176
-# kowiki,11,12427987
+kowiki,11,12427987
 srwiki,11,11368979
 idwiki,11,11033502
 cebwiki,11,9638105
 dawiki,11,8194270
-# rowiki,11,8167548
+rowiki,11,8167548
 bgwiki,11,6954448
 ruwiktionary,11,6439760
 warwiki,11,6122929
@@ -734,5 +734,3 @@
 arwikimedia,13,224
 cnwikimedia,13,155
 loginwiki,13,17
-# labtestwiki,13,0
-# labswiki,13,0

-- 
To view, visit https://gerrit.wikimedia.org/r/369409
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I01a9237cbbe868671092e40d480082ea1f5880f3
Gerrit-PatchSet: 2
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Joal 
Gerrit-Reviewer: Milimetric 
Gerrit-Reviewer: Ottomata 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: [WIP] Don't merge this

2017-08-05 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/370322 )

Change subject: [WIP] Don't merge this
..

[WIP] Don't merge this

This change that allows us to run one-off _private snapshots more
easily.  I'm not sure whether you can set private_suffix to an empty
string, and I haven't tested that yet.  I'm just going to use this
change to run the 2017-07_private snapshot, and we can decide what to do
when Joseph's back.

Change-Id: Ib63f27430c15872de1966fa51728211dfe6b3486
---
M oozie/mediawiki/history/datasets.xml
M oozie/mediawiki/history/datasets_raw.xml
M oozie/mediawiki/history/denormalize/coordinator.properties
M oozie/mediawiki/history/denormalize/coordinator.xml
4 files changed, 18 insertions(+), 16 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery 
refs/changes/22/370322/1

diff --git a/oozie/mediawiki/history/datasets.xml 
b/oozie/mediawiki/history/datasets.xml
index c2232d8..08bab57 100644
--- a/oozie/mediawiki/history/datasets.xml
+++ b/oozie/mediawiki/history/datasets.xml
@@ -22,7 +22,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_directory}/user_history/snapshot=${YEAR}-${MONTH}
+
${mw_directory}/user_history/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
@@ -30,7 +30,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_directory}/page_history/snapshot=${YEAR}-${MONTH}
+
${mw_directory}/page_history/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
@@ -38,7 +38,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_directory}/history/snapshot=${YEAR}-${MONTH}
+
${mw_directory}/history/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
@@ -48,7 +48,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_directory}/user_history/snapshot=${YEAR}-${MONTH}
+
${mw_directory}/user_history/snapshot=${YEAR}-${MONTH}${private_suffix}
 _PARTITIONED
 
 
@@ -56,7 +56,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_directory}/page_history/snapshot=${YEAR}-${MONTH}
+
${mw_directory}/page_history/snapshot=${YEAR}-${MONTH}${private_suffix}
 _PARTITIONED
 
 
@@ -64,7 +64,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_directory}/history/snapshot=${YEAR}-${MONTH}
+
${mw_directory}/history/snapshot=${YEAR}-${MONTH}${private_suffix}
 _PARTITIONED
 
 
@@ -73,7 +73,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_directory}/metrics/snapshot=${YEAR}-${MONTH}
+
${mw_directory}/metrics/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
diff --git a/oozie/mediawiki/history/datasets_raw.xml 
b/oozie/mediawiki/history/datasets_raw.xml
index a672a0e..931d5e3 100644
--- a/oozie/mediawiki/history/datasets_raw.xml
+++ b/oozie/mediawiki/history/datasets_raw.xml
@@ -25,7 +25,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_raw_directory}/tables/archive/snapshot=${YEAR}-${MONTH}
+
${mw_raw_directory}/tables/archive/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
@@ -33,7 +33,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_raw_directory}/tables/logging/snapshot=${YEAR}-${MONTH}
+
${mw_raw_directory}/tables/logging/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
@@ -41,7 +41,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_raw_directory}/tables/page/snapshot=${YEAR}-${MONTH}
+
${mw_raw_directory}/tables/page/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
@@ -49,7 +49,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
  timezone="Universal">
-
${mw_raw_directory}/tables/revision/snapshot=${YEAR}-${MONTH}
+
${mw_raw_directory}/tables/revision/snapshot=${YEAR}-${MONTH}${private_suffix}
 _SUCCESS
 
 
@@ -57,7 +57,7 @@
  frequency="${coord:months(1)}"
  initial-instance="${start_time}"
 

[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Disable nonexistent wikis

2017-08-05 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/370320 )

Change subject: Disable nonexistent wikis
..


Disable nonexistent wikis

Change-Id: I0fa4d90fe4a5a70e708f18f4b2eec5a49a8434f9
---
M static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv 
b/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
index ea96b33..1921782 100644
--- a/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
+++ b/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
@@ -734,5 +734,5 @@
 arwikimedia,13,224
 cnwikimedia,13,155
 loginwiki,13,17
-labtestwiki,13,0
-labswiki,13,0
+# labtestwiki,13,0
+# labswiki,13,0

-- 
To view, visit https://gerrit.wikimedia.org/r/370320
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I0fa4d90fe4a5a70e708f18f4b2eec5a49a8434f9
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics/refinery[master]: Disable nonexistent wikis

2017-08-05 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/370320 )

Change subject: Disable nonexistent wikis
..

Disable nonexistent wikis

Change-Id: I0fa4d90fe4a5a70e708f18f4b2eec5a49a8434f9
---
M static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery 
refs/changes/20/370320/1

diff --git a/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv 
b/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
index ea96b33..1921782 100644
--- a/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
+++ b/static_data/mediawiki/grouped_wikis/prod_grouped_wikis.csv
@@ -734,5 +734,5 @@
 arwikimedia,13,224
 cnwikimedia,13,155
 loginwiki,13,17
-labtestwiki,13,0
-labswiki,13,0
+# labtestwiki,13,0
+# labswiki,13,0

-- 
To view, visit https://gerrit.wikimedia.org/r/370320
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0fa4d90fe4a5a70e708f18f4b2eec5a49a8434f9
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...scap[master]: Change stat1002 to stat1005

2017-08-03 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/370008 )

Change subject: Change stat1002 to stat1005
..

Change stat1002 to stat1005

Change-Id: Ib033248e6e2411bafd7e4405104575d773950b5a
---
M target-canary
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/refinery/scap 
refs/changes/08/370008/1

diff --git a/target-canary b/target-canary
index 83c70f3..ec079aa 100644
--- a/target-canary
+++ b/target-canary
@@ -1 +1 @@
-stat1002.eqiad.wmnet
\ No newline at end of file
+stat1005.eqiad.wmnet

-- 
To view, visit https://gerrit.wikimedia.org/r/370008
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib033248e6e2411bafd7e4405104575d773950b5a
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery/scap
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...scap[master]: Change stat1002 to stat1005

2017-08-03 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/370008 )

Change subject: Change stat1002 to stat1005
..


Change stat1002 to stat1005

Change-Id: Ib033248e6e2411bafd7e4405104575d773950b5a
---
M target-canary
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Milimetric: Verified; Looks good to me, approved



diff --git a/target-canary b/target-canary
index 83c70f3..ec079aa 100644
--- a/target-canary
+++ b/target-canary
@@ -1 +1 @@
-stat1002.eqiad.wmnet
\ No newline at end of file
+stat1005.eqiad.wmnet

-- 
To view, visit https://gerrit.wikimedia.org/r/370008
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib033248e6e2411bafd7e4405104575d773950b5a
Gerrit-PatchSet: 1
Gerrit-Project: analytics/refinery/scap
Gerrit-Branch: master
Gerrit-Owner: Milimetric 
Gerrit-Reviewer: Milimetric 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


  1   2   3   4   5   6   7   8   9   10   >