| ... |
... |
@@ -149,12 +149,16 @@ git log --format='%s' $git_begin..$git_end \ |
|
149
|
149
|
printf ",\n" >> "${git_json}"
|
|
150
|
150
|
fi
|
|
151
|
151
|
|
|
152
|
|
- component="Unknown"
|
|
153
|
|
- if [[ "${summary}" =~ webcompat ]]; then
|
|
154
|
|
- component="Web Compatibility"
|
|
|
152
|
+ product="Unknown"
|
|
|
153
|
+ # Bugs that include webcompat-reviewers and no other additional -reviewers
|
|
|
154
|
+ # from other teams are *likely* in the Web Compatibility component. But they
|
|
|
155
|
+ # won't show in the bugzilla query because the component doesn't tend to
|
|
|
156
|
+ # have any set milestones.
|
|
|
157
|
+ if [[ "${summary}" =~ r=.*webcompat-reviewers && ! "${summary}" =~ r=.*-reviewers.*-reviewers ]]; then
|
|
|
158
|
+ product="Web Compatibility"
|
|
155
|
159
|
fi
|
|
156
|
160
|
|
|
157
|
|
- printf " { \"component\": \"%s\", \"id\": %s, \"summary\": \"%s\" }" "${component}" ${id} "${summary}" >> "${git_json}"
|
|
|
161
|
+ printf " { \"product\": \"%s\", \"component\": \"Unknown\", \"id\": %s, \"summary\": \"%s\" }" "${product}" ${id} "${summary}" >> "${git_json}"
|
|
158
|
162
|
done
|
|
159
|
163
|
printf "\n]\n" >> "${git_json}"
|
|
160
|
164
|
|
| ... |
... |
@@ -170,7 +174,7 @@ printf "\n]\n" >> "${git_json}" |
|
170
|
174
|
query_tail="&f1=product&n1=1&o1=anyexact&v1=Thunderbird%2CCalendar%2CChat%20Core%2CMailNews%20Core&f2=target_milestone&o2=substring&v2=${firefox_version}&limit=0"
|
|
171
|
175
|
|
|
172
|
176
|
bugzilla_query="https://bugzilla.mozilla.org/buglist.cgi?${query_tail}"
|
|
173
|
|
-bugzilla_json_query="https://bugzilla.mozilla.org/rest/bug?include_fields=id,component,summary${query_tail}"
|
|
|
177
|
+bugzilla_json_query="https://bugzilla.mozilla.org/rest/bug?include_fields=id,product,component,summary${query_tail}"
|
|
174
|
178
|
|
|
175
|
179
|
wget "${bugzilla_json_query}" -O ${bugzilla_json}
|
|
176
|
180
|
|
| ... |
... |
@@ -185,10 +189,10 @@ jq -s '[ (.[0].bugs)[], (.[1])[] ] | group_by(.id) | map(.[0])' "${bugzilla_json |
|
185
|
189
|
# Generate Triage CSV
|
|
186
|
190
|
#
|
|
187
|
191
|
|
|
188
|
|
-echo "\"Review\",,\"Bugzilla Component\",\"Bugzilla Bug\""
|
|
|
192
|
+echo "\"Review\",,\"Product :: Component\",\"Bugzilla Bug\""
|
|
189
|
193
|
|
|
190
|
|
-jq '. | sort_by([.component, .id])[] | "\(.id)|\(.component)|\(.summary)"' ${union_json} \
|
|
191
|
|
-| while IFS='|' read -r id component summary; do
|
|
|
194
|
+jq '. | sort_by([.product, .component, .id])[] | "\(.id)|\(.product)|\(.component)|\(.summary)"' ${union_json} \
|
|
|
195
|
+| while IFS='|' read -r id product component summary; do
|
|
192
|
196
|
|
|
193
|
197
|
# bugzilla info
|
|
194
|
198
|
id="${id:1}"
|
| ... |
... |
@@ -219,7 +223,7 @@ jq '. | sort_by([.component, .id])[] | "\(.id)|\(.component)|\(.summary)"' ${uni |
|
219
|
223
|
echoerr "Skipped Bugzilla ${id}: ${summary_short}"
|
|
220
|
224
|
else
|
|
221
|
225
|
csv_summary=$(csv_escape "${summary}")
|
|
222
|
|
- csv_component=$(csv_escape "${component}")
|
|
|
226
|
+ csv_product_component=$(csv_escape "${product} :: ${component}")
|
|
223
|
227
|
|
|
224
|
228
|
# parent issue
|
|
225
|
229
|
bugzilla_url="https://bugzilla.mozilla.org/show_bug.cgi?id=${id}"
|
| ... |
... |
@@ -235,7 +239,7 @@ jq '. | sort_by([.component, .id])[] | "\(.id)|\(.component)|\(.summary)"' ${uni |
|
235
|
239
|
create_issue=$(csv_escape "=HYPERLINK(\"${new_issue_url}\", \"New Issue\")")
|
|
236
|
240
|
bugzilla_link=$(csv_escape "=HYPERLINK(\"${bugzilla_url}\", \"Bugzilla ${id}: ${csv_summary}\")")
|
|
237
|
241
|
|
|
238
|
|
- echo "FALSE,\"${create_issue}\",\"${csv_component}\",\"${bugzilla_link}\","
|
|
|
242
|
+ echo "FALSE,\"${create_issue}\",\"${csv_product_component}\",\"${bugzilla_link}\","
|
|
239
|
243
|
fi
|
|
240
|
244
|
done
|
|
241
|
245
|
|